public class FocusUtility
extends java.lang.Object
| Constructor and Description |
|---|
FocusUtility() |
| Modifier and Type | Method and Description |
|---|---|
static void |
setFocusToFirstSelectedRow(javax.swing.JList list,
java.awt.event.FocusEvent focusEvent)
Changes focus to first selected row in
JList. |
static void |
setFocusToFirstSelectedRow(javax.swing.JTree jTree,
java.awt.event.FocusEvent focusEvent)
Changes focus to first selected row in
JTree. |
public static void setFocusToFirstSelectedRow(javax.swing.JTree jTree,
java.awt.event.FocusEvent focusEvent)
JTree.
If there are no rows selected, it defaults to the first available.jTree - a JTree value that represents the
component whose focus we are trying to set.focusEvent - a FocusEvent value that will be used
to determine if the focus is being set on the JTree.public static void setFocusToFirstSelectedRow(javax.swing.JList list,
java.awt.event.FocusEvent focusEvent)
JList.
If there are no rows selected, it defaults to the first available.list - a JList value that represents the
component whose focus we are trying to set.focusEvent - a FocusEvent value that will be used
to determine if the focus is being set on the JList.