Commit 43d6c685 authored by stambaughw's avatar stambaughw
Browse files

Command ID refactoring and other minor improvements.

* Split out application specific command IDs to prevent unnecessary rebuilding.
* Eliminate duplicate menu and tool bar command IDs.
* Split component library editor and viewer definitions to separate header files.
* More component library and document file merge code.
* A bunch of minor string readability and consistency fixes.
parent dcc3463b
Loading
Loading
Loading
Loading
+0 −18
Original line number Original line Diff line number Diff line
@@ -21,7 +21,6 @@
#include "wx/dataobj.h"
#include "wx/dataobj.h"
#include "wx/clipbrd.h"
#include "wx/clipbrd.h"


#include "id.h"
#include "gestfich.h"
#include "gestfich.h"


#include "3d_viewer.h"
#include "3d_viewer.h"
@@ -30,23 +29,6 @@
/* Tool and button Bitmaps */
/* Tool and button Bitmaps */
#include "bitmaps.h"
#include "bitmaps.h"


enum onrclick_id {
    ID_POPUP_3D_VIEW_START = 2000,
    ID_POPUP_ZOOMIN,
    ID_POPUP_ZOOMOUT,
    ID_POPUP_VIEW_XPOS,
    ID_POPUP_VIEW_XNEG,
    ID_POPUP_VIEW_YPOS,
    ID_POPUP_VIEW_YNEG,
    ID_POPUP_VIEW_ZPOS,
    ID_POPUP_VIEW_ZNEG,
    ID_POPUP_MOVE3D_LEFT,
    ID_POPUP_MOVE3D_RIGHT,
    ID_POPUP_MOVE3D_UP,
    ID_POPUP_MOVE3D_DOWN,
    ID_POPUP_3D_VIEW_END
};



/*
/*
 * Pcb3D_GLCanvas implementation
 * Pcb3D_GLCanvas implementation
+0 −1
Original line number Original line Diff line number Diff line
@@ -18,7 +18,6 @@
#endif
#endif


#include "bitmaps.h"
#include "bitmaps.h"
#include "id.h"


#include "3d_viewer.h"
#include "3d_viewer.h"
#include "trackball.h"
#include "trackball.h"
+0 −3
Original line number Original line Diff line number Diff line
@@ -4,11 +4,8 @@


#include "fctsys.h"
#include "fctsys.h"
#include "macros.h"
#include "macros.h"

#include "bitmaps.h"
#include "bitmaps.h"


#include "id.h"

#include "3d_viewer.h"
#include "3d_viewer.h"




+56 −0
Original line number Original line Diff line number Diff line
@@ -23,12 +23,68 @@


#include "pcbstruct.h"
#include "pcbstruct.h"
#include "3d_struct.h"
#include "3d_struct.h"
#include "id.h"



#define KICAD_DEFAULT_3D_DRAWFRAME_STYLE wxDEFAULT_FRAME_STYLE|wxWANTS_CHARS
#define KICAD_DEFAULT_3D_DRAWFRAME_STYLE wxDEFAULT_FRAME_STYLE|wxWANTS_CHARS




#define LIB3D_PATH wxT("packages3d")
#define LIB3D_PATH wxT("packages3d")


/**
 * Command IDs for the 3D viewer.
 *
 * Please add IDs that are unique to the 3D viewer here and not in the global
 * id.h file.  This will prevent the entire project from being rebuilt when
 * adding new commands to the 3D viewer.
 */
enum id_3dview_frm
{
    ID_START_COMMAND_3D = ID_END_LIST,
    ID_ROTATE3D_X_NEG,
    ID_ROTATE3D_X_POS,
    ID_ROTATE3D_Y_NEG,
    ID_ROTATE3D_Y_POS,
    ID_ROTATE3D_Z_NEG,
    ID_ROTATE3D_Z_POS,
    ID_RELOAD3D_BOARD,
    ID_TOOL_SCREENCOPY_TOCLIBBOARD,
    ID_MOVE3D_LEFT,
    ID_MOVE3D_RIGHT,
    ID_MOVE3D_UP,
    ID_MOVE3D_DOWN,
    ID_MENU3D_BGCOLOR_SELECTION,
    ID_MENU3D_AXIS_ONOFF,
    ID_MENU3D_MODULE_ONOFF,
    ID_MENU3D_UNUSED,
    ID_MENU3D_ZONE_ONOFF,
    ID_MENU3D_DRAWINGS_ONOFF,
    ID_MENU3D_COMMENTS_ONOFF,
    ID_MENU3D_ECO1_ONOFF,
    ID_MENU3D_ECO2_ONOFF,
    ID_END_COMMAND_3D,

    ID_MENU_SCREENCOPY_PNG,
    ID_MENU_SCREENCOPY_JPEG,
    ID_MENU_SCREENCOPY_TOCLIBBOARD,

    ID_POPUP_3D_VIEW_START,
    ID_POPUP_ZOOMIN,
    ID_POPUP_ZOOMOUT,
    ID_POPUP_VIEW_XPOS,
    ID_POPUP_VIEW_XNEG,
    ID_POPUP_VIEW_YPOS,
    ID_POPUP_VIEW_YNEG,
    ID_POPUP_VIEW_ZPOS,
    ID_POPUP_VIEW_ZNEG,
    ID_POPUP_MOVE3D_LEFT,
    ID_POPUP_MOVE3D_RIGHT,
    ID_POPUP_MOVE3D_UP,
    ID_POPUP_MOVE3D_DOWN,
    ID_POPUP_3D_VIEW_END
};


class Pcb3D_GLCanvas;
class Pcb3D_GLCanvas;
class WinEDA3D_DrawFrame;
class WinEDA3D_DrawFrame;
class Info_3D_Visu;
class Info_3D_Visu;
+2 −0
Original line number Original line Diff line number Diff line
@@ -81,6 +81,8 @@ const wxString ModuleFileExtension( wxT( "mod" ) );
const wxString ModuleFileWildcard(
const wxString ModuleFileWildcard(
    _( "Kicad footprint library files (*.mod)|*.mod" )
    _( "Kicad footprint library files (*.mod)|*.mod" )
);
);
const wxString PcbFileWildcard(
    _( "Printed circuit board files (*.brd)|*.brd" ) );


int g_CurrentVersionPCB = 1;
int g_CurrentVersionPCB = 1;


Loading