From 8415cf6da16201127aadb7853e3969ed824de919 Mon Sep 17 00:00:00 2001 From: Claudio Saavedra Date: Tue, 21 Jun 2011 01:17:06 +0300 Subject: Implement GtkApplication based activation and uniqueness This replaces the existing dbus-glib activation and uniqueness code. The changes are kept to the minimum necessary to make all the features work, but there are still some optimizations possible (like doing most of the initialization in ephy_application_startup() when we know we are not remoting). These changes are left for later to avoid making this patch huge. Command-line parameter parsing is done in the main method and parameters are passed to the application through a EphyApplicationStartupContext structure, which is later passed as a GVariant to the primare instance. This way we avoid moving the GOption code out of the place where it's intended to run: in the main() method. Based in work by Alexandre Mazari. https://bugzilla.gnome.org/show_bug.cgi?id=637334 --- src/ephy-window.c | 2 ++ 1 file changed, 2 insertions(+) (limited to 'src/ephy-window.c') diff --git a/src/ephy-window.c b/src/ephy-window.c index 006915126..28031e545 100644 --- a/src/ephy-window.c +++ b/src/ephy-window.c @@ -3825,6 +3825,8 @@ ephy_window_constructor (GType type, proxies = gtk_action_get_proxies (action); proxy = GTK_WIDGET (proxies->data); priv->entry = ephy_location_entry_get_entry (EPHY_LOCATION_ENTRY (proxy)); + gtk_window_set_application (GTK_WINDOW (window), + GTK_APPLICATION (ephy_shell_get_application (ephy_shell_get_default ()))); return object; } -- cgit v1.2.3