OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/Source/WebKit/chromium/public/WebCache.h" | 10 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCache.h" |
(...skipping 29 matching lines...) Expand all Loading... |
40 WebKit::WebRuntimeFeatures::enableNotifications(true); | 40 WebKit::WebRuntimeFeatures::enableNotifications(true); |
41 WebKit::WebRuntimeFeatures::enableTouch(true); | 41 WebKit::WebRuntimeFeatures::enableTouch(true); |
42 WebKit::WebRuntimeFeatures::enableIndexedDatabase(true); | 42 WebKit::WebRuntimeFeatures::enableIndexedDatabase(true); |
43 WebKit::WebRuntimeFeatures::enableSpeechInput(true); | 43 WebKit::WebRuntimeFeatures::enableSpeechInput(true); |
44 WebKit::WebRuntimeFeatures::enableFileSystem(true); | 44 WebKit::WebRuntimeFeatures::enableFileSystem(true); |
45 | 45 |
46 // TODO(hwennborg): Enable this once the implementation supports it. | 46 // TODO(hwennborg): Enable this once the implementation supports it. |
47 WebKit::WebRuntimeFeatures::enableDeviceMotion(false); | 47 WebKit::WebRuntimeFeatures::enableDeviceMotion(false); |
48 WebKit::WebRuntimeFeatures::enableDeviceOrientation(true); | 48 WebKit::WebRuntimeFeatures::enableDeviceOrientation(true); |
49 | 49 |
| 50 // Enable experimental I18N API for testing. |
| 51 WebKit::WebRuntimeFeatures::enableJavaScriptI18NAPI(true); |
| 52 |
50 // Load libraries for media and enable the media player. | 53 // Load libraries for media and enable the media player. |
51 FilePath module_path; | 54 FilePath module_path; |
52 WebKit::WebRuntimeFeatures::enableMediaPlayer( | 55 WebKit::WebRuntimeFeatures::enableMediaPlayer( |
53 PathService::Get(base::DIR_MODULE, &module_path) && | 56 PathService::Get(base::DIR_MODULE, &module_path) && |
54 media::InitializeMediaLibrary(module_path)); | 57 media::InitializeMediaLibrary(module_path)); |
55 | 58 |
56 WebKit::WebRuntimeFeatures::enableGeolocation(true); | 59 WebKit::WebRuntimeFeatures::enableGeolocation(true); |
57 | 60 |
58 // Construct and initialize an appcache system for this scope. | 61 // Construct and initialize an appcache system for this scope. |
59 // A new empty temp directory is created to house any cached | 62 // A new empty temp directory is created to house any cached |
(...skipping 216 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
276 } | 279 } |
277 | 280 |
278 WebKit::WebSharedWorkerRepository* | 281 WebKit::WebSharedWorkerRepository* |
279 TestShellWebKitInit::sharedWorkerRepository() { | 282 TestShellWebKitInit::sharedWorkerRepository() { |
280 return NULL; | 283 return NULL; |
281 } | 284 } |
282 | 285 |
283 WebKit::WebGraphicsContext3D* TestShellWebKitInit::createGraphicsContext3D() { | 286 WebKit::WebGraphicsContext3D* TestShellWebKitInit::createGraphicsContext3D() { |
284 return new webkit::gpu::WebGraphicsContext3DInProcessImpl(); | 287 return new webkit::gpu::WebGraphicsContext3DInProcessImpl(); |
285 } | 288 } |
OLD | NEW |