diff options
author | Silenio Quarti <silenio> | 2004-08-17 15:54:03 +0000 |
---|---|---|
committer | Silenio Quarti <silenio> | 2004-08-17 15:54:03 +0000 |
commit | 892a7994107068a8903be793398c8b4e9d56cbd7 (patch) | |
tree | 27482cd1320a68d976e8d67b30ebbb80ba9f7322 /bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt | |
parent | 74284d2a285369eacfa106ac7a40bccd4dea49cb (diff) | |
download | eclipse.platform.swt-892a7994107068a8903be793398c8b4e9d56cbd7.tar.gz eclipse.platform.swt-892a7994107068a8903be793398c8b4e9d56cbd7.tar.xz eclipse.platform.swt-892a7994107068a8903be793398c8b4e9d56cbd7.zip |
jni gen
Diffstat (limited to 'bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt')
20 files changed, 268 insertions, 436 deletions
diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CAUUID.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CAUUID.java index b2441fd096..663499dc22 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CAUUID.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CAUUID.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java index 7ed921ed2d..dcb8344545 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COM.java @@ -15,27 +15,19 @@ import org.eclipse.swt.internal.win32.*; public class COM extends OS { static { - /* Initialize OLE */ - // OleInitialize Initializes the COM library on the current apartment - // and identifies the concurrency model as single-thread apartment (STA). - // To use any other threading model, you must call CoInitializeEx OS.OleInitialize(0); } - /* Constants */ - - // GUIDs for Home Page Browser + /** GUID Constants */ public static final GUID IIDIEditorSiteTime = IIDFromString("{6BD2AEFE-7876-45e6-A6E7-3BFCDF6540AA}"); //$NON-NLS-1$ public static final GUID IIDIEditorSiteProperty = IIDFromString("{D381A1F4-2326-4f3c-AFB9-B7537DB9E238}"); //$NON-NLS-1$ public static final GUID IIDIEditorBaseProperty = IIDFromString("{61E55B0B-2647-47c4-8C89-E736EF15D636}"); //$NON-NLS-1$ public static final GUID IIDIEditorSite = IIDFromString("{CDD88AB9-B01D-426E-B0F0-30973E9A074B}"); //$NON-NLS-1$ public static final GUID IIDIEditorService = IIDFromString("{BEE283FE-7B42-4FF3-8232-0F07D43ABCF1}"); //$NON-NLS-1$ public static final GUID IIDIEditorManager = IIDFromString("{EFDE08C4-BE87-4B1A-BF84-15FC30207180}"); //$NON-NLS-1$ - public static final GUID IIDIAccessible = IIDFromString("{618736E0-3C3D-11CF-810C-00AA00389B71}"); //$NON-NLS-1$ //public static final GUID IIDIAccessibleHandler = IIDFromString("{03022430-ABC4-11D0-BDE2-00AA001A1953}"); //$NON-NLS-1$ //public static final GUID IIDIAccessor = IIDFromString("{0C733A8C-2A1C-11CE-ADE5-00AA0044773D}"); //$NON-NLS-1$ - public static final GUID IIDIAdviseSink = IIDFromString("{0000010F-0000-0000-C000-000000000046}"); //$NON-NLS-1$ //public static final GUID IIDIAdviseSink2 = IIDFromString("{00000125-0000-0000-C000-000000000046}"); //$NON-NLS-1$ //public static final GUID IIDIBindCtx = IIDFromString("{0000000E-0000-0000-C000-000000000046}"); //$NON-NLS-1$ @@ -133,10 +125,10 @@ public class COM extends OS { public static final GUID IIDIUnknown = IIDFromString("{00000000-0000-0000-C000-000000000046}"); //$NON-NLS-1$ //public static final GUID IIDIViewObject = IIDFromString("{0000010D-0000-0000-C000-000000000046}"); //$NON-NLS-1$ public static final GUID IIDIViewObject2 = IIDFromString("{00000127-0000-0000-C000-000000000046}"); //$NON-NLS-1$ - public static final GUID CGID_Explorer = IIDFromString("{000214D0-0000-0000-C000-000000000046}"); //$NON-NLS-1$ + /** Constants */ //public static final int ADVF_DATAONSTOP = 64; //public static final int ADVF_NODATA = 1; //public static final int ADVF_ONLYONCE = 2; @@ -144,32 +136,32 @@ public class COM extends OS { //public static final int ADVFCACHE_FORCEBUILTIN = 16; //public static final int ADVFCACHE_NOHANDLER = 8; //public static final int ADVFCACHE_ONSAVE = 32; - public static final int CF_TEXT = 1; - public static final int CF_BITMAP = 2; + public static final int CF_TEXT = 1; + public static final int CF_BITMAP = 2; public static final int CF_METAFILEPICT = 3; - public static final int CF_SYLK = 4; - public static final int CF_DIF = 5; - public static final int CF_TIFF = 6; - public static final int CF_OEMTEXT = 7; - public static final int CF_DIB = 8; - public static final int CF_PALETTE = 9; - public static final int CF_PENDATA = 10; - public static final int CF_RIFF = 11; - public static final int CF_WAVE = 12; - public static final int CF_UNICODETEXT = 13; - public static final int CF_ENHMETAFILE = 14; - public static final int CF_HDROP = 15; - public static final int CF_LOCALE = 16; - public static final int CF_MAX = 17; + public static final int CF_SYLK = 4; + public static final int CF_DIF = 5; + public static final int CF_TIFF = 6; + public static final int CF_OEMTEXT = 7; + public static final int CF_DIB = 8; + public static final int CF_PALETTE = 9; + public static final int CF_PENDATA = 10; + public static final int CF_RIFF = 11; + public static final int CF_WAVE = 12; + public static final int CF_UNICODETEXT = 13; + public static final int CF_ENHMETAFILE = 14; + public static final int CF_HDROP = 15; + public static final int CF_LOCALE = 16; + public static final int CF_MAX = 17; public static final int CLSCTX_INPROC_HANDLER = 2; public static final int CLSCTX_INPROC_SERVER = 1; public static final int CLSCTX_LOCAL_SERVER = 4; public static final int CLSCTX_REMOTE_SERVER = 16; public static final int CO_E_CLASSSTRING = -2147221005; - //public static final int COINIT_APARTMENTTHREADED = 2; Apartment model - //public static final int COINIT_DISABLE_OLE1DDE = 4; Don't use DDE for Ole1 support. - //public static final int COINIT_MULTITHREADED = 0; OLE calls objects on any thread. - //public static final int COINIT_SPEED_OVER_MEMORY = 8; Trade memory for speed. + //public static final int COINIT_APARTMENTTHREADED = 2; + //public static final int COINIT_DISABLE_OLE1DDE = 4; + //public static final int COINIT_MULTITHREADED = 0; + //public static final int COINIT_SPEED_OVER_MEMORY = 8; public static final int DATADIR_GET = 1; public static final int DATADIR_SET = 2; public static final int DISP_E_EXCEPTION = 0x80020009; @@ -201,28 +193,25 @@ public class COM extends OS { public static final int DISPID_AMBIENT_USERMODE = -709; public static final int DISPID_BACKCOLOR = -501; public static final int DISPID_FONT = -512; - public static final int DISPID_FONT_BOLD = 3; + public static final int DISPID_FONT_BOLD = 3; public static final int DISPID_FONT_CHARSET = 8; - public static final int DISPID_FONT_ITALIC = 4; - public static final int DISPID_FONT_NAME = 0; - public static final int DISPID_FONT_SIZE = 2; - public static final int DISPID_FONT_STRIKE = 6; - public static final int DISPID_FONT_UNDER = 5; - public static final int DISPID_FONT_WEIGHT = 7; + public static final int DISPID_FONT_ITALIC = 4; + public static final int DISPID_FONT_NAME = 0; + public static final int DISPID_FONT_SIZE = 2; + public static final int DISPID_FONT_STRIKE = 6; + public static final int DISPID_FONT_UNDER = 5; + public static final int DISPID_FONT_WEIGHT = 7; public static final int DISPID_FORECOLOR = -513; //public static final int DISPID_READYSTATE = -525; //public static final int DISPID_READYSTATECHANGE = -609; - public static final int DRAGDROP_S_DROP = 0x00040100; //Successful drop took place - public static final int DRAGDROP_S_CANCEL = 0x00040101; // Drag-drop operation canceled - public static final int DRAGDROP_S_USEDEFAULTCURSORS = 0x00040102; // Use the default cursor - public static final int DROPEFFECT_NONE = 0; // Drop target cannot accept the data. - public static final int DROPEFFECT_COPY = 1; // Drop results in a copy. The original data is untouched by - // the drag source. - public static final int DROPEFFECT_MOVE = 2; // Drag source should remove the data. - public static final int DROPEFFECT_LINK = 4; // Drag source should create a link to the original data. - public static final int DROPEFFECT_SCROLL = 0x80000000; // Scrolling is about to start or is currently - // occurring in the target. This value is used in - // addition to the other values. + public static final int DRAGDROP_S_DROP = 0x00040100; + public static final int DRAGDROP_S_CANCEL = 0x00040101; + public static final int DRAGDROP_S_USEDEFAULTCURSORS = 0x00040102; + public static final int DROPEFFECT_NONE = 0; + public static final int DROPEFFECT_COPY = 1; + public static final int DROPEFFECT_MOVE = 2; + public static final int DROPEFFECT_LINK = 4; + public static final int DROPEFFECT_SCROLL = 0x80000000; public static final int DV_E_FORMATETC = -2147221404; public static final int DV_E_STGMEDIUM = -2147221402; public static final int DV_E_TYMED = -2147221399; @@ -230,15 +219,15 @@ public class COM extends OS { //public static final int DVASPECT_DOCPRINT = 8; //public static final int DVASPECT_ICON = 4; //public static final int DVASPECT_THUMBNAIL = 2; - public static final int E_FAIL = -2147467259; //Unspecified failure. + public static final int E_FAIL = -2147467259; public static final int E_INVALIDARG = -2147024809; - public static final int E_NOINTERFACE = -2147467262; //QueryInterface did not recognize the requested interface. - public static final int E_NOTIMPL = -2147467263; //Member function contains no implementation. + public static final int E_NOINTERFACE = -2147467262; + public static final int E_NOTIMPL = -2147467263; public static final int E_NOTSUPPORTED = 0x80040100; //public static final int E_NOTLICENSED = -2147221230; - //public static final int E_OUTOFMEMORY = -2147024882; //Function failed to allocate necessary memory. + //public static final int E_OUTOFMEMORY = -2147024882; //public static final int E_POINTER = -2147467261; - public static final int GMEM_FIXED = 0; //Global Memory Constants + public static final int GMEM_FIXED = 0; //public static final int GMEM_MOVABLE = 2; //public static final int GMEM_NODISCARD = 32; public static final int GMEM_ZEROINIT = 64; @@ -247,45 +236,45 @@ public class COM extends OS { //public static final int IMPLTYPEFLAG_FDEFAULTVTABLE = 2048; public static final int IMPLTYPEFLAG_FRESTRICTED = 4; public static final int IMPLTYPEFLAG_FSOURCE = 2; - public static final int LOCALE_SYSTEM_DEFAULT = 1024; //Locale Constants + public static final int LOCALE_SYSTEM_DEFAULT = 1024; public static final int LOCALE_USER_DEFAULT = 2048; - //public static final int MEMCTX_TASK = 1; //dwMemContext values for COM's task memory allocation service - //public static final int OLEACTIVATEAUTO = 3; //Object is activated based on the object's default method of activation - //public static final int OLEACTIVATEDOUBLECLICK = 2; //Object is activated when the OLE container control is double-clicked - //public static final int OLEACTIVATEGETFOCUS = 1; //Object is activated when the OLE container control gets the focus - //public static final int OLEACTIVATEMANUAL = 0; //OLE object isn't automatically activated - //public static final int OLEAUTOMATIC = 0; //Object is updated each time the linked data changes - //public static final int OLECHANGED = 0; //Object's data has changed + //public static final int MEMCTX_TASK = 1; + //public static final int OLEACTIVATEAUTO = 3; + //public static final int OLEACTIVATEDOUBLECLICK = 2; + //public static final int OLEACTIVATEGETFOCUS = 1; + //public static final int OLEACTIVATEMANUAL = 0; + //public static final int OLEAUTOMATIC = 0; + //public static final int OLECHANGED = 0; public static final int OLECLOSE_NOSAVE = 1; //public static final int OLECLOSE_PROMPTSAVE = 2; public static final int OLECLOSE_SAVEIFDIRTY = 0; - //public static final int OLECLOSED = 2; //Application file containing the linked object's data has been closed - //public static final int OLECONTF_EMBEDDINGS = 1; //The OLECONTF enumeration indicates the kind of objects to be enumerated by the returned IEnumUnknown interface + //public static final int OLECLOSED = 2; + //public static final int OLECONTF_EMBEDDINGS = 1; //public static final int OLECONTF_LINKS = 2; //public static final int OLECONTF_ONLYIFRUNNING = 16; //public static final int OLECONTF_ONLYUSER = 8; //public static final int OLECONTF_OTHERS = 4; - //public static final int OLEDEACTIVATEMANUAL = 1; //The OLE object can only be deactivated programatically via the #doVerb: method." - //public static final int OLEDEACTIVATEONLOSEFOCUS = 0; //The OLE object is deactivated whenever focus is given to another widget in the receiver's shell. - //public static final int OLEDECBORDER = 1; //a border is displayed around the receiver. - //public static final int OLEDECBORDERANDNIBS = 3; //border and resize nibs are displayed. - //public static final int OLEDECNIBS = 2; //resize nibs are displayed around the reciever. - //public static final int OLEDECNONE = 0; //no special trimmings are displayed around the receiver. - //public static final int OLEDISPLAYCONTENT = 0; //Object's data is displayed in the OLE container control - //public static final int OLEDISPLAYICON = 1; //Object's icon is displayed in the OLE container control - //public static final int OLEEITHER = 2; //OLE container control can contain either a linked or an embedded object - public static final int OLEEMBEDDED = 1; //OLE container control contains an embedded object - //public static final int OLEFROZEN = 1; //Object is updated whenever the user saves the linked document from within the application in which it was created - public static final int OLEIVERB_DISCARDUNDOSTATE = -6; //close the OLE object and discard the undo state - //public static final int OLEIVERB_HIDE = -3; //hide the OLE object - public static final int OLEIVERB_INPLACEACTIVATE = -5; //open the OLE for editing in-place - //public static final int OLEIVERB_OPEN = -2; //open the OLE object for editing in a separate window - public static final int OLEIVERB_PRIMARY = 0; //opens the OLE object for editing - //public static final int OLEIVERB_PROPERTIES = -7; //request the OLE object properties dialog - //public static final int OLEIVERB_SHOW = -1; //show the OLE object - //public static final int OLEIVERB_UIACTIVATE = -4; //activate the UI for the OLE object - public static final int OLELINKED = 0; //OLE container control contains a linked object - //public static final int OLEMANUAL = 2; //Object is updated only when the Action property is set to 6 (Update) + //public static final int OLEDEACTIVATEMANUAL = 1; + //public static final int OLEDEACTIVATEONLOSEFOCUS = 0; + //public static final int OLEDECBORDER = 1; + //public static final int OLEDECBORDERANDNIBS = 3; + //public static final int OLEDECNIBS = 2; + //public static final int OLEDECNONE = 0; + //public static final int OLEDISPLAYCONTENT = 0; + //public static final int OLEDISPLAYICON = 1; + //public static final int OLEEITHER = 2; + public static final int OLEEMBEDDED = 1; + //public static final int OLEFROZEN = 1; + public static final int OLEIVERB_DISCARDUNDOSTATE = -6; + //public static final int OLEIVERB_HIDE = -3; + public static final int OLEIVERB_INPLACEACTIVATE = -5; + //public static final int OLEIVERB_OPEN = -2; + public static final int OLEIVERB_PRIMARY = 0; + //public static final int OLEIVERB_PROPERTIES = -7; + //public static final int OLEIVERB_SHOW = -1; + //public static final int OLEIVERB_UIACTIVATE = -4; + public static final int OLELINKED = 0; + //public static final int OLEMANUAL = 2; //public static final int OLEMISC_ACTIVATEWHENVISIBLE = 256; //public static final int OLEMISC_ACTSLIKEBUTTON = 4096; //public static final int OLEMISC_ACTSLIKELABEL = 8192; @@ -308,22 +297,22 @@ public class COM extends OS { //public static final int OLEMISC_STATIC = 8; //public static final int OLEMISC_SUPPORTSMULTILEVELUNDO = 2097152; //public static final int OLEMISC_WANTSTOMENUMERGE = 1048576; - //public static final int OLENONE = 3; //OLE container control doesn't contain an object - //public static final int OLERENAMED = 3; //Application file containing the linked object's data has been renamed - //public static final int OLERENDER_ASIS = 3; //Ole Create rendering formats + //public static final int OLENONE = 3; + //public static final int OLERENAMED = 3; + //public static final int OLERENDER_ASIS = 3; public static final int OLERENDER_DRAW = 1; //public static final int OLERENDER_FORMAT = 2; //public static final int OLERENDER_NONE = 0; - //public static final int OLESAVED = 1; //Object's data has been saved by the application that created the object - //public static final int OLESIZEAUTOSIZE = 2; //OLE container control is automatically resized to display the entire object - //public static final int OLESIZECLIP = 0; //Object's image is clipped by the OLE container control's borders - //public static final int OLESIZESTRETCH = 1; //Object's image is sized to fill the OLE container control - //public static final int OLESIZEZOOM = 3; //Object's image is stretched but in proportion + //public static final int OLESAVED = 1; + //public static final int OLESIZEAUTOSIZE = 2; + //public static final int OLESIZECLIP = 0; + //public static final int OLESIZESTRETCH = 1; + //public static final int OLESIZEZOOM = 3; //public static final int OLEWHICHMK_CONTAINER = 1; //public static final int OLEWHICHMK_OBJFULL = 3; //public static final int OLEWHICHMK_OBJREL = 2; - public static final int S_FALSE = 1; //Used for functions that semantically return a Boolean FALSE result to indicate that the function succeeded. - public static final int S_OK = 0; //Function succeeded. + public static final int S_FALSE = 1; + public static final int S_OK = 0; public static final int STG_E_FILENOTFOUND = 0x80030002; public static final int STG_S_CONVERTED = 0x00030200; //public static final int STGC_CONSOLIDATE = 8; @@ -349,11 +338,11 @@ public class COM extends OS { public static final int STGM_SIMPLE = 0x08000000; public static final int STGM_TRANSACTED = 0x00010000; public static final int STGM_WRITE = 0x00000001; - public static final int STGTY_STORAGE = 1; - public static final int STGTY_STREAM = 2; - public static final int STGTY_LOCKBYTES = 3; - public static final int STGTY_PROPERTY = 4; - //public static final int TYMED_ENHMF = 64; //Values for tymed + public static final int STGTY_STORAGE = 1; + public static final int STGTY_STREAM = 2; + public static final int STGTY_LOCKBYTES = 3; + public static final int STGTY_PROPERTY = 4; + //public static final int TYMED_ENHMF = 64; //public static final int TYMED_FILE = 2; //public static final int TYMED_GDI = 16; public static final int TYMED_HGLOBAL = 1; @@ -361,8 +350,7 @@ public class COM extends OS { //public static final int TYMED_ISTREAM = 4; //public static final int TYMED_MFPICT = 32; //public static final int TYMED_NULL = 0; - - public static final short DISPATCH_METHOD = 0x1; //Dispatch Constants + public static final short DISPATCH_METHOD = 0x1; public static final short DISPATCH_PROPERTYGET = 0x2; public static final short DISPATCH_PROPERTYPUT = 0x4; public static final short DISPATCH_PROPERTYPUTREF = 0x8; @@ -373,70 +361,47 @@ public class COM extends OS { public static final short DISPID_PROPERTYPUT = -3; //public static final short DISPID_UNKNOWN = -1; //public static final short DISPID_VALUE = 0; - - // Variant types - public static final short VT_BOOL = 11; // Boolean; True=-1, False=0. - public static final short VT_BSTR = 8; // Binary String. - public static final short VT_BYREF = 16384; // By reference - must be combined with one of the othre VT values - public static final short VT_CY = 6; // Currency. - public static final short VT_DATE = 7; // Date. - public static final short VT_DISPATCH = 9; // IDispatch - public static final short VT_EMPTY = 0; // Not specified. - public static final short VT_ERROR = 10; // Scodes. - public static final short VT_I2 = 2; // 2-byte signed int. - public static final short VT_I4 = 3; // 4-byte signed int. - public static final short VT_NULL = 1; // Null. - public static final short VT_R4 = 4; // 4-byte real. - public static final short VT_R8 = 5; // 8-byte real. - public static final short VT_UI1 = 17; // Unsigned char. - public static final short VT_UI4 = 19; // Unsigned int. - public static final short VT_UNKNOWN = 13; // IUnknown FAR*. - public static final short VT_VARIANT = 12; // VARIANT FAR*. - + public static final short VT_BOOL = 11; + public static final short VT_BSTR = 8; + public static final short VT_BYREF = 16384; + public static final short VT_CY = 6; + public static final short VT_DATE = 7; + public static final short VT_DISPATCH = 9; + public static final short VT_EMPTY = 0; + public static final short VT_ERROR = 10; + public static final short VT_I2 = 2; + public static final short VT_I4 = 3; + public static final short VT_NULL = 1; + public static final short VT_R4 = 4; + public static final short VT_R8 = 5; + public static final short VT_UI1 = 17; + public static final short VT_UI4 = 19; + public static final short VT_UNKNOWN = 13; + public static final short VT_VARIANT = 12; public static final short VARIANT_TRUE = -1; public static final short VARIANT_FALSE = 0; +private static GUID IIDFromString(String lpsz) { + int length = lpsz.length(); + char[] buffer = new char[length + 1]; + lpsz.getChars(0, length, buffer, 0); + GUID lpiid = new GUID(); + if (COM.IIDFromString(buffer, lpiid) == COM.S_OK) return lpiid; + return null; +} + +/** Natives */ public static final native int CLSIDFromProgID(char[] lpszProgID, GUID pclsid); public static final native int CLSIDFromString(char[] lpsz, GUID pclsid); -public static final native int CoCreateInstance( - GUID rclsid, - int pUnkOuter, - int dwClsContext, - GUID riid, - int[] ppv -); - +public static final native int CoCreateInstance(GUID rclsid, int pUnkOuter, int dwClsContext, GUID riid, int[] ppv); public static final native void CoFreeUnusedLibraries(); public static final native int CoGetClassObject(GUID rclsid, int dwClsContext, int pServerInfo, GUID riid, int[] ppv); -public static final native int CoLockObjectExternal( - int pUnk, //Pointer to object to be locked or unlocked - boolean fLock, //TRUE = lock, FALSE = unlock - boolean fLastUnlockReleases //TRUE = release all pointers to object -); -public static final native int CoTaskMemAlloc(int cb); //Size in bytes of memory block to be allocated +public static final native int CoLockObjectExternal(int pUnk, boolean fLock, boolean fLastUnlockReleases); +public static final native int CoTaskMemAlloc(int cb); public static final native void CoTaskMemFree(int pv); -public static final native int DoDragDrop( - int pDataObject, //Pointer to the data object - int pDropSource, //Pointer to the source - int dwOKEffect, //Effects allowed by the source - int[] pdwEffect //Pointer to effects on the source -); - -public static final native int GetClassFile( - char[] szFileName, //Pointer to filename for which you are requesting a CLSID - GUID clsid //Pointer to location for returning the CLSID -); +public static final native int DoDragDrop(int pDataObject, int pDropSource, int dwOKEffect, int[] pdwEffect); +public static final native int GetClassFile(char[] szFileName, GUID clsid); public static final native int IIDFromString(char[] lpsz, GUID lpiid); -private static GUID IIDFromString(String lpsz) { - // create a null terminated array of char - char[] buffer = (lpsz +"\0").toCharArray(); - - // invoke system method - GUID lpiid = new GUID(); - if (COM.IIDFromString(buffer, lpiid) == COM.S_OK) - return lpiid; - return null; -} public static final native boolean IsEqualGUID(GUID rguid1, GUID rguid2); public static final native void MoveMemory(int Destination, FORMATETC Source, int Length); public static final native void MoveMemory(int DestinationPtr, GUID Source, int Length); @@ -450,70 +415,30 @@ public static final native void MoveMemory(GUID Destination, int SourcePtr, int public static final native void MoveMemory(STATSTG Destination, int Source, int Length); public static final native void MoveMemory(TYPEATTR Destination, int SourcePtr, int Length); public static final native void MoveMemory(RECT Destination, int Source, int Length); -public static final native void MoveMemory(FUNCDESC1 Destination, int Source, int Length); -public static final native void MoveMemory(VARDESC1 Destination, int Source, int Length); -public static final native void MoveMemory(FUNCDESC2 Destination, int Source, int Length); -public static final native void MoveMemory(VARDESC2 Destination, int Source, int Length); - +public static final native void MoveMemory(FUNCDESC Destination, int Source, int Length); +public static final native void MoveMemory(VARDESC Destination, int Source, int Length); public static final native int OleCreate(GUID rclsid, GUID riid, int renderopt, FORMATETC pFormatEtc, int pClientSite, int pStg, int[] ppvObject); -public static final native int OleCreateFromFile( - GUID rclsid, //Reserved. Must be CLSID_NULL - char[] lpszFileName, //Pointer to full path of file used to create object - GUID riid, //Reference to the identifier of the interface to be used to - // communicate with new object - int renderopt, //Value from OLERENDER - FORMATETC pFormatEtc, //Pointer to the FORMATETC structure - int pClientSite, //Pointer to an interface - int pStg, //Pointer tothe interface to be used as object storage - int[] ppvObj); //Address of output variable that receives the interface pointer - // requested in riid +public static final native int OleCreateFromFile(GUID rclsid, char[] lpszFileName, GUID riid, int renderopt, FORMATETC pFormatEtc, int pClientSite, int pStg, int[] ppvObj); public static final native int OleCreatePropertyFrame(int hwndOwner,int x, int y, char[] lpszCaption, int cObjects, int[] lplpUnk, int cPages, int lpPageClsID, int lcid, int dwReserved, int lpvReserved); -public static final native int OleDraw(int pUnk, //Pointer to the view object to be drawn - int dwAspect, //How the object is to be represented - int hdcDraw, //Device context on which to draw - int lprcBounds);//Pointer to the rectangle in which the object is drawn +public static final native int OleDraw(int pUnk, int dwAspect, int hdcDraw, int lprcBounds); public static final native int OleFlushClipboard(); public static final native int OleGetClipboard(int[] ppDataObject); public static final native int OleIsCurrentClipboard(int pDataObject); public static final native boolean OleIsRunning(int pObject); -public static final native int OleLoad( - int pStg, //Pointer to the storage object from which to load - GUID riid, //Reference to the identifier of the interface - int pClientSite, //Pointer to the client site for the object - int[] ppvObj //Address of output variable that receives the interface pointer requested in riid -); +public static final native int OleLoad(int pStg, GUID riid, int pClientSite, int[] ppvObj); public static final native int OleRun(int pUnknown); public static final native int OleSave(int pPS, int pStg,boolean fSameAsLoad); public static final native int OleSetClipboard(int pDataObject); public static final native int OleSetContainedObject(int pUnk, boolean fContained); public static final native int OleSetMenuDescriptor(int holemenu, int hwndFrame, int hwndActiveObject, int lpFrame, int lpActiveObj); public static final native int OleTranslateColor(int clr, int hpal, int[] pcolorref); -public static final native int ProgIDFromCLSID( - GUID clsid, //CLSID for which the ProgID is requested - int[] lplpszProgID //Address of output variable that receives a pointer to the requested ProgID string -); -public static final native int RegisterDragDrop( - int hwnd, //Handle to a window that can accept drops - int pDropTarget //Pointer to object that is to be target of drop -); -public static final native void ReleaseStgMedium( - int pmedium //Pointer to storage medium to be freed -); -public static final native int RevokeDragDrop( - int hwnd //Handle to a window that can accept drops -); +public static final native int ProgIDFromCLSID(GUID clsid, int[] lplpszProgID); +public static final native int RegisterDragDrop(int hwnd, int pDropTarget); +public static final native void ReleaseStgMedium(int pmedium); +public static final native int RevokeDragDrop(int hwnd); public static final native int StgCreateDocfile(char[] pwcsName, int grfMode, int reserved, int[] ppstgOpen); -public static final native int StgIsStorageFile( - char[] pwcsName //Points to a path of the file to check -); -public static final native int StgOpenStorage( - char[] pwcsName, //Points to the path of the file containing storage object - int pstgPriority, //Points to a previous opening of a root storage object - int grfMode, //Specifies the access mode for the object - int snbExclude, //Points to an SNB structure specifying elements to be excluded - int reserved, //Reserved; must be zero - int[] ppstgOpen //Address of output variable that receives the IStorage interface pointer -); +public static final native int StgIsStorageFile(char[] pwcsName); +public static final native int StgOpenStorage(char[] pwcsName, int pstgPriority, int grfMode, int snbExclude, int reserved, int[] ppstgOpen); public static final native int StringFromCLSID(GUID rclsid, int[] ppsz); public static final native int SysAllocString(char [] sz); public static final native void SysFreeString(int bstr); @@ -558,53 +483,11 @@ public static final native int VtblCall(int fnNumber, int ppVtbl, RECT arg0, REC public static final native int VtblCall(int fnNumber, int ppVtbl, RECT arg0); public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int[] arg1, int[] arg2, int[] arg3, int[] arg4); public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int[] arg1, int arg2, int[] arg3); - public static final native int WriteClassStg(int pStg, GUID rclsid); -/* Start ACCESSIBILITY */ -public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3); -public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4); -public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5); -public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int arg7); - -public static final native int CreateStdAccessibleObject (int hwnd, int idObject, GUID riidInterface, int[] ppvObject); -public static final native int LresultFromObject (GUID riid, int wParam, int pAcc); +/** Accessibility constants */ +public static final int CHILDID_SELF = 0; public static final int CO_E_OBJNOTCONNECTED = 0x800401FD; - -public static final int STATE_SYSTEM_NORMAL = 0; -//public static final int STATE_SYSTEM_UNAVAILABLE = 0x1; -public static final int STATE_SYSTEM_SELECTED = 0x2; -public static final int STATE_SYSTEM_FOCUSED = 0x4; -public static final int STATE_SYSTEM_PRESSED = 0x8; -public static final int STATE_SYSTEM_CHECKED = 0x10; -//public static final int STATE_SYSTEM_MIXED = 0x20; -//public static final int STATE_SYSTEM_INDETERMINATE = STATE_SYSTEM_MIXED; -public static final int STATE_SYSTEM_READONLY = 0x40; -public static final int STATE_SYSTEM_HOTTRACKED = 0x80; -//public static final int STATE_SYSTEM_DEFAULT = 0x100; -public static final int STATE_SYSTEM_EXPANDED = 0x200; -public static final int STATE_SYSTEM_COLLAPSED = 0x400; -public static final int STATE_SYSTEM_BUSY = 0x800; -//public static final int STATE_SYSTEM_FLOATING = 0x1000; -//public static final int STATE_SYSTEM_MARQUEED = 0x2000; -//public static final int STATE_SYSTEM_ANIMATED = 0x4000; -public static final int STATE_SYSTEM_INVISIBLE = 0x8000; -public static final int STATE_SYSTEM_OFFSCREEN = 0x10000; -public static final int STATE_SYSTEM_SIZEABLE = 0x20000; -//public static final int STATE_SYSTEM_MOVEABLE = 0x40000; -//public static final int STATE_SYSTEM_SELFVOICING = 0x80000; -public static final int STATE_SYSTEM_FOCUSABLE = 0x100000; -public static final int STATE_SYSTEM_SELECTABLE = 0x200000; -public static final int STATE_SYSTEM_LINKED = 0x400000; -//public static final int STATE_SYSTEM_TRAVERSED = 0x800000; -public static final int STATE_SYSTEM_MULTISELECTABLE = 0x1000000; -//public static final int STATE_SYSTEM_EXTSELECTABLE = 0x2000000; -//public static final int STATE_SYSTEM_ALERT_LOW = 0x4000000; -//public static final int STATE_SYSTEM_ALERT_MEDIUM = 0x8000000; -//public static final int STATE_SYSTEM_ALERT_HIGH = 0x10000000; -//public static final int STATE_SYSTEM_PROTECTED = 0x20000000; -//public static final int STATE_SYSTEM_VALID = 0x3fffffff; - //public static final int ROLE_SYSTEM_TITLEBAR = 0x1; public static final int ROLE_SYSTEM_MENUBAR = 0x2; public static final int ROLE_SYSTEM_SCROLLBAR = 0x3; @@ -666,9 +549,46 @@ public static final int ROLE_SYSTEM_SLIDER = 0x33; //public static final int ROLE_SYSTEM_WHITESPACE = 0x3b; public static final int ROLE_SYSTEM_PAGETABLIST = 0x3c; //public static final int ROLE_SYSTEM_CLOCK = 0x3d; +public static final int STATE_SYSTEM_NORMAL = 0; +//public static final int STATE_SYSTEM_UNAVAILABLE = 0x1; +public static final int STATE_SYSTEM_SELECTED = 0x2; +public static final int STATE_SYSTEM_FOCUSED = 0x4; +public static final int STATE_SYSTEM_PRESSED = 0x8; +public static final int STATE_SYSTEM_CHECKED = 0x10; +//public static final int STATE_SYSTEM_MIXED = 0x20; +//public static final int STATE_SYSTEM_INDETERMINATE = STATE_SYSTEM_MIXED; +public static final int STATE_SYSTEM_READONLY = 0x40; +public static final int STATE_SYSTEM_HOTTRACKED = 0x80; +//public static final int STATE_SYSTEM_DEFAULT = 0x100; +public static final int STATE_SYSTEM_EXPANDED = 0x200; +public static final int STATE_SYSTEM_COLLAPSED = 0x400; +public static final int STATE_SYSTEM_BUSY = 0x800; +//public static final int STATE_SYSTEM_FLOATING = 0x1000; +//public static final int STATE_SYSTEM_MARQUEED = 0x2000; +//public static final int STATE_SYSTEM_ANIMATED = 0x4000; +public static final int STATE_SYSTEM_INVISIBLE = 0x8000; +public static final int STATE_SYSTEM_OFFSCREEN = 0x10000; +public static final int STATE_SYSTEM_SIZEABLE = 0x20000; +//public static final int STATE_SYSTEM_MOVEABLE = 0x40000; +//public static final int STATE_SYSTEM_SELFVOICING = 0x80000; +public static final int STATE_SYSTEM_FOCUSABLE = 0x100000; +public static final int STATE_SYSTEM_SELECTABLE = 0x200000; +public static final int STATE_SYSTEM_LINKED = 0x400000; +//public static final int STATE_SYSTEM_TRAVERSED = 0x800000; +public static final int STATE_SYSTEM_MULTISELECTABLE = 0x1000000; +//public static final int STATE_SYSTEM_EXTSELECTABLE = 0x2000000; +//public static final int STATE_SYSTEM_ALERT_LOW = 0x4000000; +//public static final int STATE_SYSTEM_ALERT_MEDIUM = 0x8000000; +//public static final int STATE_SYSTEM_ALERT_HIGH = 0x10000000; +//public static final int STATE_SYSTEM_PROTECTED = 0x20000000; +//public static final int STATE_SYSTEM_VALID = 0x3fffffff; -public static final int CHILDID_SELF = 0; - -/* End ACCESSIBILITY */ +/** Accessibility natives */ +public static final native int CreateStdAccessibleObject (int hwnd, int idObject, GUID riidInterface, int[] ppvObject); +public static final native int LresultFromObject (GUID riid, int wParam, int pAcc); +public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3); +public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4); +public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5); +public static final native int VtblCall(int fnNumber, int ppVtbl, int arg0, int arg1, int arg2, int arg3, int arg4, int arg5, int arg6, int arg7); } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CONTROLINFO.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CONTROLINFO.java index 92668cea7a..7773f42788 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CONTROLINFO.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/CONTROLINFO.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -11,9 +11,9 @@ package org.eclipse.swt.internal.ole.win32; public final class CONTROLINFO { - public int cb; - public int hAccel; + public int cb; + public int hAccel; public short cAccel; - public int dwFlags; + public int dwFlags; public static final int sizeof = 16; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COSERVERINFO.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COSERVERINFO.java index 1afe530c7f..bf4c3a9c76 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COSERVERINFO.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/COSERVERINFO.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DISPPARAMS.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DISPPARAMS.java index 1f0bfd7cda..d79a0cd5b4 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DISPPARAMS.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DISPPARAMS.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DVTARGETDEVICE.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DVTARGETDEVICE.java index 5b9b7b1afe..0f39b95647 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DVTARGETDEVICE.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/DVTARGETDEVICE.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -11,11 +11,11 @@ package org.eclipse.swt.internal.ole.win32; public final class DVTARGETDEVICE { - public int tdSize; - public short tdDriverNameOffset; - public short tdDeviceNameOffset; - public short tdPortNameOffset; - public short tdExtDevmodeOffset; - public byte tdData; + public int tdSize; + public short tdDriverNameOffset; + public short tdDeviceNameOffset; + public short tdPortNameOffset; + public short tdExtDevmodeOffset; + public byte[] tdData = new byte[1]; public static final int sizeof = 13; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/EXCEPINFO.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/EXCEPINFO.java index b178b85e04..d4d2b454b4 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/EXCEPINFO.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/EXCEPINFO.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FORMATETC.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FORMATETC.java index 603a0acb7d..e31c0045d3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FORMATETC.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FORMATETC.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC1.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC.java index 268f9f3a97..01c2155367 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC1.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -10,8 +10,7 @@ *******************************************************************************/ package org.eclipse.swt.internal.ole.win32; - -public class FUNCDESC1 { +public class FUNCDESC { public int memid; public int lprgscode; public int lprgelemdescParam; diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC2.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC2.java deleted file mode 100644 index 3d958bbe7b..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/FUNCDESC2.java +++ /dev/null @@ -1,34 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Common Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/cpl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.swt.internal.ole.win32; - - -public class FUNCDESC2 { - public int memid; - public int lprgscode; - public int lprgelemdescParam; - public int funckind; - public int invkind; - public int callconv; - public short cParams; - public short cParamsOpt; - public short oVft; - public short cScodes; -// ELEMDESC elemdescFunc; -// TYPEDESC elemdescFunc.tdesc - public int elemdescFunc_tdesc_union; - public short elemdescFunc_tdesc_vt; -// IDLDESC elemdescFunc.idldesc - public int elemdescFunc_idldesc_dwReserved; - public short elemdescFunc_idldesc_wIDLFlags; - public short wFuncFlags; - public static final int sizeof = 50; -} diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/GUID.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/GUID.java index b74ef76db7..9949e491ad 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/GUID.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/GUID.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -11,16 +11,9 @@ package org.eclipse.swt.internal.ole.win32; public final class GUID { - public int data1; - public short data2; - public short data3; - public byte b0; - public byte b1; - public byte b2; - public byte b3; - public byte b4; - public byte b5; - public byte b6; - public byte b7; + public int Data1; + public short Data2; + public short Data3; + public byte[] Data4 = new byte[8]; public static final int sizeof = 16; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/LICINFO.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/LICINFO.java index 42851feb08..dc48a82bab 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/LICINFO.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/LICINFO.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -12,7 +12,7 @@ package org.eclipse.swt.internal.ole.win32; public final class LICINFO { public int cbLicInfo; - public int fRuntimeKeyAvail; - public int fLicVerified; + public boolean fRuntimeKeyAvail; + public boolean fLicVerified; public static final int sizeof = 12; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMD.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMD.java index 1fd70ea5d4..4180586954 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMD.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMD.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMDTEXT.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMDTEXT.java index 88b60d718e..7d74ce97f3 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMDTEXT.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLECMDTEXT.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -14,9 +14,5 @@ public class OLECMDTEXT { public int cmdtextf; public int cwActual; public int cwBuf; - public short rgwz; - - // Note: this is a variable sized struct. The last field rgwz can vary in size. - // Currently we do not use this field and do not support accessing anything more - // than the first char in the field. + public short[] rgwz = new short[1]; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLEINPLACEFRAMEINFO.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLEINPLACEFRAMEINFO.java index f7a99de9e3..bcf3e48d3c 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLEINPLACEFRAMEINFO.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/OLEINPLACEFRAMEINFO.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STATSTG.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STATSTG.java index 7199000a7a..ba5f9046a4 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STATSTG.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STATSTG.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -11,33 +11,26 @@ package org.eclipse.swt.internal.ole.win32; public class STATSTG { - public int pwcsName; - public int type; - public long cbSize; + public int pwcsName; + public int type; + public long cbSize; // FILETIME mtime; - public int mtime_dwLowDateTime; - public int mtime_dwHighDateTime; + public int mtime_dwLowDateTime; + public int mtime_dwHighDateTime; // FILETIME ctime; - public int ctime_dwLowDateTime; - public int ctime_dwHighDateTime; + public int ctime_dwLowDateTime; + public int ctime_dwHighDateTime; // FILETIME atime; - public int atime_dwLowDateTime; - public int atime_dwHighDateTime; - public int grfMode; - public int grfLocksSupported; + public int atime_dwLowDateTime; + public int atime_dwHighDateTime; + public int grfMode; + public int grfLocksSupported; // GUID clsid; - public int clsid_data1; - public short clsid_data2; - public short clsid_data3; - public byte clsid_b0; - public byte clsid_b1; - public byte clsid_b2; - public byte clsid_b3; - public byte clsid_b4; - public byte clsid_b5; - public byte clsid_b6; - public byte clsid_b7; - public int grfStateBits; - public int reserved; + public int clsid_Data1; + public short clsid_Data2; + public short clsid_Data3; + public byte[] clsid_Data4 = new byte[8]; + public int grfStateBits; + public int reserved; public static final int sizeof = 72; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STGMEDIUM.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STGMEDIUM.java index 4375d65636..78a47c2466 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STGMEDIUM.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/STGMEDIUM.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/TYPEATTR.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/TYPEATTR.java index 0437e03457..0f88714844 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/TYPEATTR.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/TYPEATTR.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -12,37 +12,30 @@ package org.eclipse.swt.internal.ole.win32; public final class TYPEATTR { // GUID guid - public int guid_data1; - public short guid_data2; - public short guid_data3; - public byte guid_b0; - public byte guid_b1; - public byte guid_b2; - public byte guid_b3; - public byte guid_b4; - public byte guid_b5; - public byte guid_b6; - public byte guid_b7; - public int lcid; - public int dwReserved; - public int memidConstructor; - public int memidDestructor; - public int lpstrSchema; - public int cbSizeInstance; - public int typekind; - public short cFuncs; - public short cVars; - public short cImplTypes; - public short cbSizeVft; - public short cbAlignment; - public short wTypeFlags; - public short wMajorVerNum; - public short wMinorVerNum; + public int guid_Data1; + public short guid_Data2; + public short guid_Data3; + public byte[] guid_Data4 = new byte[8]; + public int lcid; + public int dwReserved; + public int memidConstructor; + public int memidDestructor; + public int lpstrSchema; + public int cbSizeInstance; + public int typekind; + public short cFuncs; + public short cVars; + public short cImplTypes; + public short cbSizeVft; + public short cbAlignment; + public short wTypeFlags; + public short wMajorVerNum; + public short wMinorVerNum; // TYPEDESC tdescAlias - public int tdescAlias_unionField; - public short tdescAlias_vt; -// IDLDESC idldesctype - public int idldescType_dwReserved; - public short idldescType_wIDLFlags; + public int tdescAlias_unionField; + public short tdescAlias_vt; +// IDLDESC idldesctype + public int idldescType_dwReserved; + public short idldescType_wIDLFlags; public static final int sizeof = 74; } diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC1.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC.java index 84b781bea3..47a609c142 100644 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC1.java +++ b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC.java @@ -1,6 +1,6 @@ /******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials + * Copyright (c) 2000, 2004 IBM Corporation and others. + * All rights reserved. This program and the accompanying materials * are made available under the terms of the Common Public License v1.0 * which accompanies this distribution, and is available at * http://www.eclipse.org/legal/cpl-v10.html @@ -10,10 +10,10 @@ *******************************************************************************/ package org.eclipse.swt.internal.ole.win32; -public class VARDESC1 { +public class VARDESC { public int memid; public int lpstrSchema; - public int unionField; + public int oInst; // ELEMDESC elemdescVar // TYPEDESC elemdescVar.tdesc public int elemdescVar_tdesc_union; diff --git a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC2.java b/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC2.java deleted file mode 100644 index eee5d21e65..0000000000 --- a/bundles/org.eclipse.swt/Eclipse SWT PI/win32/org/eclipse/swt/internal/ole/win32/VARDESC2.java +++ /dev/null @@ -1,28 +0,0 @@ -/******************************************************************************* - * Copyright (c) 2000, 2003 IBM Corporation and others. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Common Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/cpl-v10.html - * - * Contributors: - * IBM Corporation - initial API and implementation - *******************************************************************************/ -package org.eclipse.swt.internal.ole.win32; - - -public class VARDESC2 { - public int memid; - public int lpstrSchema; - public int unionField; -// ELEMDESC elemdescVar -// TYPEDESC elemdescVar.tdesc - public int elemdescVar_tdesc_union; - public short elemdescVar_tdesc_vt; -// IDLDESC elemdescFunc.idldesc - public int elemdescFunc_idldesc_dwReserved; - public short elemdescFunc_idldesc_wIDLFlags; - public short wVarFlags; - public int varkind; - public static final int sizeof = 36; -} |