| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 <string> | 5 #include <string> |
| 6 | 6 |
| 7 #include "base/bind.h" | 7 #include "base/bind.h" |
| 8 #include "base/message_loop/message_loop.h" | 8 #include "base/message_loop/message_loop.h" |
| 9 #include "content/browser/browser_thread_impl.h" | 9 #include "content/browser/browser_thread_impl.h" |
| 10 #include "content/browser/renderer_host/media/media_stream_settings_requester.h" | 10 #include "content/browser/renderer_host/media/media_stream_settings_requester.h" |
| (...skipping 25 matching lines...) Expand all Loading... |
| 36 "mic_id", | 36 "mic_id", |
| 37 0, | 37 0, |
| 38 0)); | 38 0)); |
| 39 devices->push_back(MediaStreamDevice(MEDIA_DEVICE_VIDEO_CAPTURE, | 39 devices->push_back(MediaStreamDevice(MEDIA_DEVICE_VIDEO_CAPTURE, |
| 40 "camera", | 40 "camera", |
| 41 "camera_id")); | 41 "camera_id")); |
| 42 } | 42 } |
| 43 | 43 |
| 44 protected: | 44 protected: |
| 45 virtual void SetUp() { | 45 virtual void SetUp() { |
| 46 message_loop_.reset(new base::MessageLoop(base::MessageLoop::TYPE_IO)); | 46 message_loop_.reset(new base::MessageLoopForIO); |
| 47 ui_thread_.reset(new BrowserThreadImpl(BrowserThread::UI, | 47 ui_thread_.reset(new BrowserThreadImpl(BrowserThread::UI, |
| 48 message_loop_.get())); | 48 message_loop_.get())); |
| 49 io_thread_.reset(new BrowserThreadImpl(BrowserThread::IO, | 49 io_thread_.reset(new BrowserThreadImpl(BrowserThread::IO, |
| 50 message_loop_.get())); | 50 message_loop_.get())); |
| 51 ui_controller_.reset(new MediaStreamUIController(this)); | 51 ui_controller_.reset(new MediaStreamUIController(this)); |
| 52 } | 52 } |
| 53 | 53 |
| 54 virtual void TearDown() { | 54 virtual void TearDown() { |
| 55 message_loop_->RunUntilIdle(); | 55 message_loop_->RunUntilIdle(); |
| 56 } | 56 } |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 EXPECT_CALL(*this, DevicesAccepted(label_1, _)); | 159 EXPECT_CALL(*this, DevicesAccepted(label_1, _)); |
| 160 EXPECT_CALL(*this, DevicesAccepted(label_2, _)); | 160 EXPECT_CALL(*this, DevicesAccepted(label_2, _)); |
| 161 | 161 |
| 162 message_loop_->RunUntilIdle(); | 162 message_loop_->RunUntilIdle(); |
| 163 | 163 |
| 164 ui_controller_->NotifyUIIndicatorDevicesClosed(label_1); | 164 ui_controller_->NotifyUIIndicatorDevicesClosed(label_1); |
| 165 ui_controller_->NotifyUIIndicatorDevicesClosed(label_2); | 165 ui_controller_->NotifyUIIndicatorDevicesClosed(label_2); |
| 166 } | 166 } |
| 167 | 167 |
| 168 } // namespace content | 168 } // namespace content |
| OLD | NEW |