21#define WIN32_NO_STATUS
31#include <wine/unicode.h>
39#define FM_SEPARATOR (LPCWSTR)1
42 HMENU hMenuPopup,
int nItemHeight);
70#define CCH_MAXITEMTEXT 256
89 ERR(
"menudata corrupt: %p %u\n", menudata,
MenuInfo.cbSize);
131 ULONG ulItemAttr = SFGAO_FOLDER;
132 UINT uID, uEnumFlags;
136 int NumberOfItems = 0, iIcon;
152 ERR(
"menudata corrupt: %p %u\n", menudata,
MenuInfo.cbSize);
159 pidl = (pAlternatePidl? pAlternatePidl: menudata->
pidl);
172 if (
SUCCEEDED(IShellFolder_BindToObject(lpsf, pidl,0,&IID_IShellFolder,(
LPVOID *)&lpsf2)))
176 if (
SUCCEEDED (IShellFolder_EnumObjects(lpsf2, 0, uEnumFlags, &lpe )))
182 while ((!
bAbortInit) && (
S_OK == IEnumIDList_Next(lpe,1,&pidlTemp,&ulFetched)))
189 if ( SFGAO_FOLDER & ulItemAttr)
198 lpFmMi->
uEnumFlags = SHCONTF_FOLDERS | SHCONTF_NONFOLDERS;
218 TRACE(
"enter callback\n");
219 lpfnCallback ( pidl, pidlTemp);
220 TRACE(
"leave callback\n");
225 IEnumIDList_Release (lpe);
227 IShellFolder_Release(lpsf2);
229 IShellFolder_Release(lpsf);
241 return NumberOfItems;
262 TRACE(
"0x%08x 0x%08x %p 0x%08x 0x%08x hMenu=%p\n",
263 crBorderColor, nBorderWidth, hBorderBmp, nSelHeight,
uFlags, hMenu);
318 TRACE(
"%p %s 0x%08x 0x%08x %p 0x%08x\n",
320 uID, icon, hMenuPopup, nItemHeight);
333 myItem->
hMenu = hMenu;
368 ERR(
"menudata corrupt: %p %u\n", menudata,
MenuInfo.cbSize);
391 if (!lpText)
return FALSE;
399 if (!lpszText)
return FALSE;
422 TRACE(
"%p 0x%08x %p 0x%08x 0x%08x %p\n",
423 hmenu, uID, pidl,
uFlags, uEnumFlags, lpfnCallback);
446 TRACE(
"%p 0x%08x %p 0x%08x %p\n",
447 hmenu, uID, pidl, uEnumFlags, lpfnCallback);
471 FIXME(
"%p %p\n",hMenu, pidl);
494 TRACE(
"%p %p 0x%08x\n",
hmenu, pidl,bAddSeparator);
513 TRACE(
"%p 0x%08x 0x%08x %p 0x%08x 0x%08x %p\n",
514 hmenu, uReserved, uID, pidl,
uFlags, uEnumFlags, lpfnCallback);
532 TRACE(
"%p 0x%08x 0x%x 0x%x %p %p\n",
545 FIXME(
"0x%08x %p %p\n",uReserved, ppidlFolder, ppidlItem);
549#define FM_ICON_SIZE 16
553#define FM_LEFTBORDER 2
554#define FM_RIGHTBORDER 8
708 TRACE(
"%p 0x%08x\n", hMenu, uID);
731 TRACE(
"%p 0x%08x\n", hMenu, uPos);
754 TRACE(
"%p 0x%08x\n", hMenu, uID);
763 TRACE(
"%p\n", hMenu);
788 FIXME(
"%p 0x%08x\n", hMenu, uPos);
825 FIXME(
"hmenu=%p hwnd=%p 0x%08x 0x%08x stub\n",
859 BOOL bAlreadySeparated;
862 UINT uTemp, uIDMax = uIDAdjust;
864 TRACE(
"hmenu1=%p hmenu2=%p 0x%04x 0x%04x 0x%04x 0x%04x\n",
865 hmDst, hmSrc, uInsert, uIDAdjust, uIDAdjustMax,
uFlags);
867 if (!hmDst || !hmSrc)
874 if (uInsert >= (
UINT)nItem)
876 uInsert = (
UINT)nItem;
877 bAlreadySeparated =
TRUE;
888 bAlreadySeparated =
TRUE;
914 if (bAlreadySeparated)
917 bAlreadySeparated =
TRUE;
923 miiSrc.
wID += uIDAdjust;
925 if (miiSrc.
wID > uIDAdjustMax)
928 if (uIDMax <= miiSrc.
wID)
929 uIDMax = miiSrc.
wID + 1;
933 miiSrc.
fMask &= ~MIIM_ID;
939 if (!miiSrc.
hSubMenu)
return(uIDMax);
946 bAlreadySeparated =
FALSE;
950 miiSrc.
wID += uIDAdjust;
952 if (miiSrc.
wID > uIDAdjustMax)
955 if (uIDMax <= miiSrc.
wID)
956 uIDMax = miiSrc.
wID + 1;
958 bAlreadySeparated =
FALSE;
973 if (bAlreadySeparated)
982 if (bAlreadySeparated)
HRESULT WINAPI SHGetDesktopFolder(IShellFolder **psf)
static const char * wine_dbgstr_rect(const RECT *prc)
#define WINE_DEFAULT_DEBUG_CHANNEL(t)
void shell(int argc, const char *argv[])
void pdump(LPCITEMIDLIST pidl)
BOOL WINAPI ImageList_Draw(HIMAGELIST himl, INT i, HDC hdc, INT x, INT y, UINT fStyle)
#define HeapFree(x, y, z)
#define MultiByteToWideChar
void WINAPI SHFree(LPVOID pv)
LPVOID WINAPI SHAlloc(SIZE_T len)
LPWSTR WINAPI PathFindExtensionW(LPCWSTR lpszPath)
GLint GLint GLint GLint GLint x
GLint GLint GLint GLint GLint GLint y
GLubyte GLubyte GLubyte GLubyte w
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
BOOL PidlToSicIndex(IShellFolder *sh, LPCITEMIDLIST pidl, BOOL bBigIcon, UINT uFlags, int *pIndex)
BOOL WINAPI Shell_GetImageLists(HIMAGELIST *lpBigList, HIMAGELIST *lpSmallList)
static const CLSID *static CLSID *static const GUID VARIANT VARIANT *static IServiceProvider DWORD *static HMENU
LPITEMIDLIST WINAPI ILClone(LPCITEMIDLIST pidl)
LPITEMIDLIST WINAPI ILCombine(LPCITEMIDLIST pidl1, LPCITEMIDLIST pidl2)
BOOL ILGetDisplayNameExW(LPSHELLFOLDER psf, LPCITEMIDLIST pidl, LPWSTR path, DWORD type)
static const WCHAR szName[]
static __inline BOOL SHELL_OsIsUnicode(void)
#define MM_SUBMENUSHAVEIDS
ITEMIDLIST UNALIGNED * LPITEMIDLIST
const ITEMIDLIST UNALIGNED * LPCITEMIDLIST
LPFNFMCALLBACK lpfnCallback
#define FM_DEFAULT_HEIGHT
void(CALLBACK * LPFNFMCALLBACK)(LPCITEMIDLIST pidlFolder, LPCITEMIDLIST pidlFile)
COLORREF WINAPI SetBkColor(_In_ HDC, _In_ COLORREF)
BOOL WINAPI ExtTextOutW(_In_ HDC hdc, _In_ int x, _In_ int y, _In_ UINT options, _In_opt_ const RECT *lprect, _In_reads_opt_(c) LPCWSTR lpString, _In_ UINT c, _In_reads_opt_(c) const INT *lpDx)
COLORREF WINAPI SetTextColor(_In_ HDC, _In_ COLORREF)
BOOL WINAPI GetTextExtentPoint32W(_In_ HDC hdc, _In_reads_(c) LPCWSTR lpString, _In_ int c, _Out_ LPSIZE psizl)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
DWORD WINAPI GetSysColor(_In_ int)
HMENU WINAPI CreatePopupMenu(void)
int WINAPI GetMenuItemCount(_In_opt_ HMENU)
BOOL WINAPI InsertMenuW(_In_ HMENU, _In_ UINT, _In_ UINT, _In_ UINT_PTR, _In_opt_ LPCWSTR)
BOOL WINAPI DeleteMenu(_In_ HMENU, _In_ UINT, _In_ UINT)
BOOL WINAPI TrackPopupMenuEx(_In_ HMENU, _In_ UINT, _In_ int, _In_ int, _In_ HWND, _In_opt_ LPTPMPARAMS)
BOOL WINAPI InsertMenuA(_In_ HMENU, _In_ UINT, _In_ UINT, _In_ UINT_PTR, _In_opt_ LPCSTR)
BOOL WINAPI SetMenuInfo(_In_ HMENU, _In_ LPCMENUINFO)
#define COLOR_HIGHLIGHTTEXT
HDC WINAPI GetDC(_In_opt_ HWND)
BOOL WINAPI GetMenuInfo(_In_ HMENU, _Inout_ LPMENUINFO)
BOOL WINAPI GetMenuItemRect(_In_opt_ HWND, _In_ HMENU, _In_ UINT, _Out_ LPRECT)
BOOL WINAPI DestroyMenu(_In_ HMENU)
BOOL WINAPI GetMenuItemInfoW(_In_ HMENU, _In_ UINT, _In_ BOOL, _Inout_ LPMENUITEMINFOW)
struct tagMENUINFO MENUINFO
BOOL WINAPI InsertMenuItemW(_In_ HMENU, _In_ UINT, _In_ BOOL, _In_ LPCMENUITEMINFOW)
struct tagMENUITEMINFOW MENUITEMINFOW