Fix crash again
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@56210 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
parent
2a555dcf20
commit
236a34ef3e
@ -389,8 +389,6 @@ class WXDLLIMPEXP_ADV wxDataViewCtrl: public wxDataViewCtrlBase,
|
|||||||
public:
|
public:
|
||||||
wxDataViewCtrl() : wxScrollHelperNative(this)
|
wxDataViewCtrl() : wxScrollHelperNative(this)
|
||||||
{
|
{
|
||||||
//No sorting column at start, I think
|
|
||||||
m_sortingColumn = NULL;
|
|
||||||
Init();
|
Init();
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -400,7 +398,6 @@ public:
|
|||||||
const wxValidator& validator = wxDefaultValidator )
|
const wxValidator& validator = wxDefaultValidator )
|
||||||
: wxScrollHelperNative(this)
|
: wxScrollHelperNative(this)
|
||||||
{
|
{
|
||||||
m_sortingColumn = NULL;
|
|
||||||
Create(parent, id, pos, size, style, validator );
|
Create(parent, id, pos, size, style, validator );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4093,6 +4093,10 @@ void wxDataViewCtrl::Init()
|
|||||||
{
|
{
|
||||||
m_cols.DeleteContents(true);
|
m_cols.DeleteContents(true);
|
||||||
m_notifier = NULL;
|
m_notifier = NULL;
|
||||||
|
|
||||||
|
// No sorting column at start
|
||||||
|
m_sortingColumn = NULL;
|
||||||
|
m_headerArea = NULL;
|
||||||
}
|
}
|
||||||
|
|
||||||
bool wxDataViewCtrl::Create(wxWindow *parent, wxWindowID id,
|
bool wxDataViewCtrl::Create(wxWindow *parent, wxWindowID id,
|
||||||
@ -4102,14 +4106,14 @@ bool wxDataViewCtrl::Create(wxWindow *parent, wxWindowID id,
|
|||||||
if ( (style & wxBORDER_MASK) == 0)
|
if ( (style & wxBORDER_MASK) == 0)
|
||||||
style |= wxBORDER_SUNKEN;
|
style |= wxBORDER_SUNKEN;
|
||||||
|
|
||||||
|
Init();
|
||||||
|
|
||||||
if (!wxControl::Create( parent, id, pos, size,
|
if (!wxControl::Create( parent, id, pos, size,
|
||||||
style | wxScrolledWindowStyle, validator))
|
style | wxScrolledWindowStyle, validator))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
SetInitialSize(size);
|
SetInitialSize(size);
|
||||||
|
|
||||||
Init();
|
|
||||||
|
|
||||||
#ifdef __WXMAC__
|
#ifdef __WXMAC__
|
||||||
MacSetClipChildren( true );
|
MacSetClipChildren( true );
|
||||||
#endif
|
#endif
|
||||||
|
Loading…
Reference in New Issue
Block a user