diff -r d69b38870195 -r ed476aba94de jdk/src/java.desktop/share/classes/java/awt/Event.java --- a/jdk/src/java.desktop/share/classes/java/awt/Event.java Mon Jan 11 06:10:32 2016 -0800 +++ b/jdk/src/java.desktop/share/classes/java/awt/Event.java Mon Jan 11 17:51:54 2016 +0300 @@ -28,14 +28,14 @@ import java.io.*; /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

- * Event is a platform-independent class that + * {@code 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 + * and later versions, the {@code Event} class is maintained * only for backwards compatibility. The information in this * class description is provided to assist programmers in * converting Java 1.0 programs to the new event model. @@ -43,18 +43,18 @@ * In the Java 1.0 event model, an event contains an * {@link Event#id} field * that indicates what type of event it is and which other - * Event variables are relevant for the event. + * {@code Event} variables are relevant for the event. *

* For keyboard events, {@link Event#key} * contains a value indicating which key was activated, and * {@link Event#modifiers} contains the * modifiers for that event. For the KEY_PRESS and KEY_RELEASE - * event ids, the value of key is the unicode + * event ids, the value of {@code key} is the unicode * character code for the key. For KEY_ACTION and - * KEY_ACTION_RELEASE, the value of key is + * KEY_ACTION_RELEASE, the value of {@code key} is * one of the defined action-key identifiers in the - * Event class (PGUP, - * PGDN, F1, F2, etc). + * {@code Event} class ({@code PGUP}, + * {@code PGDN}, {@code F1}, {@code F2}, etc). * * @author Sami Shaio * @since 1.0 @@ -293,7 +293,7 @@ /** * The user has pressed a non-ASCII action key. - * The key field contains a value that indicates + * The {@code key} field contains a value that indicates * that the event occurred on one of the action keys, which * comprise the 12 function keys, the arrow (cursor) keys, * Page Up, Page Down, Home, End, Print Screen, Scroll Lock, @@ -303,7 +303,7 @@ /** * The user has released a non-ASCII action key. - * The key field contains a value that indicates + * The {@code key} field contains a value that indicates * that the event occurred on one of the action keys, which * comprise the 12 function keys, the arrow (cursor) keys, * Page Up, Page Down, Home, End, Print Screen, Scroll Lock, @@ -315,9 +315,9 @@ private static final int MOUSE_EVENT = 500; /** - * The user has pressed the mouse button. The ALT_MASK + * The user has pressed the mouse button. The {@code ALT_MASK} * flag indicates that the middle button has been pressed. - * The META_MASKflag indicates that the + * The {@code META_MASK} flag indicates that the * right button has been pressed. * @see java.awt.Event#ALT_MASK * @see java.awt.Event#META_MASK @@ -325,9 +325,9 @@ public static final int MOUSE_DOWN = 1 + MOUSE_EVENT; /** - * The user has released the mouse button. The ALT_MASK + * The user has released the mouse button. The {@code ALT_MASK} * flag indicates that the middle button has been released. - * The META_MASKflag indicates that the + * The {@code META_MASK} flag indicates that the * right button has been released. * @see java.awt.Event#ALT_MASK * @see java.awt.Event#META_MASK @@ -351,8 +351,8 @@ /** * The user has moved the mouse with a button pressed. The - * ALT_MASK flag indicates that the middle - * button is being pressed. The META_MASK flag indicates + * {@code ALT_MASK} flag indicates that the middle + * button is being pressed. The {@code META_MASK} flag indicates * that the right button is being pressed. * @see java.awt.Event#ALT_MASK * @see java.awt.Event#META_MASK @@ -466,7 +466,7 @@ /** * Indicates which type of event the event is, and which - * other Event variables are relevant for the event. + * other {@code Event} variables are relevant for the event. * This has been replaced by AWTEvent.getID() * * @serial @@ -518,9 +518,9 @@ public int modifiers; /** - * For MOUSE_DOWN events, this field indicates the + * For {@code MOUSE_DOWN} events, this field indicates the * number of consecutive clicks. For other events, its value is - * 0. + * {@code 0}. * This field has been replaced by MouseEvent.getClickCount(). * * @serial @@ -531,7 +531,7 @@ /** * An arbitrary argument of the event. The value of this field * depends on the type of event. - * arg has been replaced by event specific property. + * {@code arg} has been replaced by event specific property. * * @serial */ @@ -608,11 +608,11 @@ private static native void initIDs(); /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

- * Creates an instance of Event with the specified target + * Creates an instance of {@code Event} with the specified target * component, time stamp, event type, x and y * coordinates, keyboard key, state of the modifier keys, and * argument. @@ -659,14 +659,14 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

- * Creates an instance of Event, with the specified target + * Creates an instance of {@code Event}, with the specified target * component, time stamp, event type, x and y * coordinates, keyboard key, state of the modifier keys, and an - * argument set to null. + * argument set to {@code null}. * @param target the target component. * @param when the time stamp. * @param id the event type. @@ -680,11 +680,11 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

- * Creates an instance of Event with the specified + * Creates an instance of {@code Event} with the specified * target component, event type, and argument. * @param target the target component. * @param id the event type. @@ -695,9 +695,9 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Translates this event so that its x and y * coordinates are increased by dx and dy, @@ -716,13 +716,13 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Checks if the Shift key is down. - * @return true if the key is down; - * false otherwise. + * @return {@code true} if the key is down; + * {@code false} otherwise. * @see java.awt.Event#modifiers * @see java.awt.Event#controlDown * @see java.awt.Event#metaDown @@ -732,13 +732,13 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Checks if the Control key is down. - * @return true if the key is down; - * false otherwise. + * @return {@code true} if the key is down; + * {@code false} otherwise. * @see java.awt.Event#modifiers * @see java.awt.Event#shiftDown * @see java.awt.Event#metaDown @@ -748,14 +748,14 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Checks if the Meta key is down. * - * @return true if the key is down; - * false otherwise. + * @return {@code true} if the key is down; + * {@code false} otherwise. * @see java.awt.Event#modifiers * @see java.awt.Event#shiftDown * @see java.awt.Event#controlDown @@ -765,9 +765,9 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. */ void consume() { switch(id) { @@ -783,18 +783,18 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. */ boolean isConsumed() { return consumed; } /* - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Returns the integer key-code associated with the key in this event, * as described in java.awt.Event. @@ -810,9 +810,9 @@ } /* - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Returns a new KeyEvent char which corresponds to the int key * of this old event. @@ -827,15 +827,15 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

- * Returns a string representing the state of this Event. + * Returns a string representing the state of this {@code Event}. * This method is intended to be used only for debugging purposes, and the * content and format of the returned string may vary between * implementations. The returned string may be empty but may not be - * null. + * {@code null}. * * @return the parameter string of this event */ @@ -863,9 +863,9 @@ } /** - * NOTE: The Event class is obsolete and is + * NOTE: The {@code Event} class is obsolete and is * available only for backwards compatibility. It has been replaced - * by the AWTEvent class and its subclasses. + * by the {@code AWTEvent} class and its subclasses. *

* Returns a representation of this event's values as a string. * @return a string that represents the event and the values