]>
git.saurik.com Git - wxWidgets.git/blob - contrib/samples/applet/monitorapplet.h
1 /****************************************************************************
3 * Copyright (C) 1991-2001 SciTech Software, Inc.
6 * ======================================================================
7 * |REMOVAL OR MODIFICATION OF THIS HEADER IS STRICTLY PROHIBITED BY LAW|
9 * |This copyrighted computer code is a proprietary trade secret of |
10 * |SciTech Software, Inc., located at 505 Wall Street, Chico, CA 95928 |
11 * |USA (www.scitechsoft.com). ANY UNAUTHORIZED POSSESSION, USE, |
12 * |VIEWING, COPYING, MODIFICATION OR DISSEMINATION OF THIS CODE IS |
13 * |STRICTLY PROHIBITED BY LAW. Unless you have current, express |
14 * |written authorization from SciTech to possess or use this code, you |
15 * |may be subject to civil and/or criminal penalties. |
17 * |If you received this code in error or you would like to report |
18 * |improper use, please immediately contact SciTech Software, Inc. at |
21 * |REMOVAL OR MODIFICATION OF THIS HEADER IS STRICTLY PROHIBITED BY LAW|
22 * ======================================================================
27 * Description: Header file for the MonitorApplet class
29 ****************************************************************************/
31 #ifndef __WX_MONITORAPPLET_H
32 #define __WX_MONITORAPPLET_H
34 #include "wx/applet/applet.h"
36 #include "dialogs_wdr.h"
38 /*--------------------------- Class Definitions ---------------------------*/
40 /****************************************************************************
42 Structure defining the simple monitor database records.
43 ****************************************************************************/
49 /****************************************************************************
51 Defines our wxMonitorData cookie object that is stored to maintain state
52 information for this MonitorApplet.
53 ****************************************************************************/
54 class MonitorData
: public wxObject
{
56 MonitorEntry m_Monitor
;
59 // Name used to track the monitor data cookie
60 #define MONITOR_COOKIE_NAME "MonitorData"
62 /****************************************************************************
64 Defines our wxMonitor applet class
65 ****************************************************************************/
66 class MonitorApplet
: public wxApplet
{
68 DECLARE_DYNAMIC_CLASS(MonitorApplet
);
69 DECLARE_EVENT_TABLE();
75 static MonitorEntry m_Monitors
[];
77 // Flush the current state to a cookie
78 void SaveCurrentState();
81 // Constructor (called during dynamic creation)
84 // Psuedo virtual constructor
86 wxHtmlAppletWindow
*parent
,
91 virtual ~MonitorApplet();
93 // Handle HTML navigation to a new URL
94 virtual void OnLinkClicked(const wxHtmlLinkInfo
& link
);
96 // Handle HTML navigation forward command in applet
97 virtual void OnHistoryForward();
99 // Handle HTML navigation back command in applet
100 virtual void OnHistoryBack();
102 // Handle messages from the wxAppletManager and other applets
103 virtual void OnMessage(wxEvent
& msg
);
105 // Update the model and menufacturer lists
107 void ReadModelList(bool selectCurrent
);
110 void OnChange(wxCommandEvent
&event
);
113 #endif // __WX_MONITORAPPLET_H