diff options
author | infirit <[email protected]> | 2015-07-06 20:38:55 +0200 |
---|---|---|
committer | infirit <[email protected]> | 2015-07-06 20:38:55 +0200 |
commit | 069182d3b7eb3cbe831f3c486d474129a4a69c70 (patch) | |
tree | 09c9eff4a37466638e334b6ab52a63999fa705ce /sensors-applet/prefs-dialog.c | |
parent | b1a9157125af03750b8bf9ba92972ae0988bc7bb (diff) | |
download | mate-sensors-applet-069182d3b7eb3cbe831f3c486d474129a4a69c70.tar.bz2 mate-sensors-applet-069182d3b7eb3cbe831f3c486d474129a4a69c70.tar.xz |
Small cleanup
Bring the code in sync with gnome-sensors-applet.
Diffstat (limited to 'sensors-applet/prefs-dialog.c')
-rw-r--r-- | sensors-applet/prefs-dialog.c | 13 |
1 files changed, 9 insertions, 4 deletions
diff --git a/sensors-applet/prefs-dialog.c b/sensors-applet/prefs-dialog.c index 002a668..ab2278c 100644 --- a/sensors-applet/prefs-dialog.c +++ b/sensors-applet/prefs-dialog.c @@ -389,6 +389,7 @@ void prefs_dialog_open(SensorsApplet *sensors_applet) { gchar *header_text; PrefsDialog *prefs_dialog; DisplayMode display_mode; + GtkWidget *content_area; g_assert(sensors_applet->prefs_dialog == NULL); @@ -420,9 +421,10 @@ void prefs_dialog_open(SensorsApplet *sensors_applet) { "default-height", 350, NULL); - gtk_box_set_homogeneous(GTK_BOX(gtk_dialog_get_content_area (prefs_dialog->dialog)), FALSE); + content_area = gtk_dialog_get_content_area (prefs_dialog->dialog); + gtk_box_set_homogeneous(GTK_BOX(content_area), FALSE); - gtk_box_set_spacing(GTK_BOX(gtk_dialog_get_content_area (prefs_dialog->dialog)), 5); + gtk_box_set_spacing(GTK_BOX(content_area), 5); g_signal_connect(prefs_dialog->dialog, @@ -441,8 +443,10 @@ void prefs_dialog_open(SensorsApplet *sensors_applet) { we haven't been able to access any sensors */ if (sensors_applet->sensors == NULL) { GtkWidget *label; + GtkWidget *content_area; label = gtk_label_new(_("No sensors found!")); - gtk_box_pack_start (GTK_BOX(gtk_dialog_get_content_area (prefs_dialog->dialog)), label, TRUE, TRUE, 0); + content_area = gtk_dialog_get_content_area (prefs_dialog->dialog); + gtk_box_pack_start (GTK_BOX(content_area), label, FALSE, FALSE, 0); return; } @@ -990,7 +994,8 @@ void prefs_dialog_open(SensorsApplet *sensors_applet) { gtk_label_new(_("Sensors"))); /* pack notebook into prefs_dialog */ - gtk_box_pack_start (GTK_BOX(gtk_dialog_get_content_area (prefs_dialog->dialog)), + content_area = gtk_dialog_get_content_area (prefs_dialog->dialog); + gtk_box_pack_start (GTK_BOX(content_area), GTK_WIDGET(prefs_dialog->notebook), TRUE, TRUE, 0); |