java.awt

Class Event

  • java.lang.Object
    • java.awt.Event
  • All Implemented Interfaces:
    java.io.Serializable
    public class Event extends java.lang.Object implements java.io.Serializable
    NOTE: The Event class is obsolete and is available only for backwards compatilibility. It has been replaced by the AWTEvent class and its subclasses.

    Event is a platform-independent class that encapsulates events from the platform's Graphical User Interface in the Java 1.0 event model. In Java 1.1 and later versions, the Event class is maintained only for backwards compatibilty. The information in this class description is provided to assist programmers in converting Java 1.0 programs to the new event model.

    In the Java 1.0 event model, an event contains an id field that indicates what type of event it is and which other Event variables are relevant for the event.

    For keyboard events, key contains a value indicating which key was activated, and modifiers contains the modifiers for that event. For the KEY_PRESS and KEY_RELEASE event ids, the value of key is the unicode character code for the key. For KEY_ACTION and KEY_ACTION_RELEASE, the value of key is one of the defined action-key identifiers in the Event class (PGUP, PGDN, F1, F2, etc).

    Since:
    JDK1.0
    See Also:
    Serialized Form
    • Fields 
      Modifier and Type Field and Description
      Ordinary member indicator ACTION_EVENT Reveal DetailHide Detail
      This event indicates that the user wants some action to occur.
      Ordinary member indicator ALT_MASK Reveal DetailHide Detail
      This flag indicates that the Alt key was down when the event occurred.
      Ordinary member indicator arg Reveal DetailHide Detail
      An arbitrary argument of the event.
      Ordinary member indicator BACK_SPACE Reveal DetailHide Detail
      The BackSpace key.
      Ordinary member indicator CAPS_LOCK Reveal DetailHide Detail
      The Caps Lock key, a non-ASCII action key.
      Ordinary member indicator clickCount Reveal DetailHide Detail
      For MOUSE_DOWN events, this field indicates the number of consecutive clicks.
      Ordinary member indicator CTRL_MASK Reveal DetailHide Detail
      This flag indicates that the Control key was down when the event occurred.
      Ordinary member indicator DELETE Reveal DetailHide Detail
      The Delete key.
      Ordinary member indicator DOWN Reveal DetailHide Detail
      The Down Arrow key, a non-ASCII action key.
      Ordinary member indicator END Reveal DetailHide Detail
      The End key, a non-ASCII action key.
      Ordinary member indicator ENTER Reveal DetailHide Detail
      The Enter key.
      Ordinary member indicator ESCAPE Reveal DetailHide Detail
      The Escape key.
      Ordinary member indicator evt Reveal DetailHide Detail
      The next event.
      Ordinary member indicator F1 Reveal DetailHide Detail
      The F1 function key, a non-ASCII action key.
      Ordinary member indicator F10 Reveal DetailHide Detail
      The F10 function key, a non-ASCII action key.
      Ordinary member indicator F11 Reveal DetailHide Detail
      The F11 function key, a non-ASCII action key.
      Ordinary member indicator F12 Reveal DetailHide Detail
      The F12 function key, a non-ASCII action key.
      Ordinary member indicator F2 Reveal DetailHide Detail
      The F2 function key, a non-ASCII action key.
      Ordinary member indicator F3 Reveal DetailHide Detail
      The F3 function key, a non-ASCII action key.
      Ordinary member indicator F4 Reveal DetailHide Detail
      The F4 function key, a non-ASCII action key.
      Ordinary member indicator F5 Reveal DetailHide Detail
      The F5 function key, a non-ASCII action key.
      Ordinary member indicator F6 Reveal DetailHide Detail
      The F6 function key, a non-ASCII action key.
      Ordinary member indicator F7 Reveal DetailHide Detail
      The F7 function key, a non-ASCII action key.
      Ordinary member indicator F8 Reveal DetailHide Detail
      The F8 function key, a non-ASCII action key.
      Ordinary member indicator F9 Reveal DetailHide Detail
      The F9 function key, a non-ASCII action key.
      Ordinary member indicator GOT_FOCUS Reveal DetailHide Detail
      A component gained the focus.
      Ordinary member indicator HOME Reveal DetailHide Detail
      The Home key, a non-ASCII action key.
      Ordinary member indicator id Reveal DetailHide Detail
      Indicates which type of event the event is, and which other Event variables are relevant for the event.
      Ordinary member indicator INSERT Reveal DetailHide Detail
      The Insert key, a non-ASCII action key.
      Ordinary member indicator key Reveal DetailHide Detail
      The key code of the key that was pressed in a keyboard event.
      Ordinary member indicator KEY_ACTION Reveal DetailHide Detail
      The user has pressed a non-ASCII action key.
      Ordinary member indicator KEY_ACTION_RELEASE Reveal DetailHide Detail
      The user has released a non-ASCII action key.
      Ordinary member indicator KEY_PRESS Reveal DetailHide Detail
      The user has pressed a normal key.
      Ordinary member indicator KEY_RELEASE Reveal DetailHide Detail
      The user has released a normal key.
      Ordinary member indicator LEFT Reveal DetailHide Detail
      The Left Arrow key, a non-ASCII action key.
      Ordinary member indicator LIST_DESELECT Reveal DetailHide Detail
      An item in a list has been deselected.
      Ordinary member indicator LIST_SELECT Reveal DetailHide Detail
      An item in a list has been selected.
      Ordinary member indicator LOAD_FILE Reveal DetailHide Detail
      A file loading event.
      Ordinary member indicator LOST_FOCUS Reveal DetailHide Detail
      A component lost the focus.
      Ordinary member indicator META_MASK Reveal DetailHide Detail
      This flag indicates that the Meta key was down when the event occurred.
      Ordinary member indicator modifiers Reveal DetailHide Detail
      The state of the modifier keys.
      Ordinary member indicator MOUSE_DOWN Reveal DetailHide Detail
      The user has pressed the mouse button.
      Ordinary member indicator MOUSE_DRAG Reveal DetailHide Detail
      The user has moved the mouse with a button pressed.
      Ordinary member indicator MOUSE_ENTER Reveal DetailHide Detail
      The mouse has entered a component.
      Ordinary member indicator MOUSE_EXIT Reveal DetailHide Detail
      The mouse has exited a component.
      Ordinary member indicator MOUSE_MOVE Reveal DetailHide Detail
      The mouse has moved with no button pressed.
      Ordinary member indicator MOUSE_UP Reveal DetailHide Detail
      The user has released the mouse button.
      Ordinary member indicator NUM_LOCK Reveal DetailHide Detail
      The Num Lock key, a non-ASCII action key.
      Ordinary member indicator PAUSE Reveal DetailHide Detail
      The Pause key, a non-ASCII action key.
      Ordinary member indicator PGDN Reveal DetailHide Detail
      The Page Down key, a non-ASCII action key.
      Ordinary member indicator PGUP Reveal DetailHide Detail
      The Page Up key, a non-ASCII action key.
      Ordinary member indicator PRINT_SCREEN Reveal DetailHide Detail
      The Print Screen key, a non-ASCII action key.
      Ordinary member indicator RIGHT Reveal DetailHide Detail
      The Right Arrow key, a non-ASCII action key.
      Ordinary member indicator SAVE_FILE Reveal DetailHide Detail
      A file saving event.
      Ordinary member indicator SCROLL_ABSOLUTE Reveal DetailHide Detail
      The user has moved the bubble (thumb) in a scroll bar, moving to an "absolute" position, rather than to an offset from the last postion.
      Ordinary member indicator SCROLL_BEGIN Reveal DetailHide Detail
      The scroll begin event.
      Ordinary member indicator SCROLL_END Reveal DetailHide Detail
      The scroll end event.
      Ordinary member indicator SCROLL_LINE_DOWN Reveal DetailHide Detail
      The user has activated the line down area of a scroll bar.
      Ordinary member indicator SCROLL_LINE_UP Reveal DetailHide Detail
      The user has activated the line up area of a scroll bar.
      Ordinary member indicator SCROLL_LOCK Reveal DetailHide Detail
      The Scroll Lock key, a non-ASCII action key.
      Ordinary member indicator SCROLL_PAGE_DOWN Reveal DetailHide Detail
      The user has activated the page down area of a scroll bar.
      Ordinary member indicator SCROLL_PAGE_UP Reveal DetailHide Detail
      The user has activated the page up area of a scroll bar.
      Ordinary member indicator SHIFT_MASK Reveal DetailHide Detail
      This flag indicates that the Shift key was down when the event occurred.
      Ordinary member indicator TAB Reveal DetailHide Detail
      The Tab key.
      Ordinary member indicator target Reveal DetailHide Detail
      The target component.
      Ordinary member indicator UP Reveal DetailHide Detail
      The Up Arrow key, a non-ASCII action key.
      Ordinary member indicator when Reveal DetailHide Detail
      The time stamp.
      Ordinary member indicator WINDOW_DEICONIFY Reveal DetailHide Detail
      The user has asked the window manager to de-iconify the window.
      Ordinary member indicator WINDOW_DESTROY Reveal DetailHide Detail
      The user has asked the window manager to kill the window.
      Ordinary member indicator WINDOW_EXPOSE Reveal DetailHide Detail
      The user has asked the window manager to expose the window.
      Ordinary member indicator WINDOW_ICONIFY Reveal DetailHide Detail
      The user has asked the window manager to iconify the window.
      Ordinary member indicator WINDOW_MOVED Reveal DetailHide Detail
      The user has asked the window manager to move the window.
      Ordinary member indicator x Reveal DetailHide Detail
      The x coordinate of the event.
      Ordinary member indicator y Reveal DetailHide Detail
      The y coordinate of the event.
    • Constructors 
      Constructor and Description
      Ordinary member indicator Event Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Ordinary member indicator Event Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Ordinary member indicator Event Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
    • Methods 
      Modifier and Type Method and Description
      Ordinary member indicator controlDown Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Ordinary member indicator metaDown Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Ordinary member indicator shiftDown Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Overridden member indicator toString Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      Ordinary member indicator translate Reveal DetailHide Detail
      NOTE: The Event class is obsolete and is available only for backwards compatilibility.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
This document was created by Dulcet from the OpenJDK sources. Copyright © 1993, 2012 Oracle and/or its affiliates. All rights reserved.

SourceForge