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 "media/blink/webmediaplayer_impl.h" | 5 #include "media/blink/webmediaplayer_impl.h" |
6 | 6 |
7 #include <algorithm> | 7 #include <algorithm> |
8 #include <cmath> | 8 #include <cmath> |
9 #include <limits> | 9 #include <limits> |
10 #include <string> | 10 #include <string> |
(...skipping 313 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
324 if (!defer_load_cb_.is_null()) { | 324 if (!defer_load_cb_.is_null()) { |
325 defer_load_cb_.Run(base::Bind(&WebMediaPlayerImpl::DoLoad, AsWeakPtr(), | 325 defer_load_cb_.Run(base::Bind(&WebMediaPlayerImpl::DoLoad, AsWeakPtr(), |
326 load_type, url, cors_mode)); | 326 load_type, url, cors_mode)); |
327 return; | 327 return; |
328 } | 328 } |
329 DoLoad(load_type, url, cors_mode); | 329 DoLoad(load_type, url, cors_mode); |
330 } | 330 } |
331 | 331 |
332 bool WebMediaPlayerImpl::SupportsOverlayFullscreenVideo() { | 332 bool WebMediaPlayerImpl::SupportsOverlayFullscreenVideo() { |
333 #if defined(OS_ANDROID) | 333 #if defined(OS_ANDROID) |
334 return true; | 334 return !using_media_player_renderer_; |
335 #else | 335 #else |
336 return false; | 336 return false; |
337 #endif | 337 #endif |
338 } | 338 } |
339 | 339 |
340 void WebMediaPlayerImpl::EnableOverlay() { | 340 void WebMediaPlayerImpl::EnableOverlay() { |
341 overlay_enabled_ = true; | 341 overlay_enabled_ = true; |
342 if (surface_manager_) { | 342 if (surface_manager_) { |
343 surface_created_cb_.Reset( | 343 surface_created_cb_.Reset( |
344 base::Bind(&WebMediaPlayerImpl::OnSurfaceCreated, AsWeakPtr())); | 344 base::Bind(&WebMediaPlayerImpl::OnSurfaceCreated, AsWeakPtr())); |
(...skipping 2053 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2398 | 2398 |
2399 if (is_encrypted_) | 2399 if (is_encrypted_) |
2400 UMA_HISTOGRAM_VIDEO_HEIGHT("Media.VideoHeight.Initial.EME", height); | 2400 UMA_HISTOGRAM_VIDEO_HEIGHT("Media.VideoHeight.Initial.EME", height); |
2401 | 2401 |
2402 UMA_HISTOGRAM_VIDEO_HEIGHT("Media.VideoHeight.Initial.All", height); | 2402 UMA_HISTOGRAM_VIDEO_HEIGHT("Media.VideoHeight.Initial.All", height); |
2403 } | 2403 } |
2404 | 2404 |
2405 #undef UMA_HISTOGRAM_VIDEO_HEIGHT | 2405 #undef UMA_HISTOGRAM_VIDEO_HEIGHT |
2406 | 2406 |
2407 } // namespace media | 2407 } // namespace media |
OLD | NEW |