| 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 1460 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1471 #else | 1471 #else |
| 1472 OnError(PipelineStatus::DEMUXER_ERROR_COULD_NOT_OPEN); | 1472 OnError(PipelineStatus::DEMUXER_ERROR_COULD_NOT_OPEN); |
| 1473 return; | 1473 return; |
| 1474 #endif | 1474 #endif |
| 1475 } else { | 1475 } else { |
| 1476 DCHECK(!chunk_demuxer_); | 1476 DCHECK(!chunk_demuxer_); |
| 1477 DCHECK(!data_source_); | 1477 DCHECK(!data_source_); |
| 1478 | 1478 |
| 1479 chunk_demuxer_ = new ChunkDemuxer( | 1479 chunk_demuxer_ = new ChunkDemuxer( |
| 1480 BIND_TO_RENDER_LOOP(&WebMediaPlayerImpl::OnDemuxerOpened), | 1480 BIND_TO_RENDER_LOOP(&WebMediaPlayerImpl::OnDemuxerOpened), |
| 1481 encrypted_media_init_data_cb, media_log_, true); | 1481 encrypted_media_init_data_cb, media_log_); |
| 1482 demuxer_.reset(chunk_demuxer_); | 1482 demuxer_.reset(chunk_demuxer_); |
| 1483 } | 1483 } |
| 1484 | 1484 |
| 1485 // TODO(sandersd): FileSystem objects may also be non-static, but due to our | 1485 // TODO(sandersd): FileSystem objects may also be non-static, but due to our |
| 1486 // caching layer such situations are broken already. http://crbug.com/593159 | 1486 // caching layer such situations are broken already. http://crbug.com/593159 |
| 1487 bool is_static = !chunk_demuxer_; | 1487 bool is_static = !chunk_demuxer_; |
| 1488 | 1488 |
| 1489 // ... and we're ready to go! | 1489 // ... and we're ready to go! |
| 1490 seeking_ = true; | 1490 seeking_ = true; |
| 1491 | 1491 |
| (...skipping 324 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1816 pipeline_metadata_.natural_size, | 1816 pipeline_metadata_.natural_size, |
| 1817 base::Bind(&GetCurrentTimeInternal, this))); | 1817 base::Bind(&GetCurrentTimeInternal, this))); |
| 1818 watch_time_reporter_->OnVolumeChange(volume_); | 1818 watch_time_reporter_->OnVolumeChange(volume_); |
| 1819 if (delegate_ && delegate_->IsHidden()) | 1819 if (delegate_ && delegate_->IsHidden()) |
| 1820 watch_time_reporter_->OnHidden(); | 1820 watch_time_reporter_->OnHidden(); |
| 1821 else | 1821 else |
| 1822 watch_time_reporter_->OnShown(); | 1822 watch_time_reporter_->OnShown(); |
| 1823 } | 1823 } |
| 1824 | 1824 |
| 1825 } // namespace media | 1825 } // namespace media |
| OLD | NEW |