jdk/src/java.desktop/macosx/classes/com/apple/laf/AquaComboBoxUI.java
changeset 28070 001f640e7016
parent 25859 3317bb8137f4
child 28986 79f293b29d6a
equal deleted inserted replaced
28069:907a72cb0feb 28070:001f640e7016
   494     }
   494     }
   495 
   495 
   496     // This is somewhat messy.  The difference here from BasicComboBoxUI.EnterAction is that
   496     // This is somewhat messy.  The difference here from BasicComboBoxUI.EnterAction is that
   497     // arrow up or down does not automatically select the
   497     // arrow up or down does not automatically select the
   498     @SuppressWarnings("serial") // anonymous class
   498     @SuppressWarnings("serial") // anonymous class
   499     private static final Action triggerSelectionAction = new AbstractAction() {
   499     private final Action triggerSelectionAction = new AbstractAction() {
   500         public void actionPerformed(final ActionEvent e) {
   500         public void actionPerformed(final ActionEvent e) {
   501             triggerSelectionEvent((JComboBox)e.getSource(), e);
   501             triggerSelectionEvent((JComboBox)e.getSource(), e);
       
   502         }
       
   503 
       
   504         @Override
       
   505         public boolean isEnabled() {
       
   506             return comboBox.isPopupVisible() && super.isEnabled();
   502         }
   507         }
   503     };
   508     };
   504 
   509 
   505     @SuppressWarnings("serial") // anonymous class
   510     @SuppressWarnings("serial") // anonymous class
   506     private static final Action toggleSelectionAction = new AbstractAction() {
   511     private static final Action toggleSelectionAction = new AbstractAction() {