8287446: Enhance icon presentations

Reviewed-by: prr, azvegint
This commit is contained in:
Alexander Zuev 2022-06-21 18:22:09 +00:00 committed by Henry Jen
parent 5a8e5ea3e2
commit 896a29dfae

View File

@ -1060,7 +1060,7 @@ JNIEXPORT jintArray JNICALL Java_sun_awt_shell_Win32ShellFolder2_getIconBits
// limit iconSize to MAX_ICON_SIZE, so that the colorBits and maskBits // limit iconSize to MAX_ICON_SIZE, so that the colorBits and maskBits
// arrays are big enough. // arrays are big enough.
// (logic: rather show bad icons than overrun the array size) // (logic: rather show bad icons than overrun the array size)
iconSize = iconSize > MAX_ICON_SIZE ? MAX_ICON_SIZE : iconSize; iconSize = (iconSize <= 0 || iconSize > MAX_ICON_SIZE) ? MAX_ICON_SIZE : iconSize;
// Set up BITMAPINFO // Set up BITMAPINFO
BITMAPINFO bmi; BITMAPINFO bmi;