Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse 4 » How to call QuitHandler when exiting via app switcher (macOS)(On macOS, one can quit an app by pressing Q while tabbing through the application switcher (via Cmd-Tab). No event is thrown.)
How to call QuitHandler when exiting via app switcher (macOS) [message #1824242] Fri, 10 April 2020 14:46
Andreas Buchen is currently offline Andreas BuchenFriend
Messages: 123
Registered: July 2009
Senior Member
On macOS, one can quit an application by pressing Q while tabbing through the open applications in the application switcher (via Command - Tab).

When doing so for an e4 RCP application, I never get a call to the ExitHandler nor is the user prompted to save the content. The application just closes and all changed data is lost.

How can I get the usual prompt to save parts?

One can reproduce this with the sample application that comes with Eclipse 2020-03:

(See also Vogella's tutorial)

* Create a new plug-in project
* Select Would you like to create a rich client application? Yes
* Select Eclipse 4 RCP Application
* Select Create sample content (part, menu, command...)
* Open Product File and select Launch an Eclipse application

To get a dirty part:
* Enter any text to the input
* When selecting "Quit application" then I am ask to save.

To quit via application switcher
* Cmd-Tab until the application icon is selected
* Keep Cmd pressed
* Press Q
* --> no prompt to save the dirty parts

[Updated on: Fri, 10 April 2020 14:49]

Report message to a moderator

Previous Topic:Save SWT widget properties to workspace
Next Topic:Problem building a product
Goto Forum:
  


Current Time: Thu Mar 28 09:00:24 GMT 2024

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

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

Back to the top