Thx Jimking
i have another question...i have a little bug with function OnMouseLeave
from time to time my animation stays in "ON" instead of being in "OFF". Any idea to fix this bug?
screen
https://gyazo.com/0bd3f938b08f4a4ef1da401d837154d4like on this screen where my mouse is not on the button however the animation remains displayed.
My Code
Code:
function DocBtnOnMouseEnter(Sender) // ----- ANNIMATION ON ----- //
{
setTimeout(Doc_Btn_Anim_On(),0.1);
}
function Doc_Btn_Anim_On() // ----- ANNIMATION ----- //
{
Doc_Top.AnimateFloat("width",103,0.4,2,6);
Doc_Left.AnimateFloat("height",36,0.4,2,6);
Doc_Bottom.AnimateFloat("left",-3,0.4,2,6);
Doc_Bottom.AnimateFloat("width",102,0.4,2,6);
Doc_Right.AnimateFloat("top",-2,0.4,2,6);
Doc_Right.AnimateFloat("height",37,0.4,2,6);
DocTxtHover.AnimateFloat("opacity",1,0.4,2,6);
}
function DocBtnOnMouseLeave(Sender) // ----- ANNIMATION OFF ----- //
{
setTimeout(Doc_Btn_Anim_Off(),0.1);
}
function Doc_Btn_Anim_Off() // ----- ANNIMATION ----- //
{
Doc_Top.AnimateFloat("width",0,0.4,2,6);
Doc_Left.AnimateFloat("height",0,0.4,2,6);
Doc_Bottom.AnimateFloat("left",98,0.4,2,6);
Doc_Bottom.AnimateFloat("width",0,0.4,2,6);
Doc_Right.AnimateFloat("top",35,0.4,2,6);
Doc_Right.AnimateFloat("height",0,0.4,2,6);
DocTxtHover.AnimateFloat("opacity",0,0.4,2,6);
}
maybe you have idea for force close animation with the OnMouseLeave function ?
Thx