Constructor and Description |
---|
CVetoClosingEvent(CControl control,
VetoableDockFrontendEvent source,
CDockable... dockables)
Creates a new event.
|
Modifier and Type | Method and Description |
---|---|
void |
cancel()
Stops this event from happening
|
CControl |
getControl()
Gets the control in whose realm this event was issued.
|
CDockable |
getDockable(int index)
Gets the
index 'th dockable that is associated with this event. |
int |
getDockableCount()
Gets the number of elements that are associated with this event.
|
VetoableDockFrontendEvent |
intern()
Gets the source of this event.
|
boolean |
isCancelable()
Tells whether this event can still be canceled or is already
bound to happen.
|
boolean |
isCanceled()
Tells whether this event has already been canceled.
|
boolean |
isExpected()
Tells whether this event was expected.
|
Iterator<CDockable> |
iterator() |
public CVetoClosingEvent(CControl control, VetoableDockFrontendEvent source, CDockable... dockables)
control
- the owner of this eventsource
- the reason for this eventdockables
- the affected dockables (may be only a subset of all affected dockables)public VetoableDockFrontendEvent intern()
public int getDockableCount()
public CDockable getDockable(int index)
index
'th dockable that is associated with this event.index
- the index of a dockablepublic CControl getControl()
null
public boolean isCancelable()
true
if a veto will have an effectpublic void cancel()
public boolean isCanceled()
cancel()
has already been calledpublic boolean isExpected()
CVetoClosingListener.closing(CVetoClosingEvent)
was called before
CVetoClosingListener.closed(CVetoClosingEvent)
.CDockable
is closed
in an unexpected way like not using CDockable.setVisible(boolean)
but directly
removing it from its parent DockStation
, or if a new layout (CControl.load(String)
)
is applied and the framework could not guess correctly which elements are going to be replaced.