Hello Guest

Author Topic: i want tk2dUIItem release dont fire event OnClick  (Read 4790 times)

quangtu89

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 18
    • View Profile
i want tk2dUIItem release dont fire event OnClick
« on: August 22, 2013, 02:46:41 am »
My scene can drag to change scene .
I want to when i touch down a button after i move finger to drag scene, button will release but don't fire event OnClick

My code :

Code: [Select]
[AddComponentMenu("Lunge Mine/UI/UIWithDragScene")]
public class UIWithDragScene : tk2dUIBaseItemControl {

void Update()
{
if(uiItem.IsPressed)
{
if(LGController.state == LGController.State.Animation)
{
uiItem.Release();
}
}
}
}

How can i release a uiitem but don't fire event OnClick

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: i want tk2dUIItem release dont fire event OnClick
« Reply #1 on: August 22, 2013, 10:05:19 am »
So do you want it to fire or not? You are saying it doesn't fire the OnClick, and then you're asking the same question about how to do what you've already got again?

quangtu89

  • 2D Toolkit
  • Newbie
  • *
  • Posts: 18
    • View Profile
Re: i want tk2dUIItem release dont fire event OnClick
« Reply #2 on: August 23, 2013, 07:13:05 am »
I say I want to don't fire on click