int err = GetClipboard(struct hwClipboardData *data, struct hwTagList *t);
data. The data
argument will be set to a pointer to a struct hwClipboardData
which looks like this:
struct hwClipboardData
{
int Type;
APTR Data;
};
|
You must initialize the structure members as follows:
TypeData member of the
structure. This must be one of the following values:
HWCLIPBOARDTYPE_NONE HWCLIPBOARDTYPE_TEXT HWCLIPBOARDTYPE_IMAGE HWCLIPBOARDTYPE_UNKNOWN |
See below how the actual data is passed for each of those types.
DataData depends on the data type that is set in the Type
structure member. The following data types are currently supported:
HWCLIPBOARDTYPE_NONEData to NULL.
HWCLIPBOARDTYPE_TEXTData member must be set to a NULL-terminated string that has been
allocated using hw_TrackedAlloc(). Hollywood will free the string
when it is done with it.
HWCLIPBOARDTYPE_IMAGEData member must be set to a pointer to a struct hwClipboardImage
which looks like this:
struct hwClipboardImage
{
ULONG *Data;
int Width;
int Height;
ULONG Flags;
};
|
This structure must contain the pixel data of the image from the clipboard. The structure members must be initialized as follows:
Data
Width
Height
Flags
Note that it's your responsibility to make sure that the pointer to the
struct hwClipboardImage is still valid when your function
returns. It's recommended to use a static local variable to make sure
the memory is still accessible to Hollywood when your function returns.
HWCLIPBOARDTYPE_UNKNOWNData to NULL.
NULL currently