|
org.netbeans.swing.tabcontrol 1.8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.netbeans.swing.tabcontrol.plaf.FxProvider
public abstract class FxProvider
Class which can provide sliding or other eye-candy effects as a component is displayed. To use, subclass TabbedContainerUI and create an instance in createFxProvider. The abstract doFinish() method is expected to call TabbedContainerUI.showComponent(), so this is best implemented as an inner class of a TabbbedContainerUI implementation.
Field Summary | |
---|---|
protected JComponent |
comp
|
protected Object |
orientation
|
protected JRootPane |
root
|
Constructor Summary | |
---|---|
FxProvider()
Creates a new instance of FxProvider |
Method Summary | |
---|---|
void |
abort()
Abort a running effect, so that finish will never be called. |
abstract void |
cleanup()
Clean up any artifacts of the effect, shut down timers, etc. |
protected abstract void |
doFinish()
Finish the operation - this method should be implemented to actually install the component and leave the displayer in its final state |
protected abstract void |
doStart()
Implement whatever is needed to begin running the effect - starting a timer, playing with the glass pane, creating offscreen images, etc., here |
void |
finish()
Perform any cleanup necessary and complete the effect. |
boolean |
isRunning()
Determine if an effect is currently running |
void |
start(JComponent comp,
JRootPane root,
Object orientation)
Start the effect running. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected JComponent comp
protected JRootPane root
protected Object orientation
Constructor Detail |
---|
public FxProvider()
Method Detail |
---|
public final void start(JComponent comp, JRootPane root, Object orientation)
doStart()
.
If isRunning()
is true, calls abort()
before
initializing.
public final void finish()
doFinish()
(in which
the implementation should call showComponent() on the TabbedContainerUI
to actually show the component for which an effect has been being
presented. After calling finish()
, it
calls cleanup()
. The common use case is for the effect
to be painted on the window's glass pane, so the idea is to leave that
onscreen while doing the work that will display the actual component,
and then hide the glass pane containing the effect's product once the
window is in its new state, with the component displayed.
public final void abort()
cleanup()
.
public final boolean isRunning()
public abstract void cleanup()
protected abstract void doStart()
protected abstract void doFinish()
|
org.netbeans.swing.tabcontrol 1.8 | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |