Class KeyStrokeExtensions


  • public final class KeyStrokeExtensions
    extends java.lang.Object
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static void addShortcutToComponent​(javax.swing.JComponent component, javax.swing.KeyStroke keystroke, int whenInFocus, java.lang.String actionCommand, javax.swing.Action action)
      Adds the shortcut to component.
      static void addShortcutToComponent​(javax.swing.JComponent component, javax.swing.KeyStroke keystroke, java.lang.String actionCommand, javax.swing.Action action)
      Adds the shortcut to component.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • addShortcutToComponent

        public static void addShortcutToComponent​(javax.swing.JComponent component,
                                                  javax.swing.KeyStroke keystroke,
                                                  int whenInFocus,
                                                  java.lang.String actionCommand,
                                                  javax.swing.Action action)
        Adds the shortcut to component.
        Parameters:
        component - the component
        keystroke - the keystroke
        whenInFocus - the whe in focus
        actionCommand - the action command
        action - the action
      • addShortcutToComponent

        public static void addShortcutToComponent​(javax.swing.JComponent component,
                                                  javax.swing.KeyStroke keystroke,
                                                  java.lang.String actionCommand,
                                                  javax.swing.Action action)
        Adds the shortcut to component.
        Parameters:
        component - the component
        keystroke - the keystroke
        actionCommand - the action command
        action - the action