| java.lang.Object org.eclipse.ui.internal.dnd.DragBorder
DragBorder | public class DragBorder (Code) | | Utility class that wraps a given control with a black 'border'. Moving the
border control will cause the given control to move to stay within its bounds.
since: 3.2 |
Constructor Summary | |
public | DragBorder(Composite client, Control toDrag, boolean provideFrame) Construct a new DragBorder. |
Method Summary | |
public void | dispose() Dispose the controls owned by the border. | public Rectangle | getBounds() | public void | setHighlight(boolean highlight) Sets the hilight 'mode' for the control. | public void | setLocation(Point newPos, int alignment) Move the border (and its 'contained' control to a new position. |
DragBorder | public DragBorder(Composite client, Control toDrag, boolean provideFrame)(Code) | | Construct a new DragBorder.
Parameters: client - The client window that the border must stay within Parameters: toDrag - The control to be placed 'inside' the border |
dispose | public void dispose()(Code) | | Dispose the controls owned by the border.
|
getBounds | public Rectangle getBounds()(Code) | | The bounds of the border's control. |
setHighlight | public void setHighlight(boolean highlight)(Code) | | Sets the hilight 'mode' for the control.
Parameters: highlight - true if the border should be drawn as 'hilighted' |
setLocation | public void setLocation(Point newPos, int alignment)(Code) | | Move the border (and its 'contained' control to a new position. The new
position will be adjusted to lie entirely within the client area of the
clientControl .
Parameters: newPos - The new position for the border Parameters: alignment - The location of the cursor relative to the border being dragged.Current implementation only recognizes SWT.TOP & SWT.BOTTOM (which implies SWT.LEFT)and SWT.CENTER (which centers teh dragged border on the cursor. |
|
|