Author: weiden
Date: Sun Jun 10 15:50:48 2007
New Revision: 27111
URL:
http://svn.reactos.org/svn/reactos?rev=27111&view=rev
Log:
convert a switch statement with a range to an if statement (msvc compatibility)
Modified:
trunk/reactos/base/shell/explorer-new/traywnd.c
Modified: trunk/reactos/base/shell/explorer-new/traywnd.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/base/shell/explorer-new/tr…
==============================================================================
--- trunk/reactos/base/shell/explorer-new/traywnd.c (original)
+++ trunk/reactos/base/shell/explorer-new/traywnd.c Sun Jun 10 15:50:48 2007
@@ -2337,15 +2337,12 @@
if (uiCmdId != 0)
{
- switch (uiCmdId)
- {
- case ID_SHELL_CMD_FIRST ... ID_SHELL_CMD_LAST:
- {
- CMINVOKECOMMANDINFO cmici = {0};
-
- if (pcm == NULL)
- break;
-
+ if (uiCmdId >= ID_SHELL_CMD_FIRST && uiCmdId <= ID_SHELL_CMD_LAST)
+ {
+ CMINVOKECOMMANDINFO cmici = {0};
+
+ if (pcm != NULL)
+ {
/* Setup and invoke the shell command */
cmici.cbSize = sizeof(cmici);
cmici.hwnd = hWndOwner;
@@ -2354,13 +2351,12 @@
IContextMenu_InvokeCommand(pcm,
&cmici);
- break;
- }
-
- default:
- ITrayWindow_ExecContextMenuCmd(ITrayWindow_from_impl(This),
- uiCmdId);
- break;
+ }
+ }
+ else
+ {
+ ITrayWindow_ExecContextMenuCmd(ITrayWindow_from_impl(This),
+ uiCmdId);
}
}