org.gerhardb.jibs.obsolete
Class DialogModality

java.lang.Object
  extended by org.gerhardb.jibs.obsolete.DialogModality

public class DialogModality
extends java.lang.Object

Creates the illusion of a modal dialog, by disabling all mouse and keyboard input to the owner window of a JDialog. To use this class, create an instance and call its install method.

Author:
Craig Pell <pellc@saic.com> (initial), $Author: gerhardb $ (latest), $Date: 2007/12/20 14:41:33 $

Constructor Summary
DialogModality(javax.swing.JDialog d)
          Creates an instance capable of blocking input to the parent of the specified dialog whenever the specified dialog is shown.
 
Method Summary
 void install()
          Makes this object's dialog appear modal with respect to its owner window.
static void main(java.lang.String[] args)
          Tests this class by showing a frame with a button that causes a single dialog, made "modal" by an instance of this class, to appear.
 void uninstall()
          Removes all influences of this object over its dialog, effectively undoing a call to install().
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DialogModality

public DialogModality(javax.swing.JDialog d)
Creates an instance capable of blocking input to the parent of the specified dialog whenever the specified dialog is shown. Note that none of the simulated modality will take place until install() is called.

Method Detail

install

public void install()
Makes this object's dialog appear modal with respect to its owner window.

See Also:
uninstall()

uninstall

public void uninstall()
Removes all influences of this object over its dialog, effectively undoing a call to install().


main

public static void main(java.lang.String[] args)
Tests this class by showing a frame with a button that causes a single dialog, made "modal" by an instance of this class, to appear.



Copyright ? 2007 Gerhard Beck. All rights reserved. Subject to GPL.