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

* fix: devtools allow restoring saved dock state on Windows

Co-authored-by: deepak1556 <hop2deep@gmail.com>

* chore: address feedback

Co-authored-by: deepak1556 <hop2deep@gmail.com>

---------

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: deepak1556 <hop2deep@gmail.com>
This commit is contained in:
trop[bot]
2023-09-07 11:42:02 +02:00
committed by GitHub
parent 3901b38e01
commit c14f5369af
5 changed files with 30 additions and 15 deletions

View File

@@ -2653,14 +2653,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) {