]> git.saurik.com Git - wxWidgets.git/blobdiff - src/propgrid/property.cpp
Add support for stretchable spaces to wxToolBar.
[wxWidgets.git] / src / propgrid / property.cpp
index 6f1dc5408effc54038fb1b7b355c89e78cd7afa8..09f4bc8ba86266680fcf094e64ff5bdba669cf2f 100644 (file)
@@ -277,10 +277,10 @@ void wxPGDefaultRenderer::Render( wxDC& dc, const wxRect& rect,
     {
         if ( flags & Selected )
         {
-            if ( imageWidth > 0 )
+            if ( imageOffset > 0 )
             {
                 imageOffset -= DEFAULT_IMAGE_OFFSET_INCREMENT;
-                imageWidth += wxCC_CUSTOM_IMAGE_MARGIN2 + 4;
+                imageOffset += wxCC_CUSTOM_IMAGE_MARGIN2 + 4;
             }
 
             DrawCaptionSelectionRect( dc,
@@ -1547,9 +1547,10 @@ wxPGCell& wxPGProperty::GetOrCreateCell( unsigned int column )
 }
 
 void wxPGProperty::SetBackgroundColour( const wxColour& colour,
-                                        bool recursively )
+                                        int flags )
 {
     wxPGProperty* firstProp = this;
+    bool recursively = flags & wxPG_RECURSE ? true : false;
 
     //
     // If category is tried to set recursively, skip it and only
@@ -1582,9 +1583,10 @@ void wxPGProperty::SetBackgroundColour( const wxColour& colour,
 }
 
 void wxPGProperty::SetTextColour( const wxColour& colour,
-                                  bool recursively )
+                                  int flags )
 {
     wxPGProperty* firstProp = this;
+    bool recursively = flags & wxPG_RECURSE ? true : false;
 
     //
     // If category is tried to set recursively, skip it and only
@@ -1705,7 +1707,7 @@ wxVariant wxPGProperty::GetAttributesAsList() const
 // Slots of utility flags are NULL
 const unsigned int gs_propFlagToStringSize = 14;
 
-static const wxChar* gs_propFlagToString[gs_propFlagToStringSize] = {
+static const wxChar* const gs_propFlagToString[gs_propFlagToStringSize] = {
     NULL,
     wxT("DISABLED"),
     wxT("HIDDEN"),
@@ -2682,12 +2684,12 @@ wxPGChoiceEntry& wxPGChoices::AddAsSorted( const wxString& label, int value )
 
 // -----------------------------------------------------------------------
 
-void wxPGChoices::Add( const wxChar** labels, const ValArrItem* values )
+void wxPGChoices::Add( const wxChar* const* labels, const ValArrItem* values )
 {
     AllocExclusive();
 
     unsigned int itemcount = 0;
-    const wxChar** p = &labels[0];
+    const wxChar* const* p = &labels[0];
     while ( *p ) { p++; itemcount++; }
 
     unsigned int i;