Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(379)

Side by Side Diff: webkit/tools/test_shell/test_shell_webkit_init.cc

Issue 4705007: Don't restrict supported media types in test_shell when running interactively (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/tools/test_shell/test_shell_webkit_init.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "webkit/tools/test_shell/test_shell_webkit_init.h" 5 #include "webkit/tools/test_shell/test_shell_webkit_init.h"
6 6
7 #include "base/metrics/stats_counters.h" 7 #include "base/metrics/stats_counters.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "media/base/media.h" 9 #include "media/base/media.h"
10 #include "third_party/WebKit/WebKit/chromium/public/WebCache.h" 10 #include "third_party/WebKit/WebKit/chromium/public/WebCache.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 DCHECK(appcache_dir_.path().empty()); 65 DCHECK(appcache_dir_.path().empty());
66 } 66 }
67 SimpleAppCacheSystem::InitializeOnUIThread(appcache_dir_.path()); 67 SimpleAppCacheSystem::InitializeOnUIThread(appcache_dir_.path());
68 68
69 WebKit::WebDatabase::setObserver(&database_system_); 69 WebKit::WebDatabase::setObserver(&database_system_);
70 70
71 blob_registry_ = new TestShellWebBlobRegistryImpl(); 71 blob_registry_ = new TestShellWebBlobRegistryImpl();
72 72
73 file_utilities_.set_sandbox_enabled(false); 73 file_utilities_.set_sandbox_enabled(false);
74 74
75 // Restrict the supported media types when running in layout test mode.
76 if (layout_test_mode)
77 mime_registry_.reset(new TestShellWebMimeRegistryImpl());
78 else
79 mime_registry_.reset(new webkit_glue::SimpleWebMimeRegistryImpl());
80
75 #if defined(OS_WIN) 81 #if defined(OS_WIN)
76 // Ensure we pick up the default theme engine. 82 // Ensure we pick up the default theme engine.
77 SetThemeEngine(NULL); 83 SetThemeEngine(NULL);
78 #endif 84 #endif
79 } 85 }
80 86
81 TestShellWebKitInit::~TestShellWebKitInit() { 87 TestShellWebKitInit::~TestShellWebKitInit() {
82 if (RunningOnValgrind()) 88 if (RunningOnValgrind())
83 WebKit::WebCache::clear(); 89 WebKit::WebCache::clear();
84 WebKit::shutdown(); 90 WebKit::shutdown();
(...skipping 21 matching lines...) Expand all
106 "\xff\x00\xff\x00\xff\xff\xff\xff\xff\x7b\x1f\xb1\xc4\x00\x00\x00" 112 "\xff\x00\xff\x00\xff\xff\xff\xff\xff\x7b\x1f\xb1\xc4\x00\x00\x00"
107 "\x09\x70\x48\x59\x73\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a" 113 "\x09\x70\x48\x59\x73\x00\x00\x0b\x13\x00\x00\x0b\x13\x01\x00\x9a"
108 "\x9c\x18\x00\x00\x00\x17\x49\x44\x41\x54\x78\x01\x63\x98\x89\x0a" 114 "\x9c\x18\x00\x00\x00\x17\x49\x44\x41\x54\x78\x01\x63\x98\x89\x0a"
109 "\x18\x50\xb9\x33\x47\xf9\xa8\x01\x32\xd4\xc2\x03\x00\x33\x84\x0d" 115 "\x18\x50\xb9\x33\x47\xf9\xa8\x01\x32\xd4\xc2\x03\x00\x33\x84\x0d"
110 "\x02\x3a\x91\xeb\xa5\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60" 116 "\x02\x3a\x91\xeb\xa5\x00\x00\x00\x00\x49\x45\x4e\x44\xae\x42\x60"
111 "\x82"; 117 "\x82";
112 return WebKit::WebData(red_square, arraysize(red_square)); 118 return WebKit::WebData(red_square, arraysize(red_square));
113 } 119 }
114 return webkit_glue::WebKitClientImpl::loadResource(name); 120 return webkit_glue::WebKitClientImpl::loadResource(name);
115 } 121 }
OLDNEW
« no previous file with comments | « webkit/tools/test_shell/test_shell_webkit_init.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698