diff options
author | Stefano Karapetsas <[email protected]> | 2013-11-29 14:36:23 +0100 |
---|---|---|
committer | Stefano Karapetsas <[email protected]> | 2013-11-29 14:36:23 +0100 |
commit | 17fc492a17e8f5317d7438c771ac9c95ce1e0a04 (patch) | |
tree | e40ede01db66cccda81ecf1a2c49ad76037ac26c /mate-panel/panel.c | |
parent | 3f71479324ce6896c3cd8a480aacaf588ab159a9 (diff) | |
download | mate-panel-17fc492a17e8f5317d7438c771ac9c95ce1e0a04.tar.bz2 mate-panel-17fc492a17e8f5317d7438c771ac9c95ce1e0a04.tar.xz |
Panel background improvements for GTK3
Diffstat (limited to 'mate-panel/panel.c')
-rw-r--r-- | mate-panel/panel.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/mate-panel/panel.c b/mate-panel/panel.c index 8ac44a88..666a62b7 100644 --- a/mate-panel/panel.c +++ b/mate-panel/panel.c @@ -433,7 +433,11 @@ static gboolean set_background_color (PanelToplevel *toplevel, guint16 *dropped) { +#if GTK_CHECK_VERSION (3, 0, 0) + GdkRGBA color; +#else PanelColor color; +#endif if (!dropped) return FALSE; @@ -442,10 +446,17 @@ set_background_color (PanelToplevel *toplevel, ! panel_profile_background_key_is_writable (toplevel, "type")) return FALSE; +#if GTK_CHECK_VERSION (3, 0, 0) + color.red = dropped [0]; + color.green = dropped [1]; + color.blue = dropped [2]; + color.alpha = 1.; +#else color.gdk.red = dropped [0]; color.gdk.green = dropped [1]; color.gdk.blue = dropped [2]; color.alpha = 65535; +#endif panel_profile_set_background_color (toplevel, &color); panel_profile_set_background_type (toplevel, PANEL_BACK_COLOR); |