winex11: Remove no longer needed helpers.
Signed-off-by: Jacek Caban <jacek@codeweavers.com> Signed-off-by: Huw Davies <huw@codeweavers.com> Signed-off-by: Alexandre Julliard <julliard@winehq.org>
This commit is contained in:
parent
cfb6f9a1e8
commit
523a6eba02
|
@ -118,7 +118,7 @@ static BOOL X11DRV_desktop_get_modes( ULONG_PTR id, DWORD flags, DEVMODEW **new_
|
|||
RECT primary_rect;
|
||||
DEVMODEW *modes;
|
||||
|
||||
primary_rect = get_primary_monitor_rect();
|
||||
primary_rect = NtUserGetPrimaryMonitorRect();
|
||||
screen_width = primary_rect.right - primary_rect.left;
|
||||
screen_height = primary_rect.bottom - primary_rect.top;
|
||||
|
||||
|
@ -166,7 +166,7 @@ static void X11DRV_desktop_free_modes( DEVMODEW *modes )
|
|||
|
||||
static BOOL X11DRV_desktop_get_current_mode( ULONG_PTR id, DEVMODEW *mode )
|
||||
{
|
||||
RECT primary_rect = get_primary_monitor_rect();
|
||||
RECT primary_rect = NtUserGetPrimaryMonitorRect();
|
||||
|
||||
mode->dmFields = DM_DISPLAYORIENTATION | DM_BITSPERPEL | DM_PELSWIDTH | DM_PELSHEIGHT |
|
||||
DM_DISPLAYFLAGS | DM_DISPLAYFREQUENCY | DM_POSITION;
|
||||
|
@ -374,7 +374,7 @@ BOOL CDECL X11DRV_create_desktop( UINT width, UINT height )
|
|||
|
||||
BOOL is_desktop_fullscreen(void)
|
||||
{
|
||||
RECT primary_rect = get_primary_monitor_rect();
|
||||
RECT primary_rect = NtUserGetPrimaryMonitorRect();
|
||||
return (primary_rect.right - primary_rect.left == max_width &&
|
||||
primary_rect.bottom - primary_rect.top == max_height);
|
||||
}
|
||||
|
@ -421,8 +421,8 @@ void X11DRV_resize_desktop( BOOL send_display_change )
|
|||
HWND hwnd = GetDesktopWindow();
|
||||
INT width, height;
|
||||
|
||||
virtual_rect = get_virtual_screen_rect();
|
||||
primary_rect = get_primary_monitor_rect();
|
||||
virtual_rect = NtUserGetVirtualScreenRect();
|
||||
primary_rect = NtUserGetPrimaryMonitorRect();
|
||||
width = primary_rect.right;
|
||||
height = primary_rect.bottom;
|
||||
|
||||
|
|
|
@ -44,7 +44,7 @@ void release_display_device_init_mutex(HANDLE mutex)
|
|||
|
||||
POINT virtual_screen_to_root(INT x, INT y)
|
||||
{
|
||||
RECT virtual = get_virtual_screen_rect();
|
||||
RECT virtual = NtUserGetVirtualScreenRect();
|
||||
POINT pt;
|
||||
|
||||
pt.x = x - virtual.left;
|
||||
|
@ -54,7 +54,7 @@ POINT virtual_screen_to_root(INT x, INT y)
|
|||
|
||||
POINT root_to_virtual_screen(INT x, INT y)
|
||||
{
|
||||
RECT virtual = get_virtual_screen_rect();
|
||||
RECT virtual = NtUserGetVirtualScreenRect();
|
||||
POINT pt;
|
||||
|
||||
pt.x = x + virtual.left;
|
||||
|
@ -62,16 +62,6 @@ POINT root_to_virtual_screen(INT x, INT y)
|
|||
return pt;
|
||||
}
|
||||
|
||||
RECT get_virtual_screen_rect(void)
|
||||
{
|
||||
return NtUserGetVirtualScreenRect();
|
||||
}
|
||||
|
||||
RECT get_primary_monitor_rect(void)
|
||||
{
|
||||
return NtUserGetPrimaryMonitorRect();
|
||||
}
|
||||
|
||||
/* Get the primary monitor rect from the host system */
|
||||
RECT get_host_primary_monitor_rect(void)
|
||||
{
|
||||
|
@ -214,9 +204,9 @@ void X11DRV_DisplayDevices_Update(BOOL send_display_change)
|
|||
HWND foreground;
|
||||
UINT mask = 0;
|
||||
|
||||
old_virtual_rect = get_virtual_screen_rect();
|
||||
old_virtual_rect = NtUserGetVirtualScreenRect();
|
||||
X11DRV_DisplayDevices_Init(TRUE);
|
||||
new_virtual_rect = get_virtual_screen_rect();
|
||||
new_virtual_rect = NtUserGetVirtualScreenRect();
|
||||
|
||||
/* Calculate XReconfigureWMWindow() mask */
|
||||
if (old_virtual_rect.left != new_virtual_rect.left)
|
||||
|
|
|
@ -91,7 +91,7 @@ static BOOL CDECL X11DRV_CreateDC( PHYSDEV *pdev, LPCWSTR device, LPCWSTR output
|
|||
|
||||
physDev->depth = default_visual.depth;
|
||||
physDev->color_shifts = &X11DRV_PALETTE_default_shifts;
|
||||
physDev->dc_rect = get_virtual_screen_rect();
|
||||
physDev->dc_rect = NtUserGetVirtualScreenRect();
|
||||
OffsetRect( &physDev->dc_rect, -physDev->dc_rect.left, -physDev->dc_rect.top );
|
||||
push_dc_driver( pdev, &physDev->dev, &x11drv_funcs.dc_funcs );
|
||||
if (xrender_funcs && !xrender_funcs->pCreateDC( pdev, device, output, initData )) return FALSE;
|
||||
|
|
|
@ -562,7 +562,7 @@ BOOL clip_fullscreen_window( HWND hwnd, BOOL reset )
|
|||
if (!GetMonitorInfoW( monitor, &monitor_info )) return FALSE;
|
||||
if (!grab_fullscreen)
|
||||
{
|
||||
RECT virtual_rect = get_virtual_screen_rect();
|
||||
RECT virtual_rect = NtUserGetVirtualScreenRect();
|
||||
if (!EqualRect( &monitor_info.rcMonitor, &virtual_rect )) return FALSE;
|
||||
if (is_virtual_desktop()) return FALSE;
|
||||
}
|
||||
|
@ -1540,7 +1540,7 @@ BOOL X11DRV_GetCursorPos(LPPOINT pos)
|
|||
*/
|
||||
BOOL X11DRV_ClipCursor( LPCRECT clip )
|
||||
{
|
||||
RECT virtual_rect = get_virtual_screen_rect();
|
||||
RECT virtual_rect = NtUserGetVirtualScreenRect();
|
||||
|
||||
if (!clip) clip = &virtual_rect;
|
||||
|
||||
|
@ -1853,7 +1853,7 @@ static BOOL map_raw_event_coords( XIRawEvent *event, INPUT *input )
|
|||
}
|
||||
if (event->deviceid != thread_data->xi2_current_slave) return FALSE;
|
||||
|
||||
virtual_rect = get_virtual_screen_rect();
|
||||
virtual_rect = NtUserGetVirtualScreenRect();
|
||||
|
||||
if (x->max <= x->min) x_scale = 1;
|
||||
else x_scale = (virtual_rect.right - virtual_rect.left) / (x->max - x->min);
|
||||
|
|
|
@ -1836,7 +1836,7 @@ BOOL X11DRV_CreateDesktopWindow( HWND hwnd )
|
|||
|
||||
if (!width && !height) /* not initialized yet */
|
||||
{
|
||||
RECT rect = get_virtual_screen_rect();
|
||||
RECT rect = NtUserGetVirtualScreenRect();
|
||||
|
||||
SERVER_START_REQ( set_window_pos )
|
||||
{
|
||||
|
@ -2205,7 +2205,7 @@ void X11DRV_ReleaseDC( HWND hwnd, HDC hdc )
|
|||
escape.code = X11DRV_SET_DRAWABLE;
|
||||
escape.drawable = root_window;
|
||||
escape.mode = IncludeInferiors;
|
||||
escape.dc_rect = get_virtual_screen_rect();
|
||||
escape.dc_rect = NtUserGetVirtualScreenRect();
|
||||
OffsetRect( &escape.dc_rect, -2 * escape.dc_rect.left, -2 * escape.dc_rect.top );
|
||||
NtGdiExtEscape( hdc, NULL, 0, X11DRV_ESCAPE, sizeof(escape), (LPSTR)&escape, 0, NULL );
|
||||
}
|
||||
|
@ -2320,7 +2320,7 @@ done:
|
|||
|
||||
static inline BOOL get_surface_rect( const RECT *visible_rect, RECT *surface_rect )
|
||||
{
|
||||
*surface_rect = get_virtual_screen_rect();
|
||||
*surface_rect = NtUserGetVirtualScreenRect();
|
||||
|
||||
if (!IntersectRect( surface_rect, surface_rect, visible_rect )) return FALSE;
|
||||
OffsetRect( surface_rect, -visible_rect->left, -visible_rect->top );
|
||||
|
|
|
@ -699,8 +699,6 @@ extern void X11DRV_X_to_window_rect( struct x11drv_win_data *data, RECT *rect, i
|
|||
extern BOOL is_window_rect_full_screen( const RECT *rect ) DECLSPEC_HIDDEN;
|
||||
extern POINT virtual_screen_to_root( INT x, INT y ) DECLSPEC_HIDDEN;
|
||||
extern POINT root_to_virtual_screen( INT x, INT y ) DECLSPEC_HIDDEN;
|
||||
extern RECT get_virtual_screen_rect(void) DECLSPEC_HIDDEN;
|
||||
extern RECT get_primary_monitor_rect(void) DECLSPEC_HIDDEN;
|
||||
extern RECT get_host_primary_monitor_rect(void) DECLSPEC_HIDDEN;
|
||||
extern RECT get_work_area( const RECT *monitor_rect ) DECLSPEC_HIDDEN;
|
||||
extern void xinerama_init( unsigned int width, unsigned int height ) DECLSPEC_HIDDEN;
|
||||
|
@ -833,7 +831,7 @@ extern void X11DRV_SetPreeditState(HWND hwnd, BOOL fOpen) DECLSPEC_HIDDEN;
|
|||
|
||||
static inline BOOL is_window_rect_mapped( const RECT *rect )
|
||||
{
|
||||
RECT virtual_rect = get_virtual_screen_rect();
|
||||
RECT virtual_rect = NtUserGetVirtualScreenRect();
|
||||
return (rect->left < virtual_rect.right &&
|
||||
rect->top < virtual_rect.bottom &&
|
||||
max( rect->right, rect->left + 1 ) > virtual_rect.left &&
|
||||
|
|
Loading…
Reference in New Issue