flat assembler
Message board for the users of flat assembler.

Index > Tutorials and Examples > loading ani cursors

Author
Thread Post new topic Reply to topic
Ali.Z



Joined: 08 Jan 2018
Posts: 819
Ali.Z 29 Apr 2025, 12:08
loading animated cursor for use with static controls.


Description:
Download
Filename: animated_statctl.zip
Filesize: 2.4 KB
Downloaded: 29 Time(s)


_________________
Asm For Wise Humans
Post 29 Apr 2025, 12:08
View user's profile Send private message Reply with quote
bitRAKE



Joined: 21 Jul 2003
Posts: 4227
Location: vpcmpistri
bitRAKE 29 Apr 2025, 14:24
Nice example of ANI support.

No code version:
Code:
section '.rsrc' data resource readable

  directory \
    RT_DIALOG,dialogs,\
    RT_ANICURSOR,anicurs

  resource dialogs,\
    1,LANG_ENGLISH+SUBLANG_DEFAULT,anidlg

  resource anicurs,\
    123,LANG_NEUTRAL,anicur

  dialog anidlg,'ani demo',320,240,80,60,WS_CAPTION+WS_POPUP+WS_SYSMENU+DS_MODALFRAME
    dialogitem 'static','#123',1,0,0,0,0,WS_VISIBLE+SS_ICON
  enddialog

  resdata anicur
    file 'barber.ani'
  endres    
... during load the "#{id}" will be searched for.

_________________
¯\(°_o)/¯ “languages are not safe - uses can be” Bjarne Stroustrup
Post 29 Apr 2025, 14:24
View user's profile Send private message Visit poster's website Reply with quote
Ali.Z



Joined: 08 Jan 2018
Posts: 819
Ali.Z 29 Apr 2025, 22:45
note that RT_ANIICON is apparently same as RT_ANICURSOR, even tho we dont have ani-icons files in Windows.

an .ani file can be set as window's icon as well, but it wont be animated, i.e. only the first frame will be put in window's caption.

if one dont want to associate ani-cursor id with controls, then LoadCursor or LoadImage should be used to manually load ani files.

_________________
Asm For Wise Humans
Post 29 Apr 2025, 22:45
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2025, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.