set the member of sprite the spriteNum of me to the ImageDown of me
else
set the member of sprite the spriteNum of me to the ImageRoll of me
end if
else
set the member of sprite the spriteNum of me to the ImageRoll of me
end if
end
on mouseDown me
set the member of sprite the spriteNum of me to the ImageDown of me
set the Clicked of me to 1
pass()
end
on mouseLeave me
set the member of sprite the spriteNum of me to the ImageUp of me
end
on mouseUp me
set the member of sprite the spriteNum of me to the ImageRoll of me
if the Clicked of me then
set the Clicked of me to 0
pass()
end if
end
on mouseUpOutSide me
set the member of sprite the spriteNum of me to the ImageUp of me
set the Clicked of me to 0
end
on beginSprite me
set the Clicked of me to 0
end
on getPropertyDescriptionList
if the currentSpriteNum = 0 then
set memdefault1 to 0
else
set memref to the member of sprite the currentSpriteNum
set castLibNum to the castLibNum of memref
set memdefault0 to member the memberNum of member memref of castLib castLibNum
set memdefault1 to member (the memberNum of member memref + 1) of castLib castLibNum
set memdefault2 to member (the memberNum of member memref + 2) of castLib castLibNum
end if
set p_list to [#ImageUp: [#comment: "Button Up Image:", #format: #member, #default: memdefault0], #ImageRoll: [#comment: "Button Rollover Image:", #format: #member, #default: memdefault1], #ImageDown: [#comment: "Button Down Image:", #format: #member, #default: memdefault2]]
return p_list
end
on getBehaviorDescription
return "This is a tri-state button without sounds" & RETURN & "In my opinion this button behaves like it should" & RETURN & RETURN & "PARAMETERS:" & RETURN & "ImageUp: the cast member for the normal (not pressed state)" & RETURN & "ImageRoll: the cast member for the button when a rollover occurs" & RETURN & "ImageDown: the cast member for the button when a mousedown on the button is valid"