OWLNext    7.0
Borland's Object Windows Library for the modern age
Loading...
Searching...
No Matches
trayicon.cpp File Reference

This is a conglomeration of ideas from the MSJ "Webster" application, sniffing round the online docs, and from other implementations such as PJ Naughter's "CTrayIconifyIcon" (http://indigo.ie/~pjn/ntray.html) especially the "CTrayIcon::OnTrayNotification" member function. More...

#include <owl/pch.h>
#include <owl/shellitm.h>
#include <owl/trayicon.h>
#include <owl/window.h>

Go to the source code of this file.

Namespaces

namespace  owl
 Object Windows Library (OWLNext Core)
 

Detailed Description

This is a conglomeration of ideas from the MSJ "Webster" application, sniffing round the online docs, and from other implementations such as PJ Naughter's "CTrayIconifyIcon" (http://indigo.ie/~pjn/ntray.html) especially the "CTrayIcon::OnTrayNotification" member function.

This class is a light wrapper around the windows system tray stuff. It adds an icon to the system tray with the specified ToolTip text and callback notification value, which is sent back to the Parent window.

The tray icon can be instantiated using either the constructor or by declaring the object and creating (and displaying) it later on in the program. eg.

TTrayIcon* Trayicon; // Member variable of some class
...
// in some member function maybe...
Trayicon = new TTrayIcon(... ... ... ... );
...
//in SetupWindow() or after where hWnd is valid
Trayicon->Create();

or

TTrayIcon Trayicon; // Member variable of some class
...
// in some member function maybe...
Trayicon.Init(........);
...
//in SetupWindow() or after where hWnd is valid
Trayicon.Create();

Definition in file trayicon.cpp.