diff gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmMainWindow.cs @ 140:2b9fabd65309

Re #344: Show unit requirement failures * Use status bar properly * Add initial validation label * Make use of new event from Army to see when things changed Also: * Commit some automated changes
author IBBoard <dev@ibboard.co.uk>
date Sat, 15 Oct 2011 16:07:13 +0100
parents d4b726cec12c
children 1ce4fe9ae3c1
line wrap: on
line diff
--- a/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmMainWindow.cs	Wed Oct 12 20:36:02 2011 +0100
+++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmMainWindow.cs	Sat Oct 15 16:07:13 2011 +0100
@@ -34,11 +34,11 @@
 		private global::Gtk.VBox vbox1;
 		private global::Gtk.MenuBar menubar1;
 		private global::Gtk.Toolbar toolbar;
-		private global::Gtk.HPaned hpaned2;
+		private global::Gtk.Statusbar statusbar;
+		private global::Gtk.Label lblValidationWarning;
+		private global::Gtk.HPaned mainContent;
 		private global::Gtk.TreeView treeUnits;
 		private global::Gtk.Notebook unitsNotebook;
-		private global::Gtk.Statusbar statusbar1;
-		private global::Gtk.Label lblTotalPoints;
 		
 		protected virtual void Build ()
 		{
@@ -135,6 +135,7 @@
 			// Container child IBBoard.WarFoundry.GUI.GTK.FrmMainWindow.Gtk.Container+ContainerChild
 			this.vbox1 = new global::Gtk.VBox ();
 			this.vbox1.Name = "vbox1";
+			this.vbox1.Spacing = 0;
 			// Container child vbox1.Gtk.Box+BoxChild
 			this.UIManager.AddUiFromString ("<ui><menubar name='menubar1'><menu name='menuFile' action='menuFile'><menuitem name='miNewArmy' action='miNewArmy'/><menuitem name='miOpenArmy' action='miOpenArmy'/><menuitem name='miSaveArmy' action='miSaveArmy'/><menuitem name='miSaveArmyAs' action='miSaveArmyAs'/><menu name='miExportArmyAs' action='miExportArmyAs'><menuitem name='miExportArmyAsBasicHTML' action='miExportArmyAsBasicHTML'/><menuitem name='miExportArmyAsTransformedXml' action='miExportArmyAsTransformedXml'/></menu><menuitem name='miCloseArmy' action='miCloseArmy'/><separator/><menuitem name='miReloadFiles' action='miReloadFiles'/><separator/><menuitem name='miExit' action='miExit'/></menu><menu name='menuEdit' action='menuEdit'><menuitem name='miUndo' action='miUndo'/><menuitem name='miRedo' action='miRedo'/><separator/><menuitem name='miEditArmy' action='miEditArmy'/><separator/><menuitem name='miPreferences' action='miPreferences'/></menu><menu name='menuHelp' action='menuHelp'><menuitem name='miAbout' action='miAbout'/></menu></menubar></ui>");
 			this.menubar1 = ((global::Gtk.MenuBar)(this.UIManager.GetWidget ("/menubar1")));
@@ -158,53 +159,57 @@
 			w3.Expand = false;
 			w3.Fill = false;
 			// Container child vbox1.Gtk.Box+BoxChild
-			this.hpaned2 = new global::Gtk.HPaned ();
-			this.hpaned2.CanFocus = true;
-			this.hpaned2.Name = "hpaned2";
-			this.hpaned2.Position = 178;
-			// Container child hpaned2.Gtk.Paned+PanedChild
+			this.statusbar = new global::Gtk.Statusbar ();
+			this.statusbar.Name = "statusbar";
+			this.statusbar.Spacing = 6;
+			this.statusbar.BorderWidth = ((uint)(1));
+			// Container child statusbar.Gtk.Box+BoxChild
+			this.lblValidationWarning = new global::Gtk.Label ();
+			this.lblValidationWarning.Name = "lblValidationWarning";
+			this.statusbar.Add (this.lblValidationWarning);
+			global::Gtk.Box.BoxChild w4 = ((global::Gtk.Box.BoxChild)(this.statusbar [this.lblValidationWarning]));
+			w4.PackType = ((global::Gtk.PackType)(1));
+			w4.Position = 1;
+			w4.Expand = false;
+			w4.Fill = false;
+			this.vbox1.Add (this.statusbar);
+			global::Gtk.Box.BoxChild w5 = ((global::Gtk.Box.BoxChild)(this.vbox1 [this.statusbar]));
+			w5.PackType = ((global::Gtk.PackType)(1));
+			w5.Position = 2;
+			w5.Expand = false;
+			w5.Fill = false;
+			// Container child vbox1.Gtk.Box+BoxChild
+			this.mainContent = new global::Gtk.HPaned ();
+			this.mainContent.CanFocus = true;
+			this.mainContent.Name = "mainContent";
+			this.mainContent.Position = 180;
+			// Container child mainContent.Gtk.Paned+PanedChild
 			this.treeUnits = new global::Gtk.TreeView ();
 			this.treeUnits.CanFocus = true;
 			this.treeUnits.Name = "treeUnits";
-			this.hpaned2.Add (this.treeUnits);
-			global::Gtk.Paned.PanedChild w4 = ((global::Gtk.Paned.PanedChild)(this.hpaned2 [this.treeUnits]));
-			w4.Resize = false;
-			// Container child hpaned2.Gtk.Paned+PanedChild
+			this.mainContent.Add (this.treeUnits);
+			global::Gtk.Paned.PanedChild w6 = ((global::Gtk.Paned.PanedChild)(this.mainContent [this.treeUnits]));
+			w6.Resize = false;
+			// Container child mainContent.Gtk.Paned+PanedChild
 			this.unitsNotebook = new global::Gtk.Notebook ();
 			this.unitsNotebook.CanFocus = true;
 			this.unitsNotebook.Name = "unitsNotebook";
 			this.unitsNotebook.CurrentPage = -1;
 			this.unitsNotebook.Scrollable = true;
-			this.hpaned2.Add (this.unitsNotebook);
-			global::Gtk.Paned.PanedChild w5 = ((global::Gtk.Paned.PanedChild)(this.hpaned2 [this.unitsNotebook]));
-			w5.Shrink = false;
-			this.vbox1.Add (this.hpaned2);
-			global::Gtk.Box.BoxChild w6 = ((global::Gtk.Box.BoxChild)(this.vbox1 [this.hpaned2]));
-			w6.Position = 2;
-			// Container child vbox1.Gtk.Box+BoxChild
-			this.statusbar1 = new global::Gtk.Statusbar ();
-			this.statusbar1.Name = "statusbar1";
-			this.statusbar1.Spacing = 2;
-			// Container child statusbar1.Gtk.Box+BoxChild
-			this.lblTotalPoints = new global::Gtk.Label ();
-			this.lblTotalPoints.Name = "lblTotalPoints";
-			this.statusbar1.Add (this.lblTotalPoints);
-			global::Gtk.Box.BoxChild w7 = ((global::Gtk.Box.BoxChild)(this.statusbar1 [this.lblTotalPoints]));
-			w7.Position = 2;
-			w7.Expand = false;
-			w7.Fill = false;
-			this.vbox1.Add (this.statusbar1);
-			global::Gtk.Box.BoxChild w8 = ((global::Gtk.Box.BoxChild)(this.vbox1 [this.statusbar1]));
+			this.mainContent.Add (this.unitsNotebook);
+			global::Gtk.Paned.PanedChild w7 = ((global::Gtk.Paned.PanedChild)(this.mainContent [this.unitsNotebook]));
+			w7.Shrink = false;
+			this.vbox1.Add (this.mainContent);
+			global::Gtk.Box.BoxChild w8 = ((global::Gtk.Box.BoxChild)(this.vbox1 [this.mainContent]));
+			w8.PackType = ((global::Gtk.PackType)(1));
 			w8.Position = 3;
-			w8.Expand = false;
-			w8.Fill = false;
 			this.Add (this.vbox1);
 			if ((this.Child != null)) {
 				this.Child.ShowAll ();
 			}
 			this.DefaultWidth = 832;
 			this.DefaultHeight = 659;
-			this.hpaned2.Hide ();
+			this.treeUnits.Hide ();
 			this.Show ();
 			this.miNewArmy.Activated += new global::System.EventHandler (this.OnCreateArmyActivated);
 			this.miOpenArmy.Activated += new global::System.EventHandler (this.OnOpenArmyActivated);