[gnc-plugin-page-budget] estimate/allperiods wrap begin/commit pair

This commit is contained in:
Christopher Lam 2022-01-09 11:09:14 +08:00
parent 4a91e19368
commit 64874fc704

View File

@ -1071,7 +1071,9 @@ gnc_plugin_page_budget_cmd_estimate_budget (GtkAction *action,
priv->useAvg = gtk_toggle_button_get_active (GTK_TOGGLE_BUTTON(avg));
gnc_budget_begin_edit (priv->budget);
gtk_tree_selection_selected_foreach (sel, estimate_budget_helper, page);
gnc_budget_commit_edit (priv->budget);
break;
default:
break;
@ -1200,8 +1202,12 @@ gnc_plugin_page_budget_cmd_allperiods_budget (GtkAction *action,
if (xaccParseAmount (txt, TRUE, &priv->allValue, NULL) ||
priv->action == UNSET)
{
gnc_budget_begin_edit (priv->budget);
gtk_tree_selection_selected_foreach (sel, allperiods_budget_helper,
page);
gnc_budget_commit_edit (priv->budget);
}
break;
default:
break;