javax.swing
Class JComboBox.DefaultKeySelectionManager

java.lang.Object
  extended byjavax.swing.JComboBox.DefaultKeySelectionManager
All Implemented Interfaces:
JComboBox.KeySelectionManager, Serializable
Enclosing class:
JComboBox

class JComboBox.DefaultKeySelectionManager
extends Object
implements JComboBox.KeySelectionManager, Serializable


Constructor Summary
(package private) JComboBox.DefaultKeySelectionManager()
           
 
Method Summary
 int selectionForKey(char aKey, ComboBoxModel aModel)
          Given aKey and the model, returns the row that should become selected.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JComboBox.DefaultKeySelectionManager

JComboBox.DefaultKeySelectionManager()
Method Detail

selectionForKey

public int selectionForKey(char aKey,
                           ComboBoxModel aModel)
Description copied from interface: JComboBox.KeySelectionManager
Given aKey and the model, returns the row that should become selected. Return -1 if no match was found.

Specified by:
selectionForKey in interface JComboBox.KeySelectionManager
Parameters:
aKey - a char value, usually indicating a keyboard key that was pressed
aModel - a ComboBoxModel -- the component's data model, containing the list of selectable items
Returns:
an int equal to the selected row, where 0 is the first item and -1 is none.