mirror of
https://github.com/reactos/wine.git
synced 2024-11-28 22:20:26 +00:00
Use the new header for COM definitions.
This commit is contained in:
parent
ddecd8a92f
commit
8e7cb4db7a
@ -15,14 +15,13 @@
|
||||
#include "commctrl.h"
|
||||
#include "spy.h"
|
||||
|
||||
#include "shlobj.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_enumidlist.h"
|
||||
#include "wine/obj_shellfolder.h"
|
||||
|
||||
#include "shell.h"
|
||||
#include "pidl.h"
|
||||
#include "shell32_main.h"
|
||||
#include "shlguid.h"
|
||||
|
||||
#define IDD_TREEVIEW 99
|
||||
|
||||
|
@ -10,96 +10,191 @@
|
||||
|
||||
#include "pidl.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "if_macros.h"
|
||||
#include "shlguid.h"
|
||||
#include "wine/obj_contextmenu.h"
|
||||
#include "wine/obj_shellbrowser.h"
|
||||
#include "wine/obj_shellextinit.h"
|
||||
|
||||
#include "shell32_main.h"
|
||||
#include "shresdef.h"
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu Implementation
|
||||
*/
|
||||
typedef struct
|
||||
{ ICOM_VTABLE(IContextMenu)* lpvtbl;
|
||||
DWORD ref;
|
||||
LPSHELLFOLDER pSFParent;
|
||||
LPITEMIDLIST *aPidls;
|
||||
BOOL bAllValues;
|
||||
{ ICOM_VTABLE(IContextMenu)* lpvtbl;
|
||||
DWORD ref;
|
||||
IShellFolder* pSFParent;
|
||||
LPITEMIDLIST *aPidls;
|
||||
BOOL bAllValues;
|
||||
} IContextMenuImpl;
|
||||
|
||||
static HRESULT WINAPI IContextMenu_fnQueryInterface(IContextMenu *,REFIID , LPVOID *);
|
||||
static ULONG WINAPI IContextMenu_fnAddRef(IContextMenu *);
|
||||
static ULONG WINAPI IContextMenu_fnRelease(IContextMenu *);
|
||||
static HRESULT WINAPI IContextMenu_fnQueryContextMenu(IContextMenu *, HMENU ,UINT ,UINT ,UINT ,UINT);
|
||||
static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *, LPCMINVOKECOMMANDINFO);
|
||||
static HRESULT WINAPI IContextMenu_fnGetCommandString(IContextMenu *, UINT ,UINT ,LPUINT ,LPSTR ,UINT);
|
||||
static HRESULT WINAPI IContextMenu_fnHandleMenuMsg(IContextMenu *, UINT, WPARAM, LPARAM);
|
||||
|
||||
/* Private Methods */
|
||||
BOOL IContextMenu_AllocPidlTable(IContextMenuImpl*, DWORD);
|
||||
void IContextMenu_FreePidlTable(IContextMenuImpl*);
|
||||
BOOL IContextMenu_CanRenameItems(IContextMenuImpl*);
|
||||
BOOL IContextMenu_FillPidlTable(IContextMenuImpl*, LPCITEMIDLIST *, UINT);
|
||||
static struct ICOM_VTABLE(IContextMenu) cmvt;
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu VTable
|
||||
*
|
||||
* IContextMenu_AllocPidlTable()
|
||||
*/
|
||||
static struct ICOM_VTABLE(IContextMenu) cmvt = {
|
||||
IContextMenu_fnQueryInterface,
|
||||
IContextMenu_fnAddRef,
|
||||
IContextMenu_fnRelease,
|
||||
IContextMenu_fnQueryContextMenu,
|
||||
IContextMenu_fnInvokeCommand,
|
||||
IContextMenu_fnGetCommandString,
|
||||
IContextMenu_fnHandleMenuMsg,
|
||||
(void *) 0xdeadbabe /* just paranoia */
|
||||
};
|
||||
BOOL IContextMenu_AllocPidlTable(IContextMenuImpl *This, DWORD dwEntries)
|
||||
{
|
||||
TRACE(shell,"(%p)->(entrys=%lu)\n",This, dwEntries);
|
||||
|
||||
/*add one for NULL terminator */
|
||||
dwEntries++;
|
||||
|
||||
This->aPidls = (LPITEMIDLIST*)SHAlloc(dwEntries * sizeof(LPITEMIDLIST));
|
||||
|
||||
if(This->aPidls)
|
||||
{ ZeroMemory(This->aPidls, dwEntries * sizeof(LPITEMIDLIST)); /*set all of the entries to NULL*/
|
||||
}
|
||||
return (This->aPidls != NULL);
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_FreePidlTable()
|
||||
*/
|
||||
void IContextMenu_FreePidlTable(IContextMenuImpl *This)
|
||||
{
|
||||
int i;
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
if(This->aPidls)
|
||||
{ for(i = 0; This->aPidls[i]; i++)
|
||||
{ SHFree(This->aPidls[i]);
|
||||
}
|
||||
|
||||
SHFree(This->aPidls);
|
||||
This->aPidls = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_FillPidlTable()
|
||||
*/
|
||||
BOOL IContextMenu_FillPidlTable(IContextMenuImpl *This, LPCITEMIDLIST *aPidls, UINT uItemCount)
|
||||
{
|
||||
UINT i;
|
||||
|
||||
TRACE(shell,"(%p)->(apidl=%p count=%u)\n",This, aPidls, uItemCount);
|
||||
|
||||
if(This->aPidls)
|
||||
{ for(i = 0; i < uItemCount; i++)
|
||||
{ This->aPidls[i] = ILClone(aPidls[i]);
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_CanRenameItems()
|
||||
*/
|
||||
BOOL IContextMenu_CanRenameItems(IContextMenuImpl *This)
|
||||
{ UINT i;
|
||||
DWORD dwAttributes;
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
if(This->aPidls)
|
||||
{
|
||||
for(i = 0; This->aPidls[i]; i++){} /*get the number of items assigned to This object*/
|
||||
{ if(i > 1) /*you can't rename more than one item at a time*/
|
||||
{ return FALSE;
|
||||
}
|
||||
}
|
||||
dwAttributes = SFGAO_CANRENAME;
|
||||
IShellFolder_GetAttributesOf(This->pSFParent, i, (LPCITEMIDLIST*)This->aPidls, &dwAttributes);
|
||||
|
||||
return dwAttributes & SFGAO_CANRENAME;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_Constructor()
|
||||
*/
|
||||
IContextMenu *IContextMenu_Constructor(LPSHELLFOLDER pSFParent, LPCITEMIDLIST *aPidls, UINT uItemCount)
|
||||
{ IContextMenuImpl* cm;
|
||||
UINT u;
|
||||
|
||||
cm = (IContextMenuImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IContextMenuImpl));
|
||||
cm->lpvtbl=&cmvt;
|
||||
cm->ref = 1;
|
||||
|
||||
cm->pSFParent = pSFParent;
|
||||
if(pSFParent)
|
||||
IShellFolder_AddRef(pSFParent);
|
||||
|
||||
cm->aPidls = NULL;
|
||||
|
||||
IContextMenu_AllocPidlTable(cm, uItemCount);
|
||||
|
||||
if(cm->aPidls)
|
||||
{ IContextMenu_FillPidlTable(cm, aPidls, uItemCount);
|
||||
}
|
||||
|
||||
cm->bAllValues = 1;
|
||||
for(u = 0; u < uItemCount; u++)
|
||||
{ cm->bAllValues &= (_ILIsValue(aPidls[u]) ? 1 : 0);
|
||||
}
|
||||
TRACE(shell,"(%p)->()\n",cm);
|
||||
shell32_ObjCount++;
|
||||
return (IContextMenu*)cm;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_fnQueryInterface
|
||||
*/
|
||||
static HRESULT WINAPI IContextMenu_fnQueryInterface(IContextMenu *iface, REFIID riid, LPVOID *ppvObj)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
char xriid[50];
|
||||
WINE_StringFromCLSID((LPCLSID)riid,xriid);
|
||||
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
|
||||
WINE_StringFromCLSID((LPCLSID)riid,xriid);
|
||||
|
||||
*ppvObj = NULL;
|
||||
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
|
||||
|
||||
if(IsEqualIID(riid, &IID_IUnknown)) /*IUnknown*/
|
||||
{ *ppvObj = This;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IContextMenu)) /*IContextMenu*/
|
||||
{ *ppvObj = This;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IShellExtInit)) /*IShellExtInit*/
|
||||
{ FIXME (shell,"-- LPSHELLEXTINIT pointer requested\n");
|
||||
}
|
||||
*ppvObj = NULL;
|
||||
|
||||
if(*ppvObj)
|
||||
{
|
||||
(*(IContextMenuImpl**)ppvObj)->lpvtbl->fnAddRef(iface);
|
||||
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
|
||||
return S_OK;
|
||||
}
|
||||
TRACE(shell,"-- Interface: E_NOINTERFACE\n");
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
if(IsEqualIID(riid, &IID_IUnknown)) /*IUnknown*/
|
||||
{ *ppvObj = This;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IContextMenu)) /*IContextMenu*/
|
||||
{ *ppvObj = This;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IShellExtInit)) /*IShellExtInit*/
|
||||
{ FIXME (shell,"-- LPSHELLEXTINIT pointer requested\n");
|
||||
}
|
||||
|
||||
if(*ppvObj)
|
||||
{
|
||||
IContextMenu_AddRef((IContextMenu*)*ppvObj);
|
||||
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
|
||||
return S_OK;
|
||||
}
|
||||
TRACE(shell,"-- Interface: E_NOINTERFACE\n");
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_fnAddRef
|
||||
*/
|
||||
static ULONG WINAPI IContextMenu_fnAddRef(IContextMenu *iface)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
TRACE(shell,"(%p)->(count=%lu)\n",This,(This->ref)+1);
|
||||
|
||||
shell32_ObjCount++;
|
||||
return ++(This->ref);
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_fnRelease
|
||||
*/
|
||||
static ULONG WINAPI IContextMenu_fnRelease(IContextMenu *iface)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
shell32_ObjCount--;
|
||||
@ -108,7 +203,7 @@ static ULONG WINAPI IContextMenu_fnRelease(IContextMenu *iface)
|
||||
{ TRACE(shell," destroying IContextMenu(%p)\n",This);
|
||||
|
||||
if(This->pSFParent)
|
||||
This->pSFParent->lpvtbl->fnRelease(This->pSFParent);
|
||||
IShellFolder_Release(This->pSFParent);
|
||||
|
||||
/*make sure the pidl is freed*/
|
||||
if(This->aPidls)
|
||||
@ -121,43 +216,19 @@ static ULONG WINAPI IContextMenu_fnRelease(IContextMenu *iface)
|
||||
return This->ref;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_Constructor()
|
||||
*/
|
||||
IContextMenu *IContextMenu_Constructor(LPSHELLFOLDER pSFParent, LPCITEMIDLIST *aPidls, UINT uItemCount)
|
||||
{ IContextMenuImpl* cm;
|
||||
UINT u;
|
||||
FIXME(shell, "HELLO age\n") ;
|
||||
cm = (IContextMenuImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IContextMenuImpl));
|
||||
cm->lpvtbl=&cmvt;
|
||||
cm->ref = 1;
|
||||
|
||||
cm->pSFParent = pSFParent;
|
||||
if(cm->pSFParent)
|
||||
cm->pSFParent->lpvtbl->fnAddRef(cm->pSFParent);
|
||||
|
||||
cm->aPidls = NULL;
|
||||
|
||||
IContextMenu_AllocPidlTable(cm, uItemCount);
|
||||
|
||||
if(cm->aPidls)
|
||||
{ IContextMenu_FillPidlTable(cm, aPidls, uItemCount);
|
||||
}
|
||||
|
||||
cm->bAllValues = 1;
|
||||
for(u = 0; u < uItemCount; u++)
|
||||
{ cm->bAllValues &= (_ILIsValue(aPidls[u]) ? 1 : 0);
|
||||
}
|
||||
TRACE(shell,"(%p)->()\n",cm);
|
||||
shell32_ObjCount++;
|
||||
return (IContextMenu*)cm;
|
||||
}
|
||||
/**************************************************************************
|
||||
* ICM_InsertItem()
|
||||
*/
|
||||
void WINAPI _InsertMenuItem (HMENU hmenu, UINT indexMenu, BOOL fByPosition,
|
||||
UINT wID, UINT fType, LPSTR dwTypeData, UINT fState)
|
||||
{ MENUITEMINFOA mii;
|
||||
void WINAPI _InsertMenuItem (
|
||||
HMENU hmenu,
|
||||
UINT indexMenu,
|
||||
BOOL fByPosition,
|
||||
UINT wID,
|
||||
UINT fType,
|
||||
LPSTR dwTypeData,
|
||||
UINT fState)
|
||||
{
|
||||
MENUITEMINFOA mii;
|
||||
|
||||
ZeroMemory(&mii, sizeof(mii));
|
||||
mii.cbSize = sizeof(mii);
|
||||
@ -177,9 +248,16 @@ void WINAPI _InsertMenuItem (HMENU hmenu, UINT indexMenu, BOOL fByPosition,
|
||||
* IContextMenu_fnQueryContextMenu()
|
||||
*/
|
||||
|
||||
static HRESULT WINAPI IContextMenu_fnQueryContextMenu(IContextMenu *iface, HMENU hmenu, UINT indexMenu,
|
||||
UINT idCmdFirst,UINT idCmdLast,UINT uFlags)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
static HRESULT WINAPI IContextMenu_fnQueryContextMenu(
|
||||
IContextMenu *iface,
|
||||
HMENU hmenu,
|
||||
UINT indexMenu,
|
||||
UINT idCmdFirst,
|
||||
UINT idCmdLast,
|
||||
UINT uFlags)
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
BOOL fExplore ;
|
||||
|
||||
TRACE(shell,"(%p)->(hmenu=%x indexmenu=%x cmdfirst=%x cmdlast=%x flags=%x )\n",This, hmenu, indexMenu, idCmdFirst, idCmdLast, uFlags);
|
||||
@ -193,19 +271,19 @@ static HRESULT WINAPI IContextMenu_fnQueryContextMenu(IContextMenu *iface, HMENU
|
||||
_InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_OPEN, MFT_STRING, "&Open", MFS_ENABLED);
|
||||
}
|
||||
else
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_OPEN, MFT_STRING, "&Open", MFS_ENABLED|MFS_DEFAULT);
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_OPEN, MFT_STRING, "&Open", MFS_ENABLED|MFS_DEFAULT);
|
||||
_InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_EXPLORE, MFT_STRING, "&Explore", MFS_ENABLED);
|
||||
}
|
||||
}
|
||||
|
||||
if(uFlags & CMF_CANRENAME)
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, 0, MFT_SEPARATOR, NULL, 0);
|
||||
if(uFlags & CMF_CANRENAME)
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, 0, MFT_SEPARATOR, NULL, 0);
|
||||
_InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_RENAME, MFT_STRING, "&Rename", (IContextMenu_CanRenameItems(This) ? MFS_ENABLED : MFS_DISABLED));
|
||||
}
|
||||
}
|
||||
else /* file menu */
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_OPEN, MFT_STRING, "&Open", MFS_ENABLED|MFS_DEFAULT);
|
||||
if(uFlags & CMF_CANRENAME)
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, 0, MFT_SEPARATOR, NULL, 0);
|
||||
if(uFlags & CMF_CANRENAME)
|
||||
{ _InsertMenuItem(hmenu, indexMenu++, TRUE, 0, MFT_SEPARATOR, NULL, 0);
|
||||
_InsertMenuItem(hmenu, indexMenu++, TRUE, idCmdFirst+IDM_RENAME, MFT_STRING, "&Rename", (IContextMenu_CanRenameItems(This) ? MFS_ENABLED : MFS_DISABLED));
|
||||
}
|
||||
}
|
||||
@ -217,8 +295,12 @@ static HRESULT WINAPI IContextMenu_fnQueryContextMenu(IContextMenu *iface, HMENU
|
||||
/**************************************************************************
|
||||
* IContextMenu_fnInvokeCommand()
|
||||
*/
|
||||
static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVOKECOMMANDINFO lpcmi)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
static HRESULT WINAPI IContextMenu_fnInvokeCommand(
|
||||
IContextMenu *iface,
|
||||
LPCMINVOKECOMMANDINFO lpcmi)
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
LPITEMIDLIST pidlTemp,pidlFQ;
|
||||
LPSHELLBROWSER lpSB;
|
||||
LPSHELLVIEW lpSV;
|
||||
@ -226,13 +308,13 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVO
|
||||
SHELLEXECUTEINFOA sei;
|
||||
int i;
|
||||
|
||||
TRACE(shell,"(%p)->(invcom=%p verb=%p wnd=%x)\n",This,lpcmi,lpcmi->lpVerb, lpcmi->hwnd);
|
||||
TRACE(shell,"(%p)->(invcom=%p verb=%p wnd=%x)\n",This,lpcmi,lpcmi->lpVerb, lpcmi->hwnd);
|
||||
|
||||
if(HIWORD(lpcmi->lpVerb))
|
||||
{ /* get the active IShellView */
|
||||
lpSB = (LPSHELLBROWSER)SendMessageA(lpcmi->hwnd, CWM_GETISHELLBROWSER,0,0);
|
||||
IShellBrowser_QueryActiveShellView(lpSB, &lpSV); /* does AddRef() on lpSV */
|
||||
lpSV->lpvtbl->fnGetWindow(lpSV, &hWndSV);
|
||||
IShellView_GetWindow(lpSV, &hWndSV);
|
||||
|
||||
/* these verbs are used by the filedialogs*/
|
||||
TRACE(shell,"%s\n",lpcmi->lpVerb);
|
||||
@ -248,7 +330,7 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVO
|
||||
else
|
||||
{ FIXME(shell,"please report: unknown verb %s\n",lpcmi->lpVerb);
|
||||
}
|
||||
lpSV->lpvtbl->fnRelease(lpSV);
|
||||
IShellView_Release(lpSV);
|
||||
return NOERROR;
|
||||
}
|
||||
|
||||
@ -258,18 +340,18 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVO
|
||||
switch(LOWORD(lpcmi->lpVerb))
|
||||
{ case IDM_EXPLORE:
|
||||
case IDM_OPEN:
|
||||
/* Find the first item in the list that is not a value. These commands
|
||||
should never be invoked if there isn't at least one folder item in the list.*/
|
||||
/* Find the first item in the list that is not a value. These commands
|
||||
should never be invoked if there isn't at least one folder item in the list.*/
|
||||
|
||||
for(i = 0; This->aPidls[i]; i++)
|
||||
{ if(!_ILIsValue(This->aPidls[i]))
|
||||
break;
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
pidlTemp = ILCombine(((IGenericSFImpl*)(This->pSFParent))->mpidl, This->aPidls[i]);
|
||||
pidlFQ = ILCombine(((IGenericSFImpl*)(This->pSFParent))->pMyPidl, pidlTemp);
|
||||
SHFree(pidlTemp);
|
||||
|
||||
|
||||
ZeroMemory(&sei, sizeof(sei));
|
||||
sei.cbSize = sizeof(sei);
|
||||
sei.fMask = SEE_MASK_IDLIST | SEE_MASK_CLASSNAME;
|
||||
@ -277,7 +359,7 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVO
|
||||
sei.lpClass = "folder";
|
||||
sei.hwnd = lpcmi->hwnd;
|
||||
sei.nShow = SW_SHOWNORMAL;
|
||||
|
||||
|
||||
if(LOWORD(lpcmi->lpVerb) == IDM_EXPLORE)
|
||||
{ sei.lpVerb = "explore";
|
||||
}
|
||||
@ -299,9 +381,16 @@ static HRESULT WINAPI IContextMenu_fnInvokeCommand(IContextMenu *iface, LPCMINVO
|
||||
/**************************************************************************
|
||||
* IContextMenu_fnGetCommandString()
|
||||
*/
|
||||
static HRESULT WINAPI IContextMenu_fnGetCommandString(IContextMenu *iface, UINT idCommand,
|
||||
UINT uFlags,LPUINT lpReserved,LPSTR lpszName,UINT uMaxNameLen)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
static HRESULT WINAPI IContextMenu_fnGetCommandString(
|
||||
IContextMenu *iface,
|
||||
UINT idCommand,
|
||||
UINT uFlags,
|
||||
LPUINT lpReserved,
|
||||
LPSTR lpszName,
|
||||
UINT uMaxNameLen)
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
HRESULT hr = E_INVALIDARG;
|
||||
|
||||
TRACE(shell,"(%p)->(idcom=%x flags=%x %p name=%p len=%x)\n",This, idCommand, uFlags, lpReserved, lpszName, uMaxNameLen);
|
||||
@ -310,7 +399,7 @@ static HRESULT WINAPI IContextMenu_fnGetCommandString(IContextMenu *iface, UINT
|
||||
{ case GCS_HELPTEXT:
|
||||
hr = E_NOTIMPL;
|
||||
break;
|
||||
|
||||
|
||||
case GCS_VERBA:
|
||||
switch(idCommand)
|
||||
{ case IDM_RENAME:
|
||||
@ -345,84 +434,32 @@ static HRESULT WINAPI IContextMenu_fnGetCommandString(IContextMenu *iface, UINT
|
||||
* should be only in IContextMenu2 and IContextMenu3
|
||||
* is nevertheless called from word95
|
||||
*/
|
||||
static HRESULT WINAPI IContextMenu_fnHandleMenuMsg(IContextMenu *iface, UINT uMsg,WPARAM wParam,LPARAM lParam)
|
||||
{ ICOM_THIS(IContextMenuImpl, iface);
|
||||
static HRESULT WINAPI IContextMenu_fnHandleMenuMsg(
|
||||
IContextMenu *iface,
|
||||
UINT uMsg,
|
||||
WPARAM wParam,
|
||||
LPARAM lParam)
|
||||
{
|
||||
ICOM_THIS(IContextMenuImpl, iface);
|
||||
|
||||
TRACE(shell,"(%p)->(msg=%x wp=%x lp=%lx)\n",This, uMsg, wParam, lParam);
|
||||
|
||||
return E_NOTIMPL;
|
||||
}
|
||||
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_AllocPidlTable()
|
||||
* IContextMenu VTable
|
||||
*
|
||||
*/
|
||||
BOOL IContextMenu_AllocPidlTable(IContextMenuImpl *This, DWORD dwEntries)
|
||||
{ TRACE(shell,"(%p)->(entrys=%lu)\n",This, dwEntries);
|
||||
|
||||
/*add one for NULL terminator */
|
||||
dwEntries++;
|
||||
|
||||
This->aPidls = (LPITEMIDLIST*)SHAlloc(dwEntries * sizeof(LPITEMIDLIST));
|
||||
|
||||
if(This->aPidls)
|
||||
{ ZeroMemory(This->aPidls, dwEntries * sizeof(LPITEMIDLIST)); /*set all of the entries to NULL*/
|
||||
}
|
||||
return (This->aPidls != NULL);
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_FreePidlTable()
|
||||
*/
|
||||
void IContextMenu_FreePidlTable(IContextMenuImpl *This)
|
||||
{ int i;
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
if(This->aPidls)
|
||||
{ for(i = 0; This->aPidls[i]; i++)
|
||||
{ SHFree(This->aPidls[i]);
|
||||
}
|
||||
|
||||
SHFree(This->aPidls);
|
||||
This->aPidls = NULL;
|
||||
}
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_FillPidlTable()
|
||||
*/
|
||||
BOOL IContextMenu_FillPidlTable(IContextMenuImpl *This, LPCITEMIDLIST *aPidls, UINT uItemCount)
|
||||
{ UINT i;
|
||||
TRACE(shell,"(%p)->(apidl=%p count=%u)\n",This, aPidls, uItemCount);
|
||||
if(This->aPidls)
|
||||
{ for(i = 0; i < uItemCount; i++)
|
||||
{ This->aPidls[i] = ILClone(aPidls[i]);
|
||||
}
|
||||
return TRUE;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IContextMenu_CanRenameItems()
|
||||
*/
|
||||
BOOL IContextMenu_CanRenameItems(IContextMenuImpl *This)
|
||||
{ UINT i;
|
||||
DWORD dwAttributes;
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
if(This->aPidls)
|
||||
{ for(i = 0; This->aPidls[i]; i++){} /*get the number of items assigned to This object*/
|
||||
if(i > 1) /*you can't rename more than one item at a time*/
|
||||
{ return FALSE;
|
||||
}
|
||||
dwAttributes = SFGAO_CANRENAME;
|
||||
This->pSFParent->lpvtbl->fnGetAttributesOf(This->pSFParent, i,
|
||||
(LPCITEMIDLIST*)This->aPidls, &dwAttributes);
|
||||
|
||||
return dwAttributes & SFGAO_CANRENAME;
|
||||
}
|
||||
return FALSE;
|
||||
}
|
||||
static struct ICOM_VTABLE(IContextMenu) cmvt =
|
||||
{
|
||||
IContextMenu_fnQueryInterface,
|
||||
IContextMenu_fnAddRef,
|
||||
IContextMenu_fnRelease,
|
||||
IContextMenu_fnQueryContextMenu,
|
||||
IContextMenu_fnInvokeCommand,
|
||||
IContextMenu_fnGetCommandString,
|
||||
IContextMenu_fnHandleMenuMsg,
|
||||
(void *) 0xdeadbabe /* just paranoia */
|
||||
};
|
||||
|
||||
|
@ -6,113 +6,119 @@
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "debug.h"
|
||||
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_extracticon.h"
|
||||
|
||||
#include "debug.h"
|
||||
#include "winerror.h"
|
||||
|
||||
#include "pidl.h"
|
||||
#include "shell32_main.h"
|
||||
#include "shlguid.h"
|
||||
|
||||
|
||||
/******************************************************************************
|
||||
* foreward declaration
|
||||
*/
|
||||
|
||||
/* IExtractIcon implementation*/
|
||||
static HRESULT WINAPI IExtractIcon_QueryInterface(LPEXTRACTICON, REFIID, LPVOID *);
|
||||
static ULONG WINAPI IExtractIcon_AddRef(LPEXTRACTICON);
|
||||
static ULONG WINAPI IExtractIcon_AddRef(LPEXTRACTICON);
|
||||
static ULONG WINAPI IExtractIcon_Release(LPEXTRACTICON);
|
||||
static HRESULT WINAPI IExtractIcon_GetIconLocation(LPEXTRACTICON, UINT, LPSTR, UINT, int *, UINT *);
|
||||
static HRESULT WINAPI IExtractIcon_Extract(LPEXTRACTICON, LPCSTR, UINT, HICON *, HICON *, UINT);
|
||||
|
||||
|
||||
/***********************************************************************
|
||||
* IExtractIcon implementation
|
||||
* IExtractIconA implementation
|
||||
*/
|
||||
static struct IExtractIcon_VTable eivt =
|
||||
{ IExtractIcon_QueryInterface,
|
||||
IExtractIcon_AddRef,
|
||||
IExtractIcon_Release,
|
||||
IExtractIcon_GetIconLocation,
|
||||
IExtractIcon_Extract
|
||||
};
|
||||
|
||||
typedef struct
|
||||
{ ICOM_VTABLE(IExtractIconA)* lpvtbl;
|
||||
DWORD ref;
|
||||
LPITEMIDLIST pidl;
|
||||
} IExtractIconAImpl;
|
||||
|
||||
static struct ICOM_VTABLE(IExtractIconA) eivt;
|
||||
|
||||
|
||||
/**************************************************************************
|
||||
* IExtractIcon_Constructor
|
||||
* IExtractIconA_Constructor
|
||||
*/
|
||||
LPEXTRACTICON IExtractIcon_Constructor(LPCITEMIDLIST pidl)
|
||||
{ LPEXTRACTICON ei;
|
||||
IExtractIconA* IExtractIconA_Constructor(LPCITEMIDLIST pidl)
|
||||
{
|
||||
IExtractIconAImpl* ei;
|
||||
|
||||
ei=(LPEXTRACTICON)HeapAlloc(GetProcessHeap(),0,sizeof(IExtractIcon));
|
||||
ei->ref=1;
|
||||
ei->lpvtbl=&eivt;
|
||||
ei->pidl=ILClone(pidl);
|
||||
ei=(IExtractIconAImpl*)HeapAlloc(GetProcessHeap(),0,sizeof(IExtractIconAImpl));
|
||||
ei->ref=1;
|
||||
ei->lpvtbl=&eivt;
|
||||
ei->pidl=ILClone(pidl);
|
||||
|
||||
pdump(pidl);
|
||||
pdump(pidl);
|
||||
|
||||
TRACE(shell,"(%p)\n",ei);
|
||||
shell32_ObjCount++;
|
||||
return ei;
|
||||
return (IExtractIconA *)ei;
|
||||
}
|
||||
/**************************************************************************
|
||||
* IExtractIcon_QueryInterface
|
||||
* IExtractIconA_QueryInterface
|
||||
*/
|
||||
static HRESULT WINAPI IExtractIcon_QueryInterface( LPEXTRACTICON this, REFIID riid, LPVOID *ppvObj)
|
||||
{ char xriid[50];
|
||||
WINE_StringFromCLSID((LPCLSID)riid,xriid);
|
||||
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",this,xriid,ppvObj);
|
||||
static HRESULT WINAPI IExtractIconA_fnQueryInterface( IExtractIconA * iface, REFIID riid, LPVOID *ppvObj)
|
||||
{
|
||||
ICOM_THIS(IExtractIconAImpl,iface);
|
||||
|
||||
*ppvObj = NULL;
|
||||
char xriid[50];
|
||||
WINE_StringFromCLSID((LPCLSID)riid,xriid);
|
||||
TRACE(shell,"(%p)->(\n\tIID:\t%s,%p)\n",This,xriid,ppvObj);
|
||||
|
||||
if(IsEqualIID(riid, &IID_IUnknown)) /*IUnknown*/
|
||||
{ *ppvObj = this;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IExtractIcon)) /*IExtractIcon*/
|
||||
{ *ppvObj = (IExtractIcon*)this;
|
||||
}
|
||||
*ppvObj = NULL;
|
||||
|
||||
if(*ppvObj)
|
||||
{ (*(LPEXTRACTICON*)ppvObj)->lpvtbl->fnAddRef(this);
|
||||
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
|
||||
return S_OK;
|
||||
}
|
||||
if(IsEqualIID(riid, &IID_IUnknown)) /*IUnknown*/
|
||||
{ *ppvObj = This;
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IExtractIconA)) /*IExtractIcon*/
|
||||
{ *ppvObj = (IExtractIconA*)This;
|
||||
}
|
||||
|
||||
if(*ppvObj)
|
||||
{ IExtractIconA_AddRef((IExtractIconA*) *ppvObj);
|
||||
TRACE(shell,"-- Interface: (%p)->(%p)\n",ppvObj,*ppvObj);
|
||||
return S_OK;
|
||||
}
|
||||
TRACE(shell,"-- Interface: E_NOINTERFACE\n");
|
||||
return E_NOINTERFACE;
|
||||
}
|
||||
}
|
||||
|
||||
/**************************************************************************
|
||||
* IExtractIcon_AddRef
|
||||
* IExtractIconA_AddRef
|
||||
*/
|
||||
static ULONG WINAPI IExtractIcon_AddRef(LPEXTRACTICON this)
|
||||
{ TRACE(shell,"(%p)->(count=%lu)\n",this,(this->ref)+1);
|
||||
static ULONG WINAPI IExtractIconA_fnAddRef(IExtractIconA * iface)
|
||||
{
|
||||
ICOM_THIS(IExtractIconAImpl,iface);
|
||||
|
||||
TRACE(shell,"(%p)->(count=%lu)\n",This,(This->ref)+1);
|
||||
|
||||
shell32_ObjCount++;
|
||||
|
||||
return ++(this->ref);
|
||||
return ++(This->ref);
|
||||
}
|
||||
/**************************************************************************
|
||||
* IExtractIcon_Release
|
||||
* IExtractIconA_Release
|
||||
*/
|
||||
static ULONG WINAPI IExtractIcon_Release(LPEXTRACTICON this)
|
||||
{ TRACE(shell,"(%p)->()\n",this);
|
||||
static ULONG WINAPI IExtractIconA_fnRelease(IExtractIconA * iface)
|
||||
{
|
||||
ICOM_THIS(IExtractIconAImpl,iface);
|
||||
|
||||
TRACE(shell,"(%p)->()\n",This);
|
||||
|
||||
shell32_ObjCount--;
|
||||
|
||||
if (!--(this->ref))
|
||||
{ TRACE(shell," destroying IExtractIcon(%p)\n",this);
|
||||
SHFree(this->pidl);
|
||||
HeapFree(GetProcessHeap(),0,this);
|
||||
return 0;
|
||||
}
|
||||
return this->ref;
|
||||
if (!--(This->ref))
|
||||
{ TRACE(shell," destroying IExtractIcon(%p)\n",This);
|
||||
SHFree(This->pidl);
|
||||
HeapFree(GetProcessHeap(),0,This);
|
||||
return 0;
|
||||
}
|
||||
return This->ref;
|
||||
}
|
||||
/**************************************************************************
|
||||
* IExtractIcon_GetIconLocation
|
||||
* IExtractIconA_GetIconLocation
|
||||
*/
|
||||
static HRESULT WINAPI IExtractIcon_GetIconLocation(LPEXTRACTICON this, UINT uFlags, LPSTR szIconFile, UINT cchMax, int * piIndex, UINT * pwFlags)
|
||||
{ WARN (shell,"(%p) (flags=%u file=%s max=%u %p %p) semi-stub\n", this, uFlags, szIconFile, cchMax, piIndex, pwFlags);
|
||||
static HRESULT WINAPI IExtractIconA_fnGetIconLocation(IExtractIconA * iface, UINT uFlags, LPSTR szIconFile, UINT cchMax, int * piIndex, UINT * pwFlags)
|
||||
{
|
||||
ICOM_THIS(IExtractIconAImpl,iface);
|
||||
|
||||
*piIndex = (int) SHMapPIDLToSystemImageListIndex(0, this->pidl,0);
|
||||
WARN (shell,"(%p) (flags=%u file=%s max=%u %p %p) semi-stub\n", This, uFlags, szIconFile, cchMax, piIndex, pwFlags);
|
||||
|
||||
*piIndex = (int) SHMapPIDLToSystemImageListIndex(0, This->pidl,0);
|
||||
*pwFlags = GIL_NOTFILENAME;
|
||||
|
||||
WARN (shell,"-- %x\n",*piIndex);
|
||||
@ -120,12 +126,23 @@ static HRESULT WINAPI IExtractIcon_GetIconLocation(LPEXTRACTICON this, UINT uFla
|
||||
return NOERROR;
|
||||
}
|
||||
/**************************************************************************
|
||||
* IExtractIcon_Extract
|
||||
* IExtractIconA_Extract
|
||||
*/
|
||||
static HRESULT WINAPI IExtractIcon_Extract(LPEXTRACTICON this, LPCSTR pszFile, UINT nIconIndex, HICON *phiconLarge, HICON *phiconSmall, UINT nIconSize)
|
||||
{ FIXME (shell,"(%p) (file=%s index=%u %p %p size=%u) semi-stub\n", this, pszFile, nIconIndex, phiconLarge, phiconSmall, nIconSize);
|
||||
*phiconLarge = pImageList_GetIcon(ShellBigIconList, nIconIndex, ILD_TRANSPARENT);
|
||||
*phiconSmall = pImageList_GetIcon(ShellSmallIconList, nIconIndex, ILD_TRANSPARENT);
|
||||
return S_OK;
|
||||
static HRESULT WINAPI IExtractIconA_fnExtract(IExtractIconA * iface, LPCSTR pszFile, UINT nIconIndex, HICON *phiconLarge, HICON *phiconSmall, UINT nIconSize)
|
||||
{
|
||||
ICOM_THIS(IExtractIconAImpl,iface);
|
||||
|
||||
FIXME (shell,"(%p) (file=%s index=%u %p %p size=%u) semi-stub\n", This, pszFile, nIconIndex, phiconLarge, phiconSmall, nIconSize);
|
||||
|
||||
*phiconLarge = pImageList_GetIcon(ShellBigIconList, nIconIndex, ILD_TRANSPARENT);
|
||||
*phiconSmall = pImageList_GetIcon(ShellSmallIconList, nIconIndex, ILD_TRANSPARENT);
|
||||
return S_OK;
|
||||
}
|
||||
|
||||
static struct ICOM_VTABLE(IExtractIconA) eivt =
|
||||
{ IExtractIconA_fnQueryInterface,
|
||||
IExtractIconA_fnAddRef,
|
||||
IExtractIconA_fnRelease,
|
||||
IExtractIconA_fnGetIconLocation,
|
||||
IExtractIconA_fnExtract
|
||||
};
|
||||
|
@ -1089,9 +1089,9 @@ BOOL WINAPI Shell32LibMain(HINSTANCE hinstDLL, DWORD fdwReason, LPVOID fImpLoad)
|
||||
{ pdesktopfolder->lpvtbl->fnRelease(pdesktopfolder);
|
||||
}
|
||||
|
||||
/* this one is here ot check if AddRef/Release is balanced */
|
||||
/* this one is here to check if AddRef/Release is balanced */
|
||||
if (shell32_ObjCount)
|
||||
{ FIXME(shell,"%u objects left\n", shell32_ObjCount);
|
||||
{ WARN(shell,"leaving with %u objects left (memory leak)\n", shell32_ObjCount);
|
||||
}
|
||||
}
|
||||
TRACE(shell, "refcount=%u objcount=%u \n", shell32_RefCount, shell32_ObjCount);
|
||||
|
@ -86,7 +86,11 @@ extern LPSHELLVIEW IShellView_Constructor(LPSHELLFOLDER, LPCITEMIDLIST);
|
||||
extern LPSHELLLINK IShellLink_Constructor(void);
|
||||
extern LPSHELLLINKW IShellLinkW_Constructor(void);
|
||||
extern LPENUMIDLIST IEnumIDList_Constructor(LPCSTR,DWORD);
|
||||
extern LPEXTRACTICON IExtractIcon_Constructor(LPITEMIDLIST);
|
||||
extern LPEXTRACTICONA IExtractIconA_Constructor(LPITEMIDLIST);
|
||||
|
||||
/* fixme: rename the functions when the shell32.dll has it's own exports namespace */
|
||||
HRESULT WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID * ppv);
|
||||
HRESULT WINAPI SHELL32_DllCanUnloadNow(void);
|
||||
|
||||
/* elements of this structure are accessed directly from within shell32 */
|
||||
typedef struct
|
||||
|
@ -8,17 +8,23 @@
|
||||
|
||||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
#include "winreg.h"
|
||||
#include "winerror.h"
|
||||
|
||||
#include "wine/obj_base.h"
|
||||
#include "winversion.h"
|
||||
#include "wine/obj_shelllink.h"
|
||||
#include "wine/obj_shellfolder.h"
|
||||
#include "wine/obj_shellbrowser.h"
|
||||
#include "wine/obj_contextmenu.h"
|
||||
#include "wine/obj_shellextinit.h"
|
||||
#include "wine/obj_extracticon.h"
|
||||
|
||||
#include "shlguid.h"
|
||||
#include "shlobj.h"
|
||||
#include "shell32_main.h"
|
||||
|
||||
#include "winversion.h"
|
||||
#include "winreg.h"
|
||||
#include "winerror.h"
|
||||
#include "debug.h"
|
||||
|
||||
#include "shell32_main.h"
|
||||
|
||||
/*************************************************************************
|
||||
*
|
||||
*/
|
||||
@ -149,12 +155,9 @@ LRESULT WINAPI SHCoCreateInstance(LPSTR aclsid,CLSID *clsid,LPUNKNOWN unknownout
|
||||
* With this pointer it's possible to call the IClassFactory_CreateInstance
|
||||
* method to get a instance of the requested Class.
|
||||
* This function does NOT instantiate the Class!!!
|
||||
*
|
||||
* RETURNS
|
||||
* HRESULT
|
||||
*
|
||||
*/
|
||||
DWORD WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid,REFIID iid,LPVOID *ppv)
|
||||
HRESULT WINAPI SHELL32_DllGetClassObject(REFCLSID rclsid,REFIID iid,LPVOID *ppv)
|
||||
{ HRESULT hres = E_OUTOFMEMORY;
|
||||
LPCLASSFACTORY lpclf;
|
||||
|
||||
@ -317,16 +320,16 @@ static HRESULT WINAPI IClassFactory_fnCreateInstance(
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IShellView))
|
||||
{ pObj = (IUnknown *)IShellView_Constructor(NULL,NULL);
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IExtractIcon))
|
||||
{ pObj = (IUnknown *)IExtractIcon_Constructor(NULL);
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IExtractIconA))
|
||||
{ pObj = (IUnknown *)IExtractIconA_Constructor(NULL);
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IContextMenu))
|
||||
{ pObj = (IUnknown *)IContextMenu_Constructor(NULL, NULL, 0);
|
||||
}
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IDataObject))
|
||||
{ pObj = (IUnknown *)IDataObject_Constructor(0,NULL,NULL,0);
|
||||
}
|
||||
}
|
||||
else
|
||||
{ ERR(shell,"unknown IID requested\n\tIID:\t%s\n",xriid);
|
||||
return(E_NOINTERFACE);
|
||||
|
@ -752,13 +752,13 @@ static HRESULT WINAPI IShellFolder_fnGetUIObjectOf(
|
||||
|
||||
pObj = (LPUNKNOWN)IDataObject_Constructor (hwndOwner, (IShellFolder *)This, apidl, cidl);
|
||||
}
|
||||
else if(IsEqualIID(riid, &IID_IExtractIcon))
|
||||
else if(IsEqualIID(riid, &IID_IExtractIconA))
|
||||
{
|
||||
if (cidl != 1)
|
||||
return(E_INVALIDARG);
|
||||
|
||||
pidl = ILCombine(This->pMyPidl,apidl[0]);
|
||||
pObj = (LPUNKNOWN)IExtractIcon_Constructor( pidl );
|
||||
pObj = (LPUNKNOWN)IExtractIconA_Constructor( pidl );
|
||||
SHFree(pidl);
|
||||
}
|
||||
else if (IsEqualIID(riid, &IID_IDropTarget))
|
||||
|
File diff suppressed because it is too large
Load Diff
@ -15,30 +15,20 @@ DEFINE_SHLGUID(CGID_ShellDocView, 0x000214D1L, 0, 0);
|
||||
|
||||
/* shell32interface ids */
|
||||
DEFINE_SHLGUID(IID_INewShortcutHookA, 0x000214E1L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellBrowser, 0x000214E2L, 0, 0);
|
||||
#define SID_SShellBrowser IID_IShellBrowser
|
||||
DEFINE_SHLGUID(IID_IShellView, 0x000214E3L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IContextMenu, 0x000214E4L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellIcon, 0x000214E5L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellExtInit, 0x000214E8L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellPropSheetExt, 0x000214E9L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IExtractIcon, 0x000214EBL, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellCopyHook, 0x000214EFL, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IFileViewer, 0x000214F0L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_ICommDlgBrowser, 0x000214F1L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IFileViewerSite, 0x000214F3L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IContextMenu2, 0x000214F4L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellExecuteHookA, 0x000214F5L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IPropSheetPage, 0x000214F6L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_INewShortcutHookW, 0x000214F7L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IFileViewerW, 0x000214F8L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IExtractIconW, 0x000214FAL, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellExecuteHookW, 0x000214FBL, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IShellCopyHookW, 0x000214FCL, 0, 0);
|
||||
|
||||
DEFINE_GUID (IID_IDockingWindow, 0x012dd920L, 0x7B26, 0x11D0, 0x8C, 0xA9, 0x00, 0xA0, 0xC9, 0x2D, 0xBF, 0xE8);
|
||||
DEFINE_GUID (IID_IDockingWindowSite, 0x2A342FC2L, 0x7B26, 0x11D0, 0x8C, 0xA9, 0x00, 0xA0, 0xC9, 0x2D, 0xBF, 0xE8);
|
||||
DEFINE_GUID (IID_IDockingWindowFrame, 0x47D2657AL, 0x7B27, 0x11D0, 0x8C, 0xA9, 0x00, 0xA0, 0xC9, 0x2D, 0xBF, 0xE8);
|
||||
|
||||
/****************************************************************************
|
||||
* the following should be moved to the right place
|
||||
|
512
include/shlobj.h
512
include/shlobj.h
@ -1,11 +1,18 @@
|
||||
#ifndef __WINE_SHLOBJ_H
|
||||
#define __WINE_SHLOBJ_H
|
||||
|
||||
#include "windef.h"
|
||||
#include "winbase.h" /* WIN32_FIND_* */
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_shelllink.h"
|
||||
#include "wine/obj_shellfolder.h"
|
||||
#include "wine/obj_shellbrowser.h"
|
||||
#include "wine/obj_contextmenu.h"
|
||||
#include "wine/obj_shellextinit.h"
|
||||
#include "wine/obj_extracticon.h"
|
||||
#include "wine/obj_commdlgbrowser.h"
|
||||
#include "wine/obj_dockingwindowframe.h"
|
||||
|
||||
#include "windef.h"
|
||||
#include "winbase.h" /* WIN32_FIND_* */
|
||||
#include "ole2.h"
|
||||
#include "shell.h"
|
||||
#include "commctrl.h"
|
||||
@ -17,142 +24,14 @@
|
||||
#define FAR
|
||||
#define THIS_ THIS,
|
||||
|
||||
/****************************************************************************
|
||||
* DllGetClassObject
|
||||
*/
|
||||
DWORD WINAPI SHELL32_DllGetClassObject(REFCLSID,REFIID,LPVOID*);
|
||||
|
||||
|
||||
|
||||
/* foreward declaration of the objects*/
|
||||
typedef struct IContextMenu IContextMenu, *LPCONTEXTMENU;
|
||||
typedef struct tagSHELLEXTINIT *LPSHELLEXTINIT,IShellExtInit;
|
||||
typedef struct tagSHELLVIEW *LPSHELLVIEW, IShellView;
|
||||
typedef struct tagSHELLBROWSER *LPSHELLBROWSER,IShellBrowser;
|
||||
typedef struct tagSHELLICON *LPSHELLICON, IShellIcon;
|
||||
typedef struct tagDOCKINGWINDOWFRAME *LPDOCKINGWINDOWFRAME, IDockingWindowFrame;
|
||||
typedef struct tagCOMMDLGBROWSER *LPCOMMDLGBROWSER, ICommDlgBrowser;
|
||||
|
||||
|
||||
|
||||
/*****************************************************************************
|
||||
* IContextMenu interface
|
||||
*/
|
||||
#define THIS LPCONTEXTMENU me
|
||||
|
||||
/* default menu items*/
|
||||
#define IDM_EXPLORE 0
|
||||
#define IDM_OPEN 1
|
||||
#define IDM_RENAME 2
|
||||
#define IDM_LAST IDM_RENAME
|
||||
|
||||
/* QueryContextMenu uFlags */
|
||||
#define CMF_NORMAL 0x00000000
|
||||
#define CMF_DEFAULTONLY 0x00000001
|
||||
#define CMF_VERBSONLY 0x00000002
|
||||
#define CMF_EXPLORE 0x00000004
|
||||
#define CMF_NOVERBS 0x00000008
|
||||
#define CMF_CANRENAME 0x00000010
|
||||
#define CMF_NODEFAULT 0x00000020
|
||||
#define CMF_INCLUDESTATIC 0x00000040
|
||||
#define CMF_RESERVED 0xffff0000 /* View specific */
|
||||
|
||||
/* GetCommandString uFlags */
|
||||
#define GCS_VERBA 0x00000000 /* canonical verb */
|
||||
#define GCS_HELPTEXTA 0x00000001 /* help text (for status bar) */
|
||||
#define GCS_VALIDATEA 0x00000002 /* validate command exists */
|
||||
#define GCS_VERBW 0x00000004 /* canonical verb (unicode) */
|
||||
#define GCS_HELPTEXTW 0x00000005 /* help text (unicode version) */
|
||||
#define GCS_VALIDATEW 0x00000006 /* validate command exists (unicode) */
|
||||
#define GCS_UNICODE 0x00000004 /* for bit testing - Unicode string */
|
||||
|
||||
#define GCS_VERB GCS_VERBA
|
||||
#define GCS_HELPTEXT GCS_HELPTEXTA
|
||||
#define GCS_VALIDATE GCS_VALIDATEA
|
||||
|
||||
#define CMDSTR_NEWFOLDERA "NewFolder"
|
||||
#define CMDSTR_VIEWLISTA "ViewList"
|
||||
#define CMDSTR_VIEWDETAILSA "ViewDetails"
|
||||
#define CMDSTR_NEWFOLDERW L"NewFolder"
|
||||
#define CMDSTR_VIEWLISTW L"ViewList"
|
||||
#define CMDSTR_VIEWDETAILSW L"ViewDetails"
|
||||
|
||||
#define CMDSTR_NEWFOLDER CMDSTR_NEWFOLDERA
|
||||
#define CMDSTR_VIEWLIST CMDSTR_VIEWLISTA
|
||||
#define CMDSTR_VIEWDETAILS CMDSTR_VIEWDETAILSA
|
||||
|
||||
#define CMIC_MASK_HOTKEY SEE_MASK_HOTKEY
|
||||
#define CMIC_MASK_ICON SEE_MASK_ICON
|
||||
#define CMIC_MASK_FLAG_NO_UI SEE_MASK_FLAG_NO_UI
|
||||
#define CMIC_MASK_UNICODE SEE_MASK_UNICODE
|
||||
#define CMIC_MASK_NO_CONSOLE SEE_MASK_NO_CONSOLE
|
||||
#define CMIC_MASK_HASLINKNAME SEE_MASK_HASLINKNAME
|
||||
#define CMIC_MASK_FLAG_SEP_VDM SEE_MASK_FLAG_SEPVDM
|
||||
#define CMIC_MASK_HASTITLE SEE_MASK_HASTITLE
|
||||
#define CMIC_MASK_ASYNCOK SEE_MASK_ASYNCOK
|
||||
|
||||
#define CMIC_MASK_PTINVOKE 0x20000000
|
||||
|
||||
/*NOTE: When SEE_MASK_HMONITOR is set, hIcon is treated as hMonitor */
|
||||
typedef struct tagCMINVOKECOMMANDINFO
|
||||
{ DWORD cbSize; /* sizeof(CMINVOKECOMMANDINFO) */
|
||||
DWORD fMask; /* any combination of CMIC_MASK_* */
|
||||
HWND hwnd; /* might be NULL (indicating no owner window) */
|
||||
LPCSTR lpVerb; /* either a string or MAKEINTRESOURCE(idOffset) */
|
||||
LPCSTR lpParameters; /* might be NULL (indicating no parameter) */
|
||||
LPCSTR lpDirectory; /* might be NULL (indicating no specific directory) */
|
||||
INT nShow; /* one of SW_ values for ShowWindow() API */
|
||||
|
||||
DWORD dwHotKey;
|
||||
HANDLE hIcon;
|
||||
} CMINVOKECOMMANDINFO, *LPCMINVOKECOMMANDINFO;
|
||||
|
||||
typedef struct tagCMInvokeCommandInfoEx
|
||||
{ DWORD cbSize; /* must be sizeof(CMINVOKECOMMANDINFOEX) */
|
||||
DWORD fMask; /* any combination of CMIC_MASK_* */
|
||||
HWND hwnd; /* might be NULL (indicating no owner window) */
|
||||
LPCSTR lpVerb; /* either a string or MAKEINTRESOURCE(idOffset) */
|
||||
LPCSTR lpParameters; /* might be NULL (indicating no parameter) */
|
||||
LPCSTR lpDirectory; /* might be NULL (indicating no specific directory) */
|
||||
INT nShow; /* one of SW_ values for ShowWindow() API */
|
||||
|
||||
DWORD dwHotKey;
|
||||
|
||||
HANDLE hIcon;
|
||||
LPCSTR lpTitle; /* For CreateProcess-StartupInfo.lpTitle */
|
||||
LPCWSTR lpVerbW; /* Unicode verb (for those who can use it) */
|
||||
LPCWSTR lpParametersW; /* Unicode parameters (for those who can use it) */
|
||||
LPCWSTR lpDirectoryW; /* Unicode directory (for those who can use it) */
|
||||
LPCWSTR lpTitleW; /* Unicode title (for those who can use it) */
|
||||
POINT ptInvoke; /* Point where it's invoked */
|
||||
|
||||
} CMINVOKECOMMANDINFOEX, *LPCMINVOKECOMMANDINFOEX;
|
||||
#undef THIS
|
||||
|
||||
|
||||
#define ICOM_INTERFACE IContextMenu
|
||||
#define IContextMenu_METHODS \
|
||||
ICOM_METHOD5(HRESULT,QueryContextMenu, HMENU,hmenu, UINT,indexMenu, UINT,idCmdFirst, UINT,idCmdLast, UINT,uFlags) \
|
||||
ICOM_METHOD1(HRESULT,InvokeCommand, LPCMINVOKECOMMANDINFO,lpici) \
|
||||
ICOM_METHOD5(HRESULT,GetCommandString, UINT,idCmd, UINT,uType, UINT*,pwReserved, LPSTR,pszName, UINT,cchMax) \
|
||||
ICOM_METHOD3(HRESULT,HandleMenuMsg, UINT,uMsg,WPARAM,wParam,LPARAM,lParam) \
|
||||
void * guard; /*possibly another nasty entry from ContextMenu3 ?*/
|
||||
#define IContextMenu_IMETHODS \
|
||||
IUnknown_IMETHODS \
|
||||
IContextMenu_METHODS
|
||||
ICOM_DEFINE(IContextMenu, IUnknown)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
// *** IUnknown methods *** //
|
||||
#define IContextMenu_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IContextMenu_AddRef(p) ICOM_CALL (AddRef,p)
|
||||
#define IContextMenu_Release(p) ICOM_CALL (Release,p)
|
||||
// *** IContextMenu methods *** //
|
||||
#define IContextMenu_QueryContextMenu(p,a,b,c,d,e) ICOM_CALL5(QueryContextMenu,p,a,b,c,d,e)
|
||||
#define IContextMenu_InvokeCommand(p,a) ICOM_CALL1(InvokeCommand,p,a)
|
||||
#define IContextMenu_GetCommandString(p,a,b,c,d,e) ICOM_CALL5(GetCommandString,p,a,b,c,d,e)
|
||||
#define IContextMenu_HandleMenuMsg(p,a,b,c) ICOM_CALL3(HandleMenuMsg,p,a,b,c)
|
||||
#endif
|
||||
|
||||
/* DATAOBJECT_InitShellIDList*/
|
||||
#define CFSTR_SHELLIDLIST "Shell IDList Array" /* CF_IDLIST */
|
||||
@ -225,357 +104,15 @@ extern void IDLList_Destructor(LPIDLLIST me);
|
||||
#undef THIS
|
||||
|
||||
|
||||
/*****************************************************************************
|
||||
* IShellExtInit interface
|
||||
*/
|
||||
#define THIS LPSHELLEXTINIT me
|
||||
|
||||
typedef struct IShellExtInit_VTable
|
||||
{ /* *** IUnknown methods *** */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* *** IShellExtInit methods *** */
|
||||
STDMETHOD(Initialize)(THIS_ LPCITEMIDLIST pidlFolder, LPDATAOBJECT lpdobj, HKEY hkeyProgID) PURE;
|
||||
} IShellExtInit_VTable,*LPSHELLEXTINIT_VTABLE;
|
||||
|
||||
struct tagSHELLEXTINIT
|
||||
{ LPSHELLEXTINIT_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
};
|
||||
|
||||
#undef THIS
|
||||
|
||||
/*-------------------------------------------------------------------------- */
|
||||
/* */
|
||||
/* FOLDERSETTINGS */
|
||||
/* */
|
||||
/* FOLDERSETTINGS is a data structure that explorer passes from one folder */
|
||||
/* view to another, when the user is browsing. It calls ISV::GetCurrentInfo */
|
||||
/* member to get the current settings and pass it to ISV::CreateViewWindow */
|
||||
/* to allow the next folder view "inherit" it. These settings assumes a */
|
||||
/* particular UI (which the shell's folder view has), and shell extensions */
|
||||
/* may or may not use those settings. */
|
||||
/* */
|
||||
/*-------------------------------------------------------------------------- */
|
||||
|
||||
typedef LPBYTE LPVIEWSETTINGS;
|
||||
|
||||
/* NB Bitfields. */
|
||||
/* FWF_DESKTOP implies FWF_TRANSPARENT/NOCLIENTEDGE/NOSCROLL */
|
||||
typedef enum
|
||||
{ FWF_AUTOARRANGE = 0x0001,
|
||||
FWF_ABBREVIATEDNAMES = 0x0002,
|
||||
FWF_SNAPTOGRID = 0x0004,
|
||||
FWF_OWNERDATA = 0x0008,
|
||||
FWF_BESTFITWINDOW = 0x0010,
|
||||
FWF_DESKTOP = 0x0020,
|
||||
FWF_SINGLESEL = 0x0040,
|
||||
FWF_NOSUBFOLDERS = 0x0080,
|
||||
FWF_TRANSPARENT = 0x0100,
|
||||
FWF_NOCLIENTEDGE = 0x0200,
|
||||
FWF_NOSCROLL = 0x0400,
|
||||
FWF_ALIGNLEFT = 0x0800,
|
||||
FWF_SINGLECLICKACTIVATE=0x8000 /* TEMPORARY -- NO UI FOR THIS */
|
||||
} FOLDERFLAGS;
|
||||
|
||||
typedef enum
|
||||
{ FVM_ICON = 1,
|
||||
FVM_SMALLICON = 2,
|
||||
FVM_LIST = 3,
|
||||
FVM_DETAILS = 4
|
||||
} FOLDERVIEWMODE;
|
||||
|
||||
typedef struct
|
||||
{ UINT ViewMode; /* View mode (FOLDERVIEWMODE values) */
|
||||
UINT fFlags; /* View options (FOLDERFLAGS bits) */
|
||||
} FOLDERSETTINGS, *LPFOLDERSETTINGS;
|
||||
|
||||
typedef const FOLDERSETTINGS * LPCFOLDERSETTINGS;
|
||||
|
||||
|
||||
/************************************************************************
|
||||
* IShellBrowser interface
|
||||
*/
|
||||
#define THIS LPSHELLBROWSER me
|
||||
/* targets for GetWindow/SendControlMsg */
|
||||
#define FCW_STATUS 0x0001
|
||||
#define FCW_TOOLBAR 0x0002
|
||||
#define FCW_TREE 0x0003
|
||||
#define FCW_INTERNETBAR 0x0006
|
||||
#define FCW_PROGRESS 0x0008
|
||||
|
||||
/* wFlags for BrowseObject*/
|
||||
#define SBSP_DEFBROWSER 0x0000
|
||||
#define SBSP_SAMEBROWSER 0x0001
|
||||
#define SBSP_NEWBROWSER 0x0002
|
||||
|
||||
#define SBSP_DEFMODE 0x0000
|
||||
#define SBSP_OPENMODE 0x0010
|
||||
#define SBSP_EXPLOREMODE 0x0020
|
||||
|
||||
#define SBSP_ABSOLUTE 0x0000
|
||||
#define SBSP_RELATIVE 0x1000
|
||||
#define SBSP_PARENT 0x2000
|
||||
#define SBSP_NAVIGATEBACK 0x4000
|
||||
#define SBSP_NAVIGATEFORWARD 0x8000
|
||||
|
||||
#define SBSP_ALLOW_AUTONAVIGATE 0x10000
|
||||
|
||||
#define SBSP_INITIATEDBYHLINKFRAME 0x80000000
|
||||
#define SBSP_REDIRECT 0x40000000
|
||||
#define SBSP_WRITENOHISTORY 0x08000000
|
||||
|
||||
/* uFlage for SetToolbarItems */
|
||||
#define FCT_MERGE 0x0001
|
||||
#define FCT_CONFIGABLE 0x0002
|
||||
#define FCT_ADDTOEND 0x0004
|
||||
|
||||
/* undocumented, found in the web posted by Chris Becke */
|
||||
#define CWM_SETPATH (WM_USER+2)
|
||||
#define CWM_WANTIDLE (WM_USER+3)
|
||||
#define CWM_GETSETCURRENTINFO (WM_USER+4)
|
||||
#define CWM_SELECTITEM (WM_USER+5)
|
||||
#define CWM_STOPWAITING (WM_USER+6)
|
||||
#define CWM_GETISHELLBROWSER (WM_USER+7)
|
||||
|
||||
typedef struct IShellBrowser_VTable
|
||||
{ /* *** IUnknown methods *** */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* *** IOleWindow methods *** */
|
||||
STDMETHOD(GetWindow) (THIS_ HWND * lphwnd) PURE;
|
||||
STDMETHOD(ContextSensitiveHelp) (THIS_ BOOL fEnterMode) PURE;
|
||||
|
||||
/* *** IShellBrowser methods *** (same as IOleInPlaceFrame) */
|
||||
STDMETHOD(InsertMenusSB) (THIS_ HMENU hmenuShared, LPOLEMENUGROUPWIDTHS lpMenuWidths) PURE;
|
||||
STDMETHOD(SetMenuSB) (THIS_ HMENU hmenuShared, HOLEMENU holemenuReserved, HWND hwndActiveObject) PURE;
|
||||
STDMETHOD(RemoveMenusSB) (THIS_ HMENU hmenuShared) PURE;
|
||||
STDMETHOD(SetStatusTextSB) (THIS_ LPCOLESTR lpszStatusText) PURE;
|
||||
STDMETHOD(EnableModelessSB) (THIS_ BOOL fEnable) PURE;
|
||||
STDMETHOD(TranslateAcceleratorSB) (THIS_ LPMSG lpmsg, WORD wID) PURE;
|
||||
|
||||
/* *** IShellBrowser methods *** */
|
||||
STDMETHOD(BrowseObject)(THIS_ LPCITEMIDLIST pidl, UINT wFlags) PURE;
|
||||
STDMETHOD(GetViewStateStream)(THIS_ DWORD grfMode, LPSTREAM *ppStrm) PURE;
|
||||
STDMETHOD(GetControlWindow)(THIS_ UINT id, HWND * lphwnd) PURE;
|
||||
STDMETHOD(SendControlMsg)(THIS_ UINT id, UINT uMsg, WPARAM wParam, LPARAM lParam, LRESULT * pret) PURE;
|
||||
STDMETHOD(QueryActiveShellView)(THIS_ IShellView ** ppshv) PURE;
|
||||
STDMETHOD(OnViewWindowActive)(THIS_ IShellView * ppshv) PURE;
|
||||
STDMETHOD(SetToolbarItems)(THIS_ LPTBBUTTON lpButtons, UINT nButtons, UINT uFlags) PURE;
|
||||
} *LPSHELLBROWSER_VTABLE,IShellBrowser_VTable;
|
||||
|
||||
struct tagSHELLBROWSER
|
||||
{ LPSHELLBROWSER_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
};
|
||||
|
||||
#undef THIS
|
||||
|
||||
/************************************************************************
|
||||
* IShellView interface
|
||||
*/
|
||||
#define THIS LPSHELLVIEW me
|
||||
|
||||
/* shellview select item flags*/
|
||||
#define SVSI_DESELECT 0x0000
|
||||
#define SVSI_SELECT 0x0001
|
||||
#define SVSI_EDIT 0x0003 /* includes select */
|
||||
#define SVSI_DESELECTOTHERS 0x0004
|
||||
#define SVSI_ENSUREVISIBLE 0x0008
|
||||
#define SVSI_FOCUSED 0x0010
|
||||
|
||||
/* shellview get item object flags */
|
||||
#define SVGIO_BACKGROUND 0x00000000
|
||||
#define SVGIO_SELECTION 0x00000001
|
||||
#define SVGIO_ALLVIEW 0x00000002
|
||||
|
||||
/* The explorer dispatches WM_COMMAND messages based on the range of
|
||||
command/menuitem IDs. All the IDs of menuitems that the view (right
|
||||
pane) inserts must be in FCIDM_SHVIEWFIRST/LAST (otherwise, the explorer
|
||||
won't dispatch them). The view should not deal with any menuitems
|
||||
in FCIDM_BROWSERFIRST/LAST (otherwise, it won't work with the future
|
||||
version of the shell).
|
||||
|
||||
FCIDM_SHVIEWFIRST/LAST for the right pane (IShellView)
|
||||
FCIDM_BROWSERFIRST/LAST for the explorer frame (IShellBrowser)
|
||||
FCIDM_GLOBAL/LAST for the explorer's submenu IDs
|
||||
*/
|
||||
#define FCIDM_SHVIEWFIRST 0x0000
|
||||
/* undocumented */
|
||||
#define FCIDM_SHVIEW_ARRANGE 0x7001
|
||||
#define FCIDM_SHVIEW_DELETE 0x7011
|
||||
#define FCIDM_SHVIEW_PROPERTIES 0x7013
|
||||
#define FCIDM_SHVIEW_CUT 0x7018
|
||||
#define FCIDM_SHVIEW_COPY 0x7019
|
||||
#define FCIDM_SHVIEW_INSERT 0x701A
|
||||
#define FCIDM_SHVIEW_UNDO 0x701B
|
||||
#define FCIDM_SHVIEW_INSERTLINK 0x701C
|
||||
#define FCIDM_SHVIEW_SELECTALL 0x7021
|
||||
#define FCIDM_SHVIEW_INVERTSELECTION 0x7022
|
||||
#define FCIDM_SHVIEW_BIGICON 0x7029
|
||||
#define FCIDM_SHVIEW_SMALLICON 0x702A
|
||||
#define FCIDM_SHVIEW_LISTVIEW 0x702B
|
||||
#define FCIDM_SHVIEW_REPORTVIEW 0x702C
|
||||
#define FCIDM_SHVIEW_AUTOARRANGE 0x7031
|
||||
#define FCIDM_SHVIEW_SNAPTOGRID 0x7032
|
||||
#define FCIDM_SHVIEW_HELP 0x7041
|
||||
|
||||
#define FCIDM_SHVIEWLAST 0x7fff
|
||||
#define FCIDM_BROWSERFIRST 0xA000
|
||||
/* undocumented toolbar items from stddlg's*/
|
||||
#define FCIDM_TB_SMALLICON 0xA003
|
||||
#define FCIDM_TB_REPORTVIEW 0xA004
|
||||
|
||||
#define FCIDM_BROWSERLAST 0xbf00
|
||||
#define FCIDM_GLOBALFIRST 0x8000
|
||||
#define FCIDM_GLOBALLAST 0x9fff
|
||||
|
||||
/*
|
||||
* Global submenu IDs and separator IDs
|
||||
*/
|
||||
#define FCIDM_MENU_FILE (FCIDM_GLOBALFIRST+0x0000)
|
||||
#define FCIDM_MENU_EDIT (FCIDM_GLOBALFIRST+0x0040)
|
||||
#define FCIDM_MENU_VIEW (FCIDM_GLOBALFIRST+0x0080)
|
||||
#define FCIDM_MENU_VIEW_SEP_OPTIONS (FCIDM_GLOBALFIRST+0x0081)
|
||||
#define FCIDM_MENU_TOOLS (FCIDM_GLOBALFIRST+0x00c0)
|
||||
#define FCIDM_MENU_TOOLS_SEP_GOTO (FCIDM_GLOBALFIRST+0x00c1)
|
||||
#define FCIDM_MENU_HELP (FCIDM_GLOBALFIRST+0x0100)
|
||||
#define FCIDM_MENU_FIND (FCIDM_GLOBALFIRST+0x0140)
|
||||
#define FCIDM_MENU_EXPLORE (FCIDM_GLOBALFIRST+0x0150)
|
||||
#define FCIDM_MENU_FAVORITES (FCIDM_GLOBALFIRST+0x0170)
|
||||
|
||||
/* control IDs known to the view */
|
||||
#define FCIDM_TOOLBAR (FCIDM_BROWSERFIRST + 0)
|
||||
#define FCIDM_STATUS (FCIDM_BROWSERFIRST + 1)
|
||||
|
||||
/* uState values for IShellView::UIActivate */
|
||||
typedef enum
|
||||
{ SVUIA_DEACTIVATE = 0,
|
||||
SVUIA_ACTIVATE_NOFOCUS = 1,
|
||||
SVUIA_ACTIVATE_FOCUS = 2,
|
||||
SVUIA_INPLACEACTIVATE = 3 /* new flag for IShellView2 */
|
||||
} SVUIA_STATUS;
|
||||
|
||||
|
||||
|
||||
typedef struct IShellView_VTable
|
||||
{ /* *** IUnknown methods *** */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* *** IOleWindow methods *** */
|
||||
STDMETHOD(GetWindow) (THIS_ HWND * lphwnd) PURE;
|
||||
STDMETHOD(ContextSensitiveHelp) (THIS_ BOOL fEnterMode) PURE;
|
||||
|
||||
/* *** IShellView methods *** */
|
||||
STDMETHOD(TranslateAccelerator) (THIS_ LPMSG lpmsg) PURE;
|
||||
STDMETHOD(EnableModeless) (THIS_ BOOL fEnable) PURE;
|
||||
STDMETHOD(UIActivate) (THIS_ UINT uState) PURE;
|
||||
STDMETHOD(Refresh) (THIS) PURE;
|
||||
STDMETHOD(CreateViewWindow)(THIS_ IShellView *lpPrevView,LPCFOLDERSETTINGS lpfs, IShellBrowser * psb,RECT * prcView, HWND *phWnd) PURE;
|
||||
STDMETHOD(DestroyViewWindow)(THIS) PURE;
|
||||
STDMETHOD(GetCurrentInfo)(THIS_ LPFOLDERSETTINGS lpfs) PURE;
|
||||
STDMETHOD(AddPropertySheetPages)(THIS_ DWORD dwReserved,LPFNADDPROPSHEETPAGE lpfn, LPARAM lparam) PURE;
|
||||
STDMETHOD(SaveViewState)(THIS) PURE;
|
||||
STDMETHOD(SelectItem)(THIS_ LPCITEMIDLIST pidlItem, UINT uFlags) PURE;
|
||||
STDMETHOD(GetItemObject)(THIS_ UINT uItem, REFIID riid,LPVOID *ppv) PURE;
|
||||
} IShellView_VTable,*LPSHELLVIEW_VTABLE;
|
||||
|
||||
struct tagSHELLVIEW
|
||||
{ LPSHELLVIEW_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
LPITEMIDLIST mpidl;
|
||||
LPSHELLFOLDER pSFParent;
|
||||
LPSHELLBROWSER pShellBrowser;
|
||||
LPCOMMDLGBROWSER pCommDlgBrowser;
|
||||
HWND hWnd;
|
||||
HWND hWndList;
|
||||
HWND hWndParent;
|
||||
FOLDERSETTINGS FolderSettings;
|
||||
HMENU hMenu;
|
||||
UINT uState;
|
||||
UINT uSelected;
|
||||
LPITEMIDLIST *aSelectedItems;
|
||||
};
|
||||
|
||||
typedef GUID SHELLVIEWID;
|
||||
#define SV_CLASS_NAME ("SHELLDLL_DefView")
|
||||
|
||||
#undef THIS
|
||||
/****************************************************************************
|
||||
* ICommDlgBrowser interface
|
||||
*/
|
||||
#define THIS LPCOMMDLGBROWSER me
|
||||
|
||||
/* for OnStateChange*/
|
||||
#define CDBOSC_SETFOCUS 0x00000000
|
||||
#define CDBOSC_KILLFOCUS 0x00000001
|
||||
#define CDBOSC_SELCHANGE 0x00000002
|
||||
#define CDBOSC_RENAME 0x00000003
|
||||
|
||||
typedef struct ICommDlgBrowser_VTable
|
||||
{ /* IUnknown methods */
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/* ICommDlgBrowser methods */
|
||||
STDMETHOD(OnDefaultCommand) (THIS_ LPSHELLVIEW ppshv) PURE;
|
||||
STDMETHOD(OnStateChange) (THIS_ LPSHELLVIEW ppshv, ULONG uChange) PURE;
|
||||
STDMETHOD(IncludeObject) (THIS_ LPSHELLVIEW ppshv, LPCITEMIDLIST pidl) PURE;
|
||||
} ICommDlgBrowser_VTable,*LPCOMMDLGBROWSER_VTABLE;
|
||||
|
||||
struct tagCOMMDLGBROWSER
|
||||
{ LPCOMMDLGBROWSER_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
};
|
||||
#undef THIS
|
||||
|
||||
/****************************************************************************
|
||||
* IExtractIconinterface
|
||||
*
|
||||
* FIXME
|
||||
* Is the ExtractIconA interface
|
||||
*/
|
||||
#define THIS LPEXTRACTICON me
|
||||
|
||||
/* GetIconLocation() input flags*/
|
||||
#define GIL_OPENICON 0x0001 /* allows containers to specify an "open" look */
|
||||
#define GIL_FORSHELL 0x0002 /* icon is to be displayed in a ShellFolder */
|
||||
#define GIL_ASYNC 0x0020 /* this is an async extract, return E_ASYNC */
|
||||
|
||||
/* GetIconLocation() return flags */
|
||||
#define GIL_SIMULATEDOC 0x0001 /* simulate this document icon for this */
|
||||
#define GIL_PERINSTANCE 0x0002 /* icons from this class are per instance (each file has its own) */
|
||||
#define GIL_PERCLASS 0x0004 /* icons from this class per class (shared for all files of this type) */
|
||||
#define GIL_NOTFILENAME 0x0008 /* location is not a filename, must call ::ExtractIcon */
|
||||
#define GIL_DONTCACHE 0x0010 /* this icon should not be cached */
|
||||
|
||||
typedef struct IExtractIcon IExtractIcon,*LPEXTRACTICON;
|
||||
typedef struct IExtractIcon_VTable
|
||||
{ /*** IUnknown methods ***/
|
||||
STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/*** IExtractIcon methods ***/
|
||||
STDMETHOD(GetIconLocation)(THIS_ UINT uFlags, LPSTR szIconFile, UINT cchMax,INT * piIndex, UINT * pwFlags) PURE;
|
||||
STDMETHOD(Extract)(THIS_ LPCSTR pszFile, UINT nIconIndex, HICON *phiconLarge, HICON *phiconSmall, UINT nIconSize) PURE;
|
||||
}IExtractIcon_VTable,*LPEXTRACTICON_VTABLE;
|
||||
|
||||
struct IExtractIcon
|
||||
{ LPEXTRACTICON_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
LPITEMIDLIST pidl;
|
||||
};
|
||||
|
||||
#undef THIS
|
||||
|
||||
DWORD WINAPI SHMapPIDLToSystemImageListIndex(LPSHELLFOLDER sh,LPITEMIDLIST pidl,DWORD z);
|
||||
|
||||
/****************************************************************************
|
||||
@ -599,36 +136,7 @@ struct tagSHELLICON
|
||||
DWORD ref;
|
||||
};
|
||||
#undef THIS
|
||||
/****************************************************************************
|
||||
* IDockingWindowFrame interface
|
||||
*/
|
||||
#define THIS LPDOCKINGWINDOWFRAME me
|
||||
|
||||
#define DWFRF_NORMAL 0x0000 /* femove toolbar flags*/
|
||||
#define DWFRF_DELETECONFIGDATA 0x0001
|
||||
#define DWFAF_HIDDEN 0x0001 /* add tolbar*/
|
||||
|
||||
typedef struct IDockingWindowFrame_VTable
|
||||
{ STDMETHOD(QueryInterface) (THIS_ REFIID riid, LPVOID * ppvObj) PURE;
|
||||
STDMETHOD_(ULONG,AddRef) (THIS) PURE;
|
||||
STDMETHOD_(ULONG,Release) (THIS) PURE;
|
||||
|
||||
/*** IOleWindow methods ***/
|
||||
STDMETHOD(GetWindow) (THIS_ HWND * lphwnd) PURE;
|
||||
STDMETHOD(ContextSensitiveHelp) (THIS_ BOOL fEnterMode) PURE;
|
||||
|
||||
/*** IDockingWindowFrame methods ***/
|
||||
STDMETHOD(AddToolbar) (THIS_ IUnknown* punkSrc, LPCWSTR pwszItem, DWORD dwAddFlags) PURE;
|
||||
STDMETHOD(RemoveToolbar) (THIS_ IUnknown* punkSrc, DWORD dwRemoveFlags) PURE;
|
||||
STDMETHOD(FindToolbar) (THIS_ LPCWSTR pwszItem, REFIID riid, LPVOID* ppvObj) PURE;
|
||||
} IDockingWindowFrame_VTable, *LPDOCKINGWINDOWFRAME_VTABLE;
|
||||
|
||||
struct tagDOCKINGWINDOWFRAME
|
||||
{ LPDOCKINGWINDOWFRAME_VTABLE lpvtbl;
|
||||
DWORD ref;
|
||||
};
|
||||
|
||||
#undef THIS
|
||||
/****************************************************************************
|
||||
* Shell Execute API
|
||||
*/
|
||||
|
@ -853,6 +853,12 @@ HRESULT WINAPI CoRegisterClassObject(REFCLSID rclsid,LPUNKNOWN pUnk,DWORD dwClsC
|
||||
|
||||
HRESULT WINAPI CoRevokeClassObject(DWORD dwRegister);
|
||||
|
||||
/*****************************************************************************
|
||||
* COM Server dll - exports
|
||||
*/
|
||||
HRESULT WINAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID * ppv);
|
||||
HRESULT WINAPI DllCanUnloadNow(void);
|
||||
|
||||
/*****************************************************************************
|
||||
* Internal WINE API
|
||||
*/
|
||||
|
44
include/wine/obj_commdlgbrowser.h
Normal file
44
include/wine/obj_commdlgbrowser.h
Normal file
@ -0,0 +1,44 @@
|
||||
/************************************************************
|
||||
* ICommDlgBrowser
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_ICOMMDLGBROWSER_H
|
||||
#define __WINE_WINE_OBJ_ICOMMDLGBROWSER_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_shellview.h"
|
||||
|
||||
DEFINE_SHLGUID(IID_ICommDlgBrowser, 0x000214F1L, 0, 0);
|
||||
typedef struct ICommDlgBrowser ICommDlgBrowser, *LPCOMMDLGBROWSER;
|
||||
|
||||
/* for OnStateChange*/
|
||||
#define CDBOSC_SETFOCUS 0x00000000
|
||||
#define CDBOSC_KILLFOCUS 0x00000001
|
||||
#define CDBOSC_SELCHANGE 0x00000002
|
||||
#define CDBOSC_RENAME 0x00000003
|
||||
|
||||
|
||||
#define ICOM_INTERFACE ICommDlgBrowser
|
||||
#define ICommDlgBrowser_METHODS \
|
||||
ICOM_METHOD1(HRESULT, OnDefaultCommand, IShellView*, IShellView) \
|
||||
ICOM_METHOD2(HRESULT, OnStateChange, IShellView*, IShellView, ULONG, uChange) \
|
||||
ICOM_METHOD2(HRESULT, IncludeObject, IShellView*, IShellView, LPCITEMIDLIST, pidl)
|
||||
#define ICommDlgBrowser_IMETHODS \
|
||||
IUnknown_IMETHODS \
|
||||
ICommDlgBrowser_METHODS
|
||||
ICOM_DEFINE(ICommDlgBrowser,IUnknown)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define ICommDlgBrowser_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define ICommDlgBrowser_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define ICommDlgBrowser_Release(p) ICOM_CALL(Release,p)
|
||||
#define ICommDlgBrowser_OnDefaultCommand(p,a) ICOM_CALL1(OnDefaultCommand,p,a)
|
||||
#define ICommDlgBrowser_OnStateChange(p,a,b) ICOM_CALL2(OnStateChange,p,a,b)
|
||||
#define ICommDlgBrowser_IncludeObject(p,a,b) ICOM_CALL2(IncludeObject,p,a,b)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_ICOMMDLGBROWSER_H */
|
128
include/wine/obj_contextmenu.h
Normal file
128
include/wine/obj_contextmenu.h
Normal file
@ -0,0 +1,128 @@
|
||||
/************************************************************
|
||||
* IContextMenu
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_ICONTEXTMENU_H
|
||||
#define __WINE_WINE_OBJ_ICONTEXTMENU_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
|
||||
DEFINE_SHLGUID(IID_IContextMenu, 0x000214E4L, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IContextMenu2, 0x000214F4L, 0, 0);
|
||||
typedef struct IContextMenu IContextMenu, *LPCONTEXTMENU;
|
||||
|
||||
/* default menu items*/
|
||||
#define IDM_EXPLORE 0
|
||||
#define IDM_OPEN 1
|
||||
#define IDM_RENAME 2
|
||||
#define IDM_LAST IDM_RENAME
|
||||
|
||||
/* QueryContextMenu uFlags */
|
||||
#define CMF_NORMAL 0x00000000
|
||||
#define CMF_DEFAULTONLY 0x00000001
|
||||
#define CMF_VERBSONLY 0x00000002
|
||||
#define CMF_EXPLORE 0x00000004
|
||||
#define CMF_NOVERBS 0x00000008
|
||||
#define CMF_CANRENAME 0x00000010
|
||||
#define CMF_NODEFAULT 0x00000020
|
||||
#define CMF_INCLUDESTATIC 0x00000040
|
||||
#define CMF_RESERVED 0xffff0000 /* View specific */
|
||||
|
||||
/* GetCommandString uFlags */
|
||||
#define GCS_VERBA 0x00000000 /* canonical verb */
|
||||
#define GCS_HELPTEXTA 0x00000001 /* help text (for status bar) */
|
||||
#define GCS_VALIDATEA 0x00000002 /* validate command exists */
|
||||
#define GCS_VERBW 0x00000004 /* canonical verb (unicode) */
|
||||
#define GCS_HELPTEXTW 0x00000005 /* help text (unicode version) */
|
||||
#define GCS_VALIDATEW 0x00000006 /* validate command exists (unicode) */
|
||||
#define GCS_UNICODE 0x00000004 /* for bit testing - Unicode string */
|
||||
|
||||
#define GCS_VERB GCS_VERBA
|
||||
#define GCS_HELPTEXT GCS_HELPTEXTA
|
||||
#define GCS_VALIDATE GCS_VALIDATEA
|
||||
|
||||
#define CMDSTR_NEWFOLDERA "NewFolder"
|
||||
#define CMDSTR_VIEWLISTA "ViewList"
|
||||
#define CMDSTR_VIEWDETAILSA "ViewDetails"
|
||||
#define CMDSTR_NEWFOLDERW L"NewFolder"
|
||||
#define CMDSTR_VIEWLISTW L"ViewList"
|
||||
#define CMDSTR_VIEWDETAILSW L"ViewDetails"
|
||||
|
||||
#define CMDSTR_NEWFOLDER CMDSTR_NEWFOLDERA
|
||||
#define CMDSTR_VIEWLIST CMDSTR_VIEWLISTA
|
||||
#define CMDSTR_VIEWDETAILS CMDSTR_VIEWDETAILSA
|
||||
|
||||
#define CMIC_MASK_HOTKEY SEE_MASK_HOTKEY
|
||||
#define CMIC_MASK_ICON SEE_MASK_ICON
|
||||
#define CMIC_MASK_FLAG_NO_UI SEE_MASK_FLAG_NO_UI
|
||||
#define CMIC_MASK_UNICODE SEE_MASK_UNICODE
|
||||
#define CMIC_MASK_NO_CONSOLE SEE_MASK_NO_CONSOLE
|
||||
#define CMIC_MASK_HASLINKNAME SEE_MASK_HASLINKNAME
|
||||
#define CMIC_MASK_FLAG_SEP_VDM SEE_MASK_FLAG_SEPVDM
|
||||
#define CMIC_MASK_HASTITLE SEE_MASK_HASTITLE
|
||||
#define CMIC_MASK_ASYNCOK SEE_MASK_ASYNCOK
|
||||
|
||||
#define CMIC_MASK_PTINVOKE 0x20000000
|
||||
|
||||
/*NOTE: When SEE_MASK_HMONITOR is set, hIcon is treated as hMonitor */
|
||||
typedef struct tagCMINVOKECOMMANDINFO
|
||||
{ DWORD cbSize; /* sizeof(CMINVOKECOMMANDINFO) */
|
||||
DWORD fMask; /* any combination of CMIC_MASK_* */
|
||||
HWND hwnd; /* might be NULL (indicating no owner window) */
|
||||
LPCSTR lpVerb; /* either a string or MAKEINTRESOURCE(idOffset) */
|
||||
LPCSTR lpParameters; /* might be NULL (indicating no parameter) */
|
||||
LPCSTR lpDirectory; /* might be NULL (indicating no specific directory) */
|
||||
INT nShow; /* one of SW_ values for ShowWindow() API */
|
||||
|
||||
DWORD dwHotKey;
|
||||
HANDLE hIcon;
|
||||
} CMINVOKECOMMANDINFO, *LPCMINVOKECOMMANDINFO;
|
||||
|
||||
typedef struct tagCMInvokeCommandInfoEx
|
||||
{ DWORD cbSize; /* must be sizeof(CMINVOKECOMMANDINFOEX) */
|
||||
DWORD fMask; /* any combination of CMIC_MASK_* */
|
||||
HWND hwnd; /* might be NULL (indicating no owner window) */
|
||||
LPCSTR lpVerb; /* either a string or MAKEINTRESOURCE(idOffset) */
|
||||
LPCSTR lpParameters; /* might be NULL (indicating no parameter) */
|
||||
LPCSTR lpDirectory; /* might be NULL (indicating no specific directory) */
|
||||
INT nShow; /* one of SW_ values for ShowWindow() API */
|
||||
|
||||
DWORD dwHotKey;
|
||||
|
||||
HANDLE hIcon;
|
||||
LPCSTR lpTitle; /* For CreateProcess-StartupInfo.lpTitle */
|
||||
LPCWSTR lpVerbW; /* Unicode verb (for those who can use it) */
|
||||
LPCWSTR lpParametersW; /* Unicode parameters (for those who can use it) */
|
||||
LPCWSTR lpDirectoryW; /* Unicode directory (for those who can use it) */
|
||||
LPCWSTR lpTitleW; /* Unicode title (for those who can use it) */
|
||||
POINT ptInvoke; /* Point where it's invoked */
|
||||
|
||||
} CMINVOKECOMMANDINFOEX, *LPCMINVOKECOMMANDINFOEX;
|
||||
|
||||
#define ICOM_INTERFACE IContextMenu
|
||||
#define IContextMenu_METHODS \
|
||||
ICOM_METHOD5(HRESULT, QueryContextMenu, HMENU, hmenu, UINT, indexMenu, UINT, idCmdFirst, UINT, idCmdLast, UINT, uFlags) \
|
||||
ICOM_METHOD1(HRESULT, InvokeCommand, LPCMINVOKECOMMANDINFO, lpici) \
|
||||
ICOM_METHOD5(HRESULT, GetCommandString, UINT, idCmd, UINT, uType, UINT*, pwReserved, LPSTR, pszName, UINT, cchMax) \
|
||||
ICOM_METHOD3(HRESULT, HandleMenuMsg, UINT, uMsg, WPARAM, wParam, LPARAM, lParam) \
|
||||
void * guard; /*possibly another nasty entry from ContextMenu3 ?*/
|
||||
#define IContextMenu_IMETHODS \
|
||||
IUnknown_IMETHODS \
|
||||
IContextMenu_METHODS
|
||||
ICOM_DEFINE(IContextMenu,IUnknown)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IContextMenu_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IContextMenu_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IContextMenu_Release(p) ICOM_CALL(Release,p)
|
||||
#define IContextMenu_QueryContextMenu(p,a,b,c,d,e) ICOM_CALL5(QueryContextMenu,p,a,b,c,d,e)
|
||||
#define IContextMenu_InvokeCommand(p,a) ICOM_CALL1(InvokeCommand,p,a)
|
||||
#define IContextMenu_GetCommandString(p,a,b,c,d,e) ICOM_CALL5(GetCommandString,p,a,b,c,d,e)
|
||||
#define IContextMenu_HandleMenuMsg(p,a,b,c) ICOM_CALL3(HandleMenuMsg,p,a,b,c)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_ICONTEXTMENU_H */
|
43
include/wine/obj_dockingwindowframe.h
Normal file
43
include/wine/obj_dockingwindowframe.h
Normal file
@ -0,0 +1,43 @@
|
||||
/************************************************************
|
||||
* IDockingWindowFrame
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_IDOCKINGWINDOWFRAME_H
|
||||
#define __WINE_WINE_OBJ_IDOCKINGWINDOWFRAME_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_inplace.h"
|
||||
|
||||
typedef struct IDockingWindowFrame IDockingWindowFrame, *LPDOCKINGWINDOWFRAME;
|
||||
DEFINE_GUID (IID_IDockingWindowFrame, 0x47D2657AL, 0x7B27, 0x11D0, 0x8C, 0xA9, 0x00, 0xA0, 0xC9, 0x2D, 0xBF, 0xE8);
|
||||
|
||||
#define DWFRF_NORMAL 0x0000 /* femove toolbar flags*/
|
||||
#define DWFRF_DELETECONFIGDATA 0x0001
|
||||
#define DWFAF_HIDDEN 0x0001 /* add tolbar*/
|
||||
|
||||
#define ICOM_INTERFACE IDockingWindowFrame
|
||||
#define IDockingWindowFrame_METHODS \
|
||||
ICOM_METHOD3(HRESULT, AddToolbar, IUnknown*, punkSrc, LPCWSTR, pwszItem, DWORD, dwAddFlags) \
|
||||
ICOM_METHOD2(HRESULT, RemoveToolbar, IUnknown*, punkSrc, DWORD, dwRemoveFlags) \
|
||||
ICOM_METHOD3(HRESULT, FindToolbar, LPCWSTR, pwszItem, REFIID, riid, LPVOID*, ppvObj)
|
||||
#define IDockingWindowFrame_IMETHODS \
|
||||
IOleWindow_IMETHODS \
|
||||
IDockingWindowFrame_METHODS
|
||||
ICOM_DEFINE(IDockingWindowFrame,IOleWindow)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IDockingWindowFrame_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IDockingWindowFrame_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IDockingWindowFrame_Release(p) ICOM_CALL(Release,p)
|
||||
#define IDockingWindowFrame_GetWindow(p,a) ICOM_CALL1(GetWindow,p,a)
|
||||
#define IDockingWindowFrame_ContextSensitiveHelp(p,a) ICOM_CALL1(ContextSensitiveHelp,p,a)
|
||||
#define IDockingWindowFrame_AddToolbar(p,a,b,c) ICOM_CALL3(AddToolbar,p,a,b,c)
|
||||
#define IDockingWindowFrame_RemoveToolbar(p,a,b) ICOM_CALL2(RemoveToolbar,p,a,b)
|
||||
#define IDockingWindowFrame_FindToolbar(p,a,b,c) ICOM_CALL3(FindToolbar,p,a,b,c)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_IDOCKINGWINDOWFRAME_H */
|
49
include/wine/obj_extracticon.h
Normal file
49
include/wine/obj_extracticon.h
Normal file
@ -0,0 +1,49 @@
|
||||
/************************************************************
|
||||
* IExtractIconA
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_IEXTRACTICONA_H
|
||||
#define __WINE_WINE_OBJ_IEXTRACTICONA_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
|
||||
DEFINE_SHLGUID(IID_IExtractIconA, 0x000214EBL, 0, 0);
|
||||
DEFINE_SHLGUID(IID_IExtractIconW, 0x000214FAL, 0, 0);
|
||||
typedef struct IExtractIconA IExtractIconA,*LPEXTRACTICONA;
|
||||
|
||||
/* GetIconLocation() input flags*/
|
||||
#define GIL_OPENICON 0x0001 /* allows containers to specify an "open" look */
|
||||
#define GIL_FORSHELL 0x0002 /* icon is to be displayed in a ShellFolder */
|
||||
#define GIL_ASYNC 0x0020 /* this is an async extract, return E_ASYNC */
|
||||
|
||||
/* GetIconLocation() return flags */
|
||||
#define GIL_SIMULATEDOC 0x0001 /* simulate this document icon for this */
|
||||
#define GIL_PERINSTANCE 0x0002 /* icons from this class are per instance (each file has its own) */
|
||||
#define GIL_PERCLASS 0x0004 /* icons from this class per class (shared for all files of this type) */
|
||||
#define GIL_NOTFILENAME 0x0008 /* location is not a filename, must call ::ExtractIcon */
|
||||
#define GIL_DONTCACHE 0x0010 /* this icon should not be cached */
|
||||
|
||||
|
||||
#define ICOM_INTERFACE IExtractIconA
|
||||
#define IExtractIconA_METHODS \
|
||||
ICOM_METHOD5(HRESULT, GetIconLocation, UINT, uFlags, LPSTR, szIconFile, UINT, cchMax, INT*, piIndex, UINT *, pwFlags) \
|
||||
ICOM_METHOD5(HRESULT, Extract, LPCSTR, pszFile, UINT, nIconIndex, HICON*, phiconLarge, HICON*, phiconSmall, UINT, nIconSize)
|
||||
#define IExtractIconA_IMETHODS \
|
||||
IUnknown_IMETHODS \
|
||||
IExtractIconA_METHODS
|
||||
ICOM_DEFINE(IExtractIconA,IUnknown)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IExtractIconA_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IExtractIconA_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IExtractIconA_Release(p) ICOM_CALL(Release,p)
|
||||
#define IExtractIconA_GetIconLocation(p,a,b,c,d,e) ICOM_CALL5(GetIconLocation,p,a,b,c,d,e)
|
||||
#define IExtractIconA_Extract(p,a,b,c,d,e) ICOM_CALL5(Extract,p,a,b,c,d,e)
|
||||
#endif
|
||||
|
||||
#define IExtractIcon IExtractIconA
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_IEXTRACTICONA_H */
|
106
include/wine/obj_shellbrowser.h
Normal file
106
include/wine/obj_shellbrowser.h
Normal file
@ -0,0 +1,106 @@
|
||||
/************************************************************
|
||||
* IShellBrowser
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_ISHELLBROWSER_H
|
||||
#define __WINE_WINE_OBJ_ISHELLBROWSER_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_inplace.h" /* IOleWindow */
|
||||
#include "wine/obj_shellview.h" /* IShellView */
|
||||
#include "commctrl.h" /* TBBUTTON */
|
||||
|
||||
/* it's ok commented out, see obj_shellview.h
|
||||
typedef struct IShellBrowser IShellBrowser, *LPSHELLBROWSER;
|
||||
*/
|
||||
|
||||
DEFINE_SHLGUID(IID_IShellBrowser, 0x000214E2L, 0, 0);
|
||||
#define SID_SShellBrowser IID_IShellBrowser
|
||||
|
||||
/* targets for GetWindow/SendControlMsg */
|
||||
#define FCW_STATUS 0x0001
|
||||
#define FCW_TOOLBAR 0x0002
|
||||
#define FCW_TREE 0x0003
|
||||
#define FCW_INTERNETBAR 0x0006
|
||||
#define FCW_PROGRESS 0x0008
|
||||
|
||||
/* wFlags for BrowseObject*/
|
||||
#define SBSP_DEFBROWSER 0x0000
|
||||
#define SBSP_SAMEBROWSER 0x0001
|
||||
#define SBSP_NEWBROWSER 0x0002
|
||||
|
||||
#define SBSP_DEFMODE 0x0000
|
||||
#define SBSP_OPENMODE 0x0010
|
||||
#define SBSP_EXPLOREMODE 0x0020
|
||||
|
||||
#define SBSP_ABSOLUTE 0x0000
|
||||
#define SBSP_RELATIVE 0x1000
|
||||
#define SBSP_PARENT 0x2000
|
||||
#define SBSP_NAVIGATEBACK 0x4000
|
||||
#define SBSP_NAVIGATEFORWARD 0x8000
|
||||
|
||||
#define SBSP_ALLOW_AUTONAVIGATE 0x10000
|
||||
|
||||
#define SBSP_INITIATEDBYHLINKFRAME 0x80000000
|
||||
#define SBSP_REDIRECT 0x40000000
|
||||
#define SBSP_WRITENOHISTORY 0x08000000
|
||||
|
||||
/* uFlage for SetToolbarItems */
|
||||
#define FCT_MERGE 0x0001
|
||||
#define FCT_CONFIGABLE 0x0002
|
||||
#define FCT_ADDTOEND 0x0004
|
||||
|
||||
/* undocumented, found in the web posted by Chris Becke */
|
||||
#define CWM_SETPATH (WM_USER+2)
|
||||
#define CWM_WANTIDLE (WM_USER+3)
|
||||
#define CWM_GETSETCURRENTINFO (WM_USER+4)
|
||||
#define CWM_SELECTITEM (WM_USER+5)
|
||||
#define CWM_STOPWAITING (WM_USER+6)
|
||||
#define CWM_GETISHELLBROWSER (WM_USER+7)
|
||||
|
||||
#define ICOM_INTERFACE IShellBrowser
|
||||
#define IShellBrowser_METHODS \
|
||||
ICOM_METHOD2(HRESULT, InsertMenusSB, HMENU, hmenuShared, LPOLEMENUGROUPWIDTHS, lpMenuWidths) \
|
||||
ICOM_METHOD3(HRESULT, SetMenuSB, HMENU, hmenuShared, HOLEMENU, holemenuReserved, HWND, hwndActiveObject) \
|
||||
ICOM_METHOD1(HRESULT, RemoveMenusSB, HMENU, hmenuShared) \
|
||||
ICOM_METHOD1(HRESULT, SetStatusTextSB, LPCOLESTR, lpszStatusText) \
|
||||
ICOM_METHOD1(HRESULT, EnableModelessSB, BOOL, fEnable) \
|
||||
ICOM_METHOD2(HRESULT, TranslateAcceleratorSB, LPMSG, lpmsg, WORD, wID) \
|
||||
ICOM_METHOD2(HRESULT, BrowseObject, LPCITEMIDLIST, pidl, UINT, wFlags) \
|
||||
ICOM_METHOD2(HRESULT, GetViewStateStream, DWORD, grfMode, LPSTREAM*, ppStrm) \
|
||||
ICOM_METHOD2(HRESULT, GetControlWindow, UINT, id, HWND*, lphwnd) \
|
||||
ICOM_METHOD5(HRESULT, SendControlMsg, UINT, id, UINT, uMsg, WPARAM, wParam, LPARAM, lParam, LRESULT*, pret) \
|
||||
ICOM_METHOD1(HRESULT, QueryActiveShellView, IShellView**, IShellView) \
|
||||
ICOM_METHOD1(HRESULT, OnViewWindowActive, IShellView*, IShellView) \
|
||||
ICOM_METHOD3(HRESULT, SetToolbarItems, LPTBBUTTON, lpButtons, UINT, nButtons, UINT, uFlags)
|
||||
#define IShellBrowser_IMETHODS \
|
||||
IOleWindow_IMETHODS \
|
||||
IShellBrowser_METHODS
|
||||
ICOM_DEFINE(IShellBrowser,IOleWindow)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IShellBrowser_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IShellBrowser_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IShellBrowser_Release(p) ICOM_CALL(Release,p)
|
||||
#define IShellBrowser_GetWindow(p,a) ICOM_CALL1(GetWindow,p,a)
|
||||
#define IShellBrowser_ContextSensitiveHelp(p,a) ICOM_CALL1(ContextSensitiveHelp,p,a)
|
||||
#define IShellBrowser_InsertMenusSB(p,a,b) ICOM_CALL2(InsertMenusSB,p,a,b)
|
||||
#define IShellBrowser_SetMenuSB(p,a,b,c) ICOM_CALL3(SetMenuSB,p,a,b,c)
|
||||
#define IShellBrowser_RemoveMenusSB(p,a) ICOM_CALL1(RemoveMenusSB,p,a)
|
||||
#define IShellBrowser_SetStatusTextSB(p,a) ICOM_CALL1(SetStatusTextSB,p,a)
|
||||
#define IShellBrowser_EnableModelessSB(p,a) ICOM_CALL1(EnableModelessSB,p,a)
|
||||
#define IShellBrowser_TranslateAcceleratorSB(p,a,b) ICOM_CALL2(TranslateAcceleratorSB,p,a,b)
|
||||
#define IShellBrowser_BrowseObject(p,a,b) ICOM_CALL2(BrowseObject,p,a,b)
|
||||
#define IShellBrowser_GetViewStateStream(p,a,b) ICOM_CALL2(GetViewStateStream,p,a,b)
|
||||
#define IShellBrowser_GetControlWindow(p,a,b) ICOM_CALL2(GetControlWindow,p,a,b)
|
||||
#define IShellBrowser_SendControlMsg(p,a,b,c,d,e) ICOM_CALL5(SendControlMsg,p,a,b,c,d,e)
|
||||
#define IShellBrowser_QueryActiveShellView(p,a) ICOM_CALL1(QueryActiveShellView,p,a)
|
||||
#define IShellBrowser_OnViewWindowActive(p,a) ICOM_CALL1(OnViewWindowActive,p,a)
|
||||
#define IShellBrowser_SetToolbarItems(p,a,b,c) ICOM_CALL3(SetToolbarItems,p,a,b,c)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_ISHELLBROWSER_H */
|
33
include/wine/obj_shellextinit.h
Normal file
33
include/wine/obj_shellextinit.h
Normal file
@ -0,0 +1,33 @@
|
||||
/************************************************************
|
||||
* IShellExtInit
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_ISHELLEXTINIT_H
|
||||
#define __WINE_WINE_OBJ_ISHELLEXTINIT_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_dataobject.h"
|
||||
|
||||
typedef struct IShellExtInit IShellExtInit, *LPSHELLEXTINIT;
|
||||
DEFINE_SHLGUID(IID_IShellExtInit, 0x000214E8L, 0, 0);
|
||||
|
||||
#define ICOM_INTERFACE IShellExtInit
|
||||
#define IShellExtInit_METHODS \
|
||||
ICOM_METHOD3(HRESULT, Initialize, LPCITEMIDLIST, pidlFolder, LPDATAOBJECT, lpdobj, HKEY, hkeyProgID)
|
||||
#define IShellExtInit_IMETHODS \
|
||||
IUnknown_IMETHODS \
|
||||
IShellExtInit_METHODS
|
||||
ICOM_DEFINE(IShellExtInit,IUnknown)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IShellExtInit_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IShellExtInit_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IShellExtInit_Release(p) ICOM_CALL(Release,p)
|
||||
#define IShellExtInit_Initialize(p,a,b,c) ICOM_CALL3(Initialize,p,a,b,c)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_ISHELLEXTINIT_H */
|
@ -87,6 +87,45 @@ typedef enum tagSHCONTF
|
||||
#define SFGAO_VALIDATE 0x01000000L /* invalidate cached information */
|
||||
#define SFGAO_REMOVABLE 0x02000000L /* is this removeable media? */
|
||||
|
||||
/************************************************************************
|
||||
*
|
||||
* FOLDERSETTINGS
|
||||
*/
|
||||
|
||||
typedef LPBYTE LPVIEWSETTINGS;
|
||||
|
||||
/* NB Bitfields. */
|
||||
/* FWF_DESKTOP implies FWF_TRANSPARENT/NOCLIENTEDGE/NOSCROLL */
|
||||
typedef enum
|
||||
{ FWF_AUTOARRANGE = 0x0001,
|
||||
FWF_ABBREVIATEDNAMES = 0x0002,
|
||||
FWF_SNAPTOGRID = 0x0004,
|
||||
FWF_OWNERDATA = 0x0008,
|
||||
FWF_BESTFITWINDOW = 0x0010,
|
||||
FWF_DESKTOP = 0x0020,
|
||||
FWF_SINGLESEL = 0x0040,
|
||||
FWF_NOSUBFOLDERS = 0x0080,
|
||||
FWF_TRANSPARENT = 0x0100,
|
||||
FWF_NOCLIENTEDGE = 0x0200,
|
||||
FWF_NOSCROLL = 0x0400,
|
||||
FWF_ALIGNLEFT = 0x0800,
|
||||
FWF_SINGLECLICKACTIVATE=0x8000 /* TEMPORARY -- NO UI FOR THIS */
|
||||
} FOLDERFLAGS;
|
||||
|
||||
typedef enum
|
||||
{ FVM_ICON = 1,
|
||||
FVM_SMALLICON = 2,
|
||||
FVM_LIST = 3,
|
||||
FVM_DETAILS = 4
|
||||
} FOLDERVIEWMODE;
|
||||
|
||||
typedef struct
|
||||
{ UINT ViewMode; /* View mode (FOLDERVIEWMODE values) */
|
||||
UINT fFlags; /* View options (FOLDERFLAGS bits) */
|
||||
} FOLDERSETTINGS, *LPFOLDERSETTINGS;
|
||||
|
||||
typedef const FOLDERSETTINGS * LPCFOLDERSETTINGS;
|
||||
|
||||
/************************************************************************
|
||||
* Desktopfolder
|
||||
*/
|
||||
@ -133,7 +172,7 @@ ICOM_DEFINE(IShellFolder,IUnknown)
|
||||
#define IShellFolder_GetUIObjectOf(p,a,b,c,d,e,f) ICOM_CALL6(GetUIObjectOf,p,a,b,c,d,e,f)
|
||||
#define IShellFolder_GetDisplayNameOf(p,a,b,c) ICOM_CALL3(GetDisplayNameOf,p,a,b,c)
|
||||
#define IShellFolder_SetNameOf(p,a,b,c,d,e) ICOM_CALL5(SetNameOf,p,a,b,c,d,e)
|
||||
#define IShellFolder_GetFolderPath(p,a,b) ICOM_CALL2(GetDisplayNameOf,p,a,b)
|
||||
#define IShellFolder_GetFolderPath(p,a,b) ICOM_CALL2(GetFolderPath,p,a,b)
|
||||
#endif
|
||||
|
||||
/*****************************************************************************
|
||||
|
143
include/wine/obj_shellview.h
Normal file
143
include/wine/obj_shellview.h
Normal file
@ -0,0 +1,143 @@
|
||||
/************************************************************
|
||||
* IShellView
|
||||
*/
|
||||
|
||||
#ifndef __WINE_WINE_OBJ_ISHELLVIEW_H
|
||||
#define __WINE_WINE_OBJ_ISHELLVIEW_H
|
||||
|
||||
#include "winbase.h"
|
||||
#include "winuser.h"
|
||||
#include "wine/obj_base.h"
|
||||
#include "wine/obj_inplace.h"
|
||||
#include "wine/obj_shellfolder.h"
|
||||
#include "prsht.h" /* LPFNADDPROPSHEETPAGE */
|
||||
|
||||
/****************************************************************************
|
||||
* IShellBrowser is here defined because of a cyclic dependance between
|
||||
* IShellBrowser and IShellView
|
||||
*/
|
||||
typedef struct IShellBrowser IShellBrowser, *LPSHELLBROWSER;
|
||||
|
||||
DEFINE_SHLGUID(IID_IShellView, 0x000214E3L, 0, 0);
|
||||
typedef struct IShellView IShellView, *LPSHELLVIEW;
|
||||
|
||||
/* shellview select item flags*/
|
||||
#define SVSI_DESELECT 0x0000
|
||||
#define SVSI_SELECT 0x0001
|
||||
#define SVSI_EDIT 0x0003 /* includes select */
|
||||
#define SVSI_DESELECTOTHERS 0x0004
|
||||
#define SVSI_ENSUREVISIBLE 0x0008
|
||||
#define SVSI_FOCUSED 0x0010
|
||||
|
||||
/* shellview get item object flags */
|
||||
#define SVGIO_BACKGROUND 0x00000000
|
||||
#define SVGIO_SELECTION 0x00000001
|
||||
#define SVGIO_ALLVIEW 0x00000002
|
||||
|
||||
/* The explorer dispatches WM_COMMAND messages based on the range of
|
||||
command/menuitem IDs. All the IDs of menuitems that the view (right
|
||||
pane) inserts must be in FCIDM_SHVIEWFIRST/LAST (otherwise, the explorer
|
||||
won't dispatch them). The view should not deal with any menuitems
|
||||
in FCIDM_BROWSERFIRST/LAST (otherwise, it won't work with the future
|
||||
version of the shell).
|
||||
|
||||
FCIDM_SHVIEWFIRST/LAST for the right pane (IShellView)
|
||||
FCIDM_BROWSERFIRST/LAST for the explorer frame (IShellBrowser)
|
||||
FCIDM_GLOBAL/LAST for the explorer's submenu IDs
|
||||
*/
|
||||
#define FCIDM_SHVIEWFIRST 0x0000
|
||||
/* undocumented */
|
||||
#define FCIDM_SHVIEW_ARRANGE 0x7001
|
||||
#define FCIDM_SHVIEW_DELETE 0x7011
|
||||
#define FCIDM_SHVIEW_PROPERTIES 0x7013
|
||||
#define FCIDM_SHVIEW_CUT 0x7018
|
||||
#define FCIDM_SHVIEW_COPY 0x7019
|
||||
#define FCIDM_SHVIEW_INSERT 0x701A
|
||||
#define FCIDM_SHVIEW_UNDO 0x701B
|
||||
#define FCIDM_SHVIEW_INSERTLINK 0x701C
|
||||
#define FCIDM_SHVIEW_SELECTALL 0x7021
|
||||
#define FCIDM_SHVIEW_INVERTSELECTION 0x7022
|
||||
#define FCIDM_SHVIEW_BIGICON 0x7029
|
||||
#define FCIDM_SHVIEW_SMALLICON 0x702A
|
||||
#define FCIDM_SHVIEW_LISTVIEW 0x702B
|
||||
#define FCIDM_SHVIEW_REPORTVIEW 0x702C
|
||||
#define FCIDM_SHVIEW_AUTOARRANGE 0x7031
|
||||
#define FCIDM_SHVIEW_SNAPTOGRID 0x7032
|
||||
#define FCIDM_SHVIEW_HELP 0x7041
|
||||
|
||||
#define FCIDM_SHVIEWLAST 0x7fff
|
||||
#define FCIDM_BROWSERFIRST 0xA000
|
||||
/* undocumented toolbar items from stddlg's*/
|
||||
#define FCIDM_TB_SMALLICON 0xA003
|
||||
#define FCIDM_TB_REPORTVIEW 0xA004
|
||||
|
||||
#define FCIDM_BROWSERLAST 0xbf00
|
||||
#define FCIDM_GLOBALFIRST 0x8000
|
||||
#define FCIDM_GLOBALLAST 0x9fff
|
||||
|
||||
/*
|
||||
* Global submenu IDs and separator IDs
|
||||
*/
|
||||
#define FCIDM_MENU_FILE (FCIDM_GLOBALFIRST+0x0000)
|
||||
#define FCIDM_MENU_EDIT (FCIDM_GLOBALFIRST+0x0040)
|
||||
#define FCIDM_MENU_VIEW (FCIDM_GLOBALFIRST+0x0080)
|
||||
#define FCIDM_MENU_VIEW_SEP_OPTIONS (FCIDM_GLOBALFIRST+0x0081)
|
||||
#define FCIDM_MENU_TOOLS (FCIDM_GLOBALFIRST+0x00c0)
|
||||
#define FCIDM_MENU_TOOLS_SEP_GOTO (FCIDM_GLOBALFIRST+0x00c1)
|
||||
#define FCIDM_MENU_HELP (FCIDM_GLOBALFIRST+0x0100)
|
||||
#define FCIDM_MENU_FIND (FCIDM_GLOBALFIRST+0x0140)
|
||||
#define FCIDM_MENU_EXPLORE (FCIDM_GLOBALFIRST+0x0150)
|
||||
#define FCIDM_MENU_FAVORITES (FCIDM_GLOBALFIRST+0x0170)
|
||||
|
||||
/* control IDs known to the view */
|
||||
#define FCIDM_TOOLBAR (FCIDM_BROWSERFIRST + 0)
|
||||
#define FCIDM_STATUS (FCIDM_BROWSERFIRST + 1)
|
||||
|
||||
/* uState values for IShellView::UIActivate */
|
||||
typedef enum
|
||||
{ SVUIA_DEACTIVATE = 0,
|
||||
SVUIA_ACTIVATE_NOFOCUS = 1,
|
||||
SVUIA_ACTIVATE_FOCUS = 2,
|
||||
SVUIA_INPLACEACTIVATE = 3 /* new flag for IShellView2 */
|
||||
} SVUIA_STATUS;
|
||||
|
||||
#define ICOM_INTERFACE IShellView
|
||||
#define IShellView_METHODS \
|
||||
ICOM_METHOD1(HRESULT, TranslateAccelerator, LPMSG, lpmsg) \
|
||||
ICOM_METHOD1(HRESULT, EnableModeless, BOOL, fEnable) \
|
||||
ICOM_METHOD1(HRESULT, UIActivate, UINT, uState) \
|
||||
ICOM_METHOD(HRESULT, Refresh) \
|
||||
ICOM_METHOD5(HRESULT, CreateViewWindow, IShellView*, lpPrevView, LPCFOLDERSETTINGS, lpfs, IShellBrowser*, psb, RECT*, prcView, HWND*, phWnd) \
|
||||
ICOM_METHOD(HRESULT, DestroyViewWindow) \
|
||||
ICOM_METHOD1(HRESULT, GetCurrentInfo, LPFOLDERSETTINGS, lpfs) \
|
||||
ICOM_METHOD3(HRESULT, AddPropertySheetPages, DWORD, dwReserved, LPFNADDPROPSHEETPAGE, lpfn, LPARAM, lparam) \
|
||||
ICOM_METHOD (HRESULT, SaveViewState) \
|
||||
ICOM_METHOD2(HRESULT, SelectItem, LPCITEMIDLIST, pidlItem, UINT, uFlags) \
|
||||
ICOM_METHOD3(HRESULT, GetItemObject, UINT, uItem, REFIID, riid, LPVOID*, ppv)
|
||||
#define IShellView_IMETHODS \
|
||||
IOleWindow_IMETHODS \
|
||||
IShellView_METHODS
|
||||
ICOM_DEFINE(IShellView,IOleWindow)
|
||||
#undef ICOM_INTERFACE
|
||||
|
||||
#ifdef ICOM_CINTERFACE
|
||||
#define IShellView_QueryInterface(p,a,b) ICOM_CALL2(QueryInterface,p,a,b)
|
||||
#define IShellView_AddRef(p) ICOM_CALL(AddRef,p)
|
||||
#define IShellView_Release(p) ICOM_CALL(Release,p)
|
||||
#define IShellView_GetWindow(p,a) ICOM_CALL1(GetWindow,p,a)
|
||||
#define IShellView_ContextSensitiveHelp(p,a) ICOM_CALL1(ContextSensitiveHelp,p,a)
|
||||
#define IShellView_TranslateAccelerator(p,a) ICOM_CALL1(TranslateAccelerator,p,a)
|
||||
#define IShellView_EnableModeless(p,a) ICOM_CALL1(EnableModeless,p,a)
|
||||
#define IShellView_UIActivate(p,a) ICOM_CALL1(UIActivate,p,a)
|
||||
#define IShellView_Refresh(p) ICOM_CALL(Refresh,p)
|
||||
#define IShellView_CreateViewWindow(p,a,b,c,d,e) ICOM_CALL5(CreateViewWindow,p,a,b,c,d,e)
|
||||
#define IShellView_DestroyViewWindow(p) ICOM_CALL(DestroyViewWindow,p)
|
||||
#define IShellView_GetCurrentInfo(p,a) ICOM_CALL1(GetCurrentInfo,p,a)
|
||||
#define IShellView_AddPropertySheetPages(p,a,b,c) ICOM_CALL3(AddPropertySheetPages,p,a,b,c)
|
||||
#define IShellView_SaveViewState(p) ICOM_CALL(SaveViewState,p)
|
||||
#define IShellView_SelectItem(p,a,b) ICOM_CALL2(SelectItem,p,a,b)
|
||||
#define IShellView_GetItemObject(p,a,b,c) ICOM_CALL3(GetItemObject,p,a,b,c)
|
||||
#endif
|
||||
|
||||
|
||||
#endif /* __WINE_WINE_OBJ_ISHELLVIEW_H */
|
Loading…
Reference in New Issue
Block a user