]>
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 /////////////////////////////////////////////////////////////////////////////
10 #ifndef _WX_GTK_APP_H_
11 #define _WX_GTK_APP_H_
13 //-----------------------------------------------------------------------------
15 //-----------------------------------------------------------------------------
17 class WXDLLIMPEXP_CORE wxApp
;
18 class WXDLLIMPEXP_BASE wxLog
;
20 //-----------------------------------------------------------------------------
22 //-----------------------------------------------------------------------------
24 class WXDLLIMPEXP_CORE wxApp
: public wxAppBase
30 /* override for altering the way wxGTK intializes the GUI
31 * (palette/visual/colorcube). under wxMSW, OnInitGui() does nothing by
32 * default. when overriding this method, the code in it is likely to be
33 * platform dependent, otherwise use OnInit(). */
34 virtual bool OnInitGui();
36 // override base class (pure) virtuals
37 virtual bool Yield(bool onlyIfNeeded
= FALSE
);
38 virtual void WakeUpIdle();
40 virtual bool Initialize(int& argc
, wxChar
**argv
);
41 virtual void CleanUp();
43 static bool InitialzeVisual();
46 virtual void OnAssertFailure(const wxChar
*file
,
52 bool IsInAssert() const { return m_isInAssert
; }
55 // GTK-specific methods
56 // -------------------
58 // this can be overridden to return a specific visual to be used for GTK+
59 // instead of the default one (it's used by wxGLApp)
61 // must return XVisualInfo pointer (it is not freed by caller)
62 virtual void *GetXVisualInfo() { return NULL
; }
65 // implementation only from now on
66 // -------------------------------
69 // temporarily disable idle events
70 void SuspendIdleCallback();
72 // This returns the current visual: either that used by wxRootWindow
73 // or the XVisualInfo* for SGI.
74 GdkVisual
*GetGdkVisual();
77 // true if we're inside an assert modal dialog
82 DECLARE_DYNAMIC_CLASS(wxApp
)
86 #endif // _WX_GTK_APP_H_