]> git.saurik.com Git - wxWidgets.git/blobdiff - src/common/dlgcmn.cpp
A little clarification
[wxWidgets.git] / src / common / dlgcmn.cpp
index 5a83e468893edb2d7bd8dc486d15f7bbd69aac63..8b6e4f619ce8d22cdbba442ec836003cc795b33b 100644 (file)
@@ -17,7 +17,7 @@
 // headers
 // ----------------------------------------------------------------------------
 
-#ifdef __GNUG__
+#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
     #pragma implementation "dialogbase.h"
 #endif
 
@@ -53,6 +53,11 @@ END_EVENT_TABLE()
 WX_DELEGATE_TO_CONTROL_CONTAINER(wxDialogBase)
 #endif
 
+wxDialogBase::wxDialogBase()
+{
+    Init();
+}
+
 void wxDialogBase::Init()
 {
     m_returnCode = 0;
@@ -67,7 +72,7 @@ void wxDialogBase::Init()
 #endif
 }
 
-#if wxUSE_STATTEXT && wxUSE_TEXTCTRL
+#if wxUSE_STATTEXT // && wxUSE_TEXTCTRL
 
 wxSizer *wxDialogBase::CreateTextSizer( const wxString& message )
 {
@@ -164,7 +169,7 @@ wxSizer *wxDialogBase::CreateTextSizer( const wxString& message )
     return box;
 }
 
-#endif // wxUSE_STATTEXT && wxUSE_TEXTCTRL
+#endif // wxUSE_STATTEXT // && wxUSE_TEXTCTRL
 
 #if wxUSE_BUTTON
 
@@ -172,14 +177,9 @@ wxSizer *wxDialogBase::CreateButtonSizer( long flags )
 {
     bool is_pda = (wxSystemSettings::GetScreenType() <= wxSYS_SCREEN_PDA);
     
-    wxBoxSizer *box = NULL;
-    
     // If we have a PDA screen, put yes/no button over 
     // all other buttons, otherwise on the left side.
-    if (is_pda)
-        box = new wxBoxSizer( wxVERTICAL );
-    else
-        box = new wxBoxSizer( wxHORIZONTAL );
+    wxBoxSizer *box = is_pda ? new wxBoxSizer( wxVERTICAL ) : new wxBoxSizer( wxHORIZONTAL );
         
     wxBoxSizer *inner_yes_no = NULL;