diff options
author | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-06-20 13:19:56 +0200 |
---|---|---|
committer | Mike Gabriel <mike.gabriel@das-netzwerkteam.de> | 2017-06-20 13:19:56 +0200 |
commit | 399b52b019cfbe0ffb5eef6ef6ba2e8652f3da61 (patch) | |
tree | fcedff03415db2d8b4c21176adc47d0471d8fa7f /src | |
parent | ae3875242f1d42e895902769810473d7819169d1 (diff) | |
download | arctica-greeter-399b52b019cfbe0ffb5eef6ef6ba2e8652f3da61.tar.gz arctica-greeter-399b52b019cfbe0ffb5eef6ef6ba2e8652f3da61.tar.bz2 arctica-greeter-399b52b019cfbe0ffb5eef6ef6ba2e8652f3da61.zip |
src/background.vala: Drop logo background.
Diffstat (limited to 'src')
-rw-r--r-- | src/background.vala | 25 | ||||
-rw-r--r-- | src/main-window.vala | 2 | ||||
-rw-r--r-- | src/settings.vala | 1 |
3 files changed, 2 insertions, 26 deletions
diff --git a/src/background.vala b/src/background.vala index e94c703..0158488 100644 --- a/src/background.vala +++ b/src/background.vala @@ -415,9 +415,6 @@ public class Background : Gtk.Fixed private Cairo.Surface? version_logo_surface = null; private int version_logo_width; private int version_logo_height; - private Cairo.Surface? background_logo_surface = null; - private int background_logo_width; - private int background_logo_height; public Background (Cairo.Surface target_surface) { @@ -432,10 +429,9 @@ public class Background : Gtk.Fixed notify["current-background"].connect (() => { reload (); }); } - public void set_logo (string version_logo, string background_logo) + public void set_logo (string version_logo) { version_logo_surface = load_image (version_logo, out version_logo_width, out version_logo_height); - background_logo_surface = load_image (background_logo, out background_logo_width, out background_logo_height); } private Cairo.Surface? load_image (string filename, out int width, out int height) @@ -561,25 +557,6 @@ public class Background : Gtk.Fixed c.clip (); c.paint_with_alpha (alpha); c.restore (); - - if (monitor != active_monitor && background_logo_surface != null) - { - var width = background_logo_width; - var height = background_logo_height; - - c.save (); - pattern = new Cairo.Pattern.for_surface (background_logo_surface); - matrix = Cairo.Matrix.identity (); - var x = monitor.x + (monitor.width - width) / 2; - var y = monitor.y + (monitor.height - height) / 2; - matrix.translate (-x, -y); - pattern.set_matrix (matrix); - c.set_source (pattern); - c.rectangle (x, y, width, height); - c.clip (); - c.paint_with_alpha (alpha); - c.restore (); - } } } diff --git a/src/main-window.vala b/src/main-window.vala index 0ae1dec..74c591b 100644 --- a/src/main-window.vala +++ b/src/main-window.vala @@ -56,7 +56,7 @@ public class MainWindow : Gtk.Window 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)); + background.set_logo (AGSettings.get_string (AGSettings.KEY_LOGO)); get_window().end_draw_frame(background_context); background.show (); add (background); diff --git a/src/settings.vala b/src/settings.vala index 8ffc239..4598d7c 100644 --- a/src/settings.vala +++ b/src/settings.vala @@ -26,7 +26,6 @@ public class AGSettings public const string KEY_DRAW_GRID = "draw-grid"; public const string KEY_SHOW_HOSTNAME = "show-hostname"; public const string KEY_LOGO = "logo"; - public const string KEY_BACKGROUND_LOGO = "background-logo"; public const string KEY_THEME_NAME = "theme-name"; public const string KEY_ICON_THEME_NAME = "icon-theme-name"; public const string KEY_FONT_NAME = "font-name"; |