GetFrameExample -- follows the containment
hierarchy up to find a component's parent frame and uses that
frame to create a dialog.
Experiment:
- Click in the blue background of the applet.
- Click on the "Create Dialog" button to create a dialog.
- Click in the green background of the dialog.
- Click on the "Destroy Dialog" button to destroy
the dialog.
The source.