Class TPGTimerManager (unit PGTray95)

Inherits from

TComponent

TPGTimerManager - Uses a single windows timer to manage a group of timed } { events. Used to conserve windows timer resources for 16 bit applications.

Constructors


constructor Create(AOwner: TComponent);

TPGTimerManager - Manages a group of timed events using a single Windows Timer.


Functions

function AddTimer(AnEnabled: Boolean; AnInterval: TPGTimerInterval; AnEvent: TNotifyEvent): TPGTimerItem;

Add a new timer to the list of currently defined timers.

procedure DeleteTimer(AnId: Integer);

Removes a timer from the list of timers.

destructor Destroy;


procedure RefreshInterval;

Refreshes the Main Timer Interval that is used to calculate and } { fire the Timer Event for all Timer Items.

function TimerCount: Integer;


function Timers(AnIndex: Integer): TPGTimerItem;

Update the timer interval and restart the timer if it was going.

procedure DoTimeouts(Sender: TObject);


procedure SetEnabled(Value: Boolean);


Properties

property Enabled : Boolean


Events

Variables

Timer : TTimer;


FEnabled : Boolean;


TimerItems : TList;



Constructors


constructor Create(AOwner: TComponent);

TPGTimerManager - Manages a group of timed events using a single Windows Timer.


Functions


function AddTimer(AnEnabled: Boolean; AnInterval: TPGTimerInterval; AnEvent: TNotifyEvent): TPGTimerItem;

Add a new timer to the list of currently defined timers.


procedure DeleteTimer(AnId: Integer);

Removes a timer from the list of timers.


destructor Destroy;


procedure RefreshInterval;

Refreshes the Main Timer Interval that is used to calculate and } { fire the Timer Event for all Timer Items. Note that the overall } { interval is calculated to be the smallest Timer Item interval } { or 150, whichever is smaller.


function TimerCount: Integer;


function Timers(AnIndex: Integer): TPGTimerItem;

Update the timer interval and restart the timer if it was going.


procedure DoTimeouts(Sender: TObject);


procedure SetEnabled(Value: Boolean);


Properties


property Enabled : Boolean


Events


Variables


Timer : TTimer;


FEnabled : Boolean;


TimerItems : TList;