Skip to content

Commit

Permalink
Remove all references to 'page-uri' for plugin pages
Browse files Browse the repository at this point in the history
Do not think it is required.
  • Loading branch information
Bob-IT committed Nov 5, 2022
1 parent 4fd868f commit 4fc1283
Show file tree
Hide file tree
Showing 9 changed files with 0 additions and 76 deletions.
49 changes: 0 additions & 49 deletions gnucash/gnome-utils/gnc-plugin-page.c
Expand Up @@ -75,7 +75,6 @@ enum
PROP_0,
PROP_PAGE_NAME,
PROP_PAGE_COLOR,
PROP_PAGE_URI,
PROP_BOOK,
PROP_STATUSBAR_TEXT,
PROP_USE_NEW_WINDOW,
Expand Down Expand Up @@ -388,15 +387,6 @@ gnc_plugin_page_class_init (GncPluginPageClass *klass)
NULL,
G_PARAM_READWRITE));

g_object_class_install_property
(gobject_class,
PROP_PAGE_URI,
g_param_spec_string ("page-uri",
"Page URI",
"The uri for this page.",
NULL,
G_PARAM_READWRITE));

g_object_class_install_property
(gobject_class,
PROP_STATUSBAR_TEXT,
Expand Down Expand Up @@ -483,7 +473,6 @@ gnc_plugin_page_init (GncPluginPage *page, void *data)
priv = GNC_PLUGIN_PAGE_GET_PRIVATE(page);
priv->page_name = NULL;
priv->page_color = NULL;
priv->uri = NULL;
priv->page_changed_id = 0;
priv->focus_source_id = 0;
priv->menu_qualifier = NULL;
Expand Down Expand Up @@ -525,9 +514,6 @@ gnc_plugin_page_finalize (GObject *object)
if (priv->page_color)
g_free (priv->page_color);

if (priv->uri)
g_free (priv->uri);

if (priv->statusbar_text)
g_free (priv->statusbar_text);

Expand Down Expand Up @@ -591,9 +577,6 @@ gnc_plugin_page_get_property (GObject *object,
case PROP_PAGE_COLOR:
g_value_set_string (value, priv->page_color);
break;
case PROP_PAGE_URI:
g_value_set_string (value, priv->uri);
break;
case PROP_STATUSBAR_TEXT:
g_value_set_string (value, priv->statusbar_text);
break;
Expand Down Expand Up @@ -646,9 +629,6 @@ gnc_plugin_page_set_property (GObject *object,
case PROP_PAGE_COLOR:
gnc_plugin_page_set_page_color (page, g_value_get_string (value));
break;
case PROP_PAGE_URI:
gnc_plugin_page_set_uri (page, g_value_get_string (value));
break;
case PROP_STATUSBAR_TEXT:
gnc_plugin_page_set_statusbar_text (page, g_value_get_string (value));
break;
Expand Down Expand Up @@ -933,35 +913,6 @@ gnc_plugin_page_disconnect_page_changed (GncPluginPage *page)
}


/* Retrieve the Uniform Resource Identifier for this page. */
const gchar *
gnc_plugin_page_get_uri (GncPluginPage *page)
{
GncPluginPagePrivate *priv;

g_return_val_if_fail (GNC_IS_PLUGIN_PAGE(page), NULL);

priv = GNC_PLUGIN_PAGE_GET_PRIVATE(page);
return priv->uri;
}


/* Set the Uniform Resource Identifier for this page. */
void
gnc_plugin_page_set_uri (GncPluginPage *page, const gchar *name)
{
GncPluginPagePrivate *priv;

g_return_if_fail (GNC_IS_PLUGIN_PAGE(page));

priv = GNC_PLUGIN_PAGE_GET_PRIVATE(page);
if (priv->uri)
g_free (priv->uri);

priv->uri = g_strdup (name);
}


/* Retrieve the statusbar text associated with this page. */
const gchar *
gnc_plugin_page_get_statusbar_text (GncPluginPage *page)
Expand Down
19 changes: 0 additions & 19 deletions gnucash/gnome-utils/gnc-plugin-page.h
Expand Up @@ -424,25 +424,6 @@ void gnc_plugin_page_inserted_cb (GncPluginPage *page, gpointer user_data);
void gnc_plugin_page_disconnect_page_changed (GncPluginPage *page);


/** Retrieve the Uniform Resource Identifier for this page.
*
* @param page The page whose URI should be retrieved.
*
* @return The URI for this page. This string is owned by the page and
* should not be freed by the caller.
*/
const gchar *gnc_plugin_page_get_uri (GncPluginPage *page);


/** Set the Uniform Resource Identifier for this page.
*
* @param page The page whose URI should be set.
*
* @param name The new URI for the page.
*/
void gnc_plugin_page_set_uri (GncPluginPage *page, const char *name);


/** Retrieve the statusbar text associated with this page.
*
* @param page The page whose statusbar should text be retrieved.
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-account-tree.c
Expand Up @@ -402,7 +402,6 @@ gnc_plugin_page_account_tree_init (GncPluginPageAccountTree *plugin_page)
parent = GNC_PLUGIN_PAGE(plugin_page);
g_object_set (G_OBJECT(plugin_page),
"page-name", _("Accounts"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-account-tree.ui",
NULL);
g_signal_connect (G_OBJECT (plugin_page), "selected",
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-budget.c
Expand Up @@ -308,7 +308,6 @@ gnc_plugin_page_budget_init (GncPluginPageBudget *plugin_page)
parent = GNC_PLUGIN_PAGE(plugin_page);
g_object_set (G_OBJECT(plugin_page),
"page-name", _("Budget"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-budget.ui",
NULL);

Expand Down
2 changes: 0 additions & 2 deletions gnucash/gnome/gnc-plugin-page-invoice.c
Expand Up @@ -374,7 +374,6 @@ gnc_plugin_page_invoice_new (InvoiceWindow *iw)

plugin_page = GNC_PLUGIN_PAGE(invoice_page);
gnc_plugin_page_invoice_update_title(plugin_page);
gnc_plugin_page_set_uri(plugin_page, "default:");

priv->component_manager_id = 0;
return plugin_page;
Expand Down Expand Up @@ -412,7 +411,6 @@ gnc_plugin_page_invoice_init (GncPluginPageInvoice *plugin_page)
use_new = gnc_prefs_get_bool (GNC_PREFS_GROUP_INVOICE, GNC_PREF_USE_NEW);
g_object_set(G_OBJECT(plugin_page),
"page-name", _("Invoice"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-invoice.ui",
"use-new-window", use_new,
(char *)NULL);
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-owner-tree.c
Expand Up @@ -385,7 +385,6 @@ gnc_plugin_page_owner_tree_init (GncPluginPageOwnerTree *plugin_page)
parent = GNC_PLUGIN_PAGE(plugin_page);
g_object_set(G_OBJECT(plugin_page),
"page-name", _("Owners"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-owner-tree.ui",
NULL);
g_signal_connect (G_OBJECT (plugin_page), "selected",
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-register.c
Expand Up @@ -664,7 +664,6 @@ gnc_plugin_page_register_init (GncPluginPageRegister* plugin_page)
GNC_PREF_USE_NEW);
g_object_set (G_OBJECT (plugin_page),
"page-name", _ ("General Journal"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-register.ui",
"use-new-window", use_new,
NULL);
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-report.cpp
Expand Up @@ -1312,7 +1312,6 @@ gnc_plugin_page_report_constr_init (GncPluginPageReport *plugin_page, gint repor
name = gnc_report_name (priv->initial_report);
g_object_set (G_OBJECT(plugin_page),
"page-name", name,
"page-uri", "default:",
"ui-description", "gnc-plugin-page-report.ui",
"use-new-window", use_new,
nullptr);
Expand Down
1 change: 0 additions & 1 deletion gnucash/gnome/gnc-plugin-page-sx-list.c
Expand Up @@ -232,7 +232,6 @@ gnc_plugin_page_sx_list_init (GncPluginPageSxList *plugin_page)
parent = GNC_PLUGIN_PAGE(plugin_page);
g_object_set(G_OBJECT(plugin_page),
"page-name", _("Scheduled Transactions"),
"page-uri", "default:",
"ui-description", "gnc-plugin-page-sx-list.ui",
NULL);

Expand Down

0 comments on commit 4fc1283

Please sign in to comment.