Skip to content

Commit

Permalink
[gnc-plugin-page-report] re-enable actions after disabling
Browse files Browse the repository at this point in the history
Otherwise Print, PDFExport, Report Options remain disabled after
modifying report options. Also restore nullptr sentinel in
disable_during_load_actions array.
  • Loading branch information
christopherlam committed Nov 7, 2023
1 parent 9e47c29 commit b450d9a
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions gnucash/gnome/gnc-plugin-page-report.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -210,7 +210,8 @@ static const gchar *disable_during_load_actions[] =
{
"FilePrintAction",
"FilePrintPDFAction",
"ReportOptionsAction"
"ReportOptionsAction",
nullptr
};

/** The default menu items that need to be add to the menu */
Expand Down Expand Up @@ -827,7 +828,7 @@ gnc_plugin_page_report_option_change_cb(gpointer data)
gnc_window_set_progressbar_window( nullptr );

gnc_plugin_set_actions_enabled(G_ACTION_MAP(priv->action_group),
disable_during_load_actions, FALSE);
disable_during_load_actions, TRUE);
priv->reloading = FALSE;
}

Expand Down Expand Up @@ -1489,7 +1490,7 @@ gnc_plugin_page_report_reload_cb (GSimpleAction *simple,
// this resets the window for the progressbar to nullptr
gnc_window_set_progressbar_window( nullptr );
gnc_plugin_set_actions_enabled(G_ACTION_MAP(priv->action_group),
disable_during_load_actions, FALSE);
disable_during_load_actions, TRUE);
priv->reloading = FALSE;
}

Expand Down

0 comments on commit b450d9a

Please sign in to comment.