[epiphany] ephy-web-view: connect to WebView signals in just one place



commit c92bf9e0656c505674df45a5fbf2d34ab7017ca2
Author: Xan Lopez <xan igalia com>
Date:   Thu Mar 15 09:47:52 2012 +0100

    ephy-web-view: connect to WebView signals in just one place

 embed/ephy-web-view.c |   20 ++++++++++++--------
 1 files changed, 12 insertions(+), 8 deletions(-)
---
diff --git a/embed/ephy-web-view.c b/embed/ephy-web-view.c
index 689835a..24443f2 100644
--- a/embed/ephy-web-view.c
+++ b/embed/ephy-web-view.c
@@ -1196,14 +1196,6 @@ hovering_over_link_cb (EphyWebView *web_view,
 static void
 ephy_web_view_constructed (GObject *object)
 {
-  EphyWebView *web_view = EPHY_WEB_VIEW (object);
-
-  g_object_connect (web_view,
-                    "signal::notify::title", G_CALLBACK (title_changed_cb), NULL,
-                    "signal::notify::uri", G_CALLBACK (uri_changed_cb), NULL,
-                    "signal::hovering-over-link", G_CALLBACK (hovering_over_link_cb), NULL,
-                    NULL);
-
   /* Use full content zooming by default */
   /* FIXME: we could make this configurable through GSettings, or have
    * different keys for text and full content zooming. AFAIK you can
@@ -2391,6 +2383,18 @@ ephy_web_view_init (EphyWebView *web_view)
                     G_CALLBACK (zoom_changed_cb),
                     NULL);
 
+  g_signal_connect (web_view, "notify::title",
+                    G_CALLBACK (title_changed_cb),
+                    NULL);
+
+  g_signal_connect (web_view, "notify::uri",
+                    G_CALLBACK (uri_changed_cb),
+                    NULL);
+
+  g_signal_connect (web_view, "hovering-over-link",
+                    G_CALLBACK (hovering_over_link_cb),
+                    NULL);
+
   g_signal_connect_object (web_view, "icon-loaded",
                            G_CALLBACK (favicon_cb),
                            web_view, (GConnectFlags)0);



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