diff options
author | Tasos Sahanidis <tasos@tasossah.com> | 2020-08-20 09:41:52 +0200 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2020-08-20 14:38:04 +0200 |
commit | 3fbc05dc4cbf564644f2500508e642eb80f07264 (patch) | |
tree | 8e76f07319bb1fca66f85fde7eee249cd0a7e818 /src/indicator-notifications-settings.c | |
parent | d1b76b9aa5330cc27a0f3ecefc57becfbe8ea02e (diff) | |
download | ayatana-indicator-notifications-3fbc05dc4cbf564644f2500508e642eb80f07264.tar.gz ayatana-indicator-notifications-3fbc05dc4cbf564644f2500508e642eb80f07264.tar.bz2 ayatana-indicator-notifications-3fbc05dc4cbf564644f2500508e642eb80f07264.zip |
Add option to swap Settings and Clear.
Diffstat (limited to 'src/indicator-notifications-settings.c')
-rw-r--r-- | src/indicator-notifications-settings.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/src/indicator-notifications-settings.c b/src/indicator-notifications-settings.c index 3e9517c..46fd37b 100644 --- a/src/indicator-notifications-settings.c +++ b/src/indicator-notifications-settings.c @@ -231,6 +231,7 @@ indicator_notifications_settings_activate(GApplication *app) GtkWidget *button_cmc; GtkWidget *button_hide_ind; GtkWidget *button_dnd; + GtkWidget *button_swap_clr_s; GtkWidget *spin; GtkWidget *spin_label; GtkWidget *blacklist_label; @@ -301,6 +302,15 @@ indicator_notifications_settings_activate(GApplication *app) gtk_box_pack_start(GTK_BOX(vbox), button_dnd, FALSE, FALSE, 4); gtk_widget_show(button_dnd); + /* swap-clear-settings */ + button_swap_clr_s = gtk_check_button_new_with_label(_("Swap \"Clear\" and \"Settings\" items")); + gtk_toggle_button_set_active(GTK_TOGGLE_BUTTON(button_swap_clr_s), + g_settings_get_boolean(self->settings, NOTIFICATIONS_KEY_SWAP_CLEAR_SETTINGS)); + g_object_set_data(G_OBJECT(button_swap_clr_s), SCHEMA_KEY, NOTIFICATIONS_KEY_SWAP_CLEAR_SETTINGS); + g_signal_connect(button_swap_clr_s, "toggled", G_CALLBACK(button_toggled_cb), self->settings); + gtk_box_pack_start(GTK_BOX(vbox), button_swap_clr_s, FALSE, FALSE, 4); + gtk_widget_show(button_swap_clr_s); + /* max-items */ /* FIXME: indicator does not change max items until restart... */ spin_label = gtk_label_new(_("Maximum number of visible notifications")); |