summaryrefslogtreecommitdiffstats
path: root/src/virt-viewer.xml
diff options
context:
space:
mode:
authorEduardo Lima (Etrunko) <etrunko@redhat.com>2015-12-09 18:11:37 -0200
committerFabiano FidĂȘncio <fidencio@redhat.com>2016-02-18 21:45:56 +0100
commita9ce19f84864cc402ea1b4682a94fe53895bb13f (patch)
tree167a3de3998be59443ec506944d06f9eb675d4d2 /src/virt-viewer.xml
parent7a54b96dbebfeb44f73a3e48e11f32006763a3b6 (diff)
downloadvirt-viewer-a9ce19f84864cc402ea1b4682a94fe53895bb13f.tar.gz
virt-viewer-a9ce19f84864cc402ea1b4682a94fe53895bb13f.tar.xz
virt-viewer-a9ce19f84864cc402ea1b4682a94fe53895bb13f.zip
Port to GtkApplication API's
Most of this patch consists in code being shuffled around to fit the expected flow while using the new APIs. I tried my best to make this patch the less intrusive as possible. Main changes are: - Updated build requirements * glib version 2.38 * gtk+ version 3.10 * gio - VirtViewerApp is now a subclass of GtkApplication. Some mainloop calls were replaced: * gtk_main() -> g_application_run() * gtk_quit() -> g_application_quit() - Unified command line option handling. The logic has moved from the main functions and split in common options, and specific ones for each application. With this, the main functions were highly simplified, and now basically responsible for instantiating the App object and running the main loop. - All Window objects must be associated with the Application. With this, there is no need to emit our own 'window-added'/'window- removed' signals, as those will be emited by GtkApplication whenever gtk_application_add_window() and gtk_application_remove_window() are called. Also, 'window-removed' was not being used anywhere. Signed-off-by: Eduardo Lima (Etrunko) <etrunko@redhat.com>
Diffstat (limited to 'src/virt-viewer.xml')
-rw-r--r--src/virt-viewer.xml2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/virt-viewer.xml b/src/virt-viewer.xml
index 07948bd..03f2f84 100644
--- a/src/virt-viewer.xml
+++ b/src/virt-viewer.xml
@@ -2,7 +2,7 @@
<interface>
<!-- interface-requires gtk+ 2.6 -->
<object class="GtkAccelGroup" id="accelgroup"/>
- <object class="GtkWindow" id="viewer">
+ <object class="GtkApplicationWindow" id="viewer">
<property name="can_focus">False</property>
<property name="default_width">1024</property>
<property name="default_height">768</property>