diff options
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java')
-rw-r--r-- | bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java | 56 |
1 files changed, 44 insertions, 12 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java index 07a49df176..64190fb4ef 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java +++ b/bundles/org.eclipse.swt/Eclipse SWT/carbon/org/eclipse/swt/widgets/Control.java @@ -215,7 +215,7 @@ public void addFocusListener(FocusListener listener) { /** * Adds the listener to the collection of listeners who will * be notified when gesture events are generated for the control, - * by sending it one of the messages defined in the + * by sending it one of the messages defined in the * <code>GestureListener</code> interface. * * @param listener the listener which should be notified @@ -481,6 +481,8 @@ public void addPaintListener(PaintListener listener) { * windowing toolkit that you want touch events to be generated. * </p> * + * @param listener the listener which should be notified + * * @exception IllegalArgumentException <ul> * <li>ERROR_NULL_ARGUMENT - if the listener is null</li> * </ul> @@ -491,6 +493,7 @@ public void addPaintListener(PaintListener listener) { * * @see TouchListener * @see #removeTouchListener + * * @since 3.7 */ public void addTouchListener (TouchListener listener) { @@ -1080,8 +1083,11 @@ public boolean forceFocus () { /** * Returns the accessible object for the receiver. + * <p> * If this is the first time this object is requested, - * then the object is created and returned. + * then the object is created and returned. The object + * returned by getAccessible() does not need to be disposed. + * </p> * * @return the accessible object * @@ -1384,6 +1390,19 @@ public Monitor getMonitor () { return monitors [index]; } +/** + * Returns the orientation of the receiver, which will be one of the + * constants <code>SWT.LEFT_TO_RIGHT</code> or <code>SWT.RIGHT_TO_LEFT</code>. + * + * @return the orientation style + * + * @exception SWTException <ul> + * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> + * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> + * </ul> + * + * @since 3.7 + */ public int getOrientation () { checkWidget (); return style & (SWT.LEFT_TO_RIGHT | SWT.RIGHT_TO_LEFT); @@ -2763,7 +2782,7 @@ public void removeFocusListener(FocusListener listener) { /** * Removes the listener from the collection of listeners who will - * be notified when a gesture is performed on the control + * be notified when gesture events are generated for the control. * * @param listener the listener which should no longer be notified * @@ -2777,6 +2796,7 @@ public void removeFocusListener(FocusListener listener) { * * @see GestureListener * @see #addGestureListener + * * @since 3.7 */ public void removeGestureListener (GestureListener listener) { @@ -3017,6 +3037,7 @@ void removeRelation () { * * @see TouchListener * @see #addTouchListener + * * @since 3.7 */ public void removeTouchListener(TouchListener listener) { @@ -3788,6 +3809,20 @@ public void setMenu (Menu menu) { this.menu = menu; } +/** + * Sets the orientation of the receiver, which must be one + * of the constants <code>SWT.LEFT_TO_RIGHT</code> or <code>SWT.RIGHT_TO_LEFT</code>. + * <p> + * + * @param orientation new orientation style + * + * @exception SWTException <ul> + * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> + * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> + * </ul> + * + * @since 3.7 + */ public void setOrientation (int orientation) { checkWidget (); } @@ -4003,18 +4038,15 @@ public void setToolTipText (String string) { } /** - * Sets the receiver to receive touch events from the OS. By default, touch - * events are not delivered to a control unless specifically requested for that control. - * This is independent of whether or not there are any <code>TouchListener</code> instances - * registered for the control. - * - * @param enabled the new touch-enabled state. - * + * Sets whether the receiver should accept touch events. By default, a Control does not accept touch + * events. No error or exception is thrown if the underlying hardware does not support touch input. + * + * @param enabled the new touch-enabled state + * * @exception SWTException <ul> * <li>ERROR_WIDGET_DISPOSED - if the receiver has been disposed</li> * <li>ERROR_THREAD_INVALID_ACCESS - if not called from the thread that created the receiver</li> - * </ul> - * + * * @since 3.7 */ public void setTouchEnabled(boolean enabled) { |