How to catch browser Refresh event

104 views
Skip to first unread message

Armishev, Sergey

unread,
Jan 10, 2012, 5:51:19 PM1/10/12
to google-we...@googlegroups.com

I have this code that suppose to logout user when he closes tab or browser. But event happened also when user presses “Refresh” button. How do I know that this is refresh and not really close event?

                  Window.addWindowClosingHandler(new Window.ClosingHandler() {

                        @Override

                        public void onWindowClosing(ClosingEvent event) {

                              logout();

                        }

                       

                  });

I am in development mode now using Firefox 9.0.1

-Sergey

 


_____________________________________________________
This electronic message and any files transmitted with it contains
information from iDirect, which may be privileged, proprietary
and/or confidential. It is intended solely for the use of the individual
or entity to whom they are addressed. If you are not the original
recipient or the person responsible for delivering the email to the
intended recipient, be advised that you have received this email
in error, and that any use, dissemination, forwarding, printing, or
copying of this email is strictly prohibited. If you received this email
in error, please delete it and immediately notify the sender.
_____________________________________________________
Reply all
Reply to author
Forward
0 new messages