Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wine-winehq
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
wine
wine-winehq
Commits
3058b68b
Commit
3058b68b
authored
Mar 27, 2010
by
Nikolay Sivov
Committed by
Alexandre Julliard
Mar 29, 2010
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
shlwapi: More trace for menu related helpers.
parent
df04c25a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
29 additions
and
16 deletions
+29
-16
ordinal.c
dlls/shlwapi/ordinal.c
+29
-16
No files found.
dlls/shlwapi/ordinal.c
View file @
3058b68b
...
@@ -1719,6 +1719,9 @@ void WINAPI SHPropagateMessage(HWND hWnd, UINT uiMsgId, WPARAM wParam, LPARAM lP
...
@@ -1719,6 +1719,9 @@ void WINAPI SHPropagateMessage(HWND hWnd, UINT uiMsgId, WPARAM wParam, LPARAM lP
DWORD
WINAPI
SHRemoveAllSubMenus
(
HMENU
hMenu
)
DWORD
WINAPI
SHRemoveAllSubMenus
(
HMENU
hMenu
)
{
{
int
iItemCount
=
GetMenuItemCount
(
hMenu
)
-
1
;
int
iItemCount
=
GetMenuItemCount
(
hMenu
)
-
1
;
TRACE
(
"%p
\n
"
,
hMenu
);
while
(
iItemCount
>=
0
)
while
(
iItemCount
>=
0
)
{
{
HMENU
hSubMenu
=
GetSubMenu
(
hMenu
,
iItemCount
);
HMENU
hSubMenu
=
GetSubMenu
(
hMenu
,
iItemCount
);
...
@@ -1744,6 +1747,7 @@ DWORD WINAPI SHRemoveAllSubMenus(HMENU hMenu)
...
@@ -1744,6 +1747,7 @@ DWORD WINAPI SHRemoveAllSubMenus(HMENU hMenu)
*/
*/
UINT
WINAPI
SHEnableMenuItem
(
HMENU
hMenu
,
UINT
wItemID
,
BOOL
bEnable
)
UINT
WINAPI
SHEnableMenuItem
(
HMENU
hMenu
,
UINT
wItemID
,
BOOL
bEnable
)
{
{
TRACE
(
"%p, %u, %d
\n
"
,
hMenu
,
wItemID
,
bEnable
);
return
EnableMenuItem
(
hMenu
,
wItemID
,
bEnable
?
MF_ENABLED
:
MF_GRAYED
);
return
EnableMenuItem
(
hMenu
,
wItemID
,
bEnable
?
MF_ENABLED
:
MF_GRAYED
);
}
}
...
@@ -1762,6 +1766,7 @@ UINT WINAPI SHEnableMenuItem(HMENU hMenu, UINT wItemID, BOOL bEnable)
...
@@ -1762,6 +1766,7 @@ UINT WINAPI SHEnableMenuItem(HMENU hMenu, UINT wItemID, BOOL bEnable)
*/
*/
DWORD
WINAPI
SHCheckMenuItem
(
HMENU
hMenu
,
UINT
uID
,
BOOL
bCheck
)
DWORD
WINAPI
SHCheckMenuItem
(
HMENU
hMenu
,
UINT
uID
,
BOOL
bCheck
)
{
{
TRACE
(
"%p, %u, %d
\n
"
,
hMenu
,
uID
,
bCheck
);
return
CheckMenuItem
(
hMenu
,
uID
,
bCheck
?
MF_CHECKED
:
MF_UNCHECKED
);
return
CheckMenuItem
(
hMenu
,
uID
,
bCheck
?
MF_CHECKED
:
MF_UNCHECKED
);
}
}
...
@@ -2945,7 +2950,8 @@ HWND WINAPI SHCreateWorkerWindowW(LONG wndProc, HWND hWndParent, DWORD dwExStyle
...
@@ -2945,7 +2950,8 @@ HWND WINAPI SHCreateWorkerWindowW(LONG wndProc, HWND hWndParent, DWORD dwExStyle
*/
*/
HRESULT
WINAPI
SHInvokeDefaultCommand
(
HWND
hWnd
,
IShellFolder
*
lpFolder
,
LPCITEMIDLIST
lpApidl
)
HRESULT
WINAPI
SHInvokeDefaultCommand
(
HWND
hWnd
,
IShellFolder
*
lpFolder
,
LPCITEMIDLIST
lpApidl
)
{
{
return
SHInvokeCommand
(
hWnd
,
lpFolder
,
lpApidl
,
FALSE
);
TRACE
(
"%p %p %p
\n
"
,
hWnd
,
lpFolder
,
lpApidl
);
return
SHInvokeCommand
(
hWnd
,
lpFolder
,
lpApidl
,
FALSE
);
}
}
/*************************************************************************
/*************************************************************************
...
@@ -3460,12 +3466,12 @@ UINT WINAPI SHDefExtractIconWrapW(LPCWSTR pszIconFile, int iIndex, UINT uFlags,
...
@@ -3460,12 +3466,12 @@ UINT WINAPI SHDefExtractIconWrapW(LPCWSTR pszIconFile, int iIndex, UINT uFlags,
HRESULT
WINAPI
SHInvokeCommand
(
HWND
hWnd
,
IShellFolder
*
lpFolder
,
LPCITEMIDLIST
lpApidl
,
BOOL
bInvokeDefault
)
HRESULT
WINAPI
SHInvokeCommand
(
HWND
hWnd
,
IShellFolder
*
lpFolder
,
LPCITEMIDLIST
lpApidl
,
BOOL
bInvokeDefault
)
{
{
IContextMenu
*
iContext
;
IContextMenu
*
iContext
;
HRESULT
hRet
=
E_FAIL
;
HRESULT
hRet
;
TRACE
(
"(%p,
%p,%p,
%d)
\n
"
,
hWnd
,
lpFolder
,
lpApidl
,
bInvokeDefault
);
TRACE
(
"(%p,
%p, %p,
%d)
\n
"
,
hWnd
,
lpFolder
,
lpApidl
,
bInvokeDefault
);
if
(
!
lpFolder
)
if
(
!
lpFolder
)
return
hRet
;
return
E_FAIL
;
/* Get the context menu from the shell folder */
/* Get the context menu from the shell folder */
hRet
=
IShellFolder_GetUIObjectOf
(
lpFolder
,
hWnd
,
1
,
&
lpApidl
,
hRet
=
IShellFolder_GetUIObjectOf
(
lpFolder
,
hWnd
,
1
,
&
lpApidl
,
...
@@ -3485,7 +3491,7 @@ HRESULT WINAPI SHInvokeCommand(HWND hWnd, IShellFolder* lpFolder, LPCITEMIDLIST
...
@@ -3485,7 +3491,7 @@ HRESULT WINAPI SHInvokeCommand(HWND hWnd, IShellFolder* lpFolder, LPCITEMIDLIST
if
(
SUCCEEDED
(
hQuery
))
if
(
SUCCEEDED
(
hQuery
))
{
{
if
(
bInvokeDefault
&&
if
(
bInvokeDefault
&&
(
dwDefaultId
=
GetMenuDefaultItem
(
hMenu
,
0
,
0
))
!=
0xFFFFFFFF
)
(
dwDefaultId
=
GetMenuDefaultItem
(
hMenu
,
0
,
0
))
!=
(
UINT
)
-
1
)
{
{
CMINVOKECOMMANDINFO
cmIci
;
CMINVOKECOMMANDINFO
cmIci
;
/* Invoke the default item */
/* Invoke the default item */
...
@@ -4255,18 +4261,24 @@ BOOL WINAPI SHIsLowMemoryMachine (DWORD x)
...
@@ -4255,18 +4261,24 @@ BOOL WINAPI SHIsLowMemoryMachine (DWORD x)
*/
*/
INT
WINAPI
GetMenuPosFromID
(
HMENU
hMenu
,
UINT
wID
)
INT
WINAPI
GetMenuPosFromID
(
HMENU
hMenu
,
UINT
wID
)
{
{
MENUITEMINFOW
mi
;
MENUITEMINFOW
mi
;
INT
nCount
=
GetMenuItemCount
(
hMenu
),
nIter
=
0
;
INT
nCount
=
GetMenuItemCount
(
hMenu
),
nIter
=
0
;
TRACE
(
"%p %u
\n
"
,
hMenu
,
wID
);
while
(
nIter
<
nCount
)
{
mi
.
cbSize
=
sizeof
(
mi
);
mi
.
fMask
=
MIIM_ID
;
if
(
GetMenuItemInfoW
(
hMenu
,
nIter
,
TRUE
,
&
mi
)
&&
mi
.
wID
==
wID
)
{
TRACE
(
"ret %d
\n
"
,
nIter
);
return
nIter
;
}
nIter
++
;
}
while
(
nIter
<
nCount
)
return
-
1
;
{
mi
.
cbSize
=
sizeof
(
mi
);
mi
.
fMask
=
MIIM_ID
;
if
(
GetMenuItemInfoW
(
hMenu
,
nIter
,
TRUE
,
&
mi
)
&&
mi
.
wID
==
wID
)
return
nIter
;
nIter
++
;
}
return
-
1
;
}
}
/*************************************************************************
/*************************************************************************
...
@@ -4276,6 +4288,7 @@ INT WINAPI GetMenuPosFromID(HMENU hMenu, UINT wID)
...
@@ -4276,6 +4288,7 @@ INT WINAPI GetMenuPosFromID(HMENU hMenu, UINT wID)
*/
*/
DWORD
WINAPI
SHMenuIndexFromID
(
HMENU
hMenu
,
UINT
uID
)
DWORD
WINAPI
SHMenuIndexFromID
(
HMENU
hMenu
,
UINT
uID
)
{
{
TRACE
(
"%p %u
\n
"
,
hMenu
,
uID
);
return
GetMenuPosFromID
(
hMenu
,
uID
);
return
GetMenuPosFromID
(
hMenu
,
uID
);
}
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment