[epiphany] ephy-embed.c: use 'address' if 'typed-address' is NULL when updating the address



commit 78a3806554cd947dbc78fa4da30ab37d2b968659
Author: Xan Lopez <xan gnome org>
Date:   Mon Jul 20 23:17:58 2009 +0300

    ephy-embed.c: use 'address' if 'typed-address' is NULL when updating the address
    
    Fixes the updating of the current address before the load starts when
    loading pages from the command line (bug #588143)

 embed/ephy-embed.c |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
---
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c
index 18c943f..f7309ae 100644
--- a/embed/ephy-embed.c
+++ b/embed/ephy-embed.c
@@ -202,6 +202,12 @@ load_status_changed_cb (WebKitWebView *view,
   } else {
     EphyWebViewNetState estate = EPHY_WEB_VIEW_STATE_UNKNOWN;
     const char *loading_uri = ephy_web_view_get_typed_address (EPHY_WEB_VIEW (view));
+    /* FIXME: typed address might be NULL when, for example, loading
+       from command line, so try plain address if that's the
+       case. This should be fixed to get the address from just one
+       place... */
+    if (loading_uri == NULL)
+      loading_uri = ephy_web_view_get_address (EPHY_WEB_VIEW (view));
 
     if (status == WEBKIT_LOAD_PROVISIONAL) {
       estate = (EphyWebViewNetState) (estate |



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