Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
f301b196
Commit
f301b196
authored
Aug 31, 2012
by
jean-pierre charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Modedit: very minor enhancements.
parent
eaf4919e
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
16 additions
and
8 deletions
+16
-8
menubar_modedit.cpp
pcbnew/menubar_modedit.cpp
+7
-2
modedit.cpp
pcbnew/modedit.cpp
+9
-6
No files found.
pcbnew/menubar_modedit.cpp
View file @
f301b196
...
@@ -59,6 +59,12 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
...
@@ -59,6 +59,12 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
// Menu File:
// Menu File:
wxMenu
*
fileMenu
=
new
wxMenu
;
wxMenu
*
fileMenu
=
new
wxMenu
;
// Active library selection
AddMenuItem
(
fileMenu
,
ID_MODEDIT_SELECT_CURRENT_LIB
,
_
(
"Current Library"
),
_
(
"Select active library"
),
KiBitmap
(
open_library_xpm
)
);
fileMenu
->
AppendSeparator
();
// New module
// New module
AddMenuItem
(
fileMenu
,
ID_MODEDIT_NEW_MODULE
,
AddMenuItem
(
fileMenu
,
ID_MODEDIT_NEW_MODULE
,
_
(
"&New Module"
),
_
(
"Create new module"
),
_
(
"&New Module"
),
_
(
"Create new module"
),
...
@@ -90,6 +96,7 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
...
@@ -90,6 +96,7 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
_
(
"&Load Module"
),
_
(
"&Load Module"
),
_
(
"Load a footprint module"
),
_
(
"Load a footprint module"
),
KiBitmap
(
open_document_xpm
)
);
KiBitmap
(
open_document_xpm
)
);
fileMenu
->
AppendSeparator
();
// Save module
// Save module
AddMenuItem
(
fileMenu
,
ID_MODEDIT_SAVE_LIBMODULE
,
AddMenuItem
(
fileMenu
,
ID_MODEDIT_SAVE_LIBMODULE
,
...
@@ -108,8 +115,6 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
...
@@ -108,8 +115,6 @@ void FOOTPRINT_EDIT_FRAME::ReCreateMenuBar()
_
(
"&Export Module"
),
_
(
"&Export Module"
),
_
(
"Save the current loaded module to a file"
),
_
(
"Save the current loaded module to a file"
),
KiBitmap
(
export_module_xpm
)
);
KiBitmap
(
export_module_xpm
)
);
// Separator
fileMenu
->
AppendSeparator
();
fileMenu
->
AppendSeparator
();
// Print
// Print
...
...
pcbnew/modedit.cpp
View file @
f301b196
...
@@ -195,6 +195,9 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
...
@@ -195,6 +195,9 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
case
ID_POPUP_MODEDIT_EDIT_LAYER_CURRENT_EDGE
:
case
ID_POPUP_MODEDIT_EDIT_LAYER_CURRENT_EDGE
:
case
ID_POPUP_MODEDIT_EDIT_LAYER_ALL_EDGE
:
case
ID_POPUP_MODEDIT_EDIT_LAYER_ALL_EDGE
:
case
ID_POPUP_MODEDIT_ENTER_EDGE_WIDTH
:
case
ID_POPUP_MODEDIT_ENTER_EDGE_WIDTH
:
case
ID_POPUP_PCB_DELETE_EDGE
:
case
ID_POPUP_PCB_DELETE_TEXTMODULE
:
case
ID_POPUP_PCB_DELETE_PAD
:
case
ID_POPUP_DELETE_BLOCK
:
case
ID_POPUP_DELETE_BLOCK
:
case
ID_POPUP_PLACE_BLOCK
:
case
ID_POPUP_PLACE_BLOCK
:
case
ID_POPUP_ZOOM_BLOCK
:
case
ID_POPUP_ZOOM_BLOCK
:
...
@@ -285,7 +288,7 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
...
@@ -285,7 +288,7 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
}
}
break
;
break
;
}
}
case
ID_MODEDIT_NEW_MODULE_FROM_WIZARD
:
case
ID_MODEDIT_NEW_MODULE_FROM_WIZARD
:
{
{
Clear_Pcb
(
true
);
Clear_Pcb
(
true
);
...
@@ -293,12 +296,12 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
...
@@ -293,12 +296,12 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
SetCurItem
(
NULL
);
SetCurItem
(
NULL
);
GetScreen
()
->
SetCrossHairPosition
(
wxPoint
(
0
,
0
)
);
GetScreen
()
->
SetCrossHairPosition
(
wxPoint
(
0
,
0
)
);
wxSemaphore
semaphore
(
0
,
1
);
wxSemaphore
semaphore
(
0
,
1
);
FOOTPRINT_WIZARD_FRAME
*
wizard
=
new
FOOTPRINT_WIZARD_FRAME
(
this
,
&
semaphore
);
FOOTPRINT_WIZARD_FRAME
*
wizard
=
new
FOOTPRINT_WIZARD_FRAME
(
this
,
&
semaphore
);
wizard
->
Show
(
true
);
wizard
->
Show
(
true
);
wizard
->
Zoom_Automatique
(
false
);
wizard
->
Zoom_Automatique
(
false
);
while
(
semaphore
.
TryWait
()
==
wxSEMA_BUSY
)
// Wait for viewer closing event
while
(
semaphore
.
TryWait
()
==
wxSEMA_BUSY
)
// Wait for viewer closing event
{
{
wxYield
();
wxYield
();
...
@@ -306,7 +309,7 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
...
@@ -306,7 +309,7 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
}
}
MODULE
*
module
=
wizard
->
GetBuiltFootprint
();
MODULE
*
module
=
wizard
->
GetBuiltFootprint
();
if
(
module
)
// i.e. if create module command not aborted
if
(
module
)
// i.e. if create module command not aborted
{
{
/* Here we should make a copy of the object before adding to board*/
/* Here we should make a copy of the object before adding to board*/
...
@@ -322,8 +325,8 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
...
@@ -322,8 +325,8 @@ void FOOTPRINT_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event )
if
(
GetBoard
()
->
m_Modules
)
if
(
GetBoard
()
->
m_Modules
)
GetBoard
()
->
m_Modules
->
ClearFlags
();
GetBoard
()
->
m_Modules
->
ClearFlags
();
}
}
wizard
->
Destroy
();
wizard
->
Destroy
();
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment