X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/4e07c80645d02aa5560841d64351ecbefa67d0c1..e17d84e1b2189d11891d41b3809903eb22d1b91d:/src/osx/utils_osx.cpp diff --git a/src/osx/utils_osx.cpp b/src/osx/utils_osx.cpp index da98e5371a..438f7ddbf0 100644 --- a/src/osx/utils_osx.cpp +++ b/src/osx/utils_osx.cpp @@ -248,7 +248,7 @@ CGColorRef wxMacCreateCGColorFromHITheme( ThemeBrush brush ) { const int maxcachedbrush = 58+5; // negative indices are for metabrushes, cache down to -5) int brushindex = brush+5; - if ( brushindex < 0 || brush > brushindex ) + if ( brushindex < 0 || brushindex > maxcachedbrush ) { CGColorRef color ; HIThemeBrushCreateCGColor( brush, &color );