OLD | NEW |
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/support/webkit_support.h" | 5 #include "webkit/support/webkit_support.h" |
6 | 6 |
7 #include "app/gfx/gl/gl_implementation.h" | 7 #include "app/gfx/gl/gl_implementation.h" |
8 #include "base/at_exit.h" | 8 #include "base/at_exit.h" |
9 #include "base/base64.h" | 9 #include "base/base64.h" |
10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
11 #include "base/debug/debugger.h" | 11 #include "base/debug/debugger.h" |
12 #include "base/file_path.h" | 12 #include "base/file_path.h" |
13 #include "base/file_util.h" | 13 #include "base/file_util.h" |
14 #include "base/i18n/icu_util.h" | 14 #include "base/i18n/icu_util.h" |
15 #include "base/logging.h" | 15 #include "base/logging.h" |
16 #include "base/message_loop.h" | 16 #include "base/message_loop.h" |
17 #include "base/path_service.h" | 17 #include "base/path_service.h" |
18 #include "base/process_util.h" | 18 #include "base/process_util.h" |
19 #include "base/string_piece.h" | 19 #include "base/string_piece.h" |
20 #include "base/string_util.h" | 20 #include "base/string_util.h" |
21 #include "base/stringprintf.h" | 21 #include "base/stringprintf.h" |
22 #include "base/sys_string_conversions.h" | 22 #include "base/sys_string_conversions.h" |
23 #include "base/time.h" | 23 #include "base/time.h" |
24 #include "base/utf_string_conversions.h" | 24 #include "base/utf_string_conversions.h" |
25 #include "base/weak_ptr.h" | 25 #include "base/weak_ptr.h" |
26 #include "grit/webkit_chromium_resources.h" | 26 #include "grit/webkit_chromium_resources.h" |
| 27 #include "media/base/filter_collection.h" |
27 #include "net/base/escape.h" | 28 #include "net/base/escape.h" |
28 #include "net/base/net_errors.h" | 29 #include "net/base/net_errors.h" |
29 #include "net/base/net_util.h" | 30 #include "net/base/net_util.h" |
30 #include "testing/gtest/include/gtest/gtest.h" | 31 #include "testing/gtest/include/gtest/gtest.h" |
31 #include "third_party/WebKit/WebKit/chromium/public/WebFileSystemCallbacks.h" | 32 #include "third_party/WebKit/WebKit/chromium/public/WebFileSystemCallbacks.h" |
32 #include "third_party/WebKit/WebKit/chromium/public/WebKit.h" | 33 #include "third_party/WebKit/WebKit/chromium/public/WebKit.h" |
33 #include "third_party/WebKit/WebKit/chromium/public/WebPluginParams.h" | 34 #include "third_party/WebKit/WebKit/chromium/public/WebPluginParams.h" |
34 #include "third_party/WebKit/WebKit/chromium/public/WebURLError.h" | 35 #include "third_party/WebKit/WebKit/chromium/public/WebURLError.h" |
35 #include "webkit/appcache/web_application_cache_host_impl.h" | 36 #include "webkit/appcache/web_application_cache_host_impl.h" |
36 #include "webkit/glue/media/buffered_data_source.h" | 37 #include "webkit/glue/media/buffered_data_source.h" |
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
259 &actual_mime_type) || !info.enabled) { | 260 &actual_mime_type) || !info.enabled) { |
260 return NULL; | 261 return NULL; |
261 } | 262 } |
262 | 263 |
263 return new WebPluginImplWithPageDelegate( | 264 return new WebPluginImplWithPageDelegate( |
264 frame, params, info.path, actual_mime_type); | 265 frame, params, info.path, actual_mime_type); |
265 } | 266 } |
266 | 267 |
267 WebKit::WebMediaPlayer* CreateMediaPlayer(WebFrame* frame, | 268 WebKit::WebMediaPlayer* CreateMediaPlayer(WebFrame* frame, |
268 WebMediaPlayerClient* client) { | 269 WebMediaPlayerClient* client) { |
269 scoped_ptr<media::MediaFilterCollection> collection( | 270 scoped_ptr<media::FilterCollection> collection( |
270 new media::MediaFilterCollection()); | 271 new media::FilterCollection()); |
271 | 272 |
272 // TODO(annacc): do we still need appcache_host? http://crbug.com/65135 | 273 // TODO(annacc): do we still need appcache_host? http://crbug.com/65135 |
273 // appcache::WebApplicationCacheHostImpl* appcache_host = | 274 // appcache::WebApplicationCacheHostImpl* appcache_host = |
274 // appcache::WebApplicationCacheHostImpl::FromFrame(frame); | 275 // appcache::WebApplicationCacheHostImpl::FromFrame(frame); |
275 | 276 |
276 scoped_refptr<webkit_glue::VideoRendererImpl> video_renderer( | 277 scoped_refptr<webkit_glue::VideoRendererImpl> video_renderer( |
277 new webkit_glue::VideoRendererImpl(false)); | 278 new webkit_glue::VideoRendererImpl(false)); |
278 collection->AddVideoRenderer(video_renderer); | 279 collection->AddVideoRenderer(video_renderer); |
279 | 280 |
280 scoped_ptr<webkit_glue::WebMediaPlayerImpl> result( | 281 scoped_ptr<webkit_glue::WebMediaPlayerImpl> result( |
(...skipping 249 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
530 | 531 |
531 // FileSystem | 532 // FileSystem |
532 void OpenFileSystem(WebFrame* frame, WebFileSystem::Type type, | 533 void OpenFileSystem(WebFrame* frame, WebFileSystem::Type type, |
533 long long size, bool create, WebFileSystemCallbacks* callbacks) { | 534 long long size, bool create, WebFileSystemCallbacks* callbacks) { |
534 SimpleFileSystem* fileSystem = static_cast<SimpleFileSystem*>( | 535 SimpleFileSystem* fileSystem = static_cast<SimpleFileSystem*>( |
535 test_environment->webkit_client()->fileSystem()); | 536 test_environment->webkit_client()->fileSystem()); |
536 fileSystem->OpenFileSystem(frame, type, size, create, callbacks); | 537 fileSystem->OpenFileSystem(frame, type, size, create, callbacks); |
537 } | 538 } |
538 | 539 |
539 } // namespace webkit_support | 540 } // namespace webkit_support |
OLD | NEW |