diff --git a/common/CMakeLists.txt b/common/CMakeLists.txt index f393288c7d..5b0c5d79ce 100644 --- a/common/CMakeLists.txt +++ b/common/CMakeLists.txt @@ -28,7 +28,6 @@ set(COMMON_SRCS block_commande.cpp build_version.cpp class_colors_design_settings.cpp - class_layerchoicebox.cpp class_marker_base.cpp class_plotter.cpp class_undoredo_container.cpp @@ -76,6 +75,7 @@ add_library(common ${COMMON_SRCS}) set(PCB_COMMON_SRCS pcbcommon.cpp footprint_info.cpp + class_layer_box_selector.cpp ../pcbnew/basepcbframe.cpp ../pcbnew/class_board.cpp ../pcbnew/class_board_connected_item.cpp diff --git a/common/build_version.cpp b/common/build_version.cpp index 41813a3d14..dccd1fa756 100644 --- a/common/build_version.cpp +++ b/common/build_version.cpp @@ -6,7 +6,7 @@ #endif #ifndef KICAD_BUILD_VERSION -#define KICAD_BUILD_VERSION "(2011-03-20)" +#define KICAD_BUILD_VERSION "(2011-03-23)" #endif // uncomment this line only when creating a stable version diff --git a/common/class_layerchoicebox.cpp b/common/class_layer_box_selector.cpp similarity index 87% rename from common/class_layerchoicebox.cpp rename to common/class_layer_box_selector.cpp index 850eaaff79..997583a852 100644 --- a/common/class_layerchoicebox.cpp +++ b/common/class_layer_box_selector.cpp @@ -14,13 +14,13 @@ #include #include -#include "class_layerchoicebox.h" +#include "class_layer_box_selector.h" /* class to display a layer list. * */ -WinEDALayerChoiceBox::WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID id, +LAYER_BOX_SELECTOR::LAYER_BOX_SELECTOR( WinEDA_Toolbar* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, int n, const wxString choices[] ) : wxBitmapComboBox( parent, id, wxEmptyString, pos, size, @@ -35,7 +35,7 @@ WinEDALayerChoiceBox::WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID i } -WinEDALayerChoiceBox::WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID id, +LAYER_BOX_SELECTOR::LAYER_BOX_SELECTOR( WinEDA_Toolbar* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, const wxArrayString& choices ) : wxBitmapComboBox( parent, id, wxEmptyString, pos, size, @@ -50,14 +50,14 @@ WinEDALayerChoiceBox::WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID i } -bool WinEDALayerChoiceBox::SetLayersOrdered( bool value ) +bool LAYER_BOX_SELECTOR::SetLayersOrdered( bool value ) { m_layerorder = value; return m_layerorder; } -bool WinEDALayerChoiceBox::SetLayersHotkeys( bool value ) +bool LAYER_BOX_SELECTOR::SetLayersHotkeys( bool value ) { m_layerhotkeys = value; return m_layerhotkeys; @@ -65,21 +65,21 @@ bool WinEDALayerChoiceBox::SetLayersHotkeys( bool value ) // Get Current Item # -int WinEDALayerChoiceBox::GetChoice() +int LAYER_BOX_SELECTOR::GetChoice() { return GetSelection(); } // Get Current Layer -int WinEDALayerChoiceBox::GetLayerSelection() +int LAYER_BOX_SELECTOR::GetLayerSelection() { return (long) GetClientData( GetSelection() ); } // Set Layer # -int WinEDALayerChoiceBox::SetLayerSelection( int layer ) +int LAYER_BOX_SELECTOR::SetLayerSelection( int layer ) { int elements = GetCount(); @@ -104,7 +104,7 @@ int WinEDALayerChoiceBox::SetLayerSelection( int layer ) // Reload the Layers -void WinEDALayerChoiceBox::Resync() +void LAYER_BOX_SELECTOR::Resync() { PCB_BASE_FRAME* pcbFrame = (PCB_BASE_FRAME*) GetParent()->GetParent(); BOARD* board = pcbFrame->GetBoard(); @@ -150,7 +150,7 @@ void WinEDALayerChoiceBox::Resync() } } -void WinEDALayerChoiceBox::ResyncBitmapOnly() +void LAYER_BOX_SELECTOR::ResyncBitmapOnly() { PCB_BASE_FRAME* pcbFrame = (PCB_BASE_FRAME*) GetParent()->GetParent(); BOARD* board = pcbFrame->GetBoard(); @@ -175,6 +175,6 @@ void WinEDALayerChoiceBox::ResyncBitmapOnly() bmpDC.SetPen( *wxBLACK_PEN ); bmpDC.DrawRectangle( 0, 0, layerbmp.GetWidth(), layerbmp.GetHeight() ); - SetItemBitmap(i, layerbmp); + SetItemBitmap(i, layerbmp); } } diff --git a/gerbview/CMakeLists.txt b/gerbview/CMakeLists.txt index 31e1f04177..f198295a5a 100644 --- a/gerbview/CMakeLists.txt +++ b/gerbview/CMakeLists.txt @@ -31,7 +31,6 @@ set(GERBVIEW_SRCS class_gerbview_layer_widget.cpp controle.cpp dcode.cpp - dummy_functions.cpp draw_gerber_screen.cpp events_called_functions.cpp excellon_read_drill_file.cpp diff --git a/gerbview/draw_gerber_screen.cpp b/gerbview/draw_gerber_screen.cpp index 18e06e930a..b6327d94d1 100644 --- a/gerbview/draw_gerber_screen.cpp +++ b/gerbview/draw_gerber_screen.cpp @@ -350,3 +350,21 @@ void GERBVIEW_FRAME::DrawItemsDCodeID( wxDC* aDC, int aDrawMode ) void PCB_SCREEN::ClearUndoORRedoList( UNDO_REDO_CONTAINER&, int ) { } + +/* dummy_functions + * + * There are functions used in some classes. + * they are useful in pcbnew, but have no meaning or are never used + * in cvpcb or gerbview. + * but they must exist because they appear in some classes, and here, no nothing. + */ + +TRACK* Marque_Une_Piste( BOARD* aPcb, + TRACK* aStartSegm, + int* aSegmCount, + int* aTrackLen, + bool aReorder ) +{ + return NULL; +} + diff --git a/gerbview/dummy_functions.cpp b/gerbview/dummy_functions.cpp deleted file mode 100644 index 68fe8b6d0a..0000000000 --- a/gerbview/dummy_functions.cpp +++ /dev/null @@ -1,21 +0,0 @@ -/* dummy_functions.cpp - * - * There are functions used in some classes. - * they are useful in pcbnew, but have no meaning or are never used - * in cvpcb or gerbview. - * but they must exist because they appear in some classes, and here, no nothing. - */ -#include "fctsys.h" - -#include "common.h" -#include "pcbnew.h" - -TRACK* Marque_Une_Piste( BOARD* aPcb, - TRACK* aStartSegm, - int* aSegmCount, - int* aTrackLen, - bool aReorder ) -{ - return NULL; -} - diff --git a/gerbview/gerbview_frame.h b/gerbview/gerbview_frame.h index 77b7d2a4a1..0265c80e70 100644 --- a/gerbview/gerbview_frame.h +++ b/gerbview/gerbview_frame.h @@ -8,7 +8,7 @@ #include "id.h" #include "param_config.h" #include "class_gerbview_layer_widget.h" -#include "class_layerchoicebox.h" +#include "class_layer_box_selector.h" #define NO_AVAILABLE_LAYERS -1 @@ -30,7 +30,7 @@ protected: wxFileHistory m_drillFileHistory; // Auxiliary file history used to store drill files history public: - WinEDALayerChoiceBox* m_SelLayerBox; + LAYER_BOX_SELECTOR* m_SelLayerBox; DCODE_SELECTION_BOX* m_DCodeSelector; // a list box to select the dcode Id to highlight. wxTextCtrl* m_TextInfo; // a wxTextCtrl used to display some info about // gerber data (format..) diff --git a/gerbview/toolbars_gerber.cpp b/gerbview/toolbars_gerber.cpp index 1dcf2be5bb..903b1fe10d 100644 --- a/gerbview/toolbars_gerber.cpp +++ b/gerbview/toolbars_gerber.cpp @@ -11,7 +11,7 @@ #include "gerbview_id.h" #include "hotkeys.h" #include "class_GERBER.h" -#include "class_layerchoicebox.h" +#include "class_layer_box_selector.h" #include "class_DCodeSelectionbox.h" #include "dialog_helpers.h" @@ -69,7 +69,7 @@ void GERBVIEW_FRAME::ReCreateHToolbar( void ) choices.Add( msg ); } - m_SelLayerBox = new WinEDALayerChoiceBox( m_HToolBar, ID_TOOLBARH_GERBVIEW_SELECT_ACTIVE_LAYER, + m_SelLayerBox = new LAYER_BOX_SELECTOR( m_HToolBar, ID_TOOLBARH_GERBVIEW_SELECT_ACTIVE_LAYER, wxDefaultPosition, wxSize( 150, -1 ), choices ); m_HToolBar->AddControl( m_SelLayerBox ); diff --git a/include/class_layerchoicebox.h b/include/class_layer_box_selector.h similarity index 85% rename from include/class_layerchoicebox.h rename to include/class_layer_box_selector.h index 535cfe5ee4..76bc492038 100644 --- a/include/class_layerchoicebox.h +++ b/include/class_layer_box_selector.h @@ -1,5 +1,5 @@ -#ifndef CLASS_LAYERCHOICEBOX_H -#define CLASS_LAYERCHOICEBOX_H 1 +#ifndef CLASS_LAYER_BOX_SELECTOR_H +#define CLASS_LAYER_BOX_SELECTOR_H 1 #include "hotkeys_basic.h" #include @@ -8,18 +8,18 @@ * */ -class WinEDALayerChoiceBox : public wxBitmapComboBox +class LAYER_BOX_SELECTOR : public wxBitmapComboBox { private: bool m_layerhotkeys; bool m_layerorder; public: - WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID id, + LAYER_BOX_SELECTOR( WinEDA_Toolbar* parent, wxWindowID id, const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxDefaultSize, int n = 0, const wxString choices[] = NULL ); - WinEDALayerChoiceBox( WinEDA_Toolbar* parent, wxWindowID id, + LAYER_BOX_SELECTOR( WinEDA_Toolbar* parent, wxWindowID id, const wxPoint& pos, const wxSize& size, const wxArrayString& choices ); @@ -62,4 +62,4 @@ public: HK_SWITCH_LAYER_TO_COMPONENT \ }; -#endif //CLASS_LAYERCHOICEBOX_H +#endif //CLASS_LAYER_BOX_SELECTOR_H diff --git a/include/wxPcbStruct.h b/include/wxPcbStruct.h index dbf959c21c..7032edd22b 100644 --- a/include/wxPcbStruct.h +++ b/include/wxPcbStruct.h @@ -9,7 +9,7 @@ #include "wxstruct.h" #include "base_struct.h" #include "param_config.h" -#include "class_layerchoicebox.h" +#include "class_layer_box_selector.h" #include "richio.h" #ifndef PCB_INTERNAL_UNIT @@ -113,7 +113,7 @@ protected: virtual void unitsChangeRefresh(); public: - WinEDALayerChoiceBox* m_SelLayerBox; // a combo box to display and + LAYER_BOX_SELECTOR* m_SelLayerBox; // a combo box to display and // select active layer WinEDAChoiceBox* m_SelTrackWidthBox; // a combo box to display and // select current track width @@ -332,7 +332,7 @@ public: void ReCreateMicrowaveVToolbar(); void ReCreateOptToolbar(); void ReCreateMenuBar(); - WinEDALayerChoiceBox* ReCreateLayerBox( WinEDA_Toolbar* parent ); + LAYER_BOX_SELECTOR* ReCreateLayerBox( WinEDA_Toolbar* parent ); /** Virtual Function OnModify() * Must be called after a board change diff --git a/packaging/windows/nsis/install.nsi b/packaging/windows/nsis/install.nsi index af7ca0cfb9..8a23abb633 100644 --- a/packaging/windows/nsis/install.nsi +++ b/packaging/windows/nsis/install.nsi @@ -17,7 +17,7 @@ ; General Product Description Definitions !define PRODUCT_NAME "KiCad" -!define PRODUCT_VERSION "2011.03.20" +!define PRODUCT_VERSION "2011.03.23" !define PRODUCT_WEB_SITE "http://iut-tice.ujf-grenoble.fr/kicad/" !define SOURCEFORGE_WEB_SITE "http://kicad.sourceforge.net/" !define COMPANY_NAME "" diff --git a/pcbnew/tool_modedit.cpp b/pcbnew/tool_modedit.cpp index 72eb2b9503..5ddc92748a 100644 --- a/pcbnew/tool_modedit.cpp +++ b/pcbnew/tool_modedit.cpp @@ -13,8 +13,6 @@ #include "pcbnew_id.h" #include "hotkeys.h" -//#include "protos.h" - #ifdef __UNIX__ #define LISTBOX_WIDTH 140 #else diff --git a/pcbnew/tool_pcb.cpp b/pcbnew/tool_pcb.cpp index 803617239e..081e26b718 100644 --- a/pcbnew/tool_pcb.cpp +++ b/pcbnew/tool_pcb.cpp @@ -26,7 +26,7 @@ #include "hotkeys.h" #include "help_common_strings.h" -#include "class_layerchoicebox.h" +#include "class_layer_box_selector.h" #define SEL_LAYER_HELP _( \ "Show active layer selections\nand select layer pair for route and place via" ) @@ -256,7 +256,7 @@ void PCB_EDIT_FRAME::ReCreateHToolbar() m_HToolBar->AddSeparator(); if( m_SelLayerBox == NULL ) - m_SelLayerBox = new WinEDALayerChoiceBox( m_HToolBar, ID_TOOLBARH_PCB_SELECT_LAYER ); + m_SelLayerBox = new LAYER_BOX_SELECTOR( m_HToolBar, ID_TOOLBARH_PCB_SELECT_LAYER ); ReCreateLayerBox( m_HToolBar ); m_HToolBar->AddControl( m_SelLayerBox ); @@ -612,7 +612,7 @@ void PCB_EDIT_FRAME::updateViaSizeSelectBox() } -WinEDALayerChoiceBox* PCB_EDIT_FRAME::ReCreateLayerBox( WinEDA_Toolbar* parent ) +LAYER_BOX_SELECTOR* PCB_EDIT_FRAME::ReCreateLayerBox( WinEDA_Toolbar* parent ) { if( m_SelLayerBox == NULL ) return NULL; diff --git a/version.txt b/version.txt index 497f900bbe..bdbd028719 100644 --- a/version.txt +++ b/version.txt @@ -1,4 +1,4 @@ release version: 2011 mar 17 files (.zip,.tgz): -kicad-2011-03-20 +kicad-2011-03-23