[gnome-chess] Don't start new game if new game dialog is deleted



commit c05a881f018ac768c5bd18571e3092c28a4f03f3
Author: Michael Catanzaro <mike catanzaro gmail com>
Date:   Tue Jul 9 08:51:38 2013 -0500

    Don't start new game if new game dialog is deleted
    
    Fixup for the previous commit
    
    https://bugzilla.gnome.org/show_bug.cgi?id=703857

 src/gnome-chess.vala |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/src/gnome-chess.vala b/src/gnome-chess.vala
index 8c21cbe..5d4c333 100644
--- a/src/gnome-chess.vala
+++ b/src/gnome-chess.vala
@@ -1081,12 +1081,12 @@ public class Application : Gtk.Application
             var result = dialog.run ();
             dialog.destroy ();
 
-            if (result == Gtk.ResponseType.CANCEL)
+            if (result == Gtk.ResponseType.CANCEL || result == Gtk.ResponseType.DELETE_EVENT)
                 return;
             else if (result == Gtk.ResponseType.YES)
                 save_game (Gtk.Stock.DISCARD, Gtk.Stock.SAVE); /* Your very last chance to save */
             else
-                warn_if_fail (result == Gtk.ResponseType.NO || result == Gtk.ResponseType.DELETE_EVENT);
+                warn_if_fail (result == Gtk.ResponseType.NO);
         }
 
         start_new_game ();


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