aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorChristian Persch <chpe@cvs.gnome.org>2005-08-22 03:04:24 +0800
committerChristian Persch <chpe@src.gnome.org>2005-08-22 03:04:24 +0800
commit066f59e93ee61f907a6a061ccc93f919259743ea (patch)
treec30ba78da1bcb83751a2c2e91cc0a54cfd9895ee /src
parent8dca3df0bfb91d1bbae002f6944c9c97a1dffb08 (diff)
downloadgsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar.gz
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar.bz2
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar.lz
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar.xz
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.tar.zst
gsoc2013-epiphany-066f59e93ee61f907a6a061ccc93f919259743ea.zip
Fix the check for unchanged address to check if we even have a monitor at
2005-08-21 Christian Persch <chpe@cvs.gnome.org> * src/ephy-tab.c: (ephy_tab_update_file_monitor): Fix the check for unchanged address to check if we even have a monitor at all. Fixes auto-reload on a file:// URI loaded after a blank page. Also modify the 'is local' check to just check for file:// prefix on URI.
Diffstat (limited to 'src')
-rw-r--r--src/ephy-tab.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/src/ephy-tab.c b/src/ephy-tab.c
index d23667c12..236e946ac 100644
--- a/src/ephy-tab.c
+++ b/src/ephy-tab.c
@@ -1324,11 +1324,12 @@ ephy_tab_update_file_monitor (EphyTab *tab,
{
EphyTabPrivate *priv = tab->priv;
GnomeVFSMonitorHandle *handle = NULL;
- GnomeVFSURI *uri;
gboolean local;
- if (priv->address != NULL && address != NULL &&
+ if (priv->monitor != NULL &&
+ priv->address != NULL && address != NULL &&
strcmp (priv->address, address) == 0)
+
{
/* same address, no change needed */
return;
@@ -1336,12 +1337,7 @@ ephy_tab_update_file_monitor (EphyTab *tab,
ephy_tab_file_monitor_cancel (tab);
- uri = gnome_vfs_uri_new (address);
- if (uri == NULL) return;
-
- local = gnome_vfs_uri_is_local (uri);
- gnome_vfs_uri_unref (uri);
-
+ local = g_str_has_prefix (address, "file://");
if (local == FALSE) return;
if (gnome_vfs_monitor_add (&handle, address,