Class TTraybar (unit Traybar) |
Inherits from
TComponent
The real component:
constructor Create( AOwner: TComponent );
- Defining the run-time interface
When creating declare never changing fields of tnid
function Add: Boolean;
Adds an icon, Result=True if successful
function Delete: Boolean;
Remove icon
destructor Destroy;
Free FIcon and go on with Destroy from TComponent
function Modify: Boolean;
Change icon or tooltip if icon already placed
procedure HandleMessage(var Msg: TMessage);
Handle incoming messages from the traybaricon.
function InitIcon: Boolean;
Fill tnid with changing date, like icon and tooltip
procedure SetIcon(Value: TIcon);
Assign icon to FIcon
property About : TAboutTraybarProperty
Defining the design time interface} {New properties:
property Hint : String
property Icon : TIcon
property PopupMenu : TPopupMenu
event Onclick : TNotifyEvent
New events:
event OnDblClick : TNotifyEvent
event OnRightClick : TNotifyEvent
FAbout : TAboutTraybarProperty;
Hiding implementation details,} {Properties storage
FEnabled : Boolean;
FHint : String;
FICon : TIcon;
FName : TComponentName;
FOnClick : TNotifyEvent;
FOnDblClick : TNotifyEvent;
FOnRightClick : TNotifyEvent;
FPopupMenu : TPopupMenu;
Tnid : TNotifyIconData;
constructor Create( AOwner: TComponent );
Defining the run-time interface
When creating declare never changing fields of tnid
function Add: Boolean;
Adds an icon, Result=True if successful
function Delete: Boolean;
Remove icon
destructor Destroy;
Free FIcon and go on with Destroy from TComponent
function Modify: Boolean;
Change icon or tooltip if icon already placed
procedure HandleMessage(var Msg: TMessage);
Handle incoming messages from the traybaricon.
All known traybaricons (like speaker, FlexiCD, Clock etc)
react on mousebutton actions as used below
function InitIcon: Boolean;
Fill tnid with changing date, like icon and tooltip
procedure SetIcon(Value: TIcon);
Assign icon to FIcon
property About : TAboutTraybarProperty
Defining the design time interface} {New properties:
property Hint : String
property Icon : TIcon
property PopupMenu : TPopupMenu
event Onclick : TNotifyEvent
New events:
event OnDblClick : TNotifyEvent
event OnRightClick : TNotifyEvent
FAbout : TAboutTraybarProperty;
Hiding implementation details,} {Properties storage
FEnabled : Boolean;
FHint : String;
FICon : TIcon;
FName : TComponentName;
FOnClick : TNotifyEvent;
FOnDblClick : TNotifyEvent;
FOnRightClick : TNotifyEvent;
FPopupMenu : TPopupMenu;
Tnid : TNotifyIconData;