diff options
author | Xan Lopez <xan@gnome.org> | 2009-12-08 16:29:08 +0200 |
---|---|---|
committer | Xan Lopez <xan@gnome.org> | 2009-12-16 11:34:43 +0100 |
commit | 26dd4368f537a9bb518e90feb59287643bf57181 (patch) | |
tree | f8ad50275bf06d8a0faf355c2eb3a0fcc81b87cb | |
parent | c140548c90a76c3dcc3297e920b25ebf94eb56ef (diff) | |
download | epiphany-26dd4368f537a9bb518e90feb59287643bf57181.tar.gz |
ephy-embed: consider text/plain pages as document-type HTML
WebKit still thinks of them as HTML documents, and otherwise things
like the text-encoding menu are disabled for them.
Bug #603927
-rw-r--r-- | embed/ephy-embed.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/embed/ephy-embed.c b/embed/ephy-embed.c index d215ed67a..408c59bfe 100644 --- a/embed/ephy-embed.c +++ b/embed/ephy-embed.c @@ -373,14 +373,15 @@ mime_type_policy_decision_requested_cb (WebKitWebView *web_view, if (webkit_web_view_get_main_frame (web_view) == frame) { type = EPHY_WEB_VIEW_DOCUMENT_OTHER; - if (!strcmp (mime_type, "text/html")) + if (!strcmp (mime_type, "text/html") || + !strcmp (mime_type, "text/plain")) type = EPHY_WEB_VIEW_DOCUMENT_HTML; else if (!strcmp (mime_type, "application/xhtml+xml")) type = EPHY_WEB_VIEW_DOCUMENT_XML; else if (!strncmp (mime_type, "image/", 6)) type = EPHY_WEB_VIEW_DOCUMENT_IMAGE; - /* FIXME: mayb e it makes more sense to have an API to query the mime + /* FIXME: maybe it makes more sense to have an API to query the mime * type when the load of a page starts than doing this here. */ /* FIXME: rename ge-document-type (and all ge- signals...) to |