Corrected the priority of operators for LISTVIEW_GetNextItem function.

Dmitry Timoshkov dmitry at baikal.ru
Tue May 17 19:47:38 CDT 2005


<taro-x at justsystem.co.jp> wrote:

> Changelog:
> 
>     *   dlls/comctl32/listview.c
> 
>     Corrected the priority of operators for LISTVIEW_GetNextItem function.

> --- dlls/comctl32/listview.c 2005-04-14 22:58:24.000000000 +0900
> +++ dlls/comctl32/listview.c 2005-05-16 11:29:08.003084512 +0900
> @@ -5665,7 +5665,7 @@
>       * so it's worth optimizing */
>      if (uFlags & LVNI_FOCUSED)
>      {
> - if (!(LISTVIEW_GetItemState(infoPtr, infoPtr->nFocusedItem, uMask) & uMask) == uMask) return -1;
> + if (!((LISTVIEW_GetItemState(infoPtr, infoPtr->nFocusedItem, uMask) & uMask) == uMask)) return -1;

Wouldn't it be more readable and less confusing in the below form?

if ((LISTVIEW_GetItemState(infoPtr, infoPtr->nFocusedItem, uMask) & uMask) != uMask) return -1;


-- 
Dmitry.




More information about the wine-devel mailing list