[gnome-sudoku] Group 'New Puzzle' and 'Clear Board' buttons in a SizeGroup
- From: Parin Porecha <parinporecha src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-sudoku] Group 'New Puzzle' and 'Clear Board' buttons in a SizeGroup
- Date: Tue, 10 Jun 2014 12:12:40 +0000 (UTC)
commit 32a78a58b6126232ad67e216987e6306d8cee193
Author: Parin Porecha <parinporecha gmail com>
Date: Tue Jun 10 21:25:19 2014 +0530
Group 'New Puzzle' and 'Clear Board' buttons in a SizeGroup
https://bugzilla.gnome.org/show_bug.cgi?id=731289
src/gnome-sudoku.vala | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
---
diff --git a/src/gnome-sudoku.vala b/src/gnome-sudoku.vala
index 8950003..d7bcc6c 100644
--- a/src/gnome-sudoku.vala
+++ b/src/gnome-sudoku.vala
@@ -148,6 +148,8 @@ public class Sudoku : Gtk.Application
back_button = (Button) builder.get_object ("back_button");
+ var control_sizegroup = new Gtk.SizeGroup (Gtk.SizeGroupMode.BOTH);
+
var clear_button = new Gtk.Button ();
var clear_label = new Gtk.Label.with_mnemonic (_("_Clear Board"));
clear_label.margin = 10;
@@ -158,6 +160,7 @@ public class Sudoku : Gtk.Application
clear_button.tooltip_text = _("Reset the board to its original state");
clear_button.show_all ();
controls_box.pack_end (clear_button, false, false, 0);
+ control_sizegroup.add_widget (clear_button);
var new_button = new Gtk.Button ();
var new_label = new Gtk.Label.with_mnemonic (_("_New Puzzle"));
@@ -169,6 +172,7 @@ public class Sudoku : Gtk.Application
new_button.tooltip_text = _("Start a new puzzle");
new_button.show_all ();
controls_box.pack_end (new_button, false, false, 0);
+ control_sizegroup.add_widget (new_button);
undo_action = (SimpleAction) lookup_action ("undo");
redo_action = (SimpleAction) lookup_action ("redo");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]