Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » F5 browser refresh to be trapped(How to trap F5 browser refresh)
F5 browser refresh to be trapped [message #1766795] Tue, 27 June 2017 11:13 Go to next message
John Gymer is currently offline John GymerFriend
Messages: 279
Registered: November 2012
Location: UK
Senior Member
Pressing F5 to refresh the browser in a RAP application causes the whole application to be restarted, losing all state date.

The exitConfirmation service is a useful feature to ask the user to confirm that they really want to navigate away from the application (also triggered on F5 refresh), but what would be useful is some mechanism that allows me to trap the F5 refresh within the application itself, and never trigger a browser refresh.

This way I would be able to process some application-specific refresh logic instead.

Is it possible to trap F5 in this way, on all browsers?


---
Just because you can doesn't mean you should
Re: F5 browser refresh to be trapped [message #1766799 is a reply to message #1766795] Tue, 27 June 2017 11:31 Go to previous messageGo to next message
Ivan Furnadjiev is currently offline Ivan FurnadjievFriend
Messages: 2426
Registered: July 2009
Location: Sofia, Bulgaria
Senior Member
Hi,
to my knowledge that's not possible. You could try to add F5 to the display CANCEL_KEYS.
Regards,
Ivan
Re: F5 browser refresh to be trapped [message #1766811 is a reply to message #1766799] Tue, 27 June 2017 14:00 Go to previous message
John Gymer is currently offline John GymerFriend
Messages: 279
Registered: November 2012
Location: UK
Senior Member
Thanks Ivan - good hint... CANCEL_KEYS in conjunction with ACTIVE_KEYS and a key listener does the job perfectly - I've tested in Chrome and IE and both work exactly how I need.
Cheers, John


---
Just because you can doesn't mean you should
Previous Topic:Deploy problem with RAP on WebSphere 8.5 for z/OS
Next Topic:add http-equiv meta in additionalHeaders
Goto Forum:
  


Current Time: Thu Apr 25 05:58:40 GMT 2024

Powered by FUDForum. Page generated in 0.03371 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top