]> git.saurik.com Git - wxWidgets.git/blobdiff - src/generic/grid.cpp
fixed wxString::FromAscii signature
[wxWidgets.git] / src / generic / grid.cpp
index 945a7914bc43a2076602ac37ce35b51a8fff18cb..47fc186875cd1bfe75bf5a38a5d299d0d11fb308 100644 (file)
@@ -4221,6 +4221,7 @@ bool wxGrid::Create(wxWindow *parent, wxWindowID id,
 
     Create();
     SetInitialSize(size);
 
     Create();
     SetInitialSize(size);
+    CalcDimensions();
 
     return true;
 }
 
     return true;
 }
@@ -6953,8 +6954,11 @@ void wxGrid::Refresh(bool eraseb, const wxRect* rect)
 
 void wxGrid::OnSize(wxSizeEvent& WXUNUSED(event))
 {
 
 void wxGrid::OnSize(wxSizeEvent& WXUNUSED(event))
 {
-    // update our children window positions and scrollbars
-    CalcDimensions();
+    if (m_targetWindow != this) // check whether initialisation has been done
+    {
+        // update our children window positions and scrollbars
+        CalcDimensions();
+    }
 }
 
 void wxGrid::OnKeyDown( wxKeyEvent& event )
 }
 
 void wxGrid::OnKeyDown( wxKeyEvent& event )