|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.javadocking.drag.StaticCompositeTabDragger
public class StaticCompositeTabDragger
This is a class for dragging dockables in a CompositeTabDock.
The dockables of one child dock can be dragged by dragging the tab. All the dockables of all the child docks
can be dragged by dragging another part of the tabbed pane. A CompositeDockable
is created with the dockables of the javax.swing.JTabbedPane.
The Docks that are used in the application should inherit
from the java.awt.Component class.
With this class a tab of the javax.swing.JTabbedPane can also be dragged. This happens, when one tab is dragged, and the mouse is over the header of the JTabbedPane.
| Constructor Summary | |
|---|---|
StaticCompositeTabDragger()
Constructs a dragger with a default painter for painting the dragged dockables: a SwDockableDragPainter with a DefaultRectanglePainter. |
|
StaticCompositeTabDragger(DockableDragPainter dockableDragPainter)
Constructs a dragger with the given painter for painting the dragged dockables. |
|
| Method Summary | |
|---|---|
void |
cancelDragging(java.awt.event.MouseEvent mouseEvent)
Resets the cursor and other fields. |
void |
drag(java.awt.event.MouseEvent mouseEvent)
Searches the dock where the dockable will be docked for the current mouse location. |
DockableDragPainter |
getDockableDragPainter()
Gets the painter for painting the dragged dockables. |
protected java.awt.Cursor |
retrieveCanDockCursor()
Gets the cursor that is used for dragging a dockable, when the dockable can be docked in an underlying dock. |
protected java.awt.Cursor |
retrieveCanNotDockCursor()
Gets the cursor that is used for dragging a dockable, when the dockable cannot be docked in an underlying dock. |
void |
setDockableDragPainter(DockableDragPainter dockableDragPainter)
Sets the painter for painting the dragged dockables. |
void |
showPopupMenu(java.awt.event.MouseEvent mouseEvent)
Shows the popup menu for the selected dockable or the selected composite dockable. |
boolean |
startDragging(java.awt.event.MouseEvent mouseEvent)
Tries to start the dragging of a Dockable
from a source Dock to a destination dock. |
void |
stopDragging(java.awt.event.MouseEvent mouseEvent)
Resets the cursor. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public StaticCompositeTabDragger()
SwDockableDragPainter with a DefaultRectanglePainter.
public StaticCompositeTabDragger(DockableDragPainter dockableDragPainter)
dockableDragPainter - The painter for painting the dragged dockables.| Method Detail |
|---|
public boolean startDragging(java.awt.event.MouseEvent mouseEvent)
Dragger
Tries to start the dragging of a Dockable
from a source Dock to a destination dock.
The dockable that should be dragged is searched for the given mouse position.
startDragging in interface DraggermouseEvent - The mouse event that was triggered.
public void drag(java.awt.event.MouseEvent mouseEvent)
drag in interface DraggermouseEvent - The new mouse event that was triggered.public void cancelDragging(java.awt.event.MouseEvent mouseEvent)
cancelDragging in interface DraggermouseEvent - The last mouse event that was triggered.public void stopDragging(java.awt.event.MouseEvent mouseEvent)
stopDragging in interface DraggermouseEvent - The last mouse event that was triggered.public void showPopupMenu(java.awt.event.MouseEvent mouseEvent)
Dragger
showPopupMenu in interface DraggermouseEvent - The last mouse event that was triggered.public DockableDragPainter getDockableDragPainter()
public void setDockableDragPainter(DockableDragPainter dockableDragPainter)
dockableDragPainter - The painter for painting the dragged dockables.protected java.awt.Cursor retrieveCanDockCursor()
protected java.awt.Cursor retrieveCanNotDockCursor()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||