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
bd529a7c
Commit
bd529a7c
authored
Aug 13, 2009
by
charras
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed in pcbnew: abort function in track creation incompatible with new undo/redo functions
parent
2be6520a
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
9 additions
and
4 deletions
+9
-4
wxPcbStruct.h
include/wxPcbStruct.h
+3
-1
board_undo_redo.cpp
pcbnew/board_undo_redo.cpp
+4
-2
editrack.cpp
pcbnew/editrack.cpp
+2
-1
No files found.
include/wxPcbStruct.h
View file @
bd529a7c
...
@@ -161,8 +161,10 @@ public:
...
@@ -161,8 +161,10 @@ public:
* Put data pointed by List in the previous state, i.e. the state memorised by List
* Put data pointed by List in the previous state, i.e. the state memorised by List
* @param aList = a PICKED_ITEMS_LIST pointer to the list of items to undo/redo
* @param aList = a PICKED_ITEMS_LIST pointer to the list of items to undo/redo
* @param aRedoCommand = a bool: true for redo, false for undo
* @param aRedoCommand = a bool: true for redo, false for undo
* @param aRebuildRatsnet = a bool: true to rebuid ratsnet (normal use), false
* to just retrieve las state (used in abort commands that do not need to rebuild ratsnest)
*/
*/
void
PutDataInPreviousState
(
PICKED_ITEMS_LIST
*
aList
,
bool
aRedoCommand
);
void
PutDataInPreviousState
(
PICKED_ITEMS_LIST
*
aList
,
bool
aRedoCommand
,
bool
aRebuildRatsnet
=
true
);
/** Function GetBoardFromRedoList
/** Function GetBoardFromRedoList
* Redo the last edition:
* Redo the last edition:
* - Save the current board in Undo list
* - Save the current board in Undo list
...
...
pcbnew/board_undo_redo.cpp
View file @
bd529a7c
...
@@ -463,8 +463,10 @@ void WinEDA_PcbFrame::SaveCopyInUndoList( PICKED_ITEMS_LIST& aItemsList,
...
@@ -463,8 +463,10 @@ void WinEDA_PcbFrame::SaveCopyInUndoList( PICKED_ITEMS_LIST& aItemsList,
* Put data pointed by List in the previous state, i.e. the state memorised by List
* Put data pointed by List in the previous state, i.e. the state memorised by List
* @param aList = a PICKED_ITEMS_LIST pointer to the list of items to undo/redo
* @param aList = a PICKED_ITEMS_LIST pointer to the list of items to undo/redo
* @param aRedoCommand = a bool: true for redo, false for undo
* @param aRedoCommand = a bool: true for redo, false for undo
* @param aRebuildRatsnet = a bool: true to rebuid ratsnet (normal use, and default), false
* to just retrieve las state (used in abort commands that do not need to rebuild ratsnest)
*/
*/
void
WinEDA_PcbFrame
::
PutDataInPreviousState
(
PICKED_ITEMS_LIST
*
aList
,
bool
aRedoCommand
)
void
WinEDA_PcbFrame
::
PutDataInPreviousState
(
PICKED_ITEMS_LIST
*
aList
,
bool
aRedoCommand
,
bool
aRebuildRatsnet
)
{
{
BOARD_ITEM
*
item
;
BOARD_ITEM
*
item
;
bool
not_found
=
false
;
bool
not_found
=
false
;
...
@@ -557,7 +559,7 @@ void WinEDA_PcbFrame::PutDataInPreviousState( PICKED_ITEMS_LIST* aList, bool aRe
...
@@ -557,7 +559,7 @@ void WinEDA_PcbFrame::PutDataInPreviousState( PICKED_ITEMS_LIST* aList, bool aRe
wxMessageBox
(
wxT
(
"Incomplete undo/redo operation: some items not found"
)
);
wxMessageBox
(
wxT
(
"Incomplete undo/redo operation: some items not found"
)
);
// Rebuild pointers and rastnest that can be changed.
// Rebuild pointers and rastnest that can be changed.
if
(
reBuild_ratsnest
)
if
(
reBuild_ratsnest
&&
aRebuildRatsnet
)
Compile_Ratsnest
(
NULL
,
true
);
Compile_Ratsnest
(
NULL
,
true
);
}
}
...
...
pcbnew/editrack.cpp
View file @
bd529a7c
...
@@ -54,7 +54,8 @@ static void Exit_Editrack( WinEDA_DrawPanel* Panel, wxDC* DC )
...
@@ -54,7 +54,8 @@ static void Exit_Editrack( WinEDA_DrawPanel* Panel, wxDC* DC )
frame
->
MsgPanel
->
EraseMsgBox
();
frame
->
MsgPanel
->
EraseMsgBox
();
// Clear the undo picker list:
// Undo pending changes (mainly a lock point cretion) and clear the undo picker list:
frame
->
PutDataInPreviousState
(
&
s_ItemsListPicker
,
false
,
false
);
s_ItemsListPicker
.
ClearListAndDeleteItems
();
s_ItemsListPicker
.
ClearListAndDeleteItems
();
// Delete current (new) track
// Delete current (new) track
...
...
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