|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.awt.Component
java.awt.Container
javax.swing.JComponent
javax.swing.text.JTextComponent
javax.swing.JTextField
bibliothek.extension.gui.dock.preference.editor.KeyStrokeEditor
public class KeyStrokeEditor
An editor for KeyStrokes.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class javax.swing.JTextField |
|---|
JTextField.AccessibleJTextField |
| Nested classes/interfaces inherited from class javax.swing.text.JTextComponent |
|---|
JTextComponent.AccessibleJTextComponent, JTextComponent.DropLocation, JTextComponent.KeyBinding |
| Nested classes/interfaces inherited from class javax.swing.JComponent |
|---|
JComponent.AccessibleJComponent |
| Nested classes/interfaces inherited from class java.awt.Container |
|---|
Container.AccessibleAWTContainer |
| Nested classes/interfaces inherited from class java.awt.Component |
|---|
Component.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy |
| Field Summary | |
|---|---|
static PreferenceEditorFactory<KeyStroke> |
FACTORY
A factory for KeyStrokeEditors. |
| Fields inherited from class javax.swing.JTextField |
|---|
notifyAction |
| Fields inherited from class javax.swing.text.JTextComponent |
|---|
DEFAULT_KEYMAP, FOCUS_ACCELERATOR_KEY |
| Fields inherited from class javax.swing.JComponent |
|---|
accessibleContext, listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW |
| Fields inherited from class java.awt.Component |
|---|
BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENT |
| Fields inherited from interface javax.swing.SwingConstants |
|---|
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST |
| Fields inherited from interface java.awt.image.ImageObserver |
|---|
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
| Constructor Summary | |
|---|---|
KeyStrokeEditor()
Creates a new editor |
|
| Method Summary | |
|---|---|
void |
doOperation(PreferenceOperation operation)
Executes the operation that matches operation or does
nothing if operation is unknown. |
Component |
getComponent()
Gets a component which displays the contents of this editor. |
KeyStroke |
getValue()
Gets the value of this editor. Note: editors should call PreferenceEditorCallback.set(Object)
when their value got edited by the user. |
static boolean |
isModifierKey(int keyCode)
Tells whether keyCode is a modifier key. |
void |
setCallback(PreferenceEditorCallback<KeyStroke> callback)
Sets a callback, a callback can be used to read the value that has to be edited or to store the edited value. Note: this editor should call PreferenceEditorCallback.set(Object)
whenever this editor shows a new valid value. |
void |
setValue(KeyStroke value)
Sets the current value of this editor. |
void |
setValueInfo(Object information)
Sets information about the value that is shown. |
static String |
toString(KeyStroke stroke,
boolean complete)
Transforms stroke into a human readable string. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static final PreferenceEditorFactory<KeyStroke> FACTORY
KeyStrokeEditors.
| Constructor Detail |
|---|
public KeyStrokeEditor()
| Method Detail |
|---|
public static final String toString(KeyStroke stroke,
boolean complete)
stroke into a human readable string.
stroke - the stroke to transformcomplete - if set, then the combination is complete, otherwise
a "+" sign will be added at the end.
public static boolean isModifierKey(int keyCode)
keyCode is a modifier key.
keyCode - some code of a key
true if keyCode is a modifier key
like "shift" or "ctrl".public void setValueInfo(Object information)
PreferenceEditorPreferenceEditor.setValue(Object). This method might be called with
a null argument when the editor is no longer needed.
setValueInfo in interface PreferenceEditor<KeyStroke>information - the information, may be nullpublic Component getComponent()
PreferenceEditor
getComponent in interface PreferenceEditor<KeyStroke>nullpublic KeyStroke getValue()
PreferenceEditorPreferenceEditorCallback.set(Object)
when their value got edited by the user. An editor should not expect
a call to this method.
getValue in interface PreferenceEditor<KeyStroke>nullpublic void setCallback(PreferenceEditorCallback<KeyStroke> callback)
PreferenceEditorPreferenceEditorCallback.set(Object)
whenever this editor shows a new valid value.
setCallback in interface PreferenceEditor<KeyStroke>callback - the callback, might be nullpublic void setValue(KeyStroke value)
PreferenceEditor
setValue in interface PreferenceEditor<KeyStroke>value - the value, might be nullpublic void doOperation(PreferenceOperation operation)
PreferenceEditoroperation or does
nothing if operation is unknown.
doOperation in interface PreferenceEditor<KeyStroke>operation - the operation that was triggered
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||