aboutsummaryrefslogtreecommitdiffstats
path: root/embed/ephy-embed.c
diff options
context:
space:
mode:
Diffstat (limited to 'embed/ephy-embed.c')
-rw-r--r--embed/ephy-embed.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c
index a91509c26..a465a142a 100644
--- a/embed/ephy-embed.c
+++ b/embed/ephy-embed.c
@@ -298,12 +298,19 @@ load_changed_cb (WebKitWebView *web_view,
WebKitLoadEvent load_event,
EphyEmbed *embed)
{
- const char *address;
+ switch (load_event) {
+ case WEBKIT_LOAD_STARTED: {
+ const char *uri;
- if (load_event == WEBKIT_LOAD_COMMITTED) {
+ uri = webkit_web_view_get_uri (web_view);
+ ephy_embed_set_overview_mode (embed, strcmp (uri, "ephy-about:overview") == 0);
+ break;
+ }
+ case WEBKIT_LOAD_COMMITTED:
ephy_embed_destroy_top_widgets (embed);
- address = ephy_web_view_get_address (EPHY_WEB_VIEW (web_view));
- ephy_embed_set_overview_mode (embed, strcmp (address, "ephy-about:overview") == 0);
+ break;
+ default:
+ break;
}
}
#else