]> git.saurik.com Git - wxWidgets.git/blobdiff - src/propgrid/propgridiface.cpp
simplify Enable()
[wxWidgets.git] / src / propgrid / propgridiface.cpp
index c0e9b5e46ea945c844ee4d0a7f34c0786475ace8..93e44177390513b52cc62be6f9d65c9a8dbf5f85 100644 (file)
@@ -216,7 +216,11 @@ wxPGProperty* wxPropertyGridInterface::GetSelection() const
 
 bool wxPropertyGridInterface::ClearSelection( bool validation )
 {
-    return DoClearSelection(validation, wxPG_SEL_DONT_SEND_EVENT);
+    bool res = DoClearSelection(validation, wxPG_SEL_DONT_SEND_EVENT);
+    wxPropertyGrid* pg = GetPropertyGrid();
+    if ( pg )
+        pg->Refresh();
+    return res;
 }
 
 // -----------------------------------------------------------------------
@@ -346,6 +350,7 @@ void wxPropertyGridInterface::ClearModifiedStatus()
         if ( !page ) break;
 
         page->DoGetRoot()->SetFlagRecursively(wxPG_PROP_MODIFIED, false);
+        page->m_anyModified = false;
 
         pageIndex++;
     }
@@ -648,22 +653,22 @@ bool wxPropertyGridInterface::SetPropertyMaxLength( wxPGPropArg id, int maxLen )
 void
 wxPropertyGridInterface::SetPropertyBackgroundColour( wxPGPropArg id,
                                                       const wxColour& colour,
-                                                      bool recursively )
+                                                      int flags )
 {
     wxPG_PROP_ARG_CALL_PROLOG()
-    p->SetBackgroundColour( colour, recursively );
-    RefreshProperty( p );
+    p->SetBackgroundColour(colour, flags);
+    RefreshProperty(p);
 }
 
 // -----------------------------------------------------------------------
 
 void wxPropertyGridInterface::SetPropertyTextColour( wxPGPropArg id,
                                                      const wxColour& colour,
-                                                     bool recursively )
+                                                     int flags )
 {
     wxPG_PROP_ARG_CALL_PROLOG()
-    p->SetTextColour( colour, recursively );
-    RefreshProperty( p );
+    p->SetTextColour(colour, flags);
+    RefreshProperty(p);
 }
 
 // -----------------------------------------------------------------------