fix: getNormalBounds() for transparent windows on Windows (#38347)

fix: getNormalBounds for transparent windows on Windows

Co-authored-by: trop[bot] <37223003+trop[bot]@users.noreply.github.com>
Co-authored-by: Shelley Vohr <shelley.vohr@gmail.com>
This commit is contained in:
trop[bot]
2023-05-22 10:12:45 +02:00
committed by GitHub
parent 53d9cdbaf0
commit d5e1edf244
2 changed files with 21 additions and 0 deletions

View File

@@ -771,6 +771,10 @@ gfx::Size NativeWindowViews::GetContentSize() {
}
gfx::Rect NativeWindowViews::GetNormalBounds() {
#if BUILDFLAG(IS_WIN)
if (IsMaximized() && transparent())
return restore_bounds_;
#endif
return widget()->GetRestoredBounds();
}