| 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/support/webkit_support.h" | 5 #include "webkit/support/webkit_support.h" |
| 6 | 6 |
| 7 #include "base/at_exit.h" | 7 #include "base/at_exit.h" |
| 8 #include "base/base64.h" | 8 #include "base/base64.h" |
| 9 #include "base/command_line.h" | 9 #include "base/command_line.h" |
| 10 #include "base/debug/debugger.h" | 10 #include "base/debug/debugger.h" |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 311 } | 311 } |
| 312 | 312 |
| 313 WebKit::WebMediaPlayer* CreateMediaPlayer(WebFrame* frame, | 313 WebKit::WebMediaPlayer* CreateMediaPlayer(WebFrame* frame, |
| 314 WebMediaPlayerClient* client) { | 314 WebMediaPlayerClient* client) { |
| 315 scoped_ptr<media::MessageLoopFactory> message_loop_factory( | 315 scoped_ptr<media::MessageLoopFactory> message_loop_factory( |
| 316 new media::MessageLoopFactoryImpl()); | 316 new media::MessageLoopFactoryImpl()); |
| 317 | 317 |
| 318 scoped_ptr<media::FilterCollection> collection( | 318 scoped_ptr<media::FilterCollection> collection( |
| 319 new media::FilterCollection()); | 319 new media::FilterCollection()); |
| 320 | 320 |
| 321 scoped_refptr<webkit_media::VideoRendererImpl> video_renderer( | |
| 322 new webkit_media::VideoRendererImpl(false)); | |
| 323 collection->AddVideoRenderer(video_renderer); | |
| 324 | |
| 325 scoped_ptr<webkit_media::WebMediaPlayerImpl> result( | 321 scoped_ptr<webkit_media::WebMediaPlayerImpl> result( |
| 326 new webkit_media::WebMediaPlayerImpl( | 322 new webkit_media::WebMediaPlayerImpl( |
| 327 client, | 323 client, |
| 328 base::WeakPtr<webkit_media::WebMediaPlayerDelegate>(), | 324 base::WeakPtr<webkit_media::WebMediaPlayerDelegate>(), |
| 329 collection.release(), | 325 collection.release(), |
| 330 message_loop_factory.release(), | 326 message_loop_factory.release(), |
| 331 NULL, | 327 NULL, |
| 332 new media::MediaLog())); | 328 new media::MediaLog())); |
| 333 if (!result->Initialize(frame, false, video_renderer)) { | 329 if (!result->Initialize(frame, false)) { |
| 334 return NULL; | 330 return NULL; |
| 335 } | 331 } |
| 336 return result.release(); | 332 return result.release(); |
| 337 } | 333 } |
| 338 | 334 |
| 339 WebKit::WebApplicationCacheHost* CreateApplicationCacheHost( | 335 WebKit::WebApplicationCacheHost* CreateApplicationCacheHost( |
| 340 WebFrame*, WebKit::WebApplicationCacheHostClient* client) { | 336 WebFrame*, WebKit::WebApplicationCacheHostClient* client) { |
| 341 return SimpleAppCacheSystem::CreateApplicationCacheHost(client); | 337 return SimpleAppCacheSystem::CreateApplicationCacheHost(client); |
| 342 } | 338 } |
| 343 | 339 |
| (...skipping 300 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 644 double GetForegroundTabTimerInterval() { | 640 double GetForegroundTabTimerInterval() { |
| 645 return webkit_glue::kForegroundTabTimerInterval; | 641 return webkit_glue::kForegroundTabTimerInterval; |
| 646 } | 642 } |
| 647 | 643 |
| 648 // Logging | 644 // Logging |
| 649 void EnableWebCoreLogChannels(const std::string& channels) { | 645 void EnableWebCoreLogChannels(const std::string& channels) { |
| 650 webkit_glue::EnableWebCoreLogChannels(channels); | 646 webkit_glue::EnableWebCoreLogChannels(channels); |
| 651 } | 647 } |
| 652 | 648 |
| 653 } // namespace webkit_support | 649 } // namespace webkit_support |
| OLD | NEW |