no changes, just removed whitespace and perfectly useless "/* if */" and the incredible "// variable definition and initialization" and wx version checks unnecessary inside wx itself

git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@57172 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
Vadim Zeitlin
2008-12-07 21:05:30 +00:00
parent b63dc1c140
commit 5829b3034b
2 changed files with 413 additions and 548 deletions

View File

@@ -347,57 +347,44 @@ private:
class WXDLLIMPEXP_ADV wxDataViewColumn: public wxDataViewColumnBase
{
public:
//
// constructors / destructor
//
wxDataViewColumn(wxString const& title, wxDataViewRenderer* renderer, unsigned int model_column, int width=80, wxAlignment align=wxALIGN_CENTER,
int flags=wxDATAVIEW_COL_RESIZABLE);
wxDataViewColumn(wxBitmap const& bitmap, wxDataViewRenderer* renderer, unsigned int model_column, int width=80, wxAlignment align=wxALIGN_CENTER,
int flags=wxDATAVIEW_COL_RESIZABLE);
//
// inherited methods from wxDataViewColumnBase
//
virtual wxAlignment GetAlignment() const
// constructors / destructor
wxDataViewColumn(const wxString& title,
wxDataViewRenderer* renderer,
unsigned int model_column,
int width = wxDVC_DEFAULT_WIDTH,
wxAlignment align = wxALIGN_CENTER,
int flags = wxDATAVIEW_COL_RESIZABLE)
: wxDataViewColumnBase(renderer, model_column),
m_title(title)
{
return this->m_alignment;
}
virtual int GetFlags() const
{
return this->m_flags;
}
virtual int GetMaxWidth() const
{
return this->m_maxWidth;
}
virtual int GetMinWidth() const
{
return this->m_minWidth;
}
virtual wxString GetTitle() const
{
return this->m_title;
}
virtual int GetWidth() const
{
return this->m_width;
Init(width, align, flags);
}
virtual bool IsHidden() const
wxDataViewColumn(const wxBitmap& bitmap,
wxDataViewRenderer* renderer,
unsigned int model_column,
int width = wxDVC_DEFAULT_WIDTH,
wxAlignment align = wxALIGN_CENTER,
int flags = wxDATAVIEW_COL_RESIZABLE)
: wxDataViewColumnBase(bitmap, renderer, model_column)
{
return false; // not implemented
}
virtual bool IsSortOrderAscending() const
{
return this->m_ascending;
Init(width, align, flags);
}
// implement wxHeaderColumnBase pure virtual methods
virtual wxAlignment GetAlignment() const { return m_alignment; }
virtual int GetFlags() const { return m_flags; }
virtual int GetMaxWidth() const { return m_maxWidth; }
virtual int GetMinWidth() const { return m_minWidth; }
virtual wxString GetTitle() const { return m_title; }
virtual int GetWidth() const { return m_width; }
virtual bool IsHidden() const { return false; } // TODO
virtual bool IsSortOrderAscending() const { return m_ascending; }
virtual void SetAlignment(wxAlignment align);
virtual void SetBitmap (wxBitmap const& bitmap);
virtual void SetFlags (int flags);
virtual void SetHidden(bool WXUNUSED(hidden))
{
}
virtual void SetFlags (int flags) { SetIndividualFlags(flags); }
virtual void SetHidden(bool WXUNUSED(hidden)) { } // TODO
virtual void SetMaxWidth (int maxWidth);
virtual void SetMinWidth (int minWidth);
virtual void SetReorderable(bool reorderable);
@@ -407,31 +394,38 @@ public:
virtual void SetTitle (wxString const& title);
virtual void SetWidth (int width);
//
// implementation
//
// implementation only
WXDataBrowserPropertyID GetPropertyID() const
{
return this->m_propertyID;
return m_propertyID;
}
void SetPropertyID(WXDataBrowserPropertyID newID)
{
this->m_propertyID = newID;
m_propertyID = newID;
}
void SetWidthVariable(int NewWidth)
{
this->m_width = NewWidth;
m_width = NewWidth;
}
protected:
private:
//
// variables
//
// common part of all ctors
void Init(int width, wxAlignment align, int flags)
{
m_ascending = true;
m_flags = flags & ~wxDATAVIEW_COL_HIDDEN; // TODO
m_maxWidth = 30000;
m_minWidth = 0;
m_width = width >= 0 ? width : wxDVC_DEFAULT_WIDTH;
m_alignment = align;
}
bool m_ascending; // sorting order
WXDataBrowserPropertyID m_propertyID; // each column is identified by its unique property ID (NOT by the column index)
// each column is identified by its unique property ID (NOT by the column
// index)
WXDataBrowserPropertyID m_propertyID;
int m_flags; // flags for the column
int m_maxWidth; // maximum width for the column
@@ -441,9 +435,6 @@ private:
wxAlignment m_alignment; // column header alignment
wxString m_title; // column title
// wxWidget internal stuff:
DECLARE_DYNAMIC_CLASS_NO_COPY(wxDataViewColumn)
};
// ---------------------------------------------------------

File diff suppressed because it is too large Load Diff