Skip to content
GitLab
Menu
Why GitLab
Pricing
Contact Sales
Explore
Why GitLab
Pricing
Contact Sales
Explore
Sign in
Get free trial
Primary navigation
Search or go to…
Project
kicad
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package registry
Container registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Privacy statement
Keyboard shortcuts
?
What's new
6
Snippets
Groups
Projects
Show more breadcrumbs
Jonathan Haas
kicad
Commits
a677998f
Commit
a677998f
authored
4 years ago
by
Jonathan Haas
Browse files
Options
Downloads
Patches
Plain Diff
Don't select new items after cancelling move following item duplication
Fixes
#7956
parent
9f8127af
No related branches found
No related tags found
No related merge requests found
Pipeline
#274548041
passed
4 years ago
Stage: build
Stage: test
Stage: report
Changes
1
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
pcbnew/tools/edit_tool.cpp
+7
-3
7 additions, 3 deletions
pcbnew/tools/edit_tool.cpp
with
7 additions
and
3 deletions
pcbnew/tools/edit_tool.cpp
+
7
−
3
View file @
a677998f
...
...
@@ -932,7 +932,8 @@ int EDIT_TOOL::doMoveSelection( TOOL_EVENT aEvent, bool aPickReference )
m_toolMgr
->
RunAction
(
PCB_ACTIONS
::
selectionClear
,
true
);
editFrame
->
PopTool
(
tool
);
return
0
;
return
restore_state
?
-
1
:
0
;
}
...
...
@@ -2086,13 +2087,16 @@ int EDIT_TOOL::Duplicate( const TOOL_EVENT& aEvent )
// If items were duplicated, pick them up
// this works well for "dropping" copies around and pushes the commit
TOOL_EVENT
evt
=
PCB_ACTIONS
::
move
.
MakeEvent
();
Move
(
evt
);
bool
move_cancelled
=
Move
(
evt
)
==
-
1
;
// After moving the new items, we need to refresh the group and view flags
m_toolMgr
->
RunAction
(
PCB_ACTIONS
::
selectionClear
,
true
);
if
(
!
is_hover
)
if
(
!
is_hover
&&
!
move_cancelled
)
{
// Do not select new items if they've been deleted again by cancelling Move()
m_toolMgr
->
RunAction
(
PCB_ACTIONS
::
selectItems
,
true
,
&
new_items
);
}
}
return
0
;
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment