mirror of
git://source.winehq.org/git/wine.git
synced 2024-10-31 10:41:12 +00:00
Moved a couple of 16-bit functions to user16.c.
This commit is contained in:
parent
f86f51a6e0
commit
c158550998
2 changed files with 56 additions and 55 deletions
|
@ -113,6 +113,51 @@ INT16 WINAPI ShowCursor16(BOOL16 bShow)
|
|||
return ShowCursor(bShow);
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* FillRect (USER.81)
|
||||
* NOTE
|
||||
* The Win16 variant doesn't support special color brushes like
|
||||
* the Win32 one, despite the fact that Win16, as well as Win32,
|
||||
* supports special background brushes for a window class.
|
||||
*/
|
||||
INT16 WINAPI FillRect16( HDC16 hdc, const RECT16 *rect, HBRUSH16 hbrush )
|
||||
{
|
||||
HBRUSH prevBrush;
|
||||
|
||||
/* coordinates are logical so we cannot fast-check 'rect',
|
||||
* it will be done later in the PatBlt().
|
||||
*/
|
||||
|
||||
if (!(prevBrush = SelectObject( HDC_32(hdc), HBRUSH_32(hbrush) ))) return 0;
|
||||
PatBlt( HDC_32(hdc), rect->left, rect->top,
|
||||
rect->right - rect->left, rect->bottom - rect->top, PATCOPY );
|
||||
SelectObject( HDC_32(hdc), prevBrush );
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* InvertRect (USER.82)
|
||||
*/
|
||||
void WINAPI InvertRect16( HDC16 hdc, const RECT16 *rect )
|
||||
{
|
||||
PatBlt( HDC_32(hdc), rect->left, rect->top,
|
||||
rect->right - rect->left, rect->bottom - rect->top, DSTINVERT );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* FrameRect (USER.83)
|
||||
*/
|
||||
INT16 WINAPI FrameRect16( HDC16 hdc, const RECT16 *rect16, HBRUSH16 hbrush )
|
||||
{
|
||||
RECT rect;
|
||||
CONV_RECT16TO32( rect16, &rect );
|
||||
return FrameRect( HDC_32(hdc), &rect, HBRUSH_32(hbrush) );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DrawIcon (USER.84)
|
||||
*/
|
||||
|
@ -873,6 +918,17 @@ DWORD WINAPI DragObject16( HWND16 hwndScope, HWND16 hWnd, UINT16 wObj,
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DrawFocusRect (USER.466)
|
||||
*/
|
||||
void WINAPI DrawFocusRect16( HDC16 hdc, const RECT16* rc )
|
||||
{
|
||||
RECT rect32;
|
||||
CONV_RECT16TO32( rc, &rect32 );
|
||||
DrawFocusRect( HDC_32(hdc), &rect32 );
|
||||
}
|
||||
|
||||
|
||||
/**********************************************************************
|
||||
* DrawFrameControl (USER.656)
|
||||
*/
|
||||
|
|
|
@ -943,29 +943,6 @@ BOOL WINAPI ValidateRect( HWND hwnd, const RECT *rect )
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* FillRect (USER.81)
|
||||
* NOTE
|
||||
* The Win16 variant doesn't support special color brushes like
|
||||
* the Win32 one, despite the fact that Win16, as well as Win32,
|
||||
* supports special background brushes for a window class.
|
||||
*/
|
||||
INT16 WINAPI FillRect16( HDC16 hdc, const RECT16 *rect, HBRUSH16 hbrush )
|
||||
{
|
||||
HBRUSH prevBrush;
|
||||
|
||||
/* coordinates are logical so we cannot fast-check 'rect',
|
||||
* it will be done later in the PatBlt().
|
||||
*/
|
||||
|
||||
if (!(prevBrush = SelectObject( HDC_32(hdc), HBRUSH_32(hbrush) ))) return 0;
|
||||
PatBlt( HDC_32(hdc), rect->left, rect->top,
|
||||
rect->right - rect->left, rect->bottom - rect->top, PATCOPY );
|
||||
SelectObject( HDC_32(hdc), prevBrush );
|
||||
return 1;
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* FillRect (USER32.@)
|
||||
*/
|
||||
|
@ -985,16 +962,6 @@ INT WINAPI FillRect( HDC hdc, const RECT *rect, HBRUSH hbrush )
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* InvertRect (USER.82)
|
||||
*/
|
||||
void WINAPI InvertRect16( HDC16 hdc, const RECT16 *rect )
|
||||
{
|
||||
PatBlt( HDC_32(hdc), rect->left, rect->top,
|
||||
rect->right - rect->left, rect->bottom - rect->top, DSTINVERT );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* InvertRect (USER32.@)
|
||||
*/
|
||||
|
@ -1031,28 +998,6 @@ INT WINAPI FrameRect( HDC hdc, const RECT *rect, HBRUSH hbrush )
|
|||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* FrameRect (USER.83)
|
||||
*/
|
||||
INT16 WINAPI FrameRect16( HDC16 hdc, const RECT16 *rect16, HBRUSH16 hbrush )
|
||||
{
|
||||
RECT rect;
|
||||
CONV_RECT16TO32( rect16, &rect );
|
||||
return FrameRect( HDC_32(hdc), &rect, HBRUSH_32(hbrush) );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DrawFocusRect (USER.466)
|
||||
*/
|
||||
void WINAPI DrawFocusRect16( HDC16 hdc, const RECT16* rc )
|
||||
{
|
||||
RECT rect32;
|
||||
CONV_RECT16TO32( rc, &rect32 );
|
||||
DrawFocusRect( HDC_32(hdc), &rect32 );
|
||||
}
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* DrawFocusRect (USER32.@)
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue