diff options
author | lukefromdc <[email protected]> | 2016-12-25 21:53:27 -0500 |
---|---|---|
committer | monsta <[email protected]> | 2017-01-24 12:03:45 +0300 |
commit | a1de9e1967d4be7d90d2bf8ce752283e2dc062af (patch) | |
tree | ffbd768e7a21de22ed5428d90cfae85fc4d2849f | |
parent | b766021eddbc7cbc504a11756b2afdf1cb5ad3cc (diff) | |
download | mate-power-manager-a1de9e1967d4be7d90d2bf8ce752283e2dc062af.tar.bz2 mate-power-manager-a1de9e1967d4be7d90d2bf8ce752283e2dc062af.tar.xz |
Brightness: fix OSD rendering when not composited
Also add style class msd-osd-window-solid, same as mate-settings-daemon volume control.
Based on
https://github.com/mate-desktop/mate-settings-daemon/commit/5d580b9985b61a486c8d23eaa34091a14d01b9e0
and
https://github.com/mate-desktop/mate-settings-daemon/commit/9aa4c4e379e71ebe8436898a3af61c4c96c9cc8a
-rw-r--r-- | src/msd-osd-window.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/msd-osd-window.c b/src/msd-osd-window.c index 89a9272..a5416b9 100644 --- a/src/msd-osd-window.c +++ b/src/msd-osd-window.c @@ -362,11 +362,11 @@ draw_when_not_composited (GtkWidget *widget, cairo_t *cr) int width; int height; - width = gtk_widget_get_allocated_width (widget); - height = gtk_widget_get_allocated_width (widget); + gtk_window_get_size (GTK_WINDOW (widget), &width, &height); context = gtk_widget_get_style_context (widget); gtk_style_context_set_state (context, GTK_STATE_FLAG_ACTIVE); + gtk_style_context_add_class(context,"msd-osd-window-solid"); gtk_render_frame (context, cr, 0, |