Class CScreenDockStationHandle.External
java.lang.Object
bibliothek.gui.dock.common.mode.station.CScreenDockStationHandle.External
- All Implemented Interfaces:
CExternalizedModeArea,CModeArea,ExternalizedModeArea,ModeArea,StationModeArea
- Enclosing class:
CScreenDockStationHandle
Represents a
CScreenDockStationHandle as CExternalizedModeArea.- Author:
- Benjamin Sigg
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidaddModeAreaListener(ModeAreaListener listener) Adds a listener to this area.booleanTells whether thisModeAreacan automatically become the default area of some mode.getCLocation(Dockable dockable) Assumingdockableis a child of this area, returns the location ofdockable.getCLocation(Dockable dockable, Location location) Assumingdockablewould be at locationlocationif it would be a child of this station, returns theCLocationthat matcheslocation.getLocation(Dockable child) Gets the location ofdockablewhich is a child of this station.Gets the station which is represented by this area.Gets a unique identifier for this area.booleanTells whetherdockableis a direct child of this station.booleanTells whether this area can be used as root in aLocation.Gets all the listeners that are registered at this area.voidremoveModeAreaListener(ModeAreaListener listener) Removes a listener from this area.booleanTells whether children of this area have to respect the settings forCWorkingAreas.voidsetController(DockController controller) Connects this area with a controller.booleansetLocation(Dockable dockable, DockableProperty location, AffectedSet set) Sets the location ofdockabletolocationand tries to ensure thatdockableis a child of this station.
This method may completely fail to change the location ofdockable, for example because aDockAcceptancedoes not allow the dockable to be moved.voidsetMode(LocationMode mode) Informs this area about the mode that uses it.
-
Constructor Details
-
External
protected External()
-
-
Method Details
-
getLocation
Description copied from interface:StationModeAreaGets the location ofdockablewhich is a child of this station.- Specified by:
getLocationin interfaceStationModeArea- Parameters:
child- the child- Returns:
- the location, may be
null
-
autoDefaultArea
public boolean autoDefaultArea()Description copied from interface:ModeAreaTells whether thisModeAreacan automatically become the default area of some mode.- Specified by:
autoDefaultAreain interfaceModeArea- Returns:
trueif this can be a default area,falseif not
-
isLocationRoot
public boolean isLocationRoot()Description copied from interface:ModeAreaTells whether this area can be used as root in aLocation. An area that is not a location root will (usually) not be used to set the location of a child.
Most implementations ofModeAreashould returntrue.- Specified by:
isLocationRootin interfaceModeArea- Returns:
- whether this
ModeAreaagrees on seeing itsModeArea.getUniqueId()in aLocation
-
setLocation
Description copied from interface:StationModeAreaSets the location ofdockabletolocationand tries to ensure thatdockableis a child of this station.
This method may completely fail to change the location ofdockable, for example because aDockAcceptancedoes not allow the dockable to be moved. In such casesfalseis returned.- Specified by:
setLocationin interfaceStationModeArea- Parameters:
dockable- the new or old childlocation- the new location, may benullset- this method has to store allDockables which might have changed their mode in the set.- Returns:
trueifdockableis now a child of thisStationModeArea,falseif not
-
addModeAreaListener
Description copied from interface:ModeAreaAdds a listener to this area.- Specified by:
addModeAreaListenerin interfaceModeArea- Parameters:
listener- the new listener
-
removeModeAreaListener
Description copied from interface:ModeAreaRemoves a listener from this area.- Specified by:
removeModeAreaListenerin interfaceModeArea- Parameters:
listener- the listener to remove
-
listeners
Gets all the listeners that are registered at this area.- Returns:
- all listeners
-
getStation
Description copied from interface:ModeAreaGets the station which is represented by this area.- Specified by:
getStationin interfaceModeArea- Returns:
- the station, not
null
-
getUniqueId
Description copied from interface:ModeAreaGets a unique identifier for this area.- Specified by:
getUniqueIdin interfaceModeArea- Returns:
- the unique identifier
- See Also:
-
isChild
Description copied from interface:ModeAreaTells whetherdockableis a direct child of this station. -
respectWorkingAreas
public boolean respectWorkingAreas()Description copied from interface:CModeAreaTells whether children of this area have to respect the settings forCWorkingAreas.- Specified by:
respectWorkingAreasin interfaceCModeArea- Returns:
- whether the settings are to be respected
-
setController
Description copied from interface:ModeAreaConnects this area with a controller. It's up to the area to add or remove listeners if necessary.- Specified by:
setControllerin interfaceModeArea- Parameters:
controller- the controller ornull
-
setMode
Description copied from interface:ModeAreaInforms this area about the mode that uses it. -
getCLocation
Description copied from interface:CModeAreaAssumingdockableis a child of this area, returns the location ofdockable.- Specified by:
getCLocationin interfaceCModeArea- Parameters:
dockable- some child- Returns:
- the location,
nullif not found
-
getCLocation
Description copied from interface:CModeAreaAssumingdockablewould be at locationlocationif it would be a child of this station, returns theCLocationthat matcheslocation.- Specified by:
getCLocationin interfaceCModeArea- Parameters:
dockable- some element which may or may not be a child of this stationlocation- the locationdockablewould have if it would be a child of this station- Returns:
- the location,
nullif not found
-