OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 "chromecast/browser/cast_content_browser_client.h" | 5 #include "chromecast/browser/cast_content_browser_client.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 #include <utility> | 10 #include <utility> |
(...skipping 50 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
61 #include "components/external_video_surface/browser/android/external_video_surfa
ce_container_impl.h" | 61 #include "components/external_video_surface/browser/android/external_video_surfa
ce_container_impl.h" |
62 #else | 62 #else |
63 #include "chromecast/browser/media/cast_browser_cdm_factory.h" | 63 #include "chromecast/browser/media/cast_browser_cdm_factory.h" |
64 #endif // defined(OS_ANDROID) | 64 #endif // defined(OS_ANDROID) |
65 | 65 |
66 namespace chromecast { | 66 namespace chromecast { |
67 namespace shell { | 67 namespace shell { |
68 | 68 |
69 namespace { | 69 namespace { |
70 #if defined(ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS) | 70 #if defined(ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS) |
71 static std::unique_ptr<mojo::ShellClient> CreateCastMojoMediaApplication( | 71 static std::unique_ptr<shell::ShellClient> CreateCastMojoMediaApplication( |
72 CastContentBrowserClient* browser_client) { | 72 CastContentBrowserClient* browser_client) { |
73 std::unique_ptr<media::CastMojoMediaClient> mojo_media_client( | 73 std::unique_ptr<media::CastMojoMediaClient> mojo_media_client( |
74 new media::CastMojoMediaClient( | 74 new media::CastMojoMediaClient( |
75 base::Bind(&CastContentBrowserClient::CreateMediaPipelineBackend, | 75 base::Bind(&CastContentBrowserClient::CreateMediaPipelineBackend, |
76 base::Unretained(browser_client)))); | 76 base::Unretained(browser_client)))); |
77 return std::unique_ptr<mojo::ShellClient>(new media::CastMojoMediaApplication( | 77 return std::unique_ptr<shell::ShellClient>( |
78 std::move(mojo_media_client), browser_client->GetMediaTaskRunner())); | 78 new media::CastMojoMediaApplication( |
| 79 std::move(mojo_media_client), browser_client->GetMediaTaskRunner())); |
79 } | 80 } |
80 #endif // ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS | 81 #endif // ENABLE_MOJO_MEDIA_IN_BROWSER_PROCESS |
81 } // namespace | 82 } // namespace |
82 | 83 |
83 CastContentBrowserClient::CastContentBrowserClient() | 84 CastContentBrowserClient::CastContentBrowserClient() |
84 : cast_browser_main_parts_(nullptr), | 85 : cast_browser_main_parts_(nullptr), |
85 url_request_context_factory_(new URLRequestContextFactory()) {} | 86 url_request_context_factory_(new URLRequestContextFactory()) {} |
86 | 87 |
87 CastContentBrowserClient::~CastContentBrowserClient() { | 88 CastContentBrowserClient::~CastContentBrowserClient() { |
88 content::BrowserThread::DeleteSoon( | 89 content::BrowserThread::DeleteSoon( |
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
490 process_type, dumps_path, false /* upload */); | 491 process_type, dumps_path, false /* upload */); |
491 // StartUploaderThread() even though upload is diferred. | 492 // StartUploaderThread() even though upload is diferred. |
492 // Breakpad-related memory is freed in the uploader thread. | 493 // Breakpad-related memory is freed in the uploader thread. |
493 crash_handler->StartUploaderThread(); | 494 crash_handler->StartUploaderThread(); |
494 return crash_handler; | 495 return crash_handler; |
495 } | 496 } |
496 #endif // !defined(OS_ANDROID) | 497 #endif // !defined(OS_ANDROID) |
497 | 498 |
498 } // namespace shell | 499 } // namespace shell |
499 } // namespace chromecast | 500 } // namespace chromecast |
OLD | NEW |