Re: How to use PopupFactory ?



Hi,

Have you looked at the API documentation?
http://java.sun.com/j2se/1.4.2/docs/api/javax/swing/PopupFactory.html

Like it says on there...

PopupFactory factory = PopupFactory.getSharedInstance();
Popup popup = factory.getPopup(owner, contents, x, y);
popup.show();
....
popup.hide();

You usually don't create an instance of Popup, rather you use the
Popupfactory's method getPopup() to obtain one.

Then use the show() method to make it visible, and once you are done
with whatever you have to do, call the hide() method to close and
dispose of the Popup

-Mike

Nicky wrote:
Hi all,
I want to use PopupFactory to popup some pane, could anyone help me
with a sample code or explain.
Thanks all.

.



Relevant Pages

  • Re: Popup in a Form
    ... Thanks for the offer to provide sample code to get the job started, ... You can then set it up that the name selected populates the field. ... > Bill Foley, Microsoft MVP ... >> such as John, Mary, Tom, is it possible to have a popup appear when tabing ...
    (microsoft.public.word.docmanagement)
  • RE: Help with popup
    ... We've included small sample code, ... >> I am loading a popup from my parent page when an image is clicked. ... >> now pass a value from a textbox to the popup page. ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: popup menus by right click
    ... needing to know this stuff, most of it will already have been figured out. ... in vba thsat popup in response to right click. ... sample code to help me understand what to do. ...
    (microsoft.public.access.formscoding)
  • How do I know if a popup is visible?
    ... How do I know if a popup is visible? ... (please show me some sample code ... to know if the popup is visible, popup may disappear with no choice at ... Daniel ...
    (comp.lang.pascal.delphi.misc)
  • Popup Calendar at Specific Location
    ... I found sample code that shows me how to implement a popup ... calendar, but I would like the calendar to popup at the lower ... Any insight on how to do this would be appreciated. ...
    (microsoft.public.dotnet.framework.aspnet)