OLD | NEW |
1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 "content/renderer/media/android/webmediaplayer_android.h" | 5 #include "content/renderer/media/android/webmediaplayer_android.h" |
6 | 6 |
7 #include <limits> | 7 #include <limits> |
8 | 8 |
9 #include "base/android/build_info.h" | 9 #include "base/android/build_info.h" |
10 #include "base/bind.h" | 10 #include "base/bind.h" |
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
132 cdm_manager_(cdm_manager), | 132 cdm_manager_(cdm_manager), |
133 network_state_(WebMediaPlayer::NetworkStateEmpty), | 133 network_state_(WebMediaPlayer::NetworkStateEmpty), |
134 ready_state_(WebMediaPlayer::ReadyStateHaveNothing), | 134 ready_state_(WebMediaPlayer::ReadyStateHaveNothing), |
135 texture_id_(0), | 135 texture_id_(0), |
136 stream_id_(0), | 136 stream_id_(0), |
137 is_playing_(false), | 137 is_playing_(false), |
138 needs_establish_peer_(true), | 138 needs_establish_peer_(true), |
139 has_size_info_(false), | 139 has_size_info_(false), |
140 // Compositor thread does not exist in layout tests. | 140 // Compositor thread does not exist in layout tests. |
141 compositor_loop_( | 141 compositor_loop_( |
142 RenderThreadImpl::current()->compositor_message_loop_proxy() | 142 RenderThreadImpl::current()->compositor_message_loop_proxy().get() |
143 ? RenderThreadImpl::current()->compositor_message_loop_proxy() | 143 ? RenderThreadImpl::current()->compositor_message_loop_proxy() |
144 : base::MessageLoopProxy::current()), | 144 : base::MessageLoopProxy::current()), |
145 stream_texture_factory_(factory), | 145 stream_texture_factory_(factory), |
146 needs_external_surface_(false), | 146 needs_external_surface_(false), |
147 video_frame_provider_client_(NULL), | 147 video_frame_provider_client_(NULL), |
148 player_type_(MEDIA_PLAYER_TYPE_URL), | 148 player_type_(MEDIA_PLAYER_TYPE_URL), |
149 is_remote_(false), | 149 is_remote_(false), |
150 media_log_(media_log), | 150 media_log_(media_log), |
151 web_cdm_(NULL), | 151 web_cdm_(NULL), |
152 allow_stored_credentials_(false), | 152 allow_stored_credentials_(false), |
(...skipping 1676 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1829 | 1829 |
1830 bool WebMediaPlayerAndroid::IsHLSStream() const { | 1830 bool WebMediaPlayerAndroid::IsHLSStream() const { |
1831 std::string mime; | 1831 std::string mime; |
1832 GURL url = redirected_url_.is_empty() ? url_ : redirected_url_; | 1832 GURL url = redirected_url_.is_empty() ? url_ : redirected_url_; |
1833 if (!net::GetMimeTypeFromFile(base::FilePath(url.path()), &mime)) | 1833 if (!net::GetMimeTypeFromFile(base::FilePath(url.path()), &mime)) |
1834 return false; | 1834 return false; |
1835 return !mime.compare("application/x-mpegurl"); | 1835 return !mime.compare("application/x-mpegurl"); |
1836 } | 1836 } |
1837 | 1837 |
1838 } // namespace content | 1838 } // namespace content |
OLD | NEW |