-
Notifications
You must be signed in to change notification settings - Fork 278
Cancel native app close #391
Comments
@DSEWayne I could not really find time to verify why 'HostClose" may not work because of the holidays. Are you able to verify that your code is being called? |
Hi, "HostClose" is being called and I can put code in there that is called upon close. I just can't see any way to cancel the close request. When the user closes the native app I want to be able to cancel the users close request if they have outstanding changes and prompt them with a HTML message box asking if they want to save before I allow the native app to be closed. |
@DSEWayne I think I get your point now. There was never really any consideration for the option to avoid closing. The method was meant primarily to allow cleanups and other utility work before closing. What you are trying to do can be done though with some customization at your end. |
Thanks, I thought that was the case. By "customization at your end" do you mean modifying the Chromely source code? Or can it be done another way? |
Is it possible to cancel the native app being closed?
I can see a "HostClose" event on IChromelyNativeHost but this doesn't let you cancel. Perhaps "CloseEventArgs" could have a cancel property?
I'm developing a Cross-Platform app and when the native form is closed I need to cancel and show a "Are you sure message?" in case they have outstanding changes to save.
I have tried the Frameless option but this appears to only be implemented on Windows?
The text was updated successfully, but these errors were encountered: