[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-commits
Subject:    playground/games/kpicross/src
From:       Jeremy Paul Whiting <jeremy () scitools ! com>
Date:       2008-02-20 14:13:17
Message-ID: 1203516797.250074.16295.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 777418 by whiting:

show 0 hints outside the drawing area

 M  +14 -8     board.cpp  


--- trunk/playground/games/kpicross/src/board.cpp #777417:777418
@@ -146,11 +146,14 @@
             m_hintRows[ row ].append( consecutive );
         }
 
-        if ( numHints > m_maxRowHints )
+        if ( !found ) {
+            m_hintRows[ row ].append( 0 );
+            numHints = 1;
+        }
+
+        if ( numHints > m_maxRowHints ) {
             m_maxRowHints = numHints;
-
-        if ( !found )
-            m_hintRows[ row ].append( 0 );
+        }
     }
 }
 
@@ -182,11 +185,14 @@
             m_hintColumns[ x ].append( consecutive );
         }
 
-        if ( numHints > m_maxColumnHints )
+        if ( !found ) {
+            m_hintColumns[ x ].append( 0 ); //nothing in this columnd
+            numHints = 1;
+        }
+
+        if ( numHints > m_maxColumnHints ) {
             m_maxColumnHints = numHints;
-
-        if ( !found )
-            m_hintColumns[ x ].append( 0 ); //nothing in this columnd
+        }
     }
 }
 
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic