Merge pull request #2904 from robob27/confirm-persist

Persist confirm config
develop
Myk 2023-02-16 00:09:32 -08:00 committed by GitHub
commit c077343a23
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 9 deletions

@ -47,6 +47,7 @@ changelog.txt uses a syntax similar to RST, with a few special sequences:
- DFHack tool windows that capture mouse clicks (and therefore prevent you from clicking on the "pause" button) now unconditionally pause the game when they open (but you can still unpause with the keyboard if you want to). Examples of this behavior: `gui/quickfort`, `gui/blueprint`, `gui/liquids`
- `showmood`: now shows the number of items needed for cloth and bars in addition to the technically correct but always confusing "total dimension" (150 per bar or 10,000 per cloth)
-@ Stopped mouse clicks from affecting the map when a click on a DFHack screen dismisses the window
- `confirm`: configuration data is now persisted globally.
## Documentation

@ -612,15 +612,7 @@ DFhackCExport command_result plugin_init (color_ostream &out, vector <PluginComm
DFhackCExport command_result plugin_enable (color_ostream &out, bool enable)
{
if (is_enabled != enable)
{
for (auto c : confirmations)
{
if (!c.second->apply(enable))
return CR_FAILURE;
}
is_enabled = enable;
}
is_enabled = enable;
if (is_enabled)
{
conf_lua::simple_call("check");