Re: [virt-manager][PATCH] Do not show manager window at startup if user requested to show any other window from command line.

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

 



Hey,

It has been quite some time since I last touched this topic here, but I would like to try to continue the discussion about providing something between virt-viewer and virt-manager for end-users whose basic necessity is to have access to the remote console but sometimes need to have some kind of control over the virtual machine, even though he/she doesn't want to interact with any other complexities related to the virtual machine management provided by virt-manager.

My first approach was to make this changes in virt-viewer, which was NACK by community. Suggestions were: create a third application in virt-viewer source code besides virt-viewer and remove-viewer to accomplish what I was trying to do or improve virt-manager to have the features I was looking for. I definitely prefer the later, and that's what I am trying to acomplish with the latest patch.

Although virt-manager has an option to start the console viewer (or any other details window) upon start, the manager window is always started as well. What I want is to avoid the manager window to be shown by default, so that a user not interested in dealing with all the details of the manager window can use the console view with a little bit more of control over the VM than is provided in virt-viewer.

Best regards,

Leonardo Garcia

On 05/29/2013 06:43 PM, lagarcia@xxxxxxxxxxxxxxxxxx wrote:
From: Leonardo Garcia <lagarcia@xxxxxxxxxx>

---
  virt-manager          |    1 +
  virtManager/engine.py |    7 +++++--
  2 files changed, 6 insertions(+), 2 deletions(-)

diff --git a/virt-manager b/virt-manager
index 4c01ccc..5b237a6 100755
--- a/virt-manager
+++ b/virt-manager
@@ -285,6 +285,7 @@ def main():
              return _conn_state_changed(conn, engine, options.show,
                                         options.uri, options.uuid)
          engine.uri_cb = cb
+        engine.show_manager_window = False


      # Finally start the app for real
diff --git a/virtManager/engine.py b/virtManager/engine.py
index 621d7c3..16ed552 100644
--- a/virtManager/engine.py
+++ b/virtManager/engine.py
@@ -118,6 +118,7 @@ class vmmEngine(vmmGObject):
          self.skip_autostart = False
          self.uri_at_startup = None
          self.uri_cb = None
+        self.show_manager_window = True

          self.init_systray()

@@ -132,7 +133,10 @@ class vmmEngine(vmmGObject):


      def _activate(self, ignore):
-        self.show_manager()
+        if self.show_manager_window:
+            self.show_manager()
+        else:
+            self.get_manager()
          self.application.add_window(self._appwindow)

          if self.uri_at_startup:
@@ -444,7 +448,6 @@ class vmmEngine(vmmGObject):
              if autoconnect is not None:
                  conn.set_autoconnect(bool(autoconnect))

-            self.show_manager()
              if do_start:
                  conn.open()
              return conn

_______________________________________________
virt-tools-list mailing list
virt-tools-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/virt-tools-list




[Index of Archives]     [Linux Virtualization]     [KVM Development]     [CentOS Virtualization]     [Netdev]     [Ethernet Bridging]     [Linux Wireless]     [Kernel Newbies]     [Security]     [Linux for Hams]     [Netfilter]     [Bugtraq]     [Yosemite Forum]     [MIPS Linux]     [ARM Linux]     [Linux RAID]     [Linux Admin]     [Samba]     [Video 4 Linux]

  Powered by Linux