thanks for wine

qingdoa daoo qingdao33122 at
Fri May 12 17:24:13 CDT 2006

A simple test

#include "windows.h"

int APIENTRY WinMain(HINSTANCE inst, HINSTANCE prev, LPSTR cmd, int show)


    HGLOBAL hmem;

    LPSTR   lpstr;



    hmem = GlobalAlloc(GMEM_MOVEABLE, 6);

    lpstr = GlobalLock(hmem);

    lstrcpy(lpstr, "Hello");


    SetClipboardData(CF_TEXT, hmem);


    return 0;


--- Ulrich Czekalla <ulrich.czekalla at>дµÀ:

> On Fri, May 12, 2006 at 04:16:28PM +0800, qingdoa daoo wrote:
> > Now that you brought it up, clipboard in wine does have some limitations. e.g.
> > when a process calls OpenClipboard(hwnd), Windows doesn't seem to care if the
> > hwnd is owned by a thread of the calling process. A process doesn't even have
> >  to have a window in order to grab the clipboard and put something on it. It
> >  can just use the desktop window. Not so with wine.
> This should work in wine as well. Do you have a test case?
> /Ulrich


More information about the wine-devel mailing list