[gnome-chess/mcatanzaro/gtk4] progress
- From: Michael Catanzaro <mcatanzaro src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-chess/mcatanzaro/gtk4] progress
- Date: Thu, 24 Dec 2020 01:18:35 +0000 (UTC)
commit e6baf6ddc43d670a59024f394061c98e7a27add4
Author: Michael Catanzaro <mcatanzaro gnome org>
Date: Wed Dec 23 19:18:51 2020 -0600
progress
src/gnome-chess.vala | 24 ++++++------------------
1 file changed, 6 insertions(+), 18 deletions(-)
---
diff --git a/src/gnome-chess.vala b/src/gnome-chess.vala
index 69fdc63..156fa1b 100644
--- a/src/gnome-chess.vala
+++ b/src/gnome-chess.vala
@@ -2329,7 +2329,7 @@ Copyright © 2015–2016 Sahil Sareen""";
{
if (about_dialog != null)
{
- about_dialog.present ();
+ about_dialog.show ();
return;
}
@@ -2346,15 +2346,12 @@ Copyright © 2015–2016 Sahil Sareen""";
about_dialog.translator_credits = _("translator-credits");
about_dialog.website = "https://wiki.gnome.org/Apps/Chess";
about_dialog.logo_icon_name = "org.gnome.Chess";
-#if 0
- about_dialog.response.connect (about_response_cb);
+ about_dialog.hide_on_close = true;
about_dialog.show ();
-#endif
}
private void run_invalid_pgn_dialog ()
{
-#if 0
var invalid_pgn_dialog = new MessageDialog (window,
DialogFlags.MODAL,
MessageType.ERROR,
@@ -2362,14 +2359,12 @@ Copyright © 2015–2016 Sahil Sareen""";
_("This does not look like a valid PGN game."));
invalid_pgn_dialog.add_button (_("_OK"), ResponseType.OK);
- invalid_pgn_dialog.run ();
- invalid_pgn_dialog.destroy ();
-#endif
+ invalid_pgn_dialog.response.connect (() => invalid_pgn_dialog.destroy ());
+ invalid_pgn_dialog.show ();
}
private void run_invalid_move_dialog (string error_message)
{
-#if 0
var invalid_move_dialog = new MessageDialog (window,
DialogFlags.MODAL,
MessageType.ERROR,
@@ -2377,15 +2372,8 @@ Copyright © 2015–2016 Sahil Sareen""";
error_message);
invalid_move_dialog.add_button (_("_OK"), ResponseType.OK);
- invalid_move_dialog.run ();
- invalid_move_dialog.destroy ();
-#endif
- }
-
- private void about_response_cb (int response_id)
- {
- about_dialog.destroy ();
- about_dialog = null;
+ invalid_move_dialog.response.connect (() => invalid_move_dialog.destroy ());
+ invalid_move_dialog.show ();
}
private void update_pgn_time_remaining ()
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]