diff options
author | Christian Persch <chpe@cvs.gnome.org> | 2005-08-22 03:04:24 +0800 |
---|---|---|
committer | Christian Persch <chpe@src.gnome.org> | 2005-08-22 03:04:24 +0800 |
commit | 066f59e93ee61f907a6a061ccc93f919259743ea (patch) | |
tree | c30ba78da1bcb83751a2c2e91cc0a54cfd9895ee | |
parent | 8dca3df0bfb91d1bbae002f6944c9c97a1dffb08 (diff) | |
download | gsoc2013-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.
-rw-r--r-- | ChangeLog | 10 | ||||
-rw-r--r-- | src/ephy-tab.c | 12 |
2 files changed, 14 insertions, 8 deletions
@@ -1,5 +1,15 @@ 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. + +2005-08-21 Christian Persch <chpe@cvs.gnome.org> + * src/ephy-find-toolbar.c: (ephy_find_toolbar_open): Don't empty find entry on Ctrl-F. 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, |