[gnome-boxes/wip/clone: 4/16] actions-popover: No properties for under-import VM



commit 90966aba285e9b132fc5de6a93ccbc64bbcea800
Author: Zeeshan Ali (Khattak) <zeeshanak gnome org>
Date:   Tue May 3 18:02:58 2016 +0100

    actions-popover: No properties for under-import VM
    
    If the VM is being imported, do not allow user to go to it's properties.
    Hardly any option will work while importing so why bother.

 src/actions-popover.vala |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)
---
diff --git a/src/actions-popover.vala b/src/actions-popover.vala
index 815d1fa..927076b 100644
--- a/src/actions-popover.vala
+++ b/src/actions-popover.vala
@@ -81,6 +81,8 @@ private class Boxes.ActionsPopover: Gtk.Popover {
         section = new GLib.Menu ();
         section.append (_("Properties"), "box.properties");
         menu.append_section (null, section);
+        var action = action_group.lookup_action ("properties") as GLib.SimpleAction;
+        action.set_enabled (!importing);
 
         bind_model (menu, null);
         window.current_item = item;


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