[gnome-mines] Start the clock only after placing the mines



commit 3190bf2afee96110ad15bb10016c10396d107830
Author: Robert Roth <robert roth off gmail com>
Date:   Wed Nov 2 09:12:28 2016 +0200

    Start the clock only after placing the mines

 src/minefield.vala |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/src/minefield.vala b/src/minefield.vala
index 08ac6ce..ce0d379 100644
--- a/src/minefield.vala
+++ b/src/minefield.vala
@@ -218,9 +218,6 @@ public class Minefield : Object
 
     public void clear_mine (uint x, uint y)
     {
-        if (!exploded && clock == null)
-            start_clock ();
-
         /* Place mines on first attempt to clear */
         if (!placed_mines)
         {
@@ -228,6 +225,9 @@ public class Minefield : Object
             placed_mines = true;
         }
 
+        if (!exploded && clock == null)
+            start_clock ();
+
         if (locations[x, y].cleared || locations[x, y].flag == FlagType.FLAG)
             return;
 


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]