aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Gabriel <mike.gabriel@das-netzwerkteam.de>2017-05-17 16:46:38 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2017-05-17 16:46:38 +0200
commitf238d62e507861649676b746ff9366ba263503dc (patch)
tree52cca123bb98ff5e4b8efe2b3fa119d3503e40b2
parentaa15b9427f7e8583463440f9c89e1919b81cfcd0 (diff)
downloadarctica-greeter-f238d62e507861649676b746ff9366ba263503dc.tar.gz
arctica-greeter-f238d62e507861649676b746ff9366ba263503dc.tar.bz2
arctica-greeter-f238d62e507861649676b746ff9366ba263503dc.zip
Gdk.cairo_create() has been deprecated in GTK 3.22. Use Gdk.Window.begin_draw_frame() instead.
-rw-r--r--src/main-window.vala5
1 files changed, 4 insertions, 1 deletions
diff --git a/src/main-window.vala b/src/main-window.vala
index b818968..13b26ad 100644
--- a/src/main-window.vala
+++ b/src/main-window.vala
@@ -51,10 +51,13 @@ public class MainWindow : Gtk.Window
ArcticaGreeter.add_style_class (this);
realize ();
- background = new Background (Gdk.cairo_create (get_window ()).get_target ());
+ Gdk.DrawingContext background_context;
+ background_context = get_window().begin_draw_frame(get_window().get_visible_region());
+ background = new Background (background_context.get_cairo_context().get_target());
background.draw_grid = AGSettings.get_boolean (AGSettings.KEY_DRAW_GRID);
background.default_background = AGSettings.get_string (AGSettings.KEY_BACKGROUND);
background.set_logo (AGSettings.get_string (AGSettings.KEY_LOGO), AGSettings.get_string (AGSettings.KEY_BACKGROUND_LOGO));
+ get_window().end_draw_frame(background_context);
background.show ();
add (background);
ArcticaGreeter.add_style_class (background);