X-Git-Url: https://git.saurik.com/wxWidgets.git/blobdiff_plain/f6cb92b81f31654a1f401bbd736c1dd555efc4c2..5cbda74b6606482f5286a5599fc60f3f91995a52:/include/wx/osx/dataview.h diff --git a/include/wx/osx/dataview.h b/include/wx/osx/dataview.h index fcb57dead1..e2ca2a2405 100644 --- a/include/wx/osx/dataview.h +++ b/include/wx/osx/dataview.h @@ -60,7 +60,7 @@ public: virtual void SetMaxWidth (int maxWidth); virtual void SetMinWidth (int minWidth); virtual void SetReorderable(bool reorderable); - virtual void SetResizeable (bool resizeable); + virtual void SetResizeable (bool resizable); virtual void SetSortable (bool sortable); virtual void SetSortOrder (bool ascending); virtual void SetTitle (wxString const& title); @@ -95,8 +95,8 @@ private: m_flags = flags & ~wxDATAVIEW_COL_HIDDEN; // TODO m_maxWidth = 30000; m_minWidth = 0; - m_width = width >= 0 ? width : wxDVC_DEFAULT_WIDTH; m_alignment = align; + SetWidth(width); } bool m_ascending; // sorting order @@ -129,18 +129,27 @@ public: { Init(); } - wxDataViewCtrl(wxWindow *parent, wxWindowID id, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, long style = 0, - const wxValidator& validator = wxDefaultValidator) + wxDataViewCtrl(wxWindow *parent, + wxWindowID winid, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = 0, + const wxValidator& validator = wxDefaultValidator, + const wxString& name = wxDataViewCtrlNameStr ) { Init(); - Create(parent, id, pos, size, style, validator ); + Create(parent, winid, pos, size, style, validator, name); } ~wxDataViewCtrl(); - // explicit control creation - bool Create(wxWindow *parent, wxWindowID id, const wxPoint& pos=wxDefaultPosition, const wxSize& size=wxDefaultSize, long style=0, - const wxValidator& validator=wxDefaultValidator); + bool Create(wxWindow *parent, + wxWindowID winid, + const wxPoint& pos = wxDefaultPosition, + const wxSize& size = wxDefaultSize, + long style = 0, + const wxValidator& validator = wxDefaultValidator, + const wxString& name = wxDataViewCtrlNameStr); virtual wxControl* GetMainWindow() // not used for the native implementation { @@ -165,7 +174,6 @@ public: virtual void Expand(const wxDataViewItem& item); virtual bool IsExpanded(const wxDataViewItem & item) const; - virtual unsigned int GetCount() const; virtual wxRect GetItemRect(const wxDataViewItem& item, const wxDataViewColumn* columnPtr) const; virtual wxDataViewItem GetSelection() const; @@ -270,6 +278,9 @@ private: // initializing of local variables: void Init(); + virtual wxDataViewItem DoGetCurrentItem() const; + virtual void DoSetCurrentItem(const wxDataViewItem& item); + // // variables //