[gnome-sudoku/vala-port] Fixed the GLib Critical error related to GLib.Timer
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-sudoku/vala-port] Fixed the GLib Critical error related to GLib.Timer
- Date: Fri, 28 Feb 2014 14:43:28 +0000 (UTC)
commit dcdeea2e45e57b386b58f3bf0dc7cdd3ed973374
Author: Parin Porecha <parinporecha gmail com>
Date: Thu Feb 27 19:17:45 2014 +0530
Fixed the GLib Critical error related to GLib.Timer
.continue() resumes a timer previously stopped with .stop()
But since .stop() is not called anywhere in the code,
the assertion to check that failed and raised the error.
Since we haven't implemented Pause and Resume functions,
and start_game() is meant only for starting a game,
I have removed the timer.continue() call.
When we implement those functions,
timer.stop() and timer.continue() will be used in them
https://bugzilla.gnome.org/show_bug.cgi?id=633464
src/gnome-sudoku.vala | 9 +--------
1 files changed, 1 insertions(+), 8 deletions(-)
---
diff --git a/src/gnome-sudoku.vala b/src/gnome-sudoku.vala
index 18ab851..7fb8a61 100644
--- a/src/gnome-sudoku.vala
+++ b/src/gnome-sudoku.vala
@@ -206,14 +206,7 @@ public class Sudoku : Gtk.Application
game = new SudokuGame (board);
- if (game.timer.elapsed() <= 0.000002)
- {
- game.timer.start ();
- }
- else
- {
- game.timer.continue ();
- }
+ game.timer.start ();
view = new SudokuView (game);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]