mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-04-21 00:21:25 +00:00
Prevent image duplication
Duplicate ancillary clipboard needs to be tested with the existence of an image when pasting Fixes https://gitlab.com/kicad/code/kicad/-/issues/19973
This commit is contained in:
parent
ef49d83bc1
commit
d2f780dfb4
@ -1656,8 +1656,9 @@ int SCH_EDITOR_CONTROL::Paste( const TOOL_EVENT& aEvent )
|
||||
|
||||
SCH_SHEET tempSheet;
|
||||
SCH_SCREEN* tempScreen = new SCH_SCREEN( &m_frame->Schematic() );
|
||||
std::unique_ptr<wxImage> clipImg = GetImageFromClipboard();
|
||||
|
||||
if( std::unique_ptr<wxImage> clipImg = GetImageFromClipboard() )
|
||||
if( !aEvent.IsAction( &ACTIONS::duplicate ) && clipImg )
|
||||
{
|
||||
// Just image data
|
||||
auto bitmap = std::make_unique<SCH_BITMAP>();
|
||||
|
Loading…
Reference in New Issue
Block a user