applications i work with do not save anything without being explicitly told so. 
even on windows shutdown. the application simply don't exit and i'll have to 
force shutdown and go back save my work or at least deal with the dialog that 
popped up. usually the same as closing the application with unsaved changes.

tl;dr Runtime.addShutdownHook() should run the Exit Plugin, done. ..ede

On 8/31/2020 11:29, michael michaud wrote:
> Implementing Runtime.addShutdownHook is not too complicated (some 
> explanations here https://www.geeksforgeeks.org/jvm-shutdown-hook-java/). It 
> is not an absolute guarantee as it depends how exactly the process is 
> shutdown.
> Question is : what can we do during this hook (must not be too long as the 
> system may shut the process down anyway after a timeout).
> I can see some options like
> - save modifications (layers having a datasource but unsaved modification)
> - save unsaved layers (layers without datasource)
> - save project
> Some could be checked by default.
> Any thought ?
>
>
> ---
>
> ** [bugs:#322] OJ stops without warnings on system shutdown**
>
> **Status:** open
> **Milestone:**
> **Created:** Fri May 24, 2013 08:44 PM UTC by Jukka Rahkonen
> **Last Updated:** Fri May 24, 2013 08:44 PM UTC
> **Owner:** nobody
>
>
> Tested with version 1.6.1 release on Windows.
> If there are layers with unsaved edits in OpenJUMP and user ask computer to 
> shut down, OpenJUMP is closed without any warnings and unsaved edits are 
> lost. For comparison, Kosmo GIS 3.0 is keeping the computer in such a state 
> that operating system sends a message that Kosmo prevents the shutdown and 
> asks if user wants to cancel or do a forced shutdown.
>
>
> ---
>
> Sent from sourceforge.net because you indicated interest in 
> <https://sourceforge.net/p/jump-pilot/bugs/322/>
>
>
>
> To unsubscribe from further messages, please visit 
> <https://sourceforge.net/auth/subscriptions/>
>



---

** [bugs:#322] OJ stops without warnings on system shutdown**

**Status:** open
**Milestone:** 
**Created:** Fri May 24, 2013 08:44 PM UTC by Jukka Rahkonen
**Last Updated:** Mon Aug 31, 2020 09:29 AM UTC
**Owner:** nobody


Tested with version 1.6.1 release on Windows.
If there are layers with unsaved edits in OpenJUMP and user ask computer to 
shut down, OpenJUMP is closed without any warnings and unsaved edits are lost. 
For comparison, Kosmo GIS 3.0 is keeping the computer in such a state that 
operating system sends a message that Kosmo prevents the shutdown and asks if 
user wants to cancel or do a forced shutdown. 


---

Sent from sourceforge.net because jump-pilot-devel@lists.sourceforge.net is 
subscribed to https://sourceforge.net/p/jump-pilot/bugs/

To unsubscribe from further messages, a project admin can change settings at 
https://sourceforge.net/p/jump-pilot/admin/bugs/options.  Or, if this is a 
mailing list, you can unsubscribe from the mailing list.
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to