com.google.gwt.user.client.ui

## Interface KeyboardListener

- All Superinterfaces:
    java.util.EventListener
  All Known Implementing Classes:
    DecoratedTabBar, DelegatingKeyboardListenerCollection, KeyboardListenerAdapter, TabBar

  Deprecated.
  use `KeyDownHandler`, `KeyUpHandler` and/or `KeyPressHandler` instead

      @Deprecated
      public interface KeyboardListener
      extends java.util.EventListener

  Event listener interface for keyboard events.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static int` | `KEY_ALT` Deprecated. use `KeyCodes.KEY_ALT` instead
    `static int` | `KEY_BACKSPACE` Deprecated. use `KeyCodes.KEY_BACKSPACE` instead
    `static int` | `KEY_CTRL` Deprecated. use `KeyCodes.KEY_CTRL` instead
    `static int` | `KEY_DELETE` Deprecated. use `KeyCodes.KEY_DELETE` instead
    `static int` | `KEY_DOWN` Deprecated. use `KeyCodes.KEY_DOWN` instead
    `static int` | `KEY_END` Deprecated. use `KeyCodes.KEY_END` instead
    `static int` | `KEY_ENTER` Deprecated. use `KeyCodes.KEY_ENTER` instead
    `static int` | `KEY_ESCAPE` Deprecated. use `KeyCodes.KEY_ESCAPE` instead
    `static int` | `KEY_HOME` Deprecated. use `KeyCodes.KEY_HOME` instead
    `static int` | `KEY_LEFT` Deprecated. use `KeyCodes.KEY_LEFT` instead
    `static int` | `KEY_PAGEDOWN` Deprecated. use `KeyCodes.KEY_PAGEDOWN` instead
    `static int` | `KEY_PAGEUP` Deprecated. use `KeyCodes.KEY_PAGEUP` instead
    `static int` | `KEY_RIGHT` Deprecated. use `KeyCodes.KEY_RIGHT` instead
    `static int` | `KEY_SHIFT` Deprecated. use `KeyCodes.KEY_SHIFT` instead
    `static int` | `KEY_TAB` Deprecated. use `KeyCodes.KEY_TAB` instead
    `static int` | `KEY_UP` Deprecated. use `KeyCodes.KEY_UP` instead
    `static int` | `MODIFIER_ALT` Deprecated. use `KeyEvent.isAltKeyDown()` instead
    `static int` | `MODIFIER_CTRL` Deprecated. use `KeyEvent.isControlKeyDown()` instead
    `static int` | `MODIFIER_META` Deprecated. use `KeyEvent.isMetaKeyDown()` instead
    `static int` | `MODIFIER_SHIFT` Deprecated. use `KeyEvent.isShiftKeyDown()` instead

  - ### Method Summary

    All Methods Instance Methods Abstract Methods Deprecated Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `onKeyDown(Widget sender, char keyCode, int modifiers)` Deprecated. use `KeyDownHandler.onKeyDown(com.google.gwt.event.dom.client.KeyDownEvent)` instead
    `void` | `onKeyPress(Widget sender, char keyCode, int modifiers)` Deprecated. use `KeyPressHandler.onKeyPress(com.google.gwt.event.dom.client.KeyPressEvent)` instead
    `void` | `onKeyUp(Widget sender, char keyCode, int modifiers)` Deprecated. use `KeyUpHandler.onKeyUp(com.google.gwt.event.dom.client.KeyUpEvent)` instead

- - ### Field Detail

    - #### KEY_ALT

          @Deprecated
          static final int KEY_ALT

      Deprecated. use `KeyCodes.KEY_ALT` instead
      See Also:
        Constant Field Values

    - #### KEY_BACKSPACE

          @Deprecated
          static final int KEY_BACKSPACE

      Deprecated. use `KeyCodes.KEY_BACKSPACE` instead
      See Also:
        Constant Field Values

    - #### KEY_CTRL

          @Deprecated
          static final int KEY_CTRL

      Deprecated. use `KeyCodes.KEY_CTRL` instead
      See Also:
        Constant Field Values

    - #### KEY_DELETE

          @Deprecated
          static final int KEY_DELETE

      Deprecated. use `KeyCodes.KEY_DELETE` instead
      See Also:
        Constant Field Values

    - #### KEY_DOWN

          @Deprecated
          static final int KEY_DOWN

      Deprecated. use `KeyCodes.KEY_DOWN` instead
      See Also:
        Constant Field Values

    - #### KEY_END

          @Deprecated
          static final int KEY_END

      Deprecated. use `KeyCodes.KEY_END` instead
      See Also:
        Constant Field Values

    - #### KEY_ENTER

          @Deprecated
          static final int KEY_ENTER

      Deprecated. use `KeyCodes.KEY_ENTER` instead
      See Also:
        Constant Field Values

    - #### KEY_ESCAPE

          @Deprecated
          static final int KEY_ESCAPE

      Deprecated. use `KeyCodes.KEY_ESCAPE` instead
      See Also:
        Constant Field Values

    - #### KEY_HOME

          @Deprecated
          static final int KEY_HOME

      Deprecated. use `KeyCodes.KEY_HOME` instead
      See Also:
        Constant Field Values

    - #### KEY_LEFT

          @Deprecated
          static final int KEY_LEFT

      Deprecated. use `KeyCodes.KEY_LEFT` instead
      See Also:
        Constant Field Values

    - #### KEY_PAGEDOWN

          @Deprecated
          static final int KEY_PAGEDOWN

      Deprecated. use `KeyCodes.KEY_PAGEDOWN` instead
      See Also:
        Constant Field Values

    - #### KEY_PAGEUP

          @Deprecated
          static final int KEY_PAGEUP

      Deprecated. use `KeyCodes.KEY_PAGEUP` instead
      See Also:
        Constant Field Values

    - #### KEY_RIGHT

          @Deprecated
          static final int KEY_RIGHT

      Deprecated. use `KeyCodes.KEY_RIGHT` instead
      See Also:
        Constant Field Values

    - #### KEY_SHIFT

          @Deprecated
          static final int KEY_SHIFT

      Deprecated. use `KeyCodes.KEY_SHIFT` instead
      See Also:
        Constant Field Values

    - #### KEY_TAB

          @Deprecated
          static final int KEY_TAB

      Deprecated. use `KeyCodes.KEY_TAB` instead
      See Also:
        Constant Field Values

    - #### KEY_UP

          @Deprecated
          static final int KEY_UP

      Deprecated. use `KeyCodes.KEY_UP` instead
      See Also:
        Constant Field Values

    - #### MODIFIER_ALT

          @Deprecated
          static final int MODIFIER_ALT

      Deprecated. use `KeyEvent.isAltKeyDown()` instead
      See Also:
        Constant Field Values

    - #### MODIFIER_CTRL

          @Deprecated
          static final int MODIFIER_CTRL

      Deprecated. use `KeyEvent.isControlKeyDown()` instead
      See Also:
        Constant Field Values

    - #### MODIFIER_META

          @Deprecated
          static final int MODIFIER_META

      Deprecated. use `KeyEvent.isMetaKeyDown()` instead
      See Also:
        Constant Field Values

    - #### MODIFIER_SHIFT

          @Deprecated
          static final int MODIFIER_SHIFT

      Deprecated. use `KeyEvent.isShiftKeyDown()` instead
      See Also:
        Constant Field Values

  - ### Method Detail

    - #### onKeyDown

          @Deprecated
          void onKeyDown(Widget sender,
                                     char keyCode,
                                     int modifiers)

      Deprecated. use `KeyDownHandler.onKeyDown(com.google.gwt.event.dom.client.KeyDownEvent)` instead
      Fired when the user depresses a physical key.
      Parameters:
        `sender` - the widget that was focused when the event occurred.
        `keyCode` - the physical key that was depressed. Constants for this value are defined in this interface with the KEY prefix.
        `modifiers` - the modifier keys pressed at when the event occurred. This value is a combination of the bits defined by `MODIFIER_SHIFT`, `MODIFIER_CTRL`, and `MODIFIER_ALT`

    - #### onKeyPress

          @Deprecated
          void onKeyPress(Widget sender,
                                      char keyCode,
                                      int modifiers)

      Deprecated. use `KeyPressHandler.onKeyPress(com.google.gwt.event.dom.client.KeyPressEvent)` instead
      Fired when a keyboard action generates a character. This occurs after onKeyDown and onKeyUp are fired for the physical key that was pressed.

      It should be noted that many browsers do not generate keypress events for non-printing keyCode values, such as `KEY_ENTER` or arrow keys. These keyCodes can be reliably captured either with `onKeyDown(Widget, char, int)` or `onKeyUp(Widget, char, int)`.

      Parameters:
        `sender` - the widget that was focused when the event occurred.
        `keyCode` - the Unicode character that was generated by the keyboard action.
        `modifiers` - the modifier keys pressed at when the event occurred. This value is a combination of the bits defined by `MODIFIER_SHIFT`, `MODIFIER_CTRL`, and `MODIFIER_ALT`

    - #### onKeyUp

          @Deprecated
          void onKeyUp(Widget sender,
                                   char keyCode,
                                   int modifiers)

      Deprecated. use `KeyUpHandler.onKeyUp(com.google.gwt.event.dom.client.KeyUpEvent)` instead
      Fired when the user releases a physical key.
      Parameters:
        `sender` - the widget that was focused when the event occurred.
        `keyCode` - the physical key that was released. Constants for this value are defined in this interface with the KEY prefix.
        `modifiers` - the modifier keys pressed at when the event occurred. This value is a combination of the bits defined by `MODIFIER_SHIFT`, `MODIFIER_CTRL`, and `MODIFIER_ALT`