Module: wine Branch: master Commit: 6e9fea22f82fe60624e1081d74ad990a5c428eed URL: http://source.winehq.org/git/wine.git/?a=commit;h=6e9fea22f82fe60624e1081d74...
Author: Rémi Assailly remi.assailly@free.fr Date: Tue Oct 2 20:13:09 2007 +0200
user32: Moved some 16-bit functions.
---
dlls/user32/clipboard.c | 51 ----------------------------------------------- dlls/user32/desktop.c | 9 -------- dlls/user32/user16.c | 27 ++++++++++++++++++++++++ 3 files changed, 27 insertions(+), 60 deletions(-)
diff --git a/dlls/user32/clipboard.c b/dlls/user32/clipboard.c index 137ace9..59d93ab 100644 --- a/dlls/user32/clipboard.c +++ b/dlls/user32/clipboard.c @@ -486,35 +486,6 @@ BOOL WINAPI ChangeClipboardChain(HWND hWnd, HWND hWndNext)
/************************************************************************** - * SetClipboardData (USER.141) - */ -HANDLE16 WINAPI SetClipboardData16(UINT16 wFormat, HANDLE16 hData) -{ - CLIPBOARDINFO cbinfo; - HANDLE16 hResult = 0; - - TRACE("(%04X, %04x) !\n", wFormat, hData); - - /* If it's not owned, data can only be set if the format doesn't exists - and its rendering is not delayed */ - if (!CLIPBOARD_GetClipboardInfo(&cbinfo) || - (!(cbinfo.flags & CB_OWNER) && !hData)) - { - WARN("Clipboard not owned by calling task. Operation failed.\n"); - return 0; - } - - if (USER_Driver->pSetClipboardData(wFormat, hData, 0, cbinfo.flags & CB_OWNER)) - { - hResult = hData; - bCBHasChanged = TRUE; - } - - return hResult; -} - - -/************************************************************************** * SetClipboardData (USER32.@) */ HANDLE WINAPI SetClipboardData(UINT wFormat, HANDLE hData) @@ -586,28 +557,6 @@ BOOL WINAPI IsClipboardFormatAvailable(UINT wFormat)
/************************************************************************** - * GetClipboardData (USER.142) - */ -HANDLE16 WINAPI GetClipboardData16(UINT16 wFormat) -{ - HANDLE16 hData = 0; - CLIPBOARDINFO cbinfo; - - if (!CLIPBOARD_GetClipboardInfo(&cbinfo) || - (~cbinfo.flags & CB_OPEN)) - { - WARN("Clipboard not opened by calling task.\n"); - SetLastError(ERROR_CLIPBOARD_NOT_OPEN); - return 0; - } - - if (!USER_Driver->pGetClipboardData(wFormat, &hData, NULL)) hData = 0; - - return hData; -} - - -/************************************************************************** * GetClipboardData (USER32.@) */ HANDLE WINAPI GetClipboardData(UINT wFormat) diff --git a/dlls/user32/desktop.c b/dlls/user32/desktop.c index 4fbb2d9..40bf184 100644 --- a/dlls/user32/desktop.c +++ b/dlls/user32/desktop.c @@ -188,15 +188,6 @@ BOOL16 WINAPI SetDeskPattern(void)
/*********************************************************************** - * SetDeskWallPaper (USER.285) - */ -BOOL16 WINAPI SetDeskWallPaper16( LPCSTR filename ) -{ - return SetDeskWallPaper( filename ); -} - - -/*********************************************************************** * SetDeskWallPaper (USER32.@) * * FIXME: is there a unicode version? diff --git a/dlls/user32/user16.c b/dlls/user32/user16.c index 1566f2c..f056fbb 100644 --- a/dlls/user32/user16.c +++ b/dlls/user32/user16.c @@ -447,6 +447,24 @@ BOOL16 WINAPI EmptyClipboard16(void)
/************************************************************************** + * SetClipboardData (USER.141) + */ +HANDLE16 WINAPI SetClipboardData16(UINT16 wFormat, HANDLE16 hData) +{ + return HANDLE_16(SetClipboardData(wFormat, HANDLE_32(hData))); +} + + +/************************************************************************** + * GetClipboardData (USER.142) + */ +HANDLE16 WINAPI GetClipboardData16(UINT16 wFormat) +{ + return HANDLE_16(GetClipboardData(wFormat)); +} + + +/************************************************************************** * CountClipboardFormats (USER.143) */ INT16 WINAPI CountClipboardFormats16(void) @@ -983,6 +1001,15 @@ WORD WINAPI GetFreeSystemResources16( WORD resType )
/*********************************************************************** + * SetDeskWallPaper (USER.285) + */ +BOOL16 WINAPI SetDeskWallPaper16( LPCSTR filename ) +{ + return SetDeskWallPaper( filename ); +} + + +/*********************************************************************** * GetClipCursor (USER.309) */ void WINAPI GetClipCursor16( RECT16 *rect )