You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The code for doing things like opening the save confirmation dialog when closing NF is very ugly and hard to follow. It's split across multiple classes App, Gui, Window, SaveConfirmationDialog and uses bools to trigger this logic. It needs to be improved. I think a good way to fix this would be to add some events to App related to app exits:
An event to indicate that an exit has been requested
Maybe an event to indicate that a previous exit has been cancelled,
An event that returns a bool. Lets objects indicate if they're ready for exit or not.
Should also look into using events for the logic that makes the save confirmation dialog popup appear when you close a document with unsaved changes, create a new project, or close a project. It has the same problems.
Could make a central event class or use the built in Beef Event type. Up to whoever implements this. For the second event listed above we won't be able to use Event since we need the result of each callback instead of just the final one.
The text was updated successfully, but these errors were encountered:
The code for doing things like opening the save confirmation dialog when closing NF is very ugly and hard to follow. It's split across multiple classes
App
,Gui
,Window
,SaveConfirmationDialog
and uses bools to trigger this logic. It needs to be improved. I think a good way to fix this would be to add some events toApp
related to app exits:Should also look into using events for the logic that makes the save confirmation dialog popup appear when you close a document with unsaved changes, create a new project, or close a project. It has the same problems.
Could make a central event class or use the built in Beef
Event
type. Up to whoever implements this. For the second event listed above we won't be able to useEvent
since we need the result of each callback instead of just the final one.The text was updated successfully, but these errors were encountered: