Update pasted items' parent pointers.
Fixes crashes when trying to manipulate the item after the paste, and weird redraw behaviour with pins. Fixes: lp:1832178 * https://bugs.launchpad.net/kicad/+bug/1832178
This commit is contained in:
parent
9f427da56f
commit
09a3c5b280
|
@ -618,6 +618,7 @@ int LIB_EDIT_TOOL::Paste( const TOOL_EVENT& aEvent )
|
|||
continue;
|
||||
|
||||
LIB_ITEM* newItem = (LIB_ITEM*) item.Clone();
|
||||
newItem->SetParent( part );
|
||||
newItem->SetFlags( IS_NEW | IS_PASTED | SELECTED );
|
||||
|
||||
part->GetDrawItems().push_back( newItem );
|
||||
|
|
Loading…
Reference in New Issue