]> git.saurik.com Git - wxWidgets.git/blame - include/wx/motif/app.h
restored wxPluginLibrary::ms_classes handling code that was removed by mistake
[wxWidgets.git] / include / wx / motif / app.h
CommitLineData
9b6dbb09
JS
1/////////////////////////////////////////////////////////////////////////////
2// Name: app.h
3// Purpose: wxApp class
4// Author: Julian Smart
5// Modified by:
6// Created: 17/09/98
7// RCS-ID: $Id$
8// Copyright: (c) Julian Smart
9// Licence: wxWindows licence
10/////////////////////////////////////////////////////////////////////////////
11
12#ifndef _WX_APP_H_
13#define _WX_APP_H_
14
15#ifdef __GNUG__
83df96d6 16#pragma interface "app.h"
9b6dbb09
JS
17#endif
18
ee31c392
VZ
19// ----------------------------------------------------------------------------
20// headers
21// ----------------------------------------------------------------------------
22
9b6dbb09
JS
23#include "wx/event.h"
24
ee31c392
VZ
25// ----------------------------------------------------------------------------
26// forward declarations
27// ----------------------------------------------------------------------------
28
9b6dbb09
JS
29class WXDLLEXPORT wxFrame;
30class WXDLLEXPORT wxWindow;
72cdf4c9 31class WXDLLEXPORT wxApp;
9b6dbb09
JS
32class WXDLLEXPORT wxKeyEvent;
33class WXDLLEXPORT wxLog;
7e1bcfa8 34class WXDLLEXPORT wxEventLoop;
9ce8d6a2 35class WXDLLEXPORT wxXVisualInfo;
eb6fa4b4 36class wxPerDisplayDataMap;
9b6dbb09 37
ee31c392
VZ
38// ----------------------------------------------------------------------------
39// the wxApp class for Motif - see wxAppBase for more details
40// ----------------------------------------------------------------------------
9b6dbb09 41
ee31c392 42class WXDLLEXPORT wxApp : public wxAppBase
9b6dbb09 43{
83df96d6
JS
44 DECLARE_DYNAMIC_CLASS(wxApp)
45
ee31c392
VZ
46public:
47 wxApp();
7e1bcfa8 48 virtual ~wxApp();
83df96d6 49
ee31c392
VZ
50 // override base class (pure) virtuals
51 // -----------------------------------
83df96d6 52
ee31c392 53 virtual int MainLoop();
e2478fde
VZ
54
55 virtual void Exit();
56
8461e4c2 57 virtual bool Yield(bool onlyIfNeeded = FALSE);
e2478fde 58 virtual void WakeUpIdle(); // implemented in motif/evtloop.cpp
83df96d6 59
ee31c392 60 virtual bool OnInitGui();
83df96d6 61
ee31c392
VZ
62 // implementation from now on
63 // --------------------------
83df96d6 64
9b6dbb09 65protected:
ee31c392 66 bool m_showOnInit;
83df96d6 67
9b6dbb09 68public:
ee31c392 69 // Implementation
05e2b077 70 virtual bool Initialize(int& argc, wxChar **argv);
94826170 71 virtual void CleanUp();
83df96d6 72
ee31c392
VZ
73 // Motif-specific
74 WXAppContext GetAppContext() const { return m_appContext; }
eb6fa4b4 75 WXWidget GetTopLevelWidget();
72cdf4c9 76 WXColormap GetMainColormap(WXDisplay* display);
ee31c392 77 WXDisplay* GetInitialDisplay() const { return m_initialDisplay; }
eb6fa4b4
MB
78
79 void SetTopLevelWidget(WXDisplay* display, WXWidget widget);
80
ee31c392
VZ
81 // This handler is called when a property change event occurs
82 virtual void HandlePropertyChange(WXEvent *event);
9ce8d6a2
MB
83
84 wxXVisualInfo* GetVisualInfo(WXDisplay* display);
85
7e1bcfa8 86private:
ee31c392
VZ
87 // Motif-specific
88 WXAppContext m_appContext;
ee31c392
VZ
89 WXColormap m_mainColormap;
90 WXDisplay* m_initialDisplay;
eb6fa4b4 91 wxPerDisplayDataMap* m_perDisplayData;
9ce8d6a2 92
ee31c392 93 DECLARE_EVENT_TABLE()
9b6dbb09
JS
94};
95
9b6dbb09 96#endif
83df96d6 97// _WX_APP_H_
9b6dbb09 98