On 16 déc, 18:42, Damon Lundin <[email protected]> wrote:
> I have a need to implement a "Are you sure you want to leave?"
> functionality that can prevent the user from leaving the page (the
> same thing Gmail does) when there is unsaved data.  All the
> documentation I've read says that you can do this by returning a
> string from the window.onbeforeunload method.  This works if I embed
> raw javascript in my html page, but it doesn't seem to work when I
> make a native GWT method to do that same thing.

In GWT, use Window.addWindowClosingHandler and setMessage on the
Window.ClosingEvent.

--

You received this message because you are subscribed to the Google Groups 
"Google Web Toolkit" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/google-web-toolkit?hl=en.


Reply via email to