[SHELL32]
authorPierre Schweitzer <pierre@reactos.org>
Sun, 11 Mar 2012 11:13:17 +0000 (11:13 +0000)
committerPierre Schweitzer <pierre@reactos.org>
Sun, 11 Mar 2012 11:13:17 +0000 (11:13 +0000)
Fix redundant check
Clarify variable usage

svn path=/trunk/; revision=56114

reactos/dll/win32/shell32/shlmenu.cpp
reactos/dll/win32/shell32/shlview.cpp

index 04d95d7..0e41fcf 100644 (file)
@@ -908,7 +908,7 @@ UINT WINAPI Shell_MergeMenus (HMENU hmDst, HMENU hmSrc, UINT uInsert, UINT uIDAd
         {
           miiSrc.wID += uIDAdjust;            /* add uIDAdjust to the ID */
 
-          if (miiSrc.wID > uIDAdjustMax && miiSrc.wID > uIDAdjustMax)        /* skip ID's higher uIDAdjustMax */
+          if (miiSrc.wID > uIDAdjustMax)        /* skip ID's higher uIDAdjustMax */
             continue;
           if (uIDMax <= miiSrc.wID)            /* remember the highest ID */
             uIDMax = miiSrc.wID + 1;
@@ -934,7 +934,7 @@ UINT WINAPI Shell_MergeMenus (HMENU hmDst, HMENU hmSrc, UINT uInsert, UINT uIDAd
       {
         miiSrc.wID += uIDAdjust;            /* add uIDAdjust to the ID */
 
-        if (miiSrc.wID > uIDAdjustMax && miiSrc.wID > uIDAdjustMax)        /* skip ID's higher uIDAdjustMax */{
+        if (miiSrc.wID > uIDAdjustMax)        /* skip ID's higher uIDAdjustMax */{
           continue;
         }
         if (uIDMax <= miiSrc.wID)            /* remember the highest ID */
index f593ef2..4748057 100644 (file)
@@ -1421,7 +1421,7 @@ void CDefView::DoActivate(UINT uState)
     TRACE("%p uState=%x\n", this, uState);
 
     /*don't do anything if the state isn't really changing */
-    if (uState == uState)
+    if (this->uState == uState)
     {
         return;
     }
@@ -2179,7 +2179,7 @@ HRESULT WINAPI CDefView::UIActivate(UINT uState)
     TRACE("(%p)->(state=%x) stub\n", this, uState);
 
     /*don't do anything if the state isn't really changing*/
-    if (uState == uState)
+    if (this->uState == uState)
     {
         return S_OK;
     }