using UnityEngine;
using System.Collections;
public class TestButtonClickSpan : MonoBehaviour {
float spanTime = 0;
bool isStart = false;
///
///
///
public GameObject mBtn = null;
// Use this for initialization
void Start () {
EventTriggerListener.Get(this.mBtn).onClick = OnHandle;
}
int i = 0;
///
/// 释放
///
///
private void OnHandle(GameObject obj)
{
if (spanTime > 5)
{ return; }
isStart = true;
LogHelper.LogError(i++);
}
// Update is called once per frame
void Update () {
if (spanTime > 5)
{ return; }
spanTime += Time.deltaTime;
}
}