]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/dynarray.cpp
implemented fallback for AlphaBlend() for the systems not supporting it
[wxWidgets.git] / src / common / dynarray.cpp
index b760aa8b24484164a5628e64497ecfcda0ccfbd0..012c6077a324155f5b7b24b1009c4659e3dc4098 100644 (file)
@@ -283,7 +283,10 @@ int name::Index(T lItem, CMPFUNC fnCompare) const                           \
 {                                                                           \
     size_t n = IndexForInsert(lItem, fnCompare);                            \
                                                                             \
-    return n < m_nCount && m_pItems[n] == lItem ? (int)n : wxNOT_FOUND;     \
+    return n < m_nCount &&                                                  \
+           (*fnCompare)((const void *)(long)lItem,                          \
+                        ((const void *)(long)m_pItems[n])) ? (int)n         \
+                                                           : wxNOT_FOUND;   \
 }                                                                           \
                                                                             \
 /* add item at the end */                                                   \