Commit 513e5c98 authored by Alexandre Julliard's avatar Alexandre Julliard

user32: Add support for loading animated cursors/icons from resources.

parent 8970e29f
......@@ -1403,7 +1403,15 @@ static HICON CURSORICON_Load(HINSTANCE hInstance, LPCWSTR name,
if (!(hRsrc = FindResourceW( hInstance, name,
(LPWSTR)(fCursor ? RT_GROUP_CURSOR : RT_GROUP_ICON) )))
return 0;
{
/* try animated resource */
if (!(hRsrc = FindResourceW( hInstance, name,
(LPWSTR)(fCursor ? RT_ANICURSOR : RT_ANIICON) ))) return 0;
if (!(handle = LoadResource( hInstance, hRsrc ))) return 0;
bits = LockResource( handle );
return CURSORICON_CreateIconFromANI( bits, SizeofResource( hInstance, handle ),
width, height, depth, !fCursor, loadflags );
}
/* Find the best entry in the directory */
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment