summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBenjamin Otte <otte@redhat.com>2019-11-18 04:56:36 +0100
committerBenjamin Otte <otte@redhat.com>2019-11-22 07:46:18 +0100
commitf5e4dc824cd701ca032075fca8aca659456504da (patch)
treeab34a8a4f7b35fdaff3ace428b84d82240001375
parent80acc8f296c1c69903c5982c5e9eb0e88fe8beb2 (diff)
downloadgtk+-f5e4dc824cd701ca032075fca8aca659456504da.tar.gz
builder: Remove application setter/getter
It's unused and doesn't belong to GtkBuilder.
-rw-r--r--docs/reference/gtk/gtk4-sections.txt2
-rw-r--r--gtk/gtkbuilder.c61
-rw-r--r--gtk/gtkbuilder.h7
3 files changed, 0 insertions, 70 deletions
diff --git a/docs/reference/gtk/gtk4-sections.txt b/docs/reference/gtk/gtk4-sections.txt
index f11cfc15c4..04bf68f83b 100644
--- a/docs/reference/gtk/gtk4-sections.txt
+++ b/docs/reference/gtk/gtk4-sections.txt
@@ -543,8 +543,6 @@ gtk_builder_connect_signals
gtk_builder_connect_signals_full
gtk_builder_set_translation_domain
gtk_builder_get_translation_domain
-gtk_builder_set_application
-gtk_builder_get_application
gtk_builder_get_type_from_name
gtk_builder_value_from_string
gtk_builder_value_from_string_type
diff --git a/gtk/gtkbuilder.c b/gtk/gtkbuilder.c
index 80ffb2d665..b2d136931a 100644
--- a/gtk/gtkbuilder.c
+++ b/gtk/gtkbuilder.c
@@ -249,7 +249,6 @@ typedef struct
gchar *filename;
gchar *resource_prefix;
GType template_type;
- GtkApplication *application;
} GtkBuilderPrivate;
G_DEFINE_TYPE_WITH_PRIVATE (GtkBuilder, gtk_builder, G_TYPE_OBJECT)
@@ -2751,66 +2750,6 @@ gtk_builder_new_from_string (const gchar *string,
return builder;
}
-/**
- * gtk_builder_set_application:
- * @builder: a #GtkBuilder
- * @application: a #GtkApplication
- *
- * Sets the application associated with @builder.
- *
- * You only need this function if there is more than one #GApplication
- * in your process. @application cannot be %NULL.
- **/
-void
-gtk_builder_set_application (GtkBuilder *builder,
- GtkApplication *application)
-{
- GtkBuilderPrivate *priv = gtk_builder_get_instance_private (builder);
-
- g_return_if_fail (GTK_IS_BUILDER (builder));
- g_return_if_fail (GTK_IS_APPLICATION (application));
-
- if (priv->application)
- g_object_unref (priv->application);
-
- priv->application = g_object_ref (application);
-}
-
-/**
- * gtk_builder_get_application:
- * @builder: a #GtkBuilder
- *
- * Gets the #GtkApplication associated with the builder.
- *
- * The #GtkApplication is used for creating action proxies as requested
- * from XML that the builder is loading.
- *
- * By default, the builder uses the default application: the one from
- * g_application_get_default(). If you want to use another application
- * for constructing proxies, use gtk_builder_set_application().
- *
- * Returns: (nullable) (transfer none): the application being used by the builder,
- * or %NULL
- **/
-GtkApplication *
-gtk_builder_get_application (GtkBuilder *builder)
-{
- GtkBuilderPrivate *priv = gtk_builder_get_instance_private (builder);
-
- g_return_val_if_fail (GTK_IS_BUILDER (builder), NULL);
-
- if (!priv->application)
- {
- GApplication *application;
-
- application = g_application_get_default ();
- if (application && GTK_IS_APPLICATION (application))
- priv->application = g_object_ref (GTK_APPLICATION (application));
- }
-
- return priv->application;
-}
-
/*< private >
* _gtk_builder_prefix_error:
* @builder: a #GtkBuilder
diff --git a/gtk/gtkbuilder.h b/gtk/gtkbuilder.h
index 4941322014..a3b2e7ad0e 100644
--- a/gtk/gtkbuilder.h
+++ b/gtk/gtkbuilder.h
@@ -198,13 +198,6 @@ GDK_AVAILABLE_IN_ALL
GCallback gtk_builder_lookup_callback_symbol (GtkBuilder *builder,
const gchar *callback_name);
-GDK_AVAILABLE_IN_ALL
-void gtk_builder_set_application (GtkBuilder *builder,
- GtkApplication *application);
-
-GDK_AVAILABLE_IN_ALL
-GtkApplication * gtk_builder_get_application (GtkBuilder *builder);
-
/**
* GTK_BUILDER_WARN_INVALID_CHILD_TYPE: