fix: devtools allow restoring saved dock state on Windows (#39734)

* fix: devtools allow restoring saved dock state on Windows

* chore: address feedback
This commit is contained in:
Robo 2023-09-07 17:14:01 +09:00 committed by GitHub
parent f6e8544ef6
commit 0a064cece9
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
5 changed files with 30 additions and 15 deletions

View file

@ -2667,14 +2667,6 @@ void WebContents::OpenDevTools(gin::Arguments* args) {
state = "detach";
}
#if BUILDFLAG(IS_WIN)
auto* win = static_cast<NativeWindowViews*>(owner_window());
// Force a detached state when WCO is enabled to match Chrome
// behavior and prevent occlusion of DevTools.
if (win && win->IsWindowControlsOverlayEnabled())
state = "detach";
#endif
bool activate = true;
std::string title;
if (args && args->Length() == 1) {