]> git.saurik.com Git - wxWidgets.git/blobdiff - src/univ/statusbr.cpp
Added dialog tabbing to wxX11.
[wxWidgets.git] / src / univ / statusbr.cpp
index ab7c9374cf8377887bd0a77e657350c350af54ea..a4a98d952dd7d88a01419895a25cb1bacbabd834 100644 (file)
@@ -35,6 +35,7 @@
 #endif
 
 #include "wx/statusbr.h"
+#include "wx/toplevel.h"
 
 #include "wx/univ/renderer.h"
 
@@ -122,12 +123,15 @@ void wxStatusBarUniv::DoDraw(wxControlRenderer *renderer)
 
         if ( IsExposed(rect) )
         {
+            wxTopLevelWindow *parentTLW = wxDynamicCast(GetParent(), wxTopLevelWindow);
+            
             // the size grip may be drawn only on the last field and only if we
             // have the corresponding style and even then only if we really can
             // resize this frame
             if ( n == m_nFields - 1 &&
                  HasFlag(wxST_SIZEGRIP) &&
-                 GetParent()->HasFlag(wxRESIZE_BORDER) )
+                 GetParent()->HasFlag(wxRESIZE_BORDER) &&
+                 parentTLW && !parentTLW->IsMaximized() )
             {
                 // NB: we use wxCONTROL_ISDEFAULT for this because it doesn't
                 //     have any meaning for the status bar otherwise anyhow
@@ -186,9 +190,8 @@ wxString wxStatusBarUniv::GetStatusText(int number) const
 
 void wxStatusBarUniv::SetFieldsCount(int number, const int *widths)
 {
-    wxStatusBarBase::SetFieldsCount(number, widths);
-
     m_statusText.SetCount(number);
+    wxStatusBarBase::SetFieldsCount(number, widths);
     m_widthsAbs.Empty();
 }