summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authormarosg42 <[email protected]>2018-04-01 17:11:36 +0200
committerraveit65 <[email protected]>2018-05-12 22:34:11 +0200
commite83811d07c2b598ebe46f9e54cb9dbcc1ea87f18 (patch)
tree5d75d59629f421ccda8846c0109d618afe3d39f8
parente5ecb8b2b584b4895b8567eb9037769d0f202f39 (diff)
downloadmate-applets-e83811d07c2b598ebe46f9e54cb9dbcc1ea87f18.tar.bz2
mate-applets-e83811d07c2b598ebe46f9e54cb9dbcc1ea87f18.tar.xz
solving type mismatch in g_settings_set_value
-rw-r--r--multiload/properties.c9
1 files changed, 5 insertions, 4 deletions
diff --git a/multiload/properties.c b/multiload/properties.c
index 5f2c68c9..477f7462 100644
--- a/multiload/properties.c
+++ b/multiload/properties.c
@@ -150,13 +150,10 @@ spin_button_changed_cb(GtkWidget *widget, gpointer name)
prop_type = GPOINTER_TO_INT(g_object_get_data(G_OBJECT(widget), "prop_type"));
value = gtk_spin_button_get_value_as_int(GTK_SPIN_BUTTON(widget));
- /* FIXME: the first toggle button to be checked/dechecked does not work, but after that everything is cool. what gives? */
- g_settings_set_uint (ma->settings, (gchar *)name, value);
- g_settings_set_uint (ma->settings, (gchar *)name, value);
-
switch(prop_type)
{
case PROP_SPEED:
+ g_settings_set_int (ma->settings, (gchar *)name, value);
for (i = 0; i < NGRAPHS; i++)
{
load_graph_stop(ma->graphs[i]);
@@ -170,6 +167,7 @@ spin_button_changed_cb(GtkWidget *widget, gpointer name)
case PROP_SIZE:
for (i = 0; i < NGRAPHS; i++)
{
+ g_settings_set_int (ma->settings, (gchar *)name, value);
ma->graphs[i]->size = value ;
if (ma->graphs[i]->orient)
@@ -186,6 +184,7 @@ spin_button_changed_cb(GtkWidget *widget, gpointer name)
break;
case PROP_NET_THRESHOLD1:
+ g_settings_set_uint (ma->settings, (gchar *)name, value);
if (value >= ma->graphs[2]->net_threshold2)
{
gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget),
@@ -197,6 +196,7 @@ spin_button_changed_cb(GtkWidget *widget, gpointer name)
break;
case PROP_NET_THRESHOLD2:
+ g_settings_set_uint (ma->settings, (gchar *)name, value);
if (value >= ma->graphs[2]->net_threshold3)
{
gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget),
@@ -215,6 +215,7 @@ spin_button_changed_cb(GtkWidget *widget, gpointer name)
break;
case PROP_NET_THRESHOLD3:
+ g_settings_set_uint (ma->settings, (gchar *)name, value);
if (value <= ma->graphs[2]->net_threshold2)
{
gtk_spin_button_set_value(GTK_SPIN_BUTTON(widget),