refactor: use gin_helper::Dictionary::ValueOrDefault() (#46982)
* refactor: use ValueOrDefault() in electron_api_web_contents.cc * refactor: use ValueOrDefault() in electron_api_url_loader.cc * refactor: use ValueOrDefault() in electron_download_manager_delegate.cc * refactor: use ValueOrDefault() in electron_touch_bar.mm * refactor: use ValueOrDefault() in electron_url_loader_factory.cc * refactor: use ValueOrDefault() in electron_browser_context.cc * refactor: use ValueOrDefault() in electron_touch_bar.mm * refactor: use ValueOrDefault() in blink_converter.cc * feat: add ValueOrDefault() to PersistentDictionary * empty commit * refactor: use ValueOrDefault() in blink_converter.cc * refactor: inline the rectangle base::Value::Dict * refactor: remove has_scroll temporary --------- Co-authored-by: Deepak Mohan <hop2deep@gmail.com>
This commit is contained in:
parent
aea7b4ae8c
commit
2cbd968da5
8 changed files with 76 additions and 114 deletions
|
|
@ -758,9 +758,9 @@ void ElectronBrowserContext::DisplayMediaDeviceChosen(
|
|||
GetAudioDesktopMediaId(request.requested_audio_device_ids));
|
||||
devices.audio_device = audio_device;
|
||||
} else if (result_dict.Get("audio", &rfh)) {
|
||||
bool enable_local_echo = false;
|
||||
result_dict.Get("enableLocalEcho", &enable_local_echo);
|
||||
bool disable_local_echo = !enable_local_echo;
|
||||
const bool enable_local_echo =
|
||||
result_dict.ValueOrDefault("enableLocalEcho", false);
|
||||
const bool disable_local_echo = !enable_local_echo;
|
||||
auto* web_contents = content::WebContents::FromRenderFrameHost(rfh);
|
||||
blink::MediaStreamDevice audio_device(
|
||||
request.audio_type,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue