Events of this class are fired when the option settings file is saved or reloaded.
This event has the following subtypes:
The event target for this event type is the optionSettings object.
PinballY keeps a copy of the settings in memory for quick access. When something changes - say, the user activates a new filter in the wheel API - the change is recorded in the in-memory copy of the settings, but isn't immediately saved to the file. This avoids the need to constantly re-write the file every time the user presses a button, which would slow things down slightly in the UI.
Whenever a change is made to the in-memory copy of the settings, the program sets an internal flag saying that the in-memory copy is "dirty" (that is, modified relative to the file copy). From time to time, the program checks the flag and automatically saves any pending changes.
The user never has to enter an explicit "Save" command to save changes. The program saves changes any pending automatically, at various times:
The program automatically reloads the option settings file any time the user makes changes in the Settings dialog.
Reloading the settings file also requires reloading the game databases and game file lists, since changes to the settings can affect which files are included in the scans and which databases are loaded. Games that were previously loaded into the in-memory game list might be removed from memory as a result. Any GameInfo objects or game ID values that referred to such games will become invalid, so you could use this event to clear any global variables or other cached information you might be keeping on loaded games.
Any table media files (playfield videos or images, etc) currently being displayed are also reloaded.
This event type has all of the standard event properties and methods (see the Event class), plus the following: