// wxAppTraits: this class defines various configurable aspects of wxApp
// ----------------------------------------------------------------------------
-#if wxUSE_BASE
class WXDLLIMPEXP_BASE wxAppTraitsBase
-#else
-class WXDLLIMPEXP_CORE wxAppTraitsBase
-#endif
{
public:
- // wxAppTraits is an ABC, but we also provide 2 standard implementations of
- // it, one for the console apps and the other for the GUI ones
- static wxAppTraits *CreateConsole();
-#if wxUSE_GUI
- static wxAppTraits *CreateGUI();
-#endif // wxUSE_GUI
-
-
// hooks for creating the global objects, may be overridden by the user
// ------------------------------------------------------------------------
wxAppTraits *wxAppConsole::CreateTraits()
{
- return wxAppTraits::CreateConsole();
+ return new wxConsoleAppTraits;
}
wxAppTraits *wxAppConsole::GetTraits()
#endif // __WXDEBUG__
-wxAppTraits *wxAppTraitsBase::CreateConsole()
-{
- return new wxConsoleAppTraits;
-}
-
// ============================================================================
// global functions implementation
// ============================================================================
wxAppTraits *wxAppBase::CreateTraits()
{
- return wxAppTraits::CreateGUI();
+ return new wxGUIAppTraits;
}
// ----------------------------------------------------------------------------
wxPendingDelete.DeleteObject(object);
}
-// ----------------------------------------------------------------------------
-// wxAppTraits
-// ----------------------------------------------------------------------------
-
-wxAppTraits *wxAppTraitsBase::CreateGUI()
-{
- return new wxGUIAppTraits;
-}
-