From 41db57c5f0a26e7998af1c3bc2b620ace6fb4a8b Mon Sep 17 00:00:00 2001 From: jean-pierre charras Date: Mon, 11 Jan 2016 09:26:55 +0100 Subject: [PATCH] pcbnew.py: fix error "NameError: name 'UNDEFINED_LAYER' is not defined" when running pcbnew/wxPython, which prevents from openning the Python console. CMakeLists.txt: remove no more used boost libs, and add missing coroutine lib in list. Fix 2 minor compil warnings. --- CMakeLists.txt | 3 +-- common/dialogs/dialog_hotkeys_editor.cpp | 3 +-- pcbnew/class_board.h | 2 +- 3 files changed, 3 insertions(+), 5 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 68f87785b2..136e62b844 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -460,8 +460,7 @@ find_package( Cairo 1.8.8 REQUIRED ) # # Note: Prior to Boost 1.59, the Boost context library is not built when compiling on windows # with GCC. You must patch the Boost sources. -find_package( Boost 1.54.0 REQUIRED COMPONENTS context date_time filesystem iostreams locale - program_options regex system thread ) +find_package( Boost 1.54.0 REQUIRED COMPONENTS context coroutine system thread ) # Include MinGW resource compiler. include( MinGWResourceCompiler ) diff --git a/common/dialogs/dialog_hotkeys_editor.cpp b/common/dialogs/dialog_hotkeys_editor.cpp index a3c274219c..ad0952e4d9 100644 --- a/common/dialogs/dialog_hotkeys_editor.cpp +++ b/common/dialogs/dialog_hotkeys_editor.cpp @@ -60,7 +60,7 @@ HOTKEY_LIST_CTRL::HOTKEY_LIST_CTRL( wxWindow *aParent, const HOTKEYS_SECTIONS& a void HOTKEY_LIST_CTRL::DeselectRow( int aRow ) { - wxASSERT( aRow >= 0 && aRow < m_items.size() ); + wxASSERT( aRow >= 0 && aRow < (int)m_items.size() ); Unselect( m_items[aRow] ); } @@ -112,7 +112,6 @@ void HOTKEY_LIST_CTRL::OnChar( wxKeyEvent& aEvent ) if( exists && data->GetHotkey().m_KeyCode != key ) { wxString tag = data->GetSectionTag(); - HOTKEYS_EDITOR_DIALOG* parent = static_cast( m_parent ); bool canUpdate = ResolveKeyConflicts( key, tag ); if( canUpdate ) diff --git a/pcbnew/class_board.h b/pcbnew/class_board.h index e61062596c..8aaa0f5fb7 100644 --- a/pcbnew/class_board.h +++ b/pcbnew/class_board.h @@ -1219,7 +1219,7 @@ public: * @param aLayer The layer to search. Use -1 for a don't care. * @return VIA* A point a to the VIA object if found, else NULL. */ - VIA* GetViaByPosition( const wxPoint& aPosition, LAYER_ID aLayer = UNDEFINED_LAYER ) const; + VIA* GetViaByPosition( const wxPoint& aPosition, LAYER_ID aLayer = LAYER_ID::UNDEFINED_LAYER ) const; /** * Function GetPad