Skip to content

Commit

Permalink
[gnc-plugin-page-register] hide toolbar and menu in regular register
Browse files Browse the repository at this point in the history
Instead of toggling sensitivity according to xaccAccountIsPriced,
toggle visibility instead.
  • Loading branch information
christopherlam committed Sep 22, 2022
1 parent 05f952d commit 1cac132
Showing 1 changed file with 3 additions and 10 deletions.
13 changes: 3 additions & 10 deletions gnucash/gnome/gnc-plugin-page-register.c
Expand Up @@ -624,12 +624,6 @@ static const gchar* view_style_actions[] =
NULL
};

static const gchar* actions_requiring_extra[] =
{
"ActionsStockAssistantAction",
NULL
};

static const gchar* actions_requiring_priced_account[] =
{
"ActionsStockAssistantAction",
Expand Down Expand Up @@ -1289,11 +1283,10 @@ gnc_plugin_page_register_ui_initial_state (GncPluginPageRegister* page)
gnc_plugin_update_actions (action_group, actions_requiring_account,
"sensitive", is_readwrite && account != NULL);

gnc_plugin_update_actions (action_group, actions_requiring_extra,
"visible", gnc_prefs_is_extra_enabled ());

gnc_plugin_update_actions (action_group, actions_requiring_priced_account,
"sensitive", account && xaccAccountIsPriced (account));
"visible", account &&
gnc_prefs_is_extra_enabled () &&
xaccAccountIsPriced (account));

/* Set "style" radio button */
ledger_type = gnc_ledger_display_type (priv->ledger);
Expand Down

0 comments on commit 1cac132

Please sign in to comment.