aboutsummaryrefslogtreecommitdiffstats
path: root/src/ephy-window.c
diff options
context:
space:
mode:
authorXan Lopez <xan@gnome.org>2009-06-17 04:20:06 +0800
committerXan Lopez <xan@gnome.org>2009-06-17 04:20:06 +0800
commit2e1e3e4fff9641bfa633f92502f50c2261641048 (patch)
treef7409df5a5e66f3f8e18ef0ea8ed5515a8cac61f /src/ephy-window.c
parent442d30e4e4fa9d97c6b3c0f202e457a8fdf193cf (diff)
downloadgsoc2013-epiphany-2e1e3e4fff9641bfa633f92502f50c2261641048.tar.gz
gsoc2013-epiphany-2e1e3e4fff9641bfa633f92502f50c2261641048.tar.zst
gsoc2013-epiphany-2e1e3e4fff9641bfa633f92502f50c2261641048.zip
ephy-window.c: can't use pspec to figure out if we should sync progress.
Since it breaks syncing when switching between loading tabs. Need to do this properly and wait for webkit bug #26409.
Diffstat (limited to 'src/ephy-window.c')
-rw-r--r--src/ephy-window.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/ephy-window.c b/src/ephy-window.c
index 13121fe10..64275a463 100644
--- a/src/ephy-window.c
+++ b/src/ephy-window.c
@@ -1608,6 +1608,7 @@ sync_tab_load_progress (EphyWebView *view, GParamSpec *pspec, EphyWindow *window
{
gdouble progress;
const char *uri;
+ gboolean loading;
if (window->priv->closing) return;
@@ -1623,15 +1624,13 @@ sync_tab_load_progress (EphyWebView *view, GParamSpec *pspec, EphyWindow *window
for about:blank until the load is finished, so assume NULL
here means we are loading about:blank. This might not be
rigt :) */
- /* When pspec is not NULL it means we are actually loading
- something as oppossed to re-syncing the load state with the
- current view */
+ loading = ephy_web_view_get_load_status (view);
uri = webkit_web_view_get_uri (WEBKIT_WEB_VIEW (view));
- if (pspec && (!uri || strcmp (uri, "about:blank") == 0))
+ if (loading && (!uri || strcmp (uri, "about:blank") == 0))
return;
progress = webkit_web_view_get_progress (WEBKIT_WEB_VIEW (view));
- if (progress == 1.0 && pspec)
+ if (progress == 1.0 && loading)
{
window->priv->clear_progress_timeout_id =
g_timeout_add (500,
@@ -1642,7 +1641,7 @@ sync_tab_load_progress (EphyWebView *view, GParamSpec *pspec, EphyWindow *window
/* Do not set progress in the entry if the load is already
finished */
gtk_entry_set_progress_fraction (GTK_ENTRY (window->priv->entry),
- pspec ? progress : 0.0);
+ loading ? progress : 0.0);
}
static void