Diffstat (limited to 'noncore/games/solitaire/patiencecardgame.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/games/solitaire/patiencecardgame.cpp | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/noncore/games/solitaire/patiencecardgame.cpp b/noncore/games/solitaire/patiencecardgame.cpp index fc91b26..1b38072 100644 --- a/noncore/games/solitaire/patiencecardgame.cpp +++ b/noncore/games/solitaire/patiencecardgame.cpp | |||
@@ -185,28 +185,26 @@ bool PatienceCardGame::mousePressCard( Card *card, QPoint p ) | |||
185 | item->setZ(highestZ); | 185 | item->setZ(highestZ); |
186 | highestZ++; | 186 | highestZ++; |
187 | 187 | ||
188 | // Added Code | 188 | // Added Code |
189 | faceDownDealingPile->removeCard(item); | 189 | faceDownDealingPile->removeCard(item); |
190 | faceUpDealingPile->addCardToTop(item); | 190 | faceUpDealingPile->addCardToTop(item); |
191 | item->setCardPile( faceUpDealingPile ); | 191 | item->setCardPile( faceUpDealingPile ); |
192 | 192 | ||
193 | if ( qt_screen->deviceWidth() < 200 ) | 193 | if ( qt_screen->deviceWidth() < 200 ) |
194 | item->flipTo( 30, (int)item->y() ); | 194 | item->flipTo( 30, (int)item->y() ); |
195 | else | 195 | else |
196 | item->flipTo( 35, (int)item->y() ); | 196 | item->flipTo( 35, (int)item->y() ); |
197 | } else { | 197 | } else return FALSE; // <- was missing, caused facedown card to react |
198 | // fix from cmader by tille | 198 | // to clicking, which is wrong |
199 | return false; | ||
200 | } | ||
201 | moving = NULL; | 199 | moving = NULL; |
202 | moved = FALSE; | 200 | moved = FALSE; |
203 | 201 | ||
204 | // move two other cards if we flip three at a time | 202 | // move two other cards if we flip three at a time |
205 | int flipped = 1; | 203 | int flipped = 1; |
206 | QCanvasItemList l = canvas()->collisions( p ); | 204 | QCanvasItemList l = canvas()->collisions( p ); |
207 | for (QCanvasItemList::Iterator it = l.begin(); (it != l.end()) && (flipped != cardsDrawn()); ++it) { | 205 | for (QCanvasItemList::Iterator it = l.begin(); (it != l.end()) && (flipped != cardsDrawn()); ++it) { |
208 | if ( (*it)->rtti() == canvasCardId ) { | 206 | if ( (*it)->rtti() == canvasCardId ) { |
209 | CanvasCard *item = (CanvasCard *)*it; | 207 | CanvasCard *item = (CanvasCard *)*it; |
210 | if (item->animated()) | 208 | if (item->animated()) |
211 | continue; | 209 | continue; |
212 | item->setZ(highestZ); | 210 | item->setZ(highestZ); |