AcornSearch - Acorn and RISC OS information searching
RISC OS Search
containing
"Nutty quip goes here!"
Home  |  About  |  Filebase Archive  |  StrongHelp Manuals  |  Newsgroups  |  Module Database
This call may be used to modify the state of menu flag which controls the tick displayed on the left of the menu item. 

*     R0 =     handle of menu item or 0 for current menu item or handle of menu
     R1 —     defines action
           if R1 = 0 then clear tick flag 
           if R1 ¹ 0 then set tick flag  
*     R0,R1     preserved

Use:     R0 must contain the item handle or zero for the current menu item. R1 defines to set or to clear the flag. If R1 is zero then the flag will be cleared and if R1 is non zero then the flag will be set.
     If R0 instead of item handle contains menu handle then the state of the flag will be changed in all items of this menu.
     It is convenient to pass in R1 the result of logical expression (to set flag if result is TRUE and to clear it if FALSE).

Example code...
Example code (MenuUtil_Tick)
Tick one of the items depending on the value of variable disp%:

  SYS "MenuUtil_Tick",largeItem%,(disp%=1)  
  SYS "MenuUtil_Tick",smallItem,(disp%=2)  
  SYS "MenuUtil_Tick",fullItem%,(disp%=3)  

[sh-index] Back to list of manuals