fix: win.center() on Windows (#42197)

fix: win.center() 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]
2024-05-16 10:15:54 -07:00
committed by GitHub
parent e4bcd82590
commit b029f38750

View File

@@ -1085,7 +1085,7 @@ void NativeWindowViews::Center() {
#else
HWND hwnd = GetAcceleratedWidget();
gfx::Size size = display::win::ScreenWin::DIPToScreenSize(hwnd, GetSize());
gfx::CenterAndSizeWindow(hwnd, hwnd, size);
gfx::CenterAndSizeWindow(nullptr, hwnd, size);
#endif
}