]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/app.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling, Julian Smart
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
13 #if defined(__GNUG__) && !defined(__APPLE__)
20 //-----------------------------------------------------------------------------
22 //-----------------------------------------------------------------------------
27 //-----------------------------------------------------------------------------
29 //-----------------------------------------------------------------------------
31 class wxApp
: public wxAppBase
37 /* override for altering the way wxGTK intializes the GUI
38 * (palette/visual/colorcube). under wxMSW, OnInitGui() does nothing by
39 * default. when overriding this method, the code in it is likely to be
40 * platform dependent, otherwise use OnInit(). */
41 virtual bool OnInitGui();
43 // override base class (pure) virtuals
44 virtual int MainLoop();
45 virtual void ExitMainLoop();
46 virtual bool Initialized();
47 virtual bool Pending();
48 virtual void Dispatch();
52 virtual bool Yield(bool onlyIfNeeded
= FALSE
);
53 virtual bool ProcessIdle();
54 virtual void WakeUpIdle();
56 // implementation only from now on
57 void OnIdle( wxIdleEvent
&event
);
58 bool SendIdleEvents();
59 bool SendIdleEvents( wxWindow
* win
);
61 static bool Initialize();
62 static bool InitialzeVisual();
63 static void CleanUp();
65 void DeletePendingObjects();
68 virtual void OnAssert(const wxChar
*file
, int line
, const wxChar
*cond
, const wxChar
*msg
);
70 bool IsInAssert() const { return m_isInAssert
; }
77 gint m_wakeUpTimerTag
;
79 unsigned char *m_colorCube
;
81 // Used by the the wxGLApp and wxGLCanvas class for GL-based X visual
82 // selection; this is actually an XVisualInfo*
84 // This returns the current visual: either that used by wxRootWindow
85 // or the XVisualInfo* for SGI.
86 GdkVisual
*GetGdkVisual();
89 // true if we're inside an assert modal dialog
94 bool CallInternalIdle( wxWindow
* win
);
96 DECLARE_DYNAMIC_CLASS(wxApp
)
100 int WXDLLEXPORT
wxEntry( int argc
, char *argv
[] );
102 #endif // __GTKAPPH__