Exemplo n.º 1
0
        protected void SetTimer(string strTimerID, float fInterval, FunctionPointer fnTimer)
        {
            CustomTimer ct = new CustomTimer();

            ct.SetInterval(fInterval);
            ct.SetTimerFunction(fnTimer);
            ct.Start();

            if (gs_TimerDictionary.ContainsKey(strTimerID))
            {
                gs_TimerDictionary[strTimerID].SetInterval(fInterval);
            }
            else
            {
                gs_TimerDictionary.Add(strTimerID, ct);
            }
        }