[gnome-disk-utility] GduWindow: When using the headerbar as a toolbar, apply the right style classes



commit 3859385b88837a4e44fad78c2e9ab40d5faf86e9
Author: Iain Lane <iain orangesquash org uk>
Date:   Wed May 27 12:29:53 2015 +0100

    GduWindow: When using the headerbar as a toolbar, apply the right style classes
    
    So that themes can style it as they do other toolbars.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=739768

 src/disks/gduwindow.c |    5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)
---
diff --git a/src/disks/gduwindow.c b/src/disks/gduwindow.c
index ccb4bfd..7245776 100644
--- a/src/disks/gduwindow.c
+++ b/src/disks/gduwindow.c
@@ -1034,9 +1034,12 @@ gdu_window_constructed (GObject *object)
                           FALSE, TRUE, 0);
       gtk_header_bar_set_show_close_button (GTK_HEADER_BAR (window->header),
                                             FALSE);
+      context = gtk_widget_get_style_context (GTK_WIDGET (window->header));
+      gtk_style_context_remove_class (context, "header-bar");
+      gtk_style_context_add_class (context, "toolbar");
+      gtk_style_context_add_class (context, "primary-toolbar");
     }
 
-
   gtk_widget_show_all (window->header);
 
   gtk_widget_reparent (window->main_box, GTK_WIDGET (window));


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]