1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: Various data
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart and Markus Holzem
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
13 #pragma implementation "data.h"
16 // For compilers that support precompilation, includes "wx.h".
17 #include "wx/wxprec.h"
27 #include "wx/prntbase.h"
29 #define _MAXPATHLEN 500
31 // Useful buffer, initialized in wxCommonInit
32 char *wxBuffer
= NULL
;
35 wxWindowList wxTopLevelWindows
;
37 // List of windows pending deletion
38 wxList WXDLLEXPORT wxPendingDelete
;
40 // List of events pending processing
42 wxList wxPendingEvents
;
43 wxCriticalSection wxPendingEventsLocker
;
46 // Current cursor, in order to hang on to
47 // cursor handle when setting the cursor globally
48 wxCursor
*g_globalCursor
= NULL
;
50 // Message Strings for Internationalization
51 char **wx_msg_str
= (char**)NULL
;
53 // Custom OS version, as optionally placed in wx.ini/.wxrc
54 // Currently this can be Win95, Windows, Win32s, WinNT.
55 // For some systems, you can't tell until run-time what services you
56 // have. See wxGetOsVersion, which uses this string if present.
57 char *wxOsVersion
= NULL
;
62 wxBrushList
*wxTheBrushList
= NULL
;
63 wxPenList
*wxThePenList
= NULL
;
64 wxFontList
*wxTheFontList
= NULL
;
65 wxBitmapList
*wxTheBitmapList
= NULL
;
67 wxColourDatabase
*wxTheColourDatabase
= NULL
;
70 wxFont
*wxNORMAL_FONT
;
72 wxFont
*wxITALIC_FONT
;
80 wxPen
*wxTRANSPARENT_PEN
;
81 wxPen
*wxBLACK_DASHED_PEN
;
83 wxPen
*wxMEDIUM_GREY_PEN
;
84 wxPen
*wxLIGHT_GREY_PEN
;
86 wxBrush
*wxBLUE_BRUSH
;
87 wxBrush
*wxGREEN_BRUSH
;
88 wxBrush
*wxWHITE_BRUSH
;
89 wxBrush
*wxBLACK_BRUSH
;
90 wxBrush
*wxTRANSPARENT_BRUSH
;
91 wxBrush
*wxCYAN_BRUSH
;
93 wxBrush
*wxGREY_BRUSH
;
94 wxBrush
*wxMEDIUM_GREY_BRUSH
;
95 wxBrush
*wxLIGHT_GREY_BRUSH
;
103 wxColour
*wxLIGHT_GREY
;
105 wxCursor
*wxSTANDARD_CURSOR
= NULL
;
106 wxCursor
*wxHOURGLASS_CURSOR
= NULL
;
107 wxCursor
*wxCROSS_CURSOR
= NULL
;
110 wxAcceleratorTable wxNullAcceleratorTable
;
111 wxBitmap wxNullBitmap
;
113 wxCursor wxNullCursor
;
116 wxPalette wxNullPalette
;
118 wxColour wxNullColour
;
120 // Default window names
121 const char *wxButtonNameStr
= "button";
122 const char *wxCanvasNameStr
= "canvas";
123 const char *wxCheckBoxNameStr
= "check";
124 const char *wxChoiceNameStr
= "choice";
125 const char *wxComboBoxNameStr
= "comboBox";
126 const char *wxDialogNameStr
= "dialog";
127 const char *wxFrameNameStr
= "frame";
128 const char *wxGaugeNameStr
= "gauge";
129 const char *wxStaticBoxNameStr
= "groupBox";
130 const char *wxListBoxNameStr
= "listBox";
131 const char *wxStaticTextNameStr
= "message";
132 const char *wxStaticBitmapNameStr
= "message";
133 const char *wxMultiTextNameStr
= "multitext";
134 const char *wxPanelNameStr
= "panel";
135 const char *wxRadioBoxNameStr
= "radioBox";
136 const char *wxRadioButtonNameStr
= "radioButton";
137 const char *wxBitmapRadioButtonNameStr
= "radioButton";
138 const char *wxScrollBarNameStr
= "scrollBar";
139 const char *wxSliderNameStr
= "slider";
140 const char *wxStaticNameStr
= "static";
141 const char *wxTextCtrlWindowNameStr
= "textWindow";
142 const char *wxTextCtrlNameStr
= "text";
143 const char *wxVirtListBoxNameStr
= "virtListBox";
144 const char *wxButtonBarNameStr
= "buttonbar";
145 const char *wxEnhDialogNameStr
= "Shell";
146 const char *wxToolBarNameStr
= "toolbar";
147 const char *wxStatusLineNameStr
= "status_line";
148 const char *wxEmptyString
= "";
149 const char *wxGetTextFromUserPromptStr
= "Input Text";
150 const char *wxMessageBoxCaptionStr
= "Message";
151 const char *wxFileSelectorPromptStr
= "Select a file";
152 const char *wxFileSelectorDefaultWildcardStr
= "*.*";
153 const char *wxInternalErrorStr
= "wxWindows Internal Error";
154 const char *wxFatalErrorStr
= "wxWindows Fatal Error";
155 const char *wxTreeCtrlNameStr
= "treeCtrl";
158 const char *wxFloatToStringStr
= "%.2f";
159 const char *wxDoubleToStringStr
= "%.2f";
162 const char *wxUserResourceStr
= "TEXT";
165 #if wxUSE_SHARED_LIBRARY
167 * For wxWindows to be made into a dynamic library (e.g. Sun),
168 * all IMPLEMENT_... macros must be in one place.
169 * But normally, the definitions are in the appropriate places.
172 // Hand-coded IMPLEMENT... macro for wxObject (define static data)
173 wxClassInfo
wxObject::classwxObject("wxObject", NULL
, NULL
, sizeof(wxObject
), NULL
);
174 wxClassInfo
*wxClassInfo::first
= NULL
;
175 wxClassInfo
wxClassInfo::classTable(wxKEY_STRING
);
177 #include "wx/button.h"
178 #include "wx/bmpbuttn.h"
179 IMPLEMENT_DYNAMIC_CLASS(wxButton
, wxControl
)
180 IMPLEMENT_DYNAMIC_CLASS(wxBitmapButton
, wxButton
)
182 #include "wx/checkbox.h"
183 IMPLEMENT_DYNAMIC_CLASS(wxCheckBox
, wxControl
)
184 IMPLEMENT_DYNAMIC_CLASS(wxBitmapCheckBox
, wxCheckBox
)
186 #include "wx/choice.h"
187 IMPLEMENT_DYNAMIC_CLASS(wxChoice
, wxControl
)
190 #include "wx/clipbrd.h"
191 IMPLEMENT_DYNAMIC_CLASS(wxClipboard
, wxObject
)
192 IMPLEMENT_ABSTRACT_CLASS(wxClipboardClient
, wxObject
)
196 #include "wx/combobox.h"
197 IMPLEMENT_DYNAMIC_CLASS(wxComboBox
, wxControl
)
201 #include "wx/dcmemory.h"
202 #include "wx/dcclient.h"
203 #include "wx/dcscreen.h"
204 IMPLEMENT_ABSTRACT_CLASS(wxDC
, wxObject
)
205 IMPLEMENT_DYNAMIC_CLASS(wxWindowDC
, wxDC
)
206 IMPLEMENT_DYNAMIC_CLASS(wxPaintDC
, wxWindowDC
)
207 IMPLEMENT_DYNAMIC_CLASS(wxClientDC
, wxWindowDC
)
208 IMPLEMENT_DYNAMIC_CLASS(wxScreenDC
, wxWindowDC
)
209 IMPLEMENT_DYNAMIC_CLASS(wxMemoryDC
, wxDC
)
211 #if defined(__WXMSW__)
212 #include "wx/dcprint.h"
213 IMPLEMENT_CLASS(wxPrinterDC
, wxDC
)
216 #include "wx/dialog.h"
217 IMPLEMENT_DYNAMIC_CLASS(wxDialog
, wxWindow
)
219 #include "wx/frame.h"
220 IMPLEMENT_DYNAMIC_CLASS(wxFrame
, wxWindow
)
223 IMPLEMENT_DYNAMIC_CLASS(wxMDIParentFrame
, wxFrame
)
224 IMPLEMENT_DYNAMIC_CLASS(wxMDIChildFrame
, wxFrame
)
225 IMPLEMENT_DYNAMIC_CLASS(wxMDIClientWindow
, wxWindow
)
227 #include "wx/cmndata.h"
228 IMPLEMENT_DYNAMIC_CLASS(wxColourData
, wxObject
)
229 IMPLEMENT_DYNAMIC_CLASS(wxFontData
, wxObject
)
230 IMPLEMENT_DYNAMIC_CLASS(wxPrintData
, wxObject
)
232 #include "wx/colordlg.h"
233 #include "wx/fontdlg.h"
235 #if !defined(__WXMSW__) || wxUSE_GENERIC_DIALOGS_IN_MSW
236 #include "wx/generic/colordlg.h"
237 #include "wx/generic/fontdlg.h"
238 IMPLEMENT_DYNAMIC_CLASS(wxGenericColourDialog
, wxDialog
)
239 IMPLEMENT_DYNAMIC_CLASS(wxGenericFontDialog
, wxDialog
)
242 // X defines wxColourDialog to be wxGenericColourDialog
244 IMPLEMENT_DYNAMIC_CLASS(wxColourDialog
, wxDialog
)
245 IMPLEMENT_DYNAMIC_CLASS(wxFontDialog
, wxDialog
)
248 #include "wx/gdicmn.h"
250 #include "wx/brush.h"
252 #include "wx/palette.h"
254 #include "wx/cursor.h"
256 IMPLEMENT_DYNAMIC_CLASS(wxColour
, wxObject
)
257 IMPLEMENT_CLASS(wxColourDatabase
, wxList
)
258 IMPLEMENT_DYNAMIC_CLASS(wxFontList
, wxList
)
259 IMPLEMENT_DYNAMIC_CLASS(wxPenList
, wxList
)
260 IMPLEMENT_DYNAMIC_CLASS(wxBrushList
, wxList
)
261 IMPLEMENT_DYNAMIC_CLASS(wxBitmapList
, wxList
)
265 IMPLEMENT_DYNAMIC_CLASS(wxPoint, wxObject)
266 IMPLEMENT_DYNAMIC_CLASS(wxRealPoint, wxObject)
271 IMPLEMENT_DYNAMIC_CLASS(wxHashTable
, wxObject
)
273 #include "wx/helpbase.h"
274 IMPLEMENT_CLASS(wxHelpControllerBase
, wxObject
)
279 #include "wx/msw/helpwin.h"
280 IMPLEMENT_DYNAMIC_CLASS(wxWinHelpController
, wxHelpControllerBase
)
283 // Generic wxHelp controller
284 IMPLEMENT_CLASS(wxXLPHelpController
, wxHelpControllerBase
)
287 IMPLEMENT_CLASS(wxXLPHelpClient
, wxDDEClient
)
288 IMPLEMENT_CLASS(wxXLPHelpConnection
, wxDDEConnection
)
290 IMPLEMENT_CLASS(wxXLPHelpClient
, wxTCPClient
)
291 IMPLEMENT_CLASS(wxXLPHelpConnection
, wxTCPConnection
)
296 IMPLEMENT_DYNAMIC_CLASS(wxString
, wxObject
)
299 IMPLEMENT_DYNAMIC_CLASS(wxNode
, wxObject
)
300 IMPLEMENT_DYNAMIC_CLASS(wxList
, wxObject
)
301 IMPLEMENT_DYNAMIC_CLASS(wxStringList
, wxList
)
303 #if wxUSE_PRINTING_ARCHITECTURE
304 #include "wx/print.h"
305 IMPLEMENT_DYNAMIC_CLASS(wxPrintDialog
, wxDialog
)
306 IMPLEMENT_DYNAMIC_CLASS(wxPrinterBase
, wxObject
)
307 IMPLEMENT_DYNAMIC_CLASS(wxPostScriptPrinter
, wxPrinterBase
)
308 IMPLEMENT_DYNAMIC_CLASS(wxWindowsPrinter
, wxPrinterBase
)
309 IMPLEMENT_ABSTRACT_CLASS(wxPrintout
, wxObject
)
310 IMPLEMENT_CLASS(wxPreviewCanvas
, wxWindow
)
311 IMPLEMENT_CLASS(wxPreviewControlBar
, wxWindow
)
312 IMPLEMENT_CLASS(wxPreviewFrame
, wxFrame
)
313 IMPLEMENT_CLASS(wxPrintPreviewBase
, wxObject
)
314 IMPLEMENT_CLASS(wxPostScriptPrintPreview
, wxPrintPreviewBase
)
315 IMPLEMENT_CLASS(wxWindowsPrintPreview
, wxPrintPreviewBase
)
316 IMPLEMENT_CLASS(wxGenericPrintDialog
, wxDialog
)
317 IMPLEMENT_CLASS(wxGenericPrintSetupDialog
, wxDialog
)
322 IMPLEMENT_DYNAMIC_CLASS(wxPostScriptDC
, wxDC
)
323 IMPLEMENT_DYNAMIC_CLASS(wxPrintSetupData
, wxObject
)
324 IMPLEMENT_DYNAMIC_CLASS(wxPageSetupData
, wxObject
)
327 IMPLEMENT_DYNAMIC_CLASS(wxPrintPaperType
, wxObject
)
328 IMPLEMENT_DYNAMIC_CLASS(wxPrintPaperDatabase
, wxList
)
330 #if wxUSE_WX_RESOURCES
331 #include "wx/resource.h"
332 IMPLEMENT_DYNAMIC_CLASS(wxItemResource
, wxObject
)
333 IMPLEMENT_DYNAMIC_CLASS(wxResourceTable
, wxHashTable
)
336 #include "wx/event.h"
337 IMPLEMENT_DYNAMIC_CLASS(wxEvtHandler
, wxObject
)
338 IMPLEMENT_ABSTRACT_CLASS(wxEvent
, wxObject
)
339 IMPLEMENT_DYNAMIC_CLASS(wxCommandEvent
, wxEvent
)
340 IMPLEMENT_DYNAMIC_CLASS(wxNotifyEvent
, wxCommandEvent
)
341 IMPLEMENT_DYNAMIC_CLASS(wxScrollEvent
, wxCommandEvent
)
342 IMPLEMENT_DYNAMIC_CLASS(wxMouseEvent
, wxEvent
)
343 IMPLEMENT_DYNAMIC_CLASS(wxKeyEvent
, wxEvent
)
344 IMPLEMENT_DYNAMIC_CLASS(wxSizeEvent
, wxEvent
)
345 IMPLEMENT_DYNAMIC_CLASS(wxPaintEvent
, wxEvent
)
346 IMPLEMENT_DYNAMIC_CLASS(wxEraseEvent
, wxEvent
)
347 IMPLEMENT_DYNAMIC_CLASS(wxMoveEvent
, wxEvent
)
348 IMPLEMENT_DYNAMIC_CLASS(wxFocusEvent
, wxEvent
)
349 IMPLEMENT_DYNAMIC_CLASS(wxCloseEvent
, wxEvent
)
350 IMPLEMENT_DYNAMIC_CLASS(wxShowEvent
, wxEvent
)
351 IMPLEMENT_DYNAMIC_CLASS(wxMaximizeEvent
, wxEvent
)
352 IMPLEMENT_DYNAMIC_CLASS(wxIconizeEvent
, wxEvent
)
353 IMPLEMENT_DYNAMIC_CLASS(wxMenuEvent
, wxEvent
)
354 IMPLEMENT_DYNAMIC_CLASS(wxJoystickEvent
, wxEvent
)
355 IMPLEMENT_DYNAMIC_CLASS(wxDropFilesEvent
, wxEvent
)
356 IMPLEMENT_DYNAMIC_CLASS(wxActivateEvent
, wxEvent
)
357 IMPLEMENT_DYNAMIC_CLASS(wxInitDialogEvent
, wxEvent
)
358 IMPLEMENT_DYNAMIC_CLASS(wxSysColourChangedEvent
, wxEvent
)
359 IMPLEMENT_DYNAMIC_CLASS(wxIdleEvent
, wxEvent
)
360 IMPLEMENT_DYNAMIC_CLASS(wxUpdateUIEvent
, wxEvent
)
361 IMPLEMENT_DYNAMIC_CLASS(wxProcessEvent
, wxEvent
)
363 #include "wx/utils.h"
364 IMPLEMENT_DYNAMIC_CLASS(wxPathList
, wxList
)
366 // IMPLEMENT_DYNAMIC_CLASS(wxRect, wxObject)
368 #include "wx/process.h"
369 IMPLEMENT_DYNAMIC_CLASS(wxProcess
, wxEvtHandler
)
373 IMPLEMENT_DYNAMIC_CLASS(wxDate
, wxObject
)
376 #if wxUSE_DOC_VIEW_ARCHITECTURE
377 #include "wx/docview.h"
378 //IMPLEMENT_ABSTRACT_CLASS(wxDocItem, wxObject)
379 IMPLEMENT_ABSTRACT_CLASS(wxDocument
, wxEvtHandler
)
380 IMPLEMENT_ABSTRACT_CLASS(wxView
, wxEvtHandler
)
381 IMPLEMENT_ABSTRACT_CLASS(wxDocTemplate
, wxObject
)
382 IMPLEMENT_DYNAMIC_CLASS(wxDocManager
, wxEvtHandler
)
383 IMPLEMENT_CLASS(wxDocChildFrame
, wxFrame
)
384 IMPLEMENT_CLASS(wxDocParentFrame
, wxFrame
)
385 #if wxUSE_PRINTING_ARCHITECTURE
386 IMPLEMENT_DYNAMIC_CLASS(wxDocPrintout
, wxPrintout
)
388 IMPLEMENT_CLASS(wxCommand
, wxObject
)
389 IMPLEMENT_DYNAMIC_CLASS(wxCommandProcessor
, wxObject
)
390 IMPLEMENT_DYNAMIC_CLASS(wxFileHistory
, wxObject
)
393 #if wxUSE_CONSTRAINTS
394 #include "wx/layout.h"
395 IMPLEMENT_DYNAMIC_CLASS(wxIndividualLayoutConstraint
, wxObject
)
396 IMPLEMENT_DYNAMIC_CLASS(wxLayoutConstraints
, wxObject
)
397 IMPLEMENT_DYNAMIC_CLASS(wxSizer
, wxObject
)
398 IMPLEMENT_DYNAMIC_CLASS(wxRowColSizer
, wxSizer
)
402 #include "wx/tbarbase.h"
403 IMPLEMENT_DYNAMIC_CLASS(wxToolBarTool
, wxObject
)
404 IMPLEMENT_DYNAMIC_CLASS(wxToolBarBase
, wxControl
)
406 #include "wx/tbarsmpl.h"
407 IMPLEMENT_DYNAMIC_CLASS(wxToolBarSimple
, wxToolBarBase
)
410 #include "wx/tbarmsw.h"
411 IMPLEMENT_DYNAMIC_CLASS(wxToolBarMSW
, wxToolBarBase
)
413 #include "wx/tbar95.h"
414 IMPLEMENT_DYNAMIC_CLASS(wxToolBar95
, wxToolBarBase
)
421 #include "wx/sckaddr.h"
423 IMPLEMENT_DYNAMIC_CLASS(wxIPV4address
, wxSockAddress
)
425 IMPLEMENT_DYNAMIC_CLASS(wxIPV6address
, wxSockAddress
)
428 IMPLEMENT_DYNAMIC_CLASS(wxUNIXaddress
, wxSockAddress
)
431 #include "wx/socket.h"
433 IMPLEMENT_CLASS(wxSocketBase
, wxEvtHandler
)
434 IMPLEMENT_CLASS(wxSocketClient
, wxSocketBase
)
435 IMPLEMENT_CLASS(wxSocketServer
, wxSocketBase
)
436 IMPLEMENT_CLASS(wxSocketHandler
, wxObject
)
437 IMPLEMENT_DYNAMIC_CLASS(wxSocketEvent
, wxEvent
)
441 IMPLEMENT_CLASS(wxProtoInfo
, wxObject
)
442 IMPLEMENT_CLASS(wxURL
, wxObject
)
444 #include "wx/protocol/http.h"
446 IMPLEMENT_DYNAMIC_CLASS(wxHTTP
, wxProtocol
)
447 IMPLEMENT_PROTOCOL(wxHTTP
, "http", "80", TRUE
)
449 #include "wx/protocol/ftp.h"
451 IMPLEMENT_DYNAMIC_CLASS(wxFTP
, wxProtocol
)
452 IMPLEMENT_PROTOCOL(wxFTP
, "ftp", "21", TRUE
)
454 #include "wx/protocol/sckfile.h"
456 IMPLEMENT_DYNAMIC_CLASS(wxFileProto
, wxProtocol
)
457 IMPLEMENT_PROTOCOL(wxFileProto
, "file", NULL
, FALSE
)
459 #include "wx/sckipc.h"
461 IMPLEMENT_DYNAMIC_CLASS(wxTCPServer
, wxServerBase
)
462 IMPLEMENT_DYNAMIC_CLASS(wxTCPClient
, wxClientBase
)
463 IMPLEMENT_DYNAMIC_CLASS(wxTCPConnection
, wxConnectionBase
)
467 #include "wx/statusbr.h"
469 IMPLEMENT_DYNAMIC_CLASS(wxStatusBar
, wxWindow
)
471 BEGIN_EVENT_TABLE(wxStatusBar
, wxWindow
)
472 EVT_PAINT(wxStatusBar::OnPaint
)
473 EVT_SYS_COLOUR_CHANGED(wxStatusBar::OnSysColourChanged
)
478 IMPLEMENT_DYNAMIC_CLASS(wxTime
, wxObject
)
481 #if !USE_GNU_WXSTRING
482 #include "wx/string.h"
483 IMPLEMENT_DYNAMIC_CLASS(wxString
, wxObject
)
487 IMPLEMENT_DYNAMIC_CLASS(wxXColormap
, wxObject
)
488 IMPLEMENT_DYNAMIC_CLASS(wxXFont
, wxObject
)
489 IMPLEMENT_DYNAMIC_CLASS(wxXCursor
, wxObject
)
491 IMPLEMENT_DYNAMIC_CLASS(wxFont
, wxGDIObject
)
492 IMPLEMENT_DYNAMIC_CLASS(wxPalette
, wxGDIObject
)
493 IMPLEMENT_DYNAMIC_CLASS(wxPen
, wxGDIObject
)
494 IMPLEMENT_DYNAMIC_CLASS(wxBrush
, wxGDIObject
)
495 IMPLEMENT_DYNAMIC_CLASS(wxIcon
, wxBitmap
)
496 IMPLEMENT_DYNAMIC_CLASS(wxCursor
, wxBitmap
)
497 IMPLEMENT_DYNAMIC_CLASS(wxBitmap
, wxGDIObject
)
498 IMPLEMENT_DYNAMIC_CLASS(wxMask
, wxObject
)
500 // This will presumably be implemented on other platforms too
502 IMPLEMENT_DYNAMIC_CLASS(wxBitmapHandler
, wxObject
)
503 IMPLEMENT_DYNAMIC_CLASS(wxBMPResourceHandler
, wxBitmapHandler
)
504 IMPLEMENT_DYNAMIC_CLASS(wxBMPFileHandler
, wxBitmapHandler
)
505 IMPLEMENT_DYNAMIC_CLASS(wxXPMFileHandler
, wxBitmapHandler
)
506 IMPLEMENT_DYNAMIC_CLASS(wxXPMDataHandler
, wxBitmapHandler
)
507 IMPLEMENT_DYNAMIC_CLASS(wxICOFileHandler
, wxBitmapHandler
)
508 IMPLEMENT_DYNAMIC_CLASS(wxICOResourceHandler
, wxBitmapHandler
)
511 #include "wx/statbox.h"
512 IMPLEMENT_DYNAMIC_CLASS(wxStaticBox
, wxControl
)
516 IMPLEMENT_CLASS(wxServerBase
, wxObject
)
517 IMPLEMENT_CLASS(wxClientBase
, wxObject
)
518 IMPLEMENT_CLASS(wxConnectionBase
, wxObject
)
520 IMPLEMENT_DYNAMIC_CLASS(wxDDEServer
, wxServerBase
)
521 IMPLEMENT_DYNAMIC_CLASS(wxDDEClient
, wxClientBase
)
522 IMPLEMENT_CLASS(wxDDEConnection
, wxConnectionBase
)
525 IMPLEMENT_ABSTRACT_CLASS(wxControl
, wxWindow
)
527 #include "wx/listbox.h"
528 IMPLEMENT_DYNAMIC_CLASS(wxListBox
, wxControl
)
530 #include "wx/checklst.h"
531 IMPLEMENT_DYNAMIC_CLASS(wxCheckListBox
, wxListBox
)
533 IMPLEMENT_DYNAMIC_CLASS(wxApp
, wxEvtHandler
)
536 IMPLEMENT_DYNAMIC_CLASS(wxMenu
, wxEvtHandler
)
537 IMPLEMENT_DYNAMIC_CLASS(wxMenuItem
, wxObject
)
538 IMPLEMENT_DYNAMIC_CLASS(wxMenuBar
, wxEvtHandler
)
540 #include "wx/stattext.h"
541 #include "wx/statbmp.h"
542 IMPLEMENT_DYNAMIC_CLASS(wxStaticText
, wxControl
)
543 IMPLEMENT_DYNAMIC_CLASS(wxStaticBitmap
, wxControl
)
546 #include "wx/metafile.h"
547 IMPLEMENT_DYNAMIC_CLASS(wxMetaFile
, wxObject
)
548 IMPLEMENT_ABSTRACT_CLASS(wxMetaFileDC
, wxDC
)
551 #include "wx/radiobox.h"
552 #include "wx/radiobut.h"
553 IMPLEMENT_DYNAMIC_CLASS(wxRadioBox
, wxControl
)
555 IMPLEMENT_DYNAMIC_CLASS(wxRadioButton
, wxControl
)
556 // IMPLEMENT_DYNAMIC_CLASS(wxBitmapRadioButton, wxRadioButton)
558 #include "wx/scrolbar.h"
559 IMPLEMENT_DYNAMIC_CLASS(wxScrollBar
, wxControl
)
561 #if WXWIN_COMPATIBILITY
562 BEGIN_EVENT_TABLE(wxScrollBar
, wxControl
)
563 EVT_SCROLL(wxScrollBar::OnScroll
)
567 #include "wx/slider.h"
568 IMPLEMENT_DYNAMIC_CLASS(wxSlider
, wxControl
)
570 #if WXWIN_COMPATIBILITY
571 BEGIN_EVENT_TABLE(wxSlider
, wxControl
)
572 EVT_SCROLL(wxSlider::OnScroll
)
576 #include "wx/timer.h"
577 IMPLEMENT_ABSTRACT_CLASS(wxTimer
, wxObject
)
579 #include "wx/textctrl.h"
580 IMPLEMENT_DYNAMIC_CLASS(wxTextCtrl
, wxControl
)
582 #include "wx/window.h"
583 IMPLEMENT_DYNAMIC_CLASS(wxWindow
, wxEvtHandler
)
585 #include "wx/scrolwin.h"
586 IMPLEMENT_DYNAMIC_CLASS(wxScrolledWindow
, wxWindow
)
588 #include "wx/panel.h"
589 IMPLEMENT_DYNAMIC_CLASS(wxPanel
, wxWindow
)
591 #include "wx/msgbxdlg.h"
592 #include "wx/textdlg.h"
593 #include "wx/filedlg.h"
594 #include "wx/dirdlg.h"
595 #include "wx/choicdlg.h"
597 #if !defined(__WXMSW__) || wxUSE_GENERIC_DIALOGS_IN_MSW
598 #include "wx/generic/msgdlgg.h"
599 IMPLEMENT_CLASS(wxGenericMessageDialog
, wxDialog
)
602 IMPLEMENT_CLASS(wxTextEntryDialog
, wxDialog
)
603 IMPLEMENT_CLASS(wxSingleChoiceDialog
, wxDialog
)
604 IMPLEMENT_CLASS(wxFileDialog
, wxDialog
)
605 IMPLEMENT_CLASS(wxDirDialog
, wxDialog
)
608 IMPLEMENT_CLASS(wxMessageDialog
)
613 #include "../../contrib/xmgauge/gauge.h"
615 #include "wx_gauge.h"
616 IMPLEMENT_DYNAMIC_CLASS(wxGauge
, wxControl
)
620 IMPLEMENT_DYNAMIC_CLASS(wxGenericGrid
, wxPanel
)
622 ///// Event tables (also must be in one, statically-linked file for shared libraries)
624 // This is the base, wxEvtHandler 'bootstrap' code which is expanded manually here
625 const wxEventTable
*wxEvtHandler::GetEventTable() const { return &wxEvtHandler::sm_eventTable
; }
627 const wxEventTable
wxEvtHandler::sm_eventTable
=
628 { NULL
, &wxEvtHandler::sm_eventTableEntries
[0] };
630 const wxEventTableEntry
wxEvtHandler::sm_eventTableEntries
[] = { { 0, 0, 0, NULL
} };
632 BEGIN_EVENT_TABLE(wxFrame
, wxWindow
)
633 EVT_ACTIVATE(wxFrame::OnActivate
)
634 EVT_SIZE(wxFrame::OnSize
)
635 EVT_MENU_HIGHLIGHT_ALL(wxFrame::OnMenuHighlight
)
636 EVT_SYS_COLOUR_CHANGED(wxFrame::OnSysColourChanged
)
637 EVT_IDLE(wxFrame::OnIdle
)
638 EVT_CLOSE(wxFrame::OnCloseWindow
)
641 BEGIN_EVENT_TABLE(wxDialog
, wxPanel
)
642 EVT_BUTTON(wxID_OK
, wxDialog::OnOK
)
643 EVT_BUTTON(wxID_APPLY
, wxDialog::OnApply
)
644 EVT_BUTTON(wxID_CANCEL
, wxDialog::OnCancel
)
645 EVT_CHAR_HOOK(wxDialog::OnCharHook
)
646 EVT_SYS_COLOUR_CHANGED(wxDialog::OnSysColourChanged
)
647 EVT_CLOSE(wxDialog::OnCloseWindow
)
650 BEGIN_EVENT_TABLE(wxWindow
, wxEvtHandler
)
651 EVT_CHAR(wxWindow::OnChar
)
652 EVT_SIZE(wxWindow::Size
)
653 EVT_ERASE_BACKGROUND(wxWindow::OnEraseBackground
)
654 EVT_SYS_COLOUR_CHANGED(wxWindow::OnSysColourChanged
)
655 EVT_INIT_DIALOG(wxWindow::OnInitDialog
)
656 EVT_IDLE(wxWindow::OnIdle
)
659 BEGIN_EVENT_TABLE(wxScrolledWindow
, wxWindow
)
660 EVT_SCROLL(wxScrolledWindow::OnScroll
)
661 EVT_SIZE(wxScrolledWindow::OnSize
)
662 EVT_PAINT(wxScrolledWindow::OnPaint
)
665 BEGIN_EVENT_TABLE(wxPanel
, wxWindow
)
666 EVT_SYS_COLOUR_CHANGED(wxPanel::OnSysColourChanged
)
669 BEGIN_EVENT_TABLE(wxTextCtrl
, wxControl
)
670 EVT_CHAR(wxTextCtrl::OnChar
)
671 EVT_DROP_FILES(wxTextCtrl::OnDropFiles
)
672 EVT_ERASE_BACKGROUND(wxTextCtrl::OnEraseBackground
)
676 BEGIN_EVENT_TABLE(wxMDIParentWindow
, wxFrame
)
677 EVT_SIZE(wxMDIParentWindow::OnSize
)
678 EVT_ACTIVATE(wxMDIParentWindow::OnActivate
)
679 EVT_SYS_COLOUR_CHANGED(wxMDIParentWindow::OnSysColourChanged
)
682 BEGIN_EVENT_TABLE(wxMDIClientWindow
, wxWindow
)
683 EVT_SCROLL(wxMDIClientWindow::OnScroll
)
687 BEGIN_EVENT_TABLE(wxToolBarBase
, wxControl
)
688 EVT_SCROLL(wxToolBarBase::OnScroll
)
689 EVT_SIZE(wxToolBarBase::OnSize
)
690 EVT_IDLE(wxToolBarBase::OnIdle
)
693 BEGIN_EVENT_TABLE(wxToolBarSimple
, wxToolBarBase
)
694 EVT_SIZE(wxToolBarSimple::OnSize
)
695 EVT_PAINT(wxToolBarSimple::OnPaint
)
696 EVT_KILL_FOCUS(wxToolBarSimple::OnKillFocus
)
697 EVT_MOUSE_EVENTS(wxToolBarSimple::OnMouseEvent
)
701 BEGIN_EVENT_TABLE(wxToolBarMSW
, wxToolBarBase
)
702 EVT_SIZE(wxToolBarMSW::OnSize
)
703 EVT_PAINT(wxToolBarMSW::OnPaint
)
704 EVT_MOUSE_EVENTS(wxToolBarMSW::OnMouseEvent
)
707 BEGIN_EVENT_TABLE(wxToolBar95
, wxToolBarBase
)
708 EVT_SIZE(wxToolBar95::OnSize
)
709 EVT_PAINT(wxToolBar95::OnPaint
)
710 EVT_KILL_FOCUS(wxToolBar95::OnKillFocus
)
711 EVT_MOUSE_EVENTS(wxToolBar95::OnMouseEvent
)
712 EVT_SYS_COLOUR_CHANGED(wxToolBar95::OnSysColourChanged
)
716 BEGIN_EVENT_TABLE(wxGenericGrid
, wxPanel
)
717 EVT_SIZE(wxGenericGrid::OnSize
)
718 EVT_PAINT(wxGenericGrid::OnPaint
)
719 EVT_MOUSE_EVENTS(wxGenericGrid::OnMouseEvent
)
720 EVT_TEXT(wxGRID_TEXT_CTRL
, wxGenericGrid::OnText
)
721 EVT_COMMAND_SCROLL(wxGRID_HSCROLL
, wxGenericGrid::OnGridScroll
)
722 EVT_COMMAND_SCROLL(wxGRID_VSCROLL
, wxGenericGrid::OnGridScroll
)
725 BEGIN_EVENT_TABLE(wxControl
, wxWindow
)
726 EVT_ERASE_BACKGROUND(wxControl::OnEraseBackground
)
729 #if !defined(__WXMSW__) || wxUSE_GENERIC_DIALOGS_IN_MSW
730 BEGIN_EVENT_TABLE(wxGenericMessageDialog
, wxDialog
)
731 EVT_BUTTON(wxID_YES
, wxGenericMessageDialog::OnYes
)
732 EVT_BUTTON(wxID_NO
, wxGenericMessageDialog::OnNo
)
733 EVT_BUTTON(wxID_CANCEL
, wxGenericMessageDialog::OnCancel
)
736 BEGIN_EVENT_TABLE(wxGenericColourDialog
, wxDialog
)
737 EVT_BUTTON(wxID_ADD_CUSTOM
, wxGenericColourDialog::OnAddCustom
)
738 EVT_SLIDER(wxID_RED_SLIDER
, wxGenericColourDialog::OnRedSlider
)
739 EVT_SLIDER(wxID_GREEN_SLIDER
, wxGenericColourDialog::OnGreenSlider
)
740 EVT_SLIDER(wxID_BLUE_SLIDER
, wxGenericColourDialog::OnBlueSlider
)
741 EVT_PAINT(wxGenericColourDialog::OnPaint
)
742 EVT_MOUSE_EVENTS(wxGenericColourDialog::OnMouseEvent
)
745 BEGIN_EVENT_TABLE(wxGenericFontDialog
, wxDialog
)
746 EVT_CHECKBOX(wxID_FONT_UNDERLINE
, wxGenericFontDialog::OnChangeFont
)
747 EVT_CHOICE(wxID_FONT_STYLE
, wxGenericFontDialog::OnChangeFont
)
748 EVT_CHOICE(wxID_FONT_WEIGHT
, wxGenericFontDialog::OnChangeFont
)
749 EVT_CHOICE(wxID_FONT_FAMILY
, wxGenericFontDialog::OnChangeFont
)
750 EVT_CHOICE(wxID_FONT_COLOUR
, wxGenericFontDialog::OnChangeFont
)
751 EVT_CHOICE(wxID_FONT_SIZE
, wxGenericFontDialog::OnChangeFont
)
752 EVT_PAINT(wxGenericFontDialog::OnPaint
)
755 BEGIN_EVENT_TABLE(wxGenericPrintDialog
, wxDialog
)
756 EVT_BUTTON(wxID_OK
, wxGenericPrintDialog::OnOK
)
757 EVT_BUTTON(wxPRINTID_SETUP
, wxGenericPrintDialog::OnSetup
)
758 EVT_RADIOBOX(wxPRINTID_RANGE
, wxGenericPrintDialog::OnRange
)
763 BEGIN_EVENT_TABLE(wxTextEntryDialog
, wxDialog
)
764 EVT_BUTTON(wxID_OK
, wxTextEntryDialog::OnOK
)
767 BEGIN_EVENT_TABLE(wxSingleChoiceDialog
, wxDialog
)
768 EVT_BUTTON(wxID_OK
, wxSingleChoiceDialog::OnOK
)
771 #include "wx/prntbase.h"
773 BEGIN_EVENT_TABLE(wxPrintAbortDialog
, wxDialog
)
774 EVT_BUTTON(wxID_CANCEL
, wxPrintAbortDialog::OnCancel
)
777 BEGIN_EVENT_TABLE(wxPreviewControlBar
, wxWindow
)
778 EVT_BUTTON(wxID_PREVIEW_CLOSE
, wxPreviewControlBar::OnClose
)
779 EVT_BUTTON(wxID_PREVIEW_PRINT
, wxPreviewControlBar::OnPrint
)
780 EVT_BUTTON(wxID_PREVIEW_PREVIOUS
, wxPreviewControlBar::OnPrevious
)
781 EVT_BUTTON(wxID_PREVIEW_NEXT
, wxPreviewControlBar::OnNext
)
782 EVT_CHOICE(wxID_PREVIEW_ZOOM
, wxPreviewControlBar::OnZoom
)
788 const wxSize
wxDefaultSize(-1, -1);
789 const wxPoint
wxDefaultPosition(-1, -1);