summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorlukefromdc <[email protected]>2016-02-27 00:05:34 -0500
committerraveit65 <[email protected]>2016-02-27 12:08:43 +0100
commitb21ae316e9c500db40129870abb1bd9e0013e950 (patch)
tree5a3a58030c762f2c9ff1c333cafaa7728e96460e
parented5e2577673901fc32a5b1e434be10299a64d2c4 (diff)
downloadmate-panel-b21ae316e9c500db40129870abb1bd9e0013e950.tar.bz2
mate-panel-b21ae316e9c500db40129870abb1bd9e0013e950.tar.xz
gtk3.20: custom background work on main panel
This makes custom backgrounds show on the panel, the menu, the launcher applets but not yet the tray, the clock button, the trash, or most applets from mate-applets. Sometimes panel BG not drawn after theme change until panel restarted. Still, this is a clue-will keep working. Adding gdk_window_ensure_native (window) was taken from gnome-panel but caused the default background not to show if the system BG is selected and does not explicitly set the theme. Also using this brings back the requirement to restart the panel to fully apply a system BG but progress is being made here.
-rw-r--r--mate-panel/panel-widget.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/mate-panel/panel-widget.c b/mate-panel/panel-widget.c
index ca4ff641..6060524b 100644
--- a/mate-panel/panel-widget.c
+++ b/mate-panel/panel-widget.c
@@ -1749,8 +1749,11 @@ panel_widget_realize (GtkWidget *widget)
/* For auto-hidden panels with a colored background, we need native
* windows to avoid some uglyness on unhide */
- gdk_window_ensure_native (window);
#endif
+#if GTK_CHECK_VERSION (3, 19, 0)
+ /* Also required to show the background at all with gtk3.20*/
+ gdk_window_ensure_native (window);
+#endif
#if GTK_CHECK_VERSION (3, 0, 0)
panel_widget_set_background_default_style (widget);