From: H.G. Muller Date: Sun, 22 Nov 2009 20:15:15 +0000 (-0800) Subject: fix bug in bughouse drop menu X-Git-Tag: master-20091122~3 X-Git-Url: http://winboard.nl/cgi-bin?a=commitdiff_plain;h=3086238e38acd1656c4be07c2a4ca26e5ffdfdc9;p=xboard.git fix bug in bughouse drop menu This patch fixes the bughouse drop menu, which was broken by the new mouse driver, and could no longer drop white Pawns. --- diff --git a/backend.c b/backend.c index 11d447d..dc20c26 100644 --- a/backend.c +++ b/backend.c @@ -5350,7 +5350,7 @@ FinishMove(moveType, fromX, fromY, toX, toY, promoChar) moveType = PromoCharToMoveType(WhiteOnMove(currentMove), promoChar); /* [HGM] convert drag-and-drop piece drops to standard form */ - if( fromX == BOARD_LEFT-2 || fromX == BOARD_RGHT+1) { + if( (fromX == BOARD_LEFT-2 || fromX == BOARD_RGHT+1) && fromY != DROP_RANK ){ moveType = WhiteOnMove(currentMove) ? WhiteDrop : BlackDrop; if(appData.debugMode) fprintf(debugFP, "Drop move %d, curr=%d, x=%d,y=%d, p=%d\n", moveType, currentMove, fromX, fromY, boards[currentMove][fromY][fromX]);