mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-10 13:06:59 -04:00
Fixed crash when deleting a card from a non-empty set.
git-svn-id: svn://svn.code.sf.net/p/magicseteditor/code/trunk@396 0fc631ac-6414-0410-93d0-97cfa31319b6
This commit is contained in:
@@ -199,7 +199,8 @@ void CardsPanel::onCommand(int id) {
|
||||
set->actions.add(new AddCardAction(*set));
|
||||
break;
|
||||
case ID_CARD_REMOVE:
|
||||
set->actions.add(new RemoveCardAction(*set, card_list->getCard()));
|
||||
if (card_list->getCard() != nullptr)
|
||||
set->actions.add(new RemoveCardAction(*set, card_list->getCard()));
|
||||
break;
|
||||
case ID_CARD_ROTATE:
|
||||
case ID_CARD_ROTATE_0: case ID_CARD_ROTATE_90: case ID_CARD_ROTATE_180: case ID_CARD_ROTATE_270: {
|
||||
|
||||
Reference in New Issue
Block a user