Reworked wxPGCell. It is now reference counted, and therefore much more user friendly, and is used internally as basis for most property colour values instead of separate row text and bg colours.

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56622 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Jaakko Salli
2008-10-31 18:53:37 +00:00
parent 42632bcee1
commit d7e2b52235
11 changed files with 852 additions and 607 deletions

View File

@@ -847,12 +847,6 @@ public:
*/
virtual wxPGEditorDialogAdapter* GetEditorDialog() const;
/**
Returns wxPGCell of given column, @NULL if none. If valid
object is returned, caller will gain its ownership.
*/
wxPGCell* AcquireCell( unsigned int column );
/**
Append a new choice to property's list of choices.
@@ -954,10 +948,9 @@ public:
const wxString& GetBaseName() const;
/**
Returns wxPGCell of given column, @NULL if none. wxPGProperty
will retain ownership of the cell object.
Returns wxPGCell of given column.
*/
wxPGCell* GetCell( unsigned int column ) const;
const wxPGCell& GetCell( unsigned int column ) const;
/**
Returns number of child properties.
@@ -1218,6 +1211,19 @@ public:
*/
void SetAttribute( const wxString& name, wxVariant value );
/**
Sets property's background colour.
@param colour
Background colour to use.
@param recursively
If @true, children are affected recursively, and any categories
are not.
*/
void SetBackgroundColour( const wxColour& colour,
bool recursively = false );
/**
Sets editor for a property.
@@ -1236,10 +1242,8 @@ public:
/**
Sets cell information for given column.
Note that the property takes ownership of given wxPGCell instance.
*/
void SetCell( int column, wxPGCell* cellObj );
void SetCell( int column, const wxPGCell& cell );
/**
Sets new set of choices for property.
@@ -1319,6 +1323,19 @@ public:
*/
void SetParentalType( int flag );
/**
Sets property's text colour.
@param colour
Text colour to use.
@param recursively
If @true, children are affected recursively, and any categories
are not.
*/
void SetTextColour( const wxColour& colour,
bool recursively = false );
/** Sets wxValidator for a property */
void SetValidator( const wxValidator& validator );