[gtk+] settings: Convert more fully to g_object_notify_by_pspec
- From: Matthias Clasen <matthiasc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+] settings: Convert more fully to g_object_notify_by_pspec
- Date: Tue, 8 Sep 2015 12:07:51 +0000 (UTC)
commit 4785f460d377c8bd277323b43e5a978d7a7c4518
Author: Matthias Clasen <mclasen redhat com>
Date: Mon Sep 7 15:55:02 2015 -0400
settings: Convert more fully to g_object_notify_by_pspec
It turns out that we always have the pspec at hand already.
gtk/gtksettings.c | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/gtk/gtksettings.c b/gtk/gtksettings.c
index 41a17c5..36a450c 100644
--- a/gtk/gtksettings.c
+++ b/gtk/gtksettings.c
@@ -322,7 +322,7 @@ gtk_settings_init (GtkSettings *settings)
g_value_init (&priv->property_values[i].value, value_type);
g_param_value_set_default (pspec, &priv->property_values[i].value);
- g_object_notify (G_OBJECT (settings), pspec->name);
+ g_object_notify_by_pspec (G_OBJECT (settings), pspec);
priv->property_values[i].source = GTK_SETTINGS_SOURCE_DEFAULT;
i++;
}
@@ -2151,7 +2151,7 @@ apply_queued_setting (GtkSettings *settings,
{
g_value_copy (&tmp_value, &priv->property_values[pspec->param_id - 1].value);
priv->property_values[pspec->param_id - 1].source = qvalue->source;
- g_object_notify (G_OBJECT (settings), g_param_spec_get_name (pspec));
+ g_object_notify_by_pspec (G_OBJECT (settings), pspec);
}
}
@@ -2229,7 +2229,7 @@ settings_install_property_parser (GtkSettingsClass *class,
g_value_init (&priv->property_values[class_n_properties - 1].value, G_PARAM_SPEC_VALUE_TYPE (pspec));
g_param_value_set_default (pspec, &priv->property_values[class_n_properties - 1].value);
priv->property_values[class_n_properties - 1].source = GTK_SETTINGS_SOURCE_DEFAULT;
- g_object_notify (G_OBJECT (settings), pspec->name);
+ g_object_notify_by_pspec (G_OBJECT (settings), pspec);
qvalue = g_datalist_get_data (&priv->queued_settings, pspec->name);
if (qvalue)
@@ -2883,7 +2883,7 @@ _gtk_settings_reset_rc_values (GtkSettings *settings)
GParamSpec *pspec = *p;
g_param_value_set_default (pspec, &priv->property_values[i].value);
- g_object_notify (G_OBJECT (settings), pspec->name);
+ g_object_notify_by_pspec (G_OBJECT (settings), pspec);
}
i++;
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]