![]() |
|
||||||||||
|
|||||||
|
|
« Предыдущая тема | Следующая тема » |
| Опции темы | Опции просмотра |
|
![]() |
|
|||||
|
Регистрация: Aug 2008
Сообщений: 1
|
import flash.events.*;
import flash.utils.*;
public class MyTimer extends Object
{
private var ticker:Timer;
private var func:Function;
public function MyTimer(t:int, f:Function)
{
ticker = new Timer(t);
ticker.addEventListener(TimerEvent.TIMER, onTick);
func = f;
ticker.start();
return;
}
function onTick(t:TimerEvent) : void
{
func(); // TypeError: Error #1009: Cannot access a property or method of a null object reference.
return;
}
}
![]() |
![]() |
Часовой пояс GMT +4, время: 02:12. |
|
|
« Предыдущая тема | Следующая тема » |
|
|