Chromium Code Reviews| Index: media/cast/cast_environment.cc |
| diff --git a/media/cast/cast_environment.cc b/media/cast/cast_environment.cc |
| index dddec1649f57ec3972f6ee54f31128a4367c4eba..16b396ebc9d52ada3588845ff3586f2d72736477 100644 |
| --- a/media/cast/cast_environment.cc |
| +++ b/media/cast/cast_environment.cc |
| @@ -17,13 +17,18 @@ CastEnvironment::CastEnvironment( |
| scoped_refptr<TaskRunner> audio_encode_thread_proxy, |
| scoped_refptr<TaskRunner> audio_decode_thread_proxy, |
| scoped_refptr<TaskRunner> video_encode_thread_proxy, |
| - scoped_refptr<TaskRunner> video_decode_thread_proxy) |
| + scoped_refptr<TaskRunner> video_decode_thread_proxy, |
| + bool enable_data_collection, |
| + bool enable_uma_stats, |
| + bool enable_tracing) |
| : clock_(clock), |
| main_thread_proxy_(main_thread_proxy), |
| audio_encode_thread_proxy_(audio_encode_thread_proxy), |
| audio_decode_thread_proxy_(audio_decode_thread_proxy), |
| video_encode_thread_proxy_(video_encode_thread_proxy), |
| - video_decode_thread_proxy_(video_decode_thread_proxy) { |
| + video_decode_thread_proxy_(video_decode_thread_proxy), |
| + logging_(new LoggingImpl(clock, main_thread_proxy, |
|
Alpha Left Google
2013/11/14 00:29:24
Use a separate method to start logging instead of
mikhal
2013/11/14 17:42:31
Don't see why.
On 2013/11/14 00:29:24, Alpha wrote
|
| + enable_data_collection, enable_uma_stats, enable_tracing)) { |
| DCHECK(main_thread_proxy) << "Main thread required"; |
| } |
| @@ -62,7 +67,7 @@ scoped_refptr<TaskRunner> CastEnvironment::GetMessageTaskRunnerForThread( |
| case CastEnvironment::VIDEO_DECODER: |
| return video_decode_thread_proxy_; |
| default: |
| - NOTREACHED() << "Invalid Thread ID."; |
| + NOTREACHED() << "Invalid Thread identifier"; |
| return NULL; |
| } |
| } |
| @@ -80,14 +85,18 @@ bool CastEnvironment::CurrentlyOn(ThreadId identifier) { |
| case CastEnvironment::VIDEO_DECODER: |
| return video_decode_thread_proxy_->RunsTasksOnCurrentThread(); |
| default: |
| - NOTREACHED() << "Wrong thread identifier"; |
| + NOTREACHED() << "Invalid thread identifier"; |
| return false; |
| } |
| } |
| -base::TickClock* CastEnvironment::Clock() { |
| +base::TickClock* const CastEnvironment::Clock() const { |
| return clock_; |
| } |
| +LoggingImpl* const CastEnvironment::Logging() { |
| + return logging_.get(); |
|
Alpha Left Google
2013/11/14 00:29:24
Check that this accessor is called on the right th
mikhal
2013/11/14 17:42:31
Added a dcheck
On 2013/11/14 00:29:24, Alpha wrote
|
| +} |
| + |
| } // namespace cast |
| } // namespace media |