Showing one image in a hidden group of images

Jan Schenkel janschenkel at yahoo.com
Sun Aug 31 00:43:00 EDT 2003


--- Barry Levine <themacguy at macosx.com> wrote:
> I have a group of four images that is invisible
> until needed. I'd now 
> like to show only one of those images when a user
> clicks at a certain 
> location. I have no trouble determining when the
> user has clicked the 
> appropriate spot.
> 
> I've tried showing and hiding the image alone but,
> as the group is 
> invisible, the "showing/hiding" is taking place in
> an invisible object 
> so, of course, you don't see it.
> 
> I'm wondering if something like the following is the
> most efficient way 
> of handling this:
> 
> on mouseUp
>    set the lockScreen to true
>    put the loc of image myImage into myLoc -- for
> brevity later on
>    copy image myImage to this stack
>    put word 3 of it into myNewID -- tha's the ID# of
> the newly created 
> image
>    set the loc of image ID myNewID to myLoc -- same
> loc as the original 
> image
>    show image ID myNewID
>    set the lockScreen to false
>    wait 2 seconds -- or do whatever
>    delete image ID myNewID
> end mouseUp
> 
> This seems to work nicely but I'm wondering if I'm
> heading down a path 
> whereby I'll screw up the carefully placed groups of
> images.
> 
> Thanks in advance,
> Barry
> 

Hi Barry,

How about placing four tranasparent buttons in the
currect spots, turning off their showname and
autohilite, and setting their 'icon' property ?

Just a thought,

Jan Schenkel.

=====
"As we grow older, we grow both wiser and more foolish at the same time."  (La Rochefoucauld)

__________________________________
Do you Yahoo!?
Yahoo! SiteBuilder - Free, easy-to-use web site design software
http://sitebuilder.yahoo.com



More information about the use-livecode mailing list