[gnome-games/applygsoc2009] Add the side-grid to display the peer's puzzle
- From: Pablo Castellano <pablog src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-games/applygsoc2009] Add the side-grid to display the peer's puzzle
- Date: Wed, 8 Sep 2010 17:43:12 +0000 (UTC)
commit 77ebdec65bb1e600fded394c9ab33938e284aa03
Author: Pablo Castellano <pablog src gnome org>
Date: Wed Sep 8 18:31:17 2010 +0200
Add the side-grid to display the peer's puzzle
Use Glade to pack the UI
gnome-sudoku/data/main.ui | 49 ++++++++++++++++++++++++++++++++++++-----
gnome-sudoku/src/lib/main.py | 7 +++--
2 files changed, 47 insertions(+), 9 deletions(-)
---
diff --git a/gnome-sudoku/data/main.ui b/gnome-sudoku/data/main.ui
index eb52842..f1d707b 100644
--- a/gnome-sudoku/data/main.ui
+++ b/gnome-sudoku/data/main.ui
@@ -14,7 +14,7 @@
<object class="GtkToggleAction" id="ToggleTracker">
<property name="label">_Track additions</property>
<property name="tooltip">Mark new additions in a separate color so you can keep track of them</property>
- <property name="icon_name">trackers</property>
+ <property name="stock_id">tracks</property>
</object>
<object class="GtkToggleAction" id="ShowImpossibleImplications">
<property name="label">Warn about _unfillable squares</property>
@@ -431,13 +431,50 @@
<object class="GtkHBox" id="main_area">
<property name="visible">True</property>
<child>
- <placeholder/>
- </child>
- <child>
- <placeholder/>
+ <object class="GtkHBox" id="main_grid_container">
+ <property name="visible">True</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
</child>
<child>
- <placeholder/>
+ <object class="GtkVBox" id="side_bar">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <object class="GtkVBox" id="tracker_ui_container">
+ <property name="visible">True</property>
+ <property name="orientation">vertical</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="position">0</property>
+ </packing>
+ </child>
+ <child>
+ <object class="GtkAlignment" id="side_grid_container">
+ <property name="visible">True</property>
+ <property name="yalign">1</property>
+ <child>
+ <placeholder/>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="position">1</property>
+ </packing>
</child>
</object>
<packing>
diff --git a/gnome-sudoku/src/lib/main.py b/gnome-sudoku/src/lib/main.py
index 454f917..a9012fe 100644
--- a/gnome-sudoku/src/lib/main.py
+++ b/gnome-sudoku/src/lib/main.py
@@ -238,15 +238,16 @@ class SudokuGame (gconf_wrapper.GConfWrapper):
self.toolbar = self.builder.get_object("toolbar")
def _setup_main_boxes(self):
- main_area = self.builder.get_object("main_area")
+ main_grid_container = self.builder.get_object("main_grid_container")
+ side_grid_container = self.builder.get_object("side_grid_container")
+ tracker_ui_container = self.builder.get_object("tracker_ui_container")
self._main_grid_vew = view.SudokuView(9, self._history_manager)
main_grid_container.pack_start(self._main_grid_vew, padding=6)
self.tracker_ui = tracker_box.TrackerBox(self._main_grid_vew)
- self.tracker_ui.show_all()
self.tracker_ui.hide()
- main_area.pack_start(self.tracker_ui, expand=False)
+ side_grid_container.add(self._side_grid_vew)
def setup_color (self):
# setup background colors
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]