refactor: use C++11 class member variable initialization (#27477)

This commit is contained in:
Milan Burda
2021-01-26 19:16:21 +01:00
committed by GitHub
parent f083380c38
commit ddf3ef0a5f
93 changed files with 130 additions and 163 deletions

View File

@@ -33,8 +33,7 @@ MediaCaptureDevicesDispatcher* MediaCaptureDevicesDispatcher::GetInstance() {
return base::Singleton<MediaCaptureDevicesDispatcher>::get();
}
MediaCaptureDevicesDispatcher::MediaCaptureDevicesDispatcher()
: is_device_enumeration_disabled_(false) {
MediaCaptureDevicesDispatcher::MediaCaptureDevicesDispatcher() {
// MediaCaptureDevicesDispatcher is a singleton. It should be created on
// UI thread.
DCHECK(BrowserThread::CurrentlyOn(BrowserThread::UI));

View File

@@ -80,7 +80,7 @@ class MediaCaptureDevicesDispatcher : public content::MediaObserver {
blink::MediaStreamDevices test_video_devices_;
// Flag used by unittests to disable device enumeration.
bool is_device_enumeration_disabled_;
bool is_device_enumeration_disabled_ = false;
DISALLOW_COPY_AND_ASSIGN(MediaCaptureDevicesDispatcher);
};