pcbnew: fix Duplicate assertion

Do not assert that the item to be duplicated can be duplicated, just don't
duplicate it. The user can trigger a Duplicate on items that aren't
duplicatable, like field texts - he'll figure out that they can't be duplicated
when they aren't, no need to deliver a scary warning and risk an abort.

TODO: Don't pick up the duplicated selection if none of the items in it were
actually duplicated, it's misleading.
This commit is contained in:
Chris Pavlina 2016-03-18 06:28:11 -04:00
parent d66cc0fedc
commit 2777182a2c
1 changed files with 1 additions and 2 deletions

View File

@ -2708,8 +2708,7 @@ BOARD_ITEM* BOARD::DuplicateAndAddItem( const BOARD_ITEM* aItem,
default:
// Un-handled item for duplication
wxASSERT_MSG( false, "Duplication not supported for items of class "
+ aItem->GetClass() );
new_item = NULL;
break;
}