mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-13 21:31:53 +00:00
MADE: Use new CursorMan with cursor surface
This commit is contained in:
parent
dd1232325d
commit
38ffb065f5
@ -72,6 +72,7 @@ void decompressImage(byte *source, Graphics::Surface &surface, uint16 cmdOffs, u
|
||||
960, 961, 962, 963
|
||||
};
|
||||
|
||||
uint16 pitch = surface.pitch;
|
||||
uint16 width = surface.w;
|
||||
uint16 height = surface.h;
|
||||
|
||||
@ -175,11 +176,12 @@ void decompressImage(byte *source, Graphics::Surface &surface, uint16 cmdOffs, u
|
||||
*destPtr = lineBuf[x + y * 320];
|
||||
destPtr++;
|
||||
}
|
||||
destPtr += pitch - width;
|
||||
}
|
||||
} else {
|
||||
for (int y = 0; y < 4 && height > 0; y++, height--) {
|
||||
memcpy(destPtr, &lineBuf[y * 320], width);
|
||||
destPtr += width;
|
||||
destPtr += pitch;
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -580,7 +580,7 @@ int16 ScriptFunctions::sfLoadMouseCursor(int16 argc, int16 *argv) {
|
||||
PictureResource *flex = _vm->_res->getPicture(argv[2]);
|
||||
if (flex) {
|
||||
Graphics::Surface *surf = flex->getPicture();
|
||||
CursorMan.replaceCursor(surf->getPixels(), surf->w, surf->h, argv[1], argv[0], 0);
|
||||
CursorMan.replaceCursor(*surf, argv[1], argv[0], 0);
|
||||
_vm->_res->freeResource(flex);
|
||||
}
|
||||
return 0;
|
||||
|
Loading…
Reference in New Issue
Block a user