[gnome-calculator] Add keyboard shortcut for new window



commit 6180f31cf837c0da0f21b41cba3b2b62376dd1b7
Author: Robert Roth <robert roth off gmail com>
Date:   Tue Oct 18 14:38:22 2016 +0300

    Add keyboard shortcut for new window

 data/menu.ui              |    3 ++-
 src/gnome-calculator.vala |    2 +-
 2 files changed, 3 insertions(+), 2 deletions(-)
---
diff --git a/data/menu.ui b/data/menu.ui
index d7c25a8..25f0bf5 100644
--- a/data/menu.ui
+++ b/data/menu.ui
@@ -5,7 +5,8 @@
     <section>
       <item>
         <attribute name="label" translatable="yes">New Window</attribute>
-        <attribute name="action">app.new_window</attribute>
+        <attribute name="action">app.newwindow</attribute>
+        <attribute name="accel">&lt;Primary&gt;n</attribute>
       </item>
     </section>
     <section>
diff --git a/src/gnome-calculator.vala b/src/gnome-calculator.vala
index 80ded6e..833fb44 100644
--- a/src/gnome-calculator.vala
+++ b/src/gnome-calculator.vala
@@ -28,7 +28,7 @@ public class Calculator : Gtk.Application
 
     private const ActionEntry[] app_entries =
     {
-        { "new_window", new_window_cb, null, null, null },
+        { "newwindow", new_window_cb, null, null, null },
         { "preferences", show_preferences_cb, null, null, null },
         { "help", help_cb, null, null, null },
         { "about", about_cb, null, null, null },


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]