diff options
author | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-07-25 06:51:21 +0200 |
---|---|---|
committer | Jörg Frings-Fürst <debian@jff-webhosting.net> | 2017-07-25 06:51:21 +0200 |
commit | 3b49907c8b012b0a62d6e264f62bf03b13e68a51 (patch) | |
tree | e9acc532002ca7a52810325eee1f16d6d17f9d27 /src/gui/pieOptionsWindow.vala | |
parent | 394ad3b32f9f79775bcac4c6cc2a4dfa74586800 (diff) | |
parent | 334f925d5866faaf6ed36a4269d14bcc7aa86a76 (diff) |
Merge branch 'feature/upstream' into develop
Diffstat (limited to 'src/gui/pieOptionsWindow.vala')
-rw-r--r-- | src/gui/pieOptionsWindow.vala | 21 |
1 files changed, 20 insertions, 1 deletions
diff --git a/src/gui/pieOptionsWindow.vala b/src/gui/pieOptionsWindow.vala index 5440305..ea50a53 100644 --- a/src/gui/pieOptionsWindow.vala +++ b/src/gui/pieOptionsWindow.vala @@ -1,5 +1,5 @@ ///////////////////////////////////////////////////////////////////////// -// Copyright (c) 2011-2016 by Simon Schneegans +// Copyright (c) 2011-2017 by Simon Schneegans // // This program is free software: you can redistribute it and/or modify // it under the terms of the GNU General Public License as published by @@ -46,6 +46,8 @@ public class PieOptionsWindow : GLib.Object { private Gtk.Button? icon_button = null; private Gtk.Image? icon = null; private Gtk.Label? pie_id = null; + private Gtk.Label? hint = null; + private Gtk.Frame? optionsFrame = null; private IconSelectWindow? icon_window = null; @@ -141,6 +143,10 @@ public class PieOptionsWindow : GLib.Object { this.icon_button = builder.get_object("icon-button") as Gtk.Button; this.icon_button.clicked.connect(on_icon_button_clicked); + this.hint = builder.get_object("hint") as Gtk.Label; + + this.optionsFrame = builder.get_object("optionsFrame") as Gtk.Frame; + this.window.delete_event.connect(this.window.hide_on_delete); } catch (GLib.Error e) { @@ -163,6 +169,10 @@ public class PieOptionsWindow : GLib.Object { public void show() { this.window.show_all(); + + if (GLib.Environment.get_variable("XDG_SESSION_TYPE") == "wayland") { + this.optionsFrame.visible = false; + } } ///////////////////////////////////////////////////////////////////// @@ -187,6 +197,15 @@ public class PieOptionsWindow : GLib.Object { this.pie_id.label = "Pie-ID: " + id; this.trigger_button.set_trigger(trigger); this.set_icon(pie.icon); + + if (GLib.Environment.get_variable("XDG_SESSION_TYPE") == "wayland") { + this.trigger_button.set_sensitive(false); + + this.hint.set_line_wrap(true); + this.hint.set_max_width_chars(40); + this.hint.set_justify(Gtk.Justification.RIGHT); + this.hint.set_label(_("Keybindings and some other options are not supported on Wayland. However, you can use the terminial command \"gnome-pie --open %s\" to open this pie. Create a global hotkey in your system settings which executes this command!").printf(id)); + } } ///////////////////////////////////////////////////////////////////// |