MacOSX: problems with cvpcb after multiline patch:

1) OSX compiler is really choosy (class_components_listbox.cpp)
2) Old OSX code maked an endless loop (listboxes.cpp)
This commit is contained in:
marco. 2012-11-19 22:34:25 +01:00
parent 2aa27122b0
commit b5302db70e
3 changed files with 5 additions and 7 deletions

View File

@ -17,7 +17,7 @@
COMPONENTS_LISTBOX::COMPONENTS_LISTBOX( CVPCB_MAINFRAME* parent, wxWindowID id,
const wxPoint& loc, const wxSize& size,
int nbitems, wxString choice[] ) :
ITEMS_LISTBOX_BASE( parent, id, loc, size, ~wxLC_SINGLE_SEL)
ITEMS_LISTBOX_BASE( parent, id, loc, size, LISTB_STYLE&(~wxLC_SINGLE_SEL))
{
}
@ -85,12 +85,10 @@ void COMPONENTS_LISTBOX::SetSelection( unsigned index, bool State )
if( (index >= 0) && (GetCount() > 0) )
{
#ifndef __WXMAC__
Select( index, State );
#endif
EnsureVisible( index );
#ifdef __WXMAC__
Refresh();
Update();
#endif
}
}

View File

@ -19,6 +19,9 @@
#define FILTERFOOTPRINTKEY "FilterFootprint"
#define LISTB_STYLE wxSUNKEN_BORDER | wxLC_NO_HEADER | \
wxLC_REPORT | wxLC_VIRTUAL
#include <netlist_reader.h>
typedef boost::ptr_vector< COMPONENT_INFO > COMPONENT_LIST;

View File

@ -18,9 +18,6 @@
* Not directly used: the 2 list boxes actually used are derived from it
******************************************************************************/
#define LISTB_STYLE wxSUNKEN_BORDER | wxLC_NO_HEADER | \
wxLC_REPORT | wxLC_VIRTUAL
ITEMS_LISTBOX_BASE::ITEMS_LISTBOX_BASE( CVPCB_MAINFRAME* aParent, wxWindowID aId,
const wxPoint& aLocation, const wxSize& aSize,
long aStyle) :