doClose() in DefaultFrame.java

21 views
Skip to first unread message

mahi

unread,
Sep 25, 2008, 1:30:23 AM9/25/08
to Gwt Window Manager
Hi folks,
I want to know the functionality of the method doClose() present in
the DefaultFrame (gwm.jar).
The thing is... i am opening one window using "" nwin = new
DefaultGFrame(""); "".
I am not able to reopen the gwm window again if i close it.
Please help me in this...

- Mahi

mahi

unread,
Sep 25, 2008, 1:31:12 AM9/25/08
to Gwt Window Manager
Sorry the class name is DefaultGFrame

Luciano Broussal

unread,
Sep 25, 2008, 2:05:13 AM9/25/08
to gwt-windo...@googlegroups.com
Hi Mahi,

A Closed window can't be reopened. It's like your operating system.
Just keep the instance of the content you put in the window and attach it to a new Window.

HTH

Luciano

mahi

unread,
Sep 25, 2008, 2:31:04 AM9/25/08
to Gwt Window Manager
Hi Luciano,
Thanks for your quick reply... actually i want to give id to the
iframe... dynamically if i click one button in jsp page, i need to
display some content in gwm window.
So after opening the window, gwm is allowing user to close it also. So
just trying to reopen the window if that object is null.
Also I am calling this code onClose event....

newWin = new DefaultGFrame("");
newWin.addFrameListener(new GFrameAdapter(){public void
frameClosed(GFrameEvent evt) {
// TODO Auto-generated method stub
//doing something when the
try{
newWin.close();
newWin = null;
}
catch (Exception e)
{
e.printStackTrace();
}
}});


please have a look at this and tell me how could I get the things to
be done,....

- Mahi

Luciano Broussal

unread,
Sep 25, 2008, 2:46:02 AM9/25/08
to gwt-windo...@googlegroups.com
Has i said Mahi you can't reuse a closed window.
Keep a handle on your content to display and reasign it to a new GFrame.

HTH

mahi

unread,
Sep 25, 2008, 3:12:14 AM9/25/08
to Gwt Window Manager
I am really very sorry to irritate you with my stupid questions...
Just I am in a big confusion...
Just tell me one thing... can I call a new GFrame object multiple
times as user can close many times...
In that case, how can I declare/maintain the variables for these many
GFrames...
Please could you give me some snippet if u have anything with you or
any suggestion...?

- Mahi

Luciano Broussal

unread,
Sep 25, 2008, 4:35:58 AM9/25/08
to gwt-windo...@googlegroups.com
No problem Mahi, you don't irritate me and answer with pleasure

Maybe i don't understand what your question...


My thoughts

You can create as many as GFrame you want by new DefaultGFrame().

but each Frame can be close once.

if it does not work that way it's a BUG and you can open an issue.

Regards.
Reply all
Reply to author
Forward
0 new messages