summaryrefslogtreecommitdiff
path: root/src/utilities/trigger.vala
diff options
context:
space:
mode:
Diffstat (limited to 'src/utilities/trigger.vala')
-rw-r--r--src/utilities/trigger.vala8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/utilities/trigger.vala b/src/utilities/trigger.vala
index 5373b41..aeed3fb 100644
--- a/src/utilities/trigger.vala
+++ b/src/utilities/trigger.vala
@@ -1,5 +1,5 @@
/////////////////////////////////////////////////////////////////////////
-// Copyright (c) 2011-2015 by Simon Schneegans
+// Copyright (c) 2011-2016 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
@@ -172,6 +172,8 @@ public class Trigger : GLib.Object {
int button = this.get_mouse_button(check_string);
if (button > 0) {
+ check_string = check_string.substring(0, check_string.index_of("button"));
+
this.with_mouse = true;
this.key_code = button;
this.key_sym = button;
@@ -179,6 +181,10 @@ public class Trigger : GLib.Object {
Gtk.accelerator_parse(check_string, null, out this._modifiers);
this.label = Gtk.accelerator_get_label(0, this.modifiers);
+ if (this.label != "") {
+ label += "+";
+ }
+
string button_text = _("Button %i").printf(this.key_code);
if (this.key_code == 1)