summaryrefslogtreecommitdiffstats
path: root/mojo
diff options
context:
space:
mode:
authoryzshen <yzshen@chromium.org>2015-09-28 15:37:58 -0700
committerCommit bot <commit-bot@chromium.org>2015-09-28 22:39:21 +0000
commitef477f8207be654a75f2009675cbc2413356aca3 (patch)
tree9e62573f5c04047eaeb1527d502410a31236d1b0 /mojo
parentadbece4bf16af98918c7f422a0bd1edec78d0865 (diff)
downloadchromium_src-ef477f8207be654a75f2009675cbc2413356aca3.zip
chromium_src-ef477f8207be654a75f2009675cbc2413356aca3.tar.gz
chromium_src-ef477f8207be654a75f2009675cbc2413356aca3.tar.bz2
Let html_viewer handle more MIME types.
These are types that we've seen on page_cycler.typical_25. BUG= Review URL: https://codereview.chromium.org/1372273002 Cr-Commit-Position: refs/heads/master@{#351174}
Diffstat (limited to 'mojo')
-rw-r--r--mojo/runner/context.cc5
1 files changed, 5 insertions, 0 deletions
diff --git a/mojo/runner/context.cc b/mojo/runner/context.cc
index 0f59f7d..c7bda8c 100644
--- a/mojo/runner/context.cc
+++ b/mojo/runner/context.cc
@@ -62,8 +62,13 @@ class Setup {
void InitContentHandlers(package_manager::PackageManagerImpl* manager,
const base::CommandLine& command_line) {
// Default content handlers.
+ manager->RegisterContentHandler("application/javascript",
+ GURL("mojo:html_viewer"));
manager->RegisterContentHandler("application/pdf", GURL("mojo:pdf_viewer"));
+ manager->RegisterContentHandler("image/gif", GURL("mojo:html_viewer"));
+ manager->RegisterContentHandler("image/jpeg", GURL("mojo:html_viewer"));
manager->RegisterContentHandler("image/png", GURL("mojo:png_viewer"));
+ manager->RegisterContentHandler("text/css", GURL("mojo:html_viewer"));
manager->RegisterContentHandler("text/html", GURL("mojo:html_viewer"));
manager->RegisterContentHandler("text/plain", GURL("mojo:html_viewer"));