/** * Returns an array of month names. * * @return an array of month names. */ public static String[] getMonths() { return getMonths(false); }
/** * Returns an array of month names. * * @return an array of month names. */ public static String[] getMonths() { return getMonths(false); }
/** * Returns an array of month names. * * @return an array of month names. */ public static String[] getMonths() { return getMonths(false); }
/** * Constructs a panel containing two JComboBoxes (for the month and year) and a button * (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); this.monthSelector = new JComboBox(SerialDate.getMonths()); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }
/** * Constructs a panel containing two JComboBoxes (for the month and year) and a button * (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); this.monthSelector = new JComboBox(SerialDate.getMonths()); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }
/** * Constructs a panel containing two JComboBoxes (for the month and year) and a button * (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); this.monthSelector = new JComboBox(SerialDate.getMonths()); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }
/** * Constructs a panel containing two JComboBoxes (for the month and year) * and a button (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); final int minMonth = this.chosenDate.getMinimum(Calendar.MONTH); final int maxMonth = this.chosenDate.getMaximum(Calendar.MONTH); final String[] months = new String[maxMonth - minMonth + 1]; System.arraycopy(SerialDate.getMonths(), minMonth, months, 0, months.length); this.monthSelector = new JComboBox(months); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }
/** * Constructs a panel containing two JComboBoxes (for the month and year) * and a button (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); final int minMonth = this.chosenDate.getMinimum(Calendar.MONTH); final int maxMonth = this.chosenDate.getMaximum(Calendar.MONTH); final String[] months = new String[maxMonth - minMonth + 1]; System.arraycopy(SerialDate.getMonths(), minMonth, months, 0, months.length); this.monthSelector = new JComboBox(months); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }
/** * Constructs a panel containing two JComboBoxes (for the month and year) * and a button (to reset the date to TODAY). * * @return the panel. */ private JPanel constructSelectionPanel() { final JPanel p = new JPanel(); final int minMonth = this.chosenDate.getMinimum(Calendar.MONTH); final int maxMonth = this.chosenDate.getMaximum(Calendar.MONTH); final String[] months = new String[maxMonth - minMonth + 1]; System.arraycopy(SerialDate.getMonths(), minMonth, months, 0, months.length); this.monthSelector = new JComboBox(months); this.monthSelector.addActionListener(this); this.monthSelector.setActionCommand("monthSelectionChanged"); p.add(this.monthSelector); this.yearSelector = new JComboBox(getYears(0)); this.yearSelector.addActionListener(this); this.yearSelector.setActionCommand("yearSelectionChanged"); p.add(this.yearSelector); return p; }