Fix wxArray::Index() with bFromEnd=true in STL build.

This function incorrectly returned index from the end of the array when
searching from the end. Fixed to work as the non-STL version.

Fixes #13626.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@69688 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Václav Slavík 2011-11-05 15:20:32 +00:00
parent 23f32cd750
commit 12a7fb5f0b

View File

@ -151,7 +151,7 @@ public: \
e = rend(); \ e = rend(); \
for ( const_reverse_iterator i = b; i != e; ++i ) \ for ( const_reverse_iterator i = b; i != e; ++i ) \
if ( *i == item ) \ if ( *i == item ) \
return (int)(i - b); \ return (int)(e - i - 1); \
} \ } \
else \ else \
{ \ { \