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
7e60cc53
Commit
7e60cc53
authored
Dec 09, 2013
by
Maciej Suminski
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Comments.
parent
a3909d4f
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
4 deletions
+4
-4
edit_tool.cpp
pcbnew/tools/edit_tool.cpp
+3
-4
edit_tool.h
pcbnew/tools/edit_tool.h
+1
-0
No files found.
pcbnew/tools/edit_tool.cpp
View file @
7e60cc53
...
...
@@ -238,15 +238,15 @@ int EDIT_TOOL::Remove( TOOL_EVENT& aEvent )
// Get a copy of the selected items set
std
::
set
<
BOARD_ITEM
*>
selectedItems
=
m_selectionTool
->
GetSelection
().
items
;
// As we are about to remove items, they have to be removed from the selection
// As we are about to remove items, they have to be removed from the selection
first
m_selectionTool
->
ClearSelection
();
std
::
set
<
BOARD_ITEM
*>::
iterator
it
;
for
(
it
=
selectedItems
.
begin
();
it
!=
selectedItems
.
end
();
++
it
)
remove
(
*
it
);
BOARD
*
board
=
getModel
<
BOARD
>
(
PCB_T
);
// Rebuild list of pads and nets if necessary
BOARD
*
board
=
getModel
<
BOARD
>
(
PCB_T
);
if
(
!
(
board
->
GetStatus
()
&
NET_CODES_OK
)
)
board
->
BuildListOfNets
();
...
...
@@ -276,10 +276,9 @@ void EDIT_TOOL::remove( BOARD_ITEM* aItem )
getView
()
->
Remove
(
&
module
->
Reference
()
);
getView
()
->
Remove
(
&
module
->
Value
()
);
// Module itself is deleted after the switch scope
// Module itself is deleted after the switch scope
is finished
// list of pads is rebuild by BOARD::BuildListOfNets()
// module->ClearFlags(); // TODO is it necessary? clearing ratsnest/list of pads?
// Clear flags to indicate, that the ratsnest, list of nets & pads are not valid anymore
board
->
m_Status_Pcb
=
0
;
}
...
...
pcbnew/tools/edit_tool.h
View file @
7e60cc53
...
...
@@ -102,6 +102,7 @@ private:
///> Flag determining if anything is being dragged right now
bool
m_dragging
;
///> Removes and frees a single BOARD_ITEM.
void
remove
(
BOARD_ITEM
*
aItem
);
///> Sets up handlers for various events
...
...
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