[cheese/wip/tidying: 4/6] Remove mode and shoot actions from the app menu



commit 92c979cd3495f4d159db7991e5c5b84f86254bbd
Author: David King <amigadave amigadave com>
Date:   Fri Nov 8 21:17:21 2013 +0000

    Remove mode and shoot actions from the app menu
    
    The current GNOME HIG suggests that actions which are already accessible
    from the application window should not be duplicated in the application
    menu:
    
    https://wiki.gnome.org/Design/HIG/ApplicationMenus

 src/cheese-application.vala |   21 +++------------------
 1 files changed, 3 insertions(+), 18 deletions(-)
---
diff --git a/src/cheese-application.vala b/src/cheese-application.vala
index 253e57c..8cc46f1 100644
--- a/src/cheese-application.vala
+++ b/src/cheese-application.vala
@@ -112,30 +112,13 @@ public class Cheese.Application : Gtk.Application
             Environment.set_application_name (_("Cheese"));
             Window.set_default_icon_name ("cheese");
 
-            Gtk.IconTheme.get_default ().append_search_path (GLib.Path.build_filename 
(Config.PACKAGE_DATADIR, "icons"));
-
             // Create the menus.
             var menu = new GLib.Menu ();
             var section = new GLib.Menu ();
             menu.append_section (null, section);
-            var item = new GLib.MenuItem (_("_Shoot"), "app.shoot");
-            item.set_attribute ("accel", "s", "space");
-            section.append_item (item);
-            section = new GLib.Menu ();
-            menu.append_section (_("Mode:"), section);
-            section.append (_("_Photo"), "app.mode::photo");
-            section.append (_("_Video"), "app.mode::video");
-            section.append (_("_Burst"), "app.mode::burst");
-            section = new GLib.Menu ();
-            menu.append_section (null, section);
-            item = new GLib.MenuItem (_("_Fullscreen"), "app.fullscreen");
+            var item = new GLib.MenuItem (_("_Fullscreen"), "app.fullscreen");
             item.set_attribute ("accel", "s", "F11");
             section.append_item (item);
-            section = new GLib.Menu ();
-            menu.append_section (null, section);
-            section.append (_("_Effects"), "app.effects");
-            section = new GLib.Menu ();
-            menu.append_section (null, section);
             section.append (_("P_references"), "app.preferences");
             section = new GLib.Menu ();
             menu.append_section (null, section);
@@ -148,6 +131,8 @@ public class Cheese.Application : Gtk.Application
             section.append_item (item);
             set_app_menu (menu);
 
+            this.add_accelerator ("space", "app.shoot", null);
+
             // FIXME: Push these into the main window initialization.
             main_window.setup_ui ();
             main_window.start_thumbview_monitors ();


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