]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/app.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling, Julian Smart
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
18 #include "wx/window.h"
22 //-----------------------------------------------------------------------------
24 //-----------------------------------------------------------------------------
29 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
33 extern wxApp
*wxTheApp
;
35 //-----------------------------------------------------------------------------
37 //-----------------------------------------------------------------------------
42 //-----------------------------------------------------------------------------
44 //-----------------------------------------------------------------------------
46 #define wxPRINT_WINDOWS 1
47 #define wxPRINT_POSTSCRIPT 2
49 //-----------------------------------------------------------------------------
51 //-----------------------------------------------------------------------------
53 class wxApp
: public wxAppBase
55 DECLARE_DYNAMIC_CLASS(wxApp
)
61 /* override for altering the way wxGTK intializes the GUI
62 * (palette/visual/colorcube). under wxMSW, OnInitGui() does nothing by
63 * default. when overriding this method, the code in it is likely to be
64 * platform dependent, otherwise use OnInit(). */
65 virtual bool OnInitGui();
67 // override base class (pure) virtuals
68 virtual int MainLoop();
69 virtual void ExitMainLoop();
70 virtual bool Initialized();
71 virtual bool Pending();
72 virtual void Dispatch();
74 virtual wxIcon
GetStdIcon(int which
) const;
76 // implementation only from now on
77 void OnIdle( wxIdleEvent
&event
);
78 bool SendIdleEvents();
79 bool SendIdleEvents( wxWindow
* win
);
81 static bool Initialize();
82 static bool InitialzeVisual();
83 static void CleanUp();
87 void ProcessPendingEvents();
89 void DeletePendingObjects();
91 // This can be used to suppress the generation of Idle events.
92 void SuppressIdleEvents(bool arg
= TRUE
) { m_suppressIdleEvents
= arg
; }
93 bool GetSuppressIdleEvents() const { return m_suppressIdleEvents
; }
99 gint m_wakeUpTimerTag
;
101 unsigned char *m_colorCube
;
104 /// Set to TRUE while we are in wxYield().
105 bool m_suppressIdleEvents
;
107 DECLARE_EVENT_TABLE()
110 #endif // __GTKAPPH__