Convert pasted objects to current unit and DeMorgan variant.
Fixes: lp:1797183 * https://bugs.launchpad.net/kicad/+bug/1797183
This commit is contained in:
parent
5c726744b6
commit
3de04e184b
|
@ -496,7 +496,19 @@ void LIB_EDIT_FRAME::InitBlockPasteInfos()
|
||||||
// (only the copy, the new instances will be appended to the part once the items are placed)
|
// (only the copy, the new instances will be appended to the part once the items are placed)
|
||||||
block.GetItems().CopyList( m_clipboard.GetItems() );
|
block.GetItems().CopyList( m_clipboard.GetItems() );
|
||||||
|
|
||||||
// Set the pate reference point
|
// Set block items to the current unit & DeMorgan variant
|
||||||
|
for( size_t i = 0; i < m_clipboard.GetItems().GetCount(); ++i )
|
||||||
|
{
|
||||||
|
LIB_ITEM* item = dynamic_cast<LIB_ITEM*>( m_clipboard.GetItem( i ) );
|
||||||
|
|
||||||
|
if( item )
|
||||||
|
{
|
||||||
|
item->SetUnit( m_unit );
|
||||||
|
item->SetConvert( m_convert );
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Set the paste reference point
|
||||||
block.SetLastCursorPosition( m_clipboard.GetLastCursorPosition() );
|
block.SetLastCursorPosition( m_clipboard.GetLastCursorPosition() );
|
||||||
m_canvas->SetMouseCaptureCallback( DrawMovingBlockOutlines );
|
m_canvas->SetMouseCaptureCallback( DrawMovingBlockOutlines );
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue