winex11: Make sure we create valid bitmaps even for a 1x1 mask.
This commit is contained in:
parent
3bbb208f8e
commit
bd44f10496
|
@ -1161,7 +1161,7 @@ static Cursor create_cursor( HANDLE handle )
|
|||
#endif
|
||||
|
||||
GetObjectW( info.hbmMask, sizeof(bm), &bm );
|
||||
if (!info.hbmColor) bm.bmHeight /= 2;
|
||||
if (!info.hbmColor) bm.bmHeight = max( 1, bm.bmHeight / 2 );
|
||||
|
||||
/* make sure hotspot is valid */
|
||||
if (info.xHotspot >= bm.bmWidth || info.yHotspot >= bm.bmHeight)
|
||||
|
|
Loading…
Reference in New Issue