src/share/classes/java/awt/Choice.java

Print this page
rev 10048 : 8044740: Convert all JDK versions used in @since tag to 1.n[.n] in jdk repo
Reviewed-by:

*** 66,76 **** * attributes as font size and length of items contained within * the <code>Choice</code>. * * @author Sami Shaio * @author Arthur van Hoff ! * @since JDK1.0 */ public class Choice extends Component implements ItemSelectable, Accessible { /** * The items for the <code>Choice</code>. * This can be a <code>null</code> value. --- 66,76 ---- * attributes as font size and length of items contained within * the <code>Choice</code>. * * @author Sami Shaio * @author Arthur van Hoff ! * @since 1.0 */ public class Choice extends Component implements ItemSelectable, Accessible { /** * The items for the <code>Choice</code>. * This can be a <code>null</code> value.
*** 156,166 **** /** * Returns the number of items in this <code>Choice</code> menu. * @return the number of items in this <code>Choice</code> menu * @see #getItem ! * @since JDK1.1 */ public int getItemCount() { return countItems(); } --- 156,166 ---- /** * Returns the number of items in this <code>Choice</code> menu. * @return the number of items in this <code>Choice</code> menu * @see #getItem ! * @since 1.1 */ public int getItemCount() { return countItems(); }
*** 194,204 **** /** * Adds an item to this <code>Choice</code> menu. * @param item the item to be added * @exception NullPointerException if the item's value is * <code>null</code> ! * @since JDK1.1 */ public void add(String item) { addItem(item); } --- 194,204 ---- /** * Adds an item to this <code>Choice</code> menu. * @param item the item to be added * @exception NullPointerException if the item's value is * <code>null</code> ! * @since 1.1 */ public void add(String item) { addItem(item); }
*** 289,299 **** * item remains selected (and the selected index is * updated accordingly). * @param item the item to remove from this <code>Choice</code> menu * @exception IllegalArgumentException if the item doesn't * exist in the choice menu ! * @since JDK1.1 */ public void remove(String item) { synchronized (this) { int index = pItems.indexOf(item); if (index < 0) { --- 289,299 ---- * item remains selected (and the selected index is * updated accordingly). * @param item the item to remove from this <code>Choice</code> menu * @exception IllegalArgumentException if the item doesn't * exist in the choice menu ! * @since 1.1 */ public void remove(String item) { synchronized (this) { int index = pItems.indexOf(item); if (index < 0) {
*** 317,327 **** * item remains selected (and the selected index is * updated accordingly). * @param position the position of the item * @throws IndexOutOfBoundsException if the specified * position is out of bounds ! * @since JDK1.1 */ public void remove(int position) { synchronized (this) { removeNoInvalidate(position); } --- 317,327 ---- * item remains selected (and the selected index is * updated accordingly). * @param position the position of the item * @throws IndexOutOfBoundsException if the specified * position is out of bounds ! * @since 1.1 */ public void remove(int position) { synchronized (this) { removeNoInvalidate(position); }
*** 355,365 **** /** * Removes all items from the choice menu. * @see #remove ! * @since JDK1.1 */ public void removeAll() { synchronized (this) { if (peer != null) { ((ChoicePeer)peer).removeAll(); --- 355,365 ---- /** * Removes all items from the choice menu. * @see #remove ! * @since 1.1 */ public void removeAll() { synchronized (this) { if (peer != null) { ((ChoicePeer)peer).removeAll();
*** 473,483 **** * @see #removeItemListener * @see #getItemListeners * @see #select * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener ! * @since JDK1.1 */ public synchronized void addItemListener(ItemListener l) { if (l == null) { return; } --- 473,483 ---- * @see #removeItemListener * @see #getItemListeners * @see #select * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener ! * @since 1.1 */ public synchronized void addItemListener(ItemListener l) { if (l == null) { return; }
*** 495,505 **** * @param l the item listener * @see #addItemListener * @see #getItemListeners * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener ! * @since JDK1.1 */ public synchronized void removeItemListener(ItemListener l) { if (l == null) { return; } --- 495,505 ---- * @param l the item listener * @see #addItemListener * @see #getItemListeners * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener ! * @since 1.1 */ public synchronized void removeItemListener(ItemListener l) { if (l == null) { return; }
*** 589,599 **** * exception. * * @param e the event * @see java.awt.event.ItemEvent * @see #processItemEvent ! * @since JDK1.1 */ protected void processEvent(AWTEvent e) { if (e instanceof ItemEvent) { processItemEvent((ItemEvent)e); return; --- 589,599 ---- * exception. * * @param e the event * @see java.awt.event.ItemEvent * @see #processItemEvent ! * @since 1.1 */ protected void processEvent(AWTEvent e) { if (e instanceof ItemEvent) { processItemEvent((ItemEvent)e); return;
*** 621,631 **** * @param e the item event * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener * @see #addItemListener(ItemListener) * @see java.awt.Component#enableEvents ! * @since JDK1.1 */ protected void processItemEvent(ItemEvent e) { ItemListener listener = itemListener; if (listener != null) { listener.itemStateChanged(e); --- 621,631 ---- * @param e the item event * @see java.awt.event.ItemEvent * @see java.awt.event.ItemListener * @see #addItemListener(ItemListener) * @see java.awt.Component#enableEvents ! * @since 1.1 */ protected void processItemEvent(ItemEvent e) { ItemListener listener = itemListener; if (listener != null) { listener.itemStateChanged(e);