mirror of
https://github.com/libretro/RetroArch
synced 2025-02-21 09:39:56 +00:00
win32: report correct monitor size for regular fullscreen in wgl
This commit is contained in:
parent
a2ea556be5
commit
eaa637aa4b
@ -43,6 +43,7 @@ static bool g_resized;
|
|||||||
|
|
||||||
static bool g_restore_desktop;
|
static bool g_restore_desktop;
|
||||||
|
|
||||||
|
static void monitor_info(MONITORINFOEX *mon, HMONITOR *hm_to_use);
|
||||||
static void gfx_ctx_get_video_size(unsigned *width, unsigned *height);
|
static void gfx_ctx_get_video_size(unsigned *width, unsigned *height);
|
||||||
static void gfx_ctx_destroy(void);
|
static void gfx_ctx_destroy(void);
|
||||||
|
|
||||||
@ -188,10 +189,13 @@ static void gfx_ctx_get_video_size(unsigned *width, unsigned *height)
|
|||||||
{
|
{
|
||||||
if (!g_hwnd)
|
if (!g_hwnd)
|
||||||
{
|
{
|
||||||
RECT screen_rect;
|
HMONITOR hm_to_use = NULL;
|
||||||
GetClientRect(GetDesktopWindow(), &screen_rect);
|
MONITORINFOEX current_mon;
|
||||||
*width = screen_rect.right - screen_rect.left;
|
|
||||||
*height = screen_rect.bottom - screen_rect.top;
|
monitor_info(¤t_mon, &hm_to_use);
|
||||||
|
RECT mon_rect = current_mon.rcMonitor;
|
||||||
|
*width = mon_rect.right - mon_rect.left;
|
||||||
|
*height = mon_rect.bottom - mon_rect.top;
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
Loading…
x
Reference in New Issue
Block a user