spin.demo.dispatcher
Class RevealedDialogDispatcherFactory
DialogDispatcherFactory
spin.demo.dispatcher.RevealedDialogDispatcherFactory
public class RevealedDialogDispatcherFactory
extends DialogDispatcherFactory
Implementation of a dispatcher which uses dialogs to dispatch events.
Due to the inability to change the owner of a dialog (after creation) this
class has to create a fresh dialog for each invocation on the bean. This
admittedly inperformant behaviour could be improved by pooling the dialogs on
a per-owner basis (e.g. utilizing a WeakHashMap
).
Subclasse might want to offer cancel functionality, display real progress or
show an animated image (e.g. the famous Netscape icon).
protected Dialog | aquireDialog() - Aquire a dialog for the currently active window.
|
protected Dialog | aquireDialog(Window owner) - Aquire a dialog for the given owning window.
|
protected Dialog | createDialog(Window owner) - Create a dialog for the given owner.
|
protected void | initDialog(Dialog dialog)
|
protected void | releaseDialog(Dialog dialog)
|
aquireDialog
protected Dialog aquireDialog()
Aquire a dialog for the currently active window.
aquireDialog
protected Dialog aquireDialog(Window owner)
Aquire a dialog for the given owning window.
This default implementation always creates a new dialog.
owner
- owner to aquire dialog for
createDialog
protected Dialog createDialog(Window owner)
Create a dialog for the given owner.
owner
- owner of dialog to create
initDialog
protected void initDialog(Dialog dialog)
releaseDialog
protected void releaseDialog(Dialog dialog)