| 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 377 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 388 | 388 |
| 389 #if defined(OS_ANDROID) // WMPI_CAST | 389 #if defined(OS_ANDROID) // WMPI_CAST |
| 390 if (isRemote()) { | 390 if (isRemote()) { |
| 391 cast_impl_.play(); | 391 cast_impl_.play(); |
| 392 return; | 392 return; |
| 393 } | 393 } |
| 394 #endif | 394 #endif |
| 395 paused_ = false; | 395 paused_ = false; |
| 396 is_idle_ = false; | 396 is_idle_ = false; |
| 397 pipeline_.SetPlaybackRate(playback_rate_); | 397 pipeline_.SetPlaybackRate(playback_rate_); |
| 398 background_pause_timer_.Stop(); |
| 398 | 399 |
| 399 if (data_source_) | 400 if (data_source_) |
| 400 data_source_->MediaIsPlaying(); | 401 data_source_->MediaIsPlaying(); |
| 401 | 402 |
| 402 DCHECK(watch_time_reporter_); | 403 DCHECK(watch_time_reporter_); |
| 403 watch_time_reporter_->OnPlaying(); | 404 watch_time_reporter_->OnPlaying(); |
| 404 media_log_->AddEvent(media_log_->CreateEvent(MediaLogEvent::PLAY)); | 405 media_log_->AddEvent(media_log_->CreateEvent(MediaLogEvent::PLAY)); |
| 405 UpdatePlayState(); | 406 UpdatePlayState(); |
| 406 } | 407 } |
| 407 | 408 |
| (...skipping 1406 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1814 pipeline_metadata_.natural_size, | 1815 pipeline_metadata_.natural_size, |
| 1815 base::Bind(&GetCurrentTimeInternal, this))); | 1816 base::Bind(&GetCurrentTimeInternal, this))); |
| 1816 watch_time_reporter_->OnVolumeChange(volume_); | 1817 watch_time_reporter_->OnVolumeChange(volume_); |
| 1817 if (delegate_ && delegate_->IsHidden()) | 1818 if (delegate_ && delegate_->IsHidden()) |
| 1818 watch_time_reporter_->OnHidden(); | 1819 watch_time_reporter_->OnHidden(); |
| 1819 else | 1820 else |
| 1820 watch_time_reporter_->OnShown(); | 1821 watch_time_reporter_->OnShown(); |
| 1821 } | 1822 } |
| 1822 | 1823 |
| 1823 } // namespace media | 1824 } // namespace media |
| OLD | NEW |