gnome-games r9026 - trunk/aisleriot/rules
- From: vpovirk svn gnome org
- To: svn-commits-list gnome org
- Subject: gnome-games r9026 - trunk/aisleriot/rules
- Date: Thu, 9 Apr 2009 04:32:14 +0000 (UTC)
Author: vpovirk
Date: Thu Apr 9 04:32:14 2009
New Revision: 9026
URL: http://svn.gnome.org/viewvc/gnome-games?rev=9026&view=rev
Log:
aisleriot: do not allow no-op drops in Plait
This fixes a test failure (see bug 569936).
Modified:
trunk/aisleriot/rules/plait.scm
Modified: trunk/aisleriot/rules/plait.scm
==============================================================================
--- trunk/aisleriot/rules/plait.scm (original)
+++ trunk/aisleriot/rules/plait.scm Thu Apr 9 04:32:14 2009
@@ -272,7 +272,8 @@
#f))
(define (droppable? start-slot card-list end-slot)
- (cond ((or (free? end-slot) (edge? end-slot)) (and
+ (cond ((= start-slot end-slot) #f)
+ ((or (free? end-slot) (edge? end-slot)) (and
(= (length card-list) 1)
(not (and (= start-slot plait)
(free? end-slot)))
@@ -281,7 +282,8 @@
(else #f)))
(define (button-released start-slot card-list end-slot)
- (cond ((free? end-slot) (move-to-cell start-slot card-list end-slot))
+ (cond ((= start-slot end-slot) #f)
+ ((free? end-slot) (move-to-cell start-slot card-list end-slot))
((home? end-slot) (and
(move-to-home card-list end-slot)
(plait-to-edge start-slot)))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]