| Index: services/video_capture/video_capture_device_factory_impl.cc
|
| diff --git a/services/video_capture/video_capture_device_factory_impl.cc b/services/video_capture/video_capture_device_factory_impl.cc
|
| index ea3309fa18192d4b926dd079b4a152151b5d19de..4ac8e436df4fad154517630579441ee041f94387 100644
|
| --- a/services/video_capture/video_capture_device_factory_impl.cc
|
| +++ b/services/video_capture/video_capture_device_factory_impl.cc
|
| @@ -46,10 +46,18 @@ bool VideoCaptureDeviceFactoryImpl::DeviceEntry::is_bound() const {
|
| void VideoCaptureDeviceFactoryImpl::DeviceEntry::Bind(
|
| mojom::VideoCaptureDeviceProxyRequest request) {
|
| binding_->Bind(std::move(request));
|
| + binding_->set_connection_error_handler(base::Bind(
|
| + &VideoCaptureDeviceFactoryImpl::DeviceEntry::OnConnectionErrorOrClose,
|
| + base::Unretained(this)));
|
| }
|
|
|
| void VideoCaptureDeviceFactoryImpl::DeviceEntry::Unbind() {
|
| binding_->Unbind();
|
| + device_proxy_->Stop();
|
| +}
|
| +
|
| +void VideoCaptureDeviceFactoryImpl::DeviceEntry::OnConnectionErrorOrClose() {
|
| + Unbind();
|
| }
|
|
|
| VideoCaptureDeviceFactoryImpl::VideoCaptureDeviceFactoryImpl() = default;
|
|
|