|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface SplitLayoutManager
A manager used to implement the behavior of a SplitDockStation
. The
SplitLayoutManager
is responsible to define the actions that have
to be taken on drop and move-events. It is also responsible to validate
any movement of the dividers.
Method Summary | |
---|---|
void |
calculateDivider(SplitDockStation station,
PutInfo putInfo,
Leaf origin)
Calculates the value a divider should have if the Dockable
of putInfo is added alongside of origin . |
void |
install(SplitDockStation station)
Called by a SplitDockStation when this manager will be used
by the station. |
PutInfo |
prepareDrop(SplitDockStation station,
int x,
int y,
int titleX,
int titleY,
boolean checkOverrideZone,
Dockable dockable)
Call forwarded from DockStation.prepareDrop . |
PutInfo |
prepareMove(SplitDockStation station,
int x,
int y,
int titleX,
int titleY,
boolean checkOverrideZone,
Dockable dockable)
Call forwarded from DockStation.prepareMove . |
void |
uninstall(SplitDockStation station)
Called by a SplitDockStation which used this manager and no
longer does. |
void |
updateBounds(Root root,
double x,
double y,
double factorW,
double factorH)
Called when the bounds of all DockableDisplayer of a station have
to be updated. |
double |
validateDivider(SplitDockStation station,
double divider,
Node node)
Tests whether the specified divider -value is legal or not. |
PutInfo |
validatePutInfo(SplitDockStation station,
PutInfo info)
Checks whether info is valid or not. |
Dockable |
willMakeFullscreen(SplitDockStation station,
Dockable dockable)
Called before the station changes its fullscreen-Dockable. |
Method Detail |
---|
void install(SplitDockStation station)
SplitDockStation
when this manager will be used
by the station.
station
- the invoking stationvoid uninstall(SplitDockStation station)
SplitDockStation
which used this manager and no
longer does.
station
- the invoking stationDockable willMakeFullscreen(SplitDockStation station, Dockable dockable)
station
- the invoking stationdockable
- the element which the station wants to make fullscreen,
can be null
station
or null
.PutInfo prepareDrop(SplitDockStation station, int x, int y, int titleX, int titleY, boolean checkOverrideZone, Dockable dockable)
DockStation.prepareDrop
.
This method calculates where to drop a new Dockable
.
station
- the calling stationx
- the x-coordinate of the mouse on the screeny
- the y-coordinate of the mouse on the screentitleX
- the location of the title or x
if no title is grabbedtitleY
- the location of the title or y
if no title is grabbedcheckOverrideZone
- whether to respect the override zone of the parentdockable
- the element that might be dropped
dockable
or null
if the element should not be droppedPutInfo prepareMove(SplitDockStation station, int x, int y, int titleX, int titleY, boolean checkOverrideZone, Dockable dockable)
DockStation.prepareMove
.
This method calculates where to move a Dockable
of station
.
station
- the calling stationx
- the x-coordinate of the mouse on the screeny
- the y-coordinate of the mouse on the screentitleX
- the location of the title or x
if no title is grabbedtitleY
- the location of the title or y
if no title is grabbedcheckOverrideZone
- whether to respect the override zone of the parentdockable
- the element that might be dropped
dockable
or null
if the element should not be droppedvoid calculateDivider(SplitDockStation station, PutInfo putInfo, Leaf origin)
Dockable
of putInfo
is added alongside of origin
. The
result has to be stored directly in putInfo
.
station
- the station for which the calculation has to be doneputInfo
- the new child of the stationorigin
- a leaf of this station or null
double validateDivider(SplitDockStation station, double divider, Node node)
divider
-value is legal or not.
station
- the station for which the divider is calculateddivider
- the value of a divider on a Node
node
- the Node
for which the test is performed
divider
PutInfo validatePutInfo(SplitDockStation station, PutInfo info)
info
is valid or not.
station
- the station for which info
will be usedinfo
- the preferred drop location
PutInfo
, info
or null
.void updateBounds(Root root, double x, double y, double factorW, double factorH)
DockableDisplayer
of a station have
to be updated. Subclasses normally can just call
Root.updateBounds(double, double, double, double, double, double, boolean)
with width
and height
set to 1.0.
root
- the root of a tree of Dockable
sx
- the left boundy
- the top boundfactorW
- a factor with which all x-coordinates have to be multiplied in
order to get coordinates in pixels. 0 if the basic station has no size.factorH
- a factor with which all y-coordinates have to be multiplied in
order to get coordinates in pixels. 0 if the basic station has no size.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |