Don't use generic wxListCtrl style for wxListMainWindow.
This resulted in double border around wxListCtrl contents in wxOSX and almost certainly other ports except wxGTK for which we already had an explicit preprocessor check in the generic list control code. Remove it and simply don't use any wxListCtrl-specific styles, including borders, for its main window as it doesn't make any sense. Closes #3701. git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@71724 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -450,10 +450,8 @@ public:
|
|||||||
wxListMainWindow();
|
wxListMainWindow();
|
||||||
wxListMainWindow( wxWindow *parent,
|
wxListMainWindow( wxWindow *parent,
|
||||||
wxWindowID id,
|
wxWindowID id,
|
||||||
const wxPoint& pos = wxDefaultPosition,
|
const wxPoint& pos,
|
||||||
const wxSize& size = wxDefaultSize,
|
const wxSize& size );
|
||||||
long style = 0,
|
|
||||||
const wxString &name = wxT("listctrlmainwindow") );
|
|
||||||
|
|
||||||
virtual ~wxListMainWindow();
|
virtual ~wxListMainWindow();
|
||||||
|
|
||||||
|
@@ -1582,10 +1582,9 @@ wxListMainWindow::wxListMainWindow()
|
|||||||
wxListMainWindow::wxListMainWindow( wxWindow *parent,
|
wxListMainWindow::wxListMainWindow( wxWindow *parent,
|
||||||
wxWindowID id,
|
wxWindowID id,
|
||||||
const wxPoint& pos,
|
const wxPoint& pos,
|
||||||
const wxSize& size,
|
const wxSize& size )
|
||||||
long style,
|
: wxWindow( parent, id, pos, size,
|
||||||
const wxString &name )
|
wxWANTS_CHARS | wxBORDER_NONE )
|
||||||
: wxWindow( parent, id, pos, size, style, name )
|
|
||||||
{
|
{
|
||||||
Init();
|
Init();
|
||||||
|
|
||||||
@@ -4389,12 +4388,7 @@ bool wxGenericListCtrl::Create(wxWindow *parent,
|
|||||||
validator, name ) )
|
validator, name ) )
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
#ifdef __WXGTK__
|
m_mainWin = new wxListMainWindow(this, wxID_ANY, wxPoint(0, 0), size);
|
||||||
style &= ~wxBORDER_MASK;
|
|
||||||
style |= wxBORDER_THEME;
|
|
||||||
#endif
|
|
||||||
|
|
||||||
m_mainWin = new wxListMainWindow( this, wxID_ANY, wxPoint(0, 0), size, style );
|
|
||||||
|
|
||||||
SetTargetWindow( m_mainWin );
|
SetTargetWindow( m_mainWin );
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user