Fix putting card stacks into invalid state

Bug: When the cursor is on a foundation stack or on the wastepile stack,
	it is possible to put this stack into an invalid state.

Reason: unmark_cards() should only be called on maneuver stacks since it
	alters the y position of cards.

Fix: Only redraw maneuver stacks on ESC-key action.
This commit is contained in:
Simon Barth 2016-11-18 01:05:09 +01:00
parent 76f0154632
commit fe0b60a799

View File

@ -160,7 +160,7 @@ static void handle_card_movement(struct cursor *cursor) {
erase_cursor(cursor);
cursor->y--;
}
if (marked_cards_count(*origin) > 0) {
if (maneuvre_stack(*origin)) {
erase_stack(*origin);
unmark_cards(*origin);
draw_stack(*origin);