changeset 138:33962c2ef550

Re #326: Make army names and sizes modifiable after creation * Add army editing form * Hook up to events to update main window * Add edit army option to Edit menu
author IBBoard <dev@ibboard.co.uk>
date Tue, 11 Oct 2011 21:05:10 +0100
parents 5b92d2be69d8
children d4b726cec12c
files FrmEditArmy.cs FrmMainWindow.cs IBBoard.WarFoundry.GUI.GTK.csproj gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmEditArmy.cs gtk-gui/gui.stetic translations/en.translation
diffstat 6 files changed, 383 insertions(+), 1 deletions(-) [+]
line diff
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/FrmEditArmy.cs	Tue Oct 11 21:05:10 2011 +0100
     1.3 @@ -0,0 +1,46 @@
     1.4 +// This file (FrmEditArmy.cs) is a part of the IBBoard.WarFoundry.GUI.GTK project and is copyright 2011 IBBoard
     1.5 +// 
     1.6 +// The file and the library/program it is in are licensed and distributed, without warranty, under the GNU Affero GPL license, either version 3 of the License or (at your option) any later version. Please see COPYING for more information and the full license.
     1.7 +using System;
     1.8 +using IBBoard.WarFoundry.API.Objects;
     1.9 +using IBBoard.Commands;
    1.10 +using IBBoard.WarFoundry.API.Commands;
    1.11 +
    1.12 +namespace IBBoard.WarFoundry.GUI.GTK
    1.13 +{
    1.14 +	public partial class FrmEditArmy : IBBoard.GtkSharp.Translatable.TranslatableDialog
    1.15 +	{
    1.16 +		private Army army;
    1.17 +		private CommandStack stack;
    1.18 +
    1.19 +		public FrmEditArmy(CommandStack cmdStack, Army toEdit)
    1.20 +		{
    1.21 +			stack = cmdStack;
    1.22 +			army = toEdit;
    1.23 +			this.Build();
    1.24 +			txtArmyName.Text = army.Name;
    1.25 +			sbPointsValue.Value = army.MaxPoints;
    1.26 +			Translate();
    1.27 +		}
    1.28 +
    1.29 +		private void DoUpdate()
    1.30 +		{
    1.31 +			EditArmyCommand command = new EditArmyCommand(army);
    1.32 +			command.NewName = txtArmyName.Text;
    1.33 +			command.NewSize = (int)sbPointsValue.Value;
    1.34 +			stack.Execute(command);
    1.35 +		}
    1.36 +
    1.37 +		protected void OnButtonOkClicked (object sender, System.EventArgs e)
    1.38 +		{
    1.39 +			DoUpdate();
    1.40 +			Respond(Gtk.ResponseType.Ok);
    1.41 +		}
    1.42 +
    1.43 +		protected void OnButtonCancelClicked (object sender, System.EventArgs e)
    1.44 +		{
    1.45 +			Respond(Gtk.ResponseType.Cancel);
    1.46 +		}
    1.47 +	}
    1.48 +}
    1.49 +
     2.1 --- a/FrmMainWindow.cs	Tue Oct 11 20:24:11 2011 +0100
     2.2 +++ b/FrmMainWindow.cs	Tue Oct 11 21:05:10 2011 +0100
     2.3 @@ -520,6 +520,8 @@
     2.4  				oldArmy.UnitAdded -= UnitAddedMethod;
     2.5  				oldArmy.UnitRemoved -= UnitRemovedMethod;
     2.6  				oldArmy.PointsValueChanged -= PointsValueChangedMethod;
     2.7 +				oldArmy.NameChanged -= OnArmyNameChanged;
     2.8 +				oldArmy.MaxPointsValueChanged -= OnMaxPointsValueChanged;
     2.9  			}
    2.10  
    2.11  			unitToWidgetMap.Clear();
    2.12 @@ -538,6 +540,8 @@
    2.13  				newArmy.UnitAdded += UnitAddedMethod;
    2.14  				newArmy.UnitRemoved += UnitRemovedMethod;
    2.15  				newArmy.PointsValueChanged += PointsValueChangedMethod;
    2.16 +				newArmy.NameChanged += OnArmyNameChanged;
    2.17 +				newArmy.MaxPointsValueChanged += OnMaxPointsValueChanged;
    2.18  				//TODO: Clear all buttons
    2.19  				EnableCategoryButtons();
    2.20  
    2.21 @@ -552,6 +556,7 @@
    2.22  			miCloseArmy.Sensitive = nonNullNewArmy;
    2.23  			miSaveArmyAs.Sensitive = nonNullNewArmy;
    2.24  			miExportArmyAs.Sensitive = nonNullNewArmy;
    2.25 +			miEditArmy.Sensitive = nonNullNewArmy;
    2.26  			hpaned2.Visible = nonNullNewArmy;
    2.27  			loadedArmyPath = null;
    2.28  			//New army has no changes, so we can't save it
    2.29 @@ -562,6 +567,16 @@
    2.30  			SetPointsPanelText();
    2.31  		}
    2.32  
    2.33 +		private void OnArmyNameChanged (WarFoundryObject obj, string oldValue, string newValue)
    2.34 +		{
    2.35 +			SetAppTitle();
    2.36 +		}
    2.37 +
    2.38 +		private void OnMaxPointsValueChanged (WarFoundryObject obj, int oldValue, int newValue)
    2.39 +		{
    2.40 +			SetPointsPanelText();
    2.41 +		}
    2.42 +
    2.43  		private void SetArmyTree(Army army)
    2.44  		{
    2.45  			logger.Debug("Resetting tree");
    2.46 @@ -1175,12 +1190,20 @@
    2.47  			}
    2.48  		}
    2.49  
    2.50 -		protected void OnTransformedXmlActionActivated (object sender, System.EventArgs e)
    2.51 +		protected void OnTransformedXmlActionActivated(object sender, System.EventArgs e)
    2.52  		{
    2.53  			FrmExportXml form = new FrmExportXml(WarFoundryCore.CurrentArmy);
    2.54  			form.Run();
    2.55  			form.Hide();
    2.56  			form.Dispose();
    2.57  		}
    2.58 +
    2.59 +		protected void OnMiEditArmyActivated(object sender, System.EventArgs e)
    2.60 +		{
    2.61 +			FrmEditArmy form = new FrmEditArmy(commandStack, WarFoundryCore.CurrentArmy);
    2.62 +			form.Run();
    2.63 +			form.Hide();
    2.64 +			form.Dispose();
    2.65 +		}
    2.66  	}
    2.67  }
     3.1 --- a/IBBoard.WarFoundry.GUI.GTK.csproj	Tue Oct 11 20:24:11 2011 +0100
     3.2 +++ b/IBBoard.WarFoundry.GUI.GTK.csproj	Tue Oct 11 21:05:10 2011 +0100
     3.3 @@ -75,6 +75,8 @@
     3.4      <Compile Include="FrmExportXml.cs" />
     3.5      <Compile Include="Widgets\TransformXmlWidget.cs" />
     3.6      <Compile Include="gtk-gui\IBBoard.WarFoundry.GUI.GTK.TransformXmlWidget.cs" />
     3.7 +    <Compile Include="FrmEditArmy.cs" />
     3.8 +    <Compile Include="gtk-gui\IBBoard.WarFoundry.GUI.GTK.FrmEditArmy.cs" />
     3.9    </ItemGroup>
    3.10    <ItemGroup>
    3.11      <Content Include="App.png" />
     4.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     4.2 +++ b/gtk-gui/IBBoard.WarFoundry.GUI.GTK.FrmEditArmy.cs	Tue Oct 11 21:05:10 2011 +0100
     4.3 @@ -0,0 +1,130 @@
     4.4 +
     4.5 +// This file has been generated by the GUI designer. Do not modify.
     4.6 +namespace IBBoard.WarFoundry.GUI.GTK
     4.7 +{
     4.8 +	public partial class FrmEditArmy
     4.9 +	{
    4.10 +		private global::Gtk.Table table1;
    4.11 +		private global::Gtk.HBox hbox2;
    4.12 +		private global::Gtk.SpinButton sbPointsValue;
    4.13 +		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblArmyName;
    4.14 +		private global::IBBoard.GtkSharp.Translatable.TranslatableLabel lblArmySize;
    4.15 +		private global::Gtk.Entry txtArmyName;
    4.16 +		private global::Gtk.Button buttonCancel;
    4.17 +		private global::Gtk.Button buttonOk;
    4.18 +		
    4.19 +		protected virtual void Build ()
    4.20 +		{
    4.21 +			global::Stetic.Gui.Initialize (this);
    4.22 +			// Widget IBBoard.WarFoundry.GUI.GTK.FrmEditArmy
    4.23 +			this.Name = "IBBoard.WarFoundry.GUI.GTK.FrmEditArmy";
    4.24 +			this.WindowPosition = ((global::Gtk.WindowPosition)(4));
    4.25 +			// Internal child IBBoard.WarFoundry.GUI.GTK.FrmEditArmy.VBox
    4.26 +			global::Gtk.VBox w1 = this.VBox;
    4.27 +			w1.Name = "dialog1_VBox";
    4.28 +			w1.BorderWidth = ((uint)(2));
    4.29 +			// Container child dialog1_VBox.Gtk.Box+BoxChild
    4.30 +			this.table1 = new global::Gtk.Table (((uint)(2)), ((uint)(2)), false);
    4.31 +			this.table1.Name = "table1";
    4.32 +			this.table1.RowSpacing = ((uint)(6));
    4.33 +			this.table1.ColumnSpacing = ((uint)(6));
    4.34 +			// Container child table1.Gtk.Table+TableChild
    4.35 +			this.hbox2 = new global::Gtk.HBox ();
    4.36 +			this.hbox2.Name = "hbox2";
    4.37 +			// Container child hbox2.Gtk.Box+BoxChild
    4.38 +			this.sbPointsValue = new global::Gtk.SpinButton (0, 2000000000, 100);
    4.39 +			this.sbPointsValue.WidthRequest = 150;
    4.40 +			this.sbPointsValue.CanFocus = true;
    4.41 +			this.sbPointsValue.Name = "sbPointsValue";
    4.42 +			this.sbPointsValue.Adjustment.PageIncrement = 1000;
    4.43 +			this.sbPointsValue.ClimbRate = 100;
    4.44 +			this.sbPointsValue.Numeric = true;
    4.45 +			this.sbPointsValue.Value = 1000;
    4.46 +			this.hbox2.Add (this.sbPointsValue);
    4.47 +			global::Gtk.Box.BoxChild w2 = ((global::Gtk.Box.BoxChild)(this.hbox2 [this.sbPointsValue]));
    4.48 +			w2.Position = 0;
    4.49 +			w2.Expand = false;
    4.50 +			w2.Fill = false;
    4.51 +			this.table1.Add (this.hbox2);
    4.52 +			global::Gtk.Table.TableChild w3 = ((global::Gtk.Table.TableChild)(this.table1 [this.hbox2]));
    4.53 +			w3.TopAttach = ((uint)(1));
    4.54 +			w3.BottomAttach = ((uint)(2));
    4.55 +			w3.LeftAttach = ((uint)(1));
    4.56 +			w3.RightAttach = ((uint)(2));
    4.57 +			w3.YOptions = ((global::Gtk.AttachOptions)(4));
    4.58 +			// Container child table1.Gtk.Table+TableChild
    4.59 +			this.lblArmyName = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel ();
    4.60 +			this.lblArmyName.Name = "lblArmyName";
    4.61 +			this.lblArmyName.LabelProp = global::Mono.Unix.Catalog.GetString ("army name:");
    4.62 +			this.table1.Add (this.lblArmyName);
    4.63 +			global::Gtk.Table.TableChild w4 = ((global::Gtk.Table.TableChild)(this.table1 [this.lblArmyName]));
    4.64 +			w4.XOptions = ((global::Gtk.AttachOptions)(4));
    4.65 +			w4.YOptions = ((global::Gtk.AttachOptions)(4));
    4.66 +			// Container child table1.Gtk.Table+TableChild
    4.67 +			this.lblArmySize = new global::IBBoard.GtkSharp.Translatable.TranslatableLabel ();
    4.68 +			this.lblArmySize.Name = "lblArmySize";
    4.69 +			this.lblArmySize.LabelProp = global::Mono.Unix.Catalog.GetString ("army size:");
    4.70 +			this.table1.Add (this.lblArmySize);
    4.71 +			global::Gtk.Table.TableChild w5 = ((global::Gtk.Table.TableChild)(this.table1 [this.lblArmySize]));
    4.72 +			w5.TopAttach = ((uint)(1));
    4.73 +			w5.BottomAttach = ((uint)(2));
    4.74 +			w5.XOptions = ((global::Gtk.AttachOptions)(4));
    4.75 +			w5.YOptions = ((global::Gtk.AttachOptions)(4));
    4.76 +			// Container child table1.Gtk.Table+TableChild
    4.77 +			this.txtArmyName = new global::Gtk.Entry ();
    4.78 +			this.txtArmyName.CanFocus = true;
    4.79 +			this.txtArmyName.Name = "txtArmyName";
    4.80 +			this.txtArmyName.IsEditable = true;
    4.81 +			this.txtArmyName.InvisibleChar = '●';
    4.82 +			this.table1.Add (this.txtArmyName);
    4.83 +			global::Gtk.Table.TableChild w6 = ((global::Gtk.Table.TableChild)(this.table1 [this.txtArmyName]));
    4.84 +			w6.LeftAttach = ((uint)(1));
    4.85 +			w6.RightAttach = ((uint)(2));
    4.86 +			w6.YOptions = ((global::Gtk.AttachOptions)(4));
    4.87 +			w1.Add (this.table1);
    4.88 +			global::Gtk.Box.BoxChild w7 = ((global::Gtk.Box.BoxChild)(w1 [this.table1]));
    4.89 +			w7.Position = 0;
    4.90 +			w7.Expand = false;
    4.91 +			w7.Fill = false;
    4.92 +			// Internal child IBBoard.WarFoundry.GUI.GTK.FrmEditArmy.ActionArea
    4.93 +			global::Gtk.HButtonBox w8 = this.ActionArea;
    4.94 +			w8.Name = "dialog1_ActionArea";
    4.95 +			w8.Spacing = 10;
    4.96 +			w8.BorderWidth = ((uint)(5));
    4.97 +			w8.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4));
    4.98 +			// Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
    4.99 +			this.buttonCancel = new global::Gtk.Button ();
   4.100 +			this.buttonCancel.CanDefault = true;
   4.101 +			this.buttonCancel.CanFocus = true;
   4.102 +			this.buttonCancel.Name = "buttonCancel";
   4.103 +			this.buttonCancel.UseStock = true;
   4.104 +			this.buttonCancel.UseUnderline = true;
   4.105 +			this.buttonCancel.Label = "gtk-cancel";
   4.106 +			this.AddActionWidget (this.buttonCancel, -6);
   4.107 +			global::Gtk.ButtonBox.ButtonBoxChild w9 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w8 [this.buttonCancel]));
   4.108 +			w9.Expand = false;
   4.109 +			w9.Fill = false;
   4.110 +			// Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
   4.111 +			this.buttonOk = new global::Gtk.Button ();
   4.112 +			this.buttonOk.CanDefault = true;
   4.113 +			this.buttonOk.CanFocus = true;
   4.114 +			this.buttonOk.Name = "buttonOk";
   4.115 +			this.buttonOk.UseStock = true;
   4.116 +			this.buttonOk.UseUnderline = true;
   4.117 +			this.buttonOk.Label = "gtk-ok";
   4.118 +			this.AddActionWidget (this.buttonOk, -5);
   4.119 +			global::Gtk.ButtonBox.ButtonBoxChild w10 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w8 [this.buttonOk]));
   4.120 +			w10.Position = 1;
   4.121 +			w10.Expand = false;
   4.122 +			w10.Fill = false;
   4.123 +			if ((this.Child != null)) {
   4.124 +				this.Child.ShowAll ();
   4.125 +			}
   4.126 +			this.DefaultWidth = 400;
   4.127 +			this.DefaultHeight = 135;
   4.128 +			this.Show ();
   4.129 +			this.buttonCancel.Clicked += new global::System.EventHandler (this.OnButtonCancelClicked);
   4.130 +			this.buttonOk.Clicked += new global::System.EventHandler (this.OnButtonOkClicked);
   4.131 +		}
   4.132 +	}
   4.133 +}
     5.1 --- a/gtk-gui/gui.stetic	Tue Oct 11 20:24:11 2011 +0100
     5.2 +++ b/gtk-gui/gui.stetic	Tue Oct 11 21:05:10 2011 +0100
     5.3 @@ -171,6 +171,14 @@
     5.4          <property name="ShortLabel" translatable="yes">transformed xml</property>
     5.5          <signal name="Activated" handler="OnTransformedXmlActionActivated" />
     5.6        </action>
     5.7 +      <action id="miEditArmy">
     5.8 +        <property name="Type">Action</property>
     5.9 +        <property name="Label" translatable="yes">_edit army</property>
    5.10 +        <property name="Sensitive">False</property>
    5.11 +        <property name="ShortLabel" translatable="yes">_edit army</property>
    5.12 +        <property name="StockId">gtk-edit</property>
    5.13 +        <signal name="Activated" handler="OnMiEditArmyActivated" />
    5.14 +      </action>
    5.15      </action-group>
    5.16      <property name="MemberName" />
    5.17      <property name="Title" translatable="yes">MainWindow</property>
    5.18 @@ -201,6 +209,8 @@
    5.19                  <node type="Menuitem" action="miUndo" />
    5.20                  <node type="Menuitem" action="miRedo" />
    5.21                  <node type="Separator" />
    5.22 +                <node type="Menuitem" action="miEditArmy" />
    5.23 +                <node type="Separator" />
    5.24                  <node type="Menuitem" action="miPreferences" />
    5.25                </node>
    5.26                <node type="Menu" action="menuHelp">
    5.27 @@ -2610,4 +2620,172 @@
    5.28        </widget>
    5.29      </child>
    5.30    </widget>
    5.31 +  <widget class="Gtk.Dialog" id="IBBoard.WarFoundry.GUI.GTK.FrmEditArmy" design-size="400 135">
    5.32 +    <property name="MemberName" />
    5.33 +    <property name="WindowPosition">CenterOnParent</property>
    5.34 +    <property name="Buttons">2</property>
    5.35 +    <property name="HelpButton">False</property>
    5.36 +    <child internal-child="VBox">
    5.37 +      <widget class="Gtk.VBox" id="dialog1_VBox">
    5.38 +        <property name="MemberName" />
    5.39 +        <property name="BorderWidth">2</property>
    5.40 +        <child>
    5.41 +          <widget class="Gtk.Table" id="table1">
    5.42 +            <property name="MemberName" />
    5.43 +            <property name="NRows">2</property>
    5.44 +            <property name="NColumns">2</property>
    5.45 +            <property name="RowSpacing">6</property>
    5.46 +            <property name="ColumnSpacing">6</property>
    5.47 +            <child>
    5.48 +              <widget class="Gtk.HBox" id="hbox2">
    5.49 +                <property name="MemberName" />
    5.50 +                <child>
    5.51 +                  <widget class="Gtk.SpinButton" id="sbPointsValue">
    5.52 +                    <property name="MemberName" />
    5.53 +                    <property name="WidthRequest">150</property>
    5.54 +                    <property name="CanFocus">True</property>
    5.55 +                    <property name="Upper">2000000000</property>
    5.56 +                    <property name="PageIncrement">1000</property>
    5.57 +                    <property name="StepIncrement">100</property>
    5.58 +                    <property name="ClimbRate">100</property>
    5.59 +                    <property name="Numeric">True</property>
    5.60 +                    <property name="Value">1000</property>
    5.61 +                  </widget>
    5.62 +                  <packing>
    5.63 +                    <property name="Position">0</property>
    5.64 +                    <property name="AutoSize">True</property>
    5.65 +                    <property name="Expand">False</property>
    5.66 +                    <property name="Fill">False</property>
    5.67 +                  </packing>
    5.68 +                </child>
    5.69 +                <child>
    5.70 +                  <placeholder />
    5.71 +                </child>
    5.72 +              </widget>
    5.73 +              <packing>
    5.74 +                <property name="TopAttach">1</property>
    5.75 +                <property name="BottomAttach">2</property>
    5.76 +                <property name="LeftAttach">1</property>
    5.77 +                <property name="RightAttach">2</property>
    5.78 +                <property name="AutoSize">True</property>
    5.79 +                <property name="YOptions">Fill</property>
    5.80 +                <property name="XExpand">True</property>
    5.81 +                <property name="XFill">True</property>
    5.82 +                <property name="XShrink">False</property>
    5.83 +                <property name="YExpand">False</property>
    5.84 +                <property name="YFill">True</property>
    5.85 +                <property name="YShrink">False</property>
    5.86 +              </packing>
    5.87 +            </child>
    5.88 +            <child>
    5.89 +              <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblArmyName">
    5.90 +                <property name="MemberName" />
    5.91 +                <property name="LabelProp" translatable="yes">army name:</property>
    5.92 +              </widget>
    5.93 +              <packing>
    5.94 +                <property name="AutoSize">True</property>
    5.95 +                <property name="XOptions">Fill</property>
    5.96 +                <property name="YOptions">Fill</property>
    5.97 +                <property name="XExpand">False</property>
    5.98 +                <property name="XFill">True</property>
    5.99 +                <property name="XShrink">False</property>
   5.100 +                <property name="YExpand">False</property>
   5.101 +                <property name="YFill">True</property>
   5.102 +                <property name="YShrink">False</property>
   5.103 +              </packing>
   5.104 +            </child>
   5.105 +            <child>
   5.106 +              <widget class="IBBoard.GtkSharp.Translatable.TranslatableLabel" id="lblArmySize">
   5.107 +                <property name="MemberName" />
   5.108 +                <property name="LabelProp" translatable="yes">army size:</property>
   5.109 +              </widget>
   5.110 +              <packing>
   5.111 +                <property name="TopAttach">1</property>
   5.112 +                <property name="BottomAttach">2</property>
   5.113 +                <property name="AutoSize">True</property>
   5.114 +                <property name="XOptions">Fill</property>
   5.115 +                <property name="YOptions">Fill</property>
   5.116 +                <property name="XExpand">False</property>
   5.117 +                <property name="XFill">True</property>
   5.118 +                <property name="XShrink">False</property>
   5.119 +                <property name="YExpand">False</property>
   5.120 +                <property name="YFill">True</property>
   5.121 +                <property name="YShrink">False</property>
   5.122 +              </packing>
   5.123 +            </child>
   5.124 +            <child>
   5.125 +              <widget class="Gtk.Entry" id="txtArmyName">
   5.126 +                <property name="MemberName" />
   5.127 +                <property name="CanFocus">True</property>
   5.128 +                <property name="IsEditable">True</property>
   5.129 +                <property name="InvisibleChar">●</property>
   5.130 +              </widget>
   5.131 +              <packing>
   5.132 +                <property name="LeftAttach">1</property>
   5.133 +                <property name="RightAttach">2</property>
   5.134 +                <property name="AutoSize">True</property>
   5.135 +                <property name="YOptions">Fill</property>
   5.136 +                <property name="XExpand">True</property>
   5.137 +                <property name="XFill">True</property>
   5.138 +                <property name="XShrink">False</property>
   5.139 +                <property name="YExpand">False</property>
   5.140 +                <property name="YFill">True</property>
   5.141 +                <property name="YShrink">False</property>
   5.142 +              </packing>
   5.143 +            </child>
   5.144 +          </widget>
   5.145 +          <packing>
   5.146 +            <property name="Position">0</property>
   5.147 +            <property name="AutoSize">True</property>
   5.148 +            <property name="Expand">False</property>
   5.149 +            <property name="Fill">False</property>
   5.150 +          </packing>
   5.151 +        </child>
   5.152 +      </widget>
   5.153 +    </child>
   5.154 +    <child internal-child="ActionArea">
   5.155 +      <widget class="Gtk.HButtonBox" id="dialog1_ActionArea">
   5.156 +        <property name="MemberName" />
   5.157 +        <property name="Spacing">10</property>
   5.158 +        <property name="BorderWidth">5</property>
   5.159 +        <property name="Size">2</property>
   5.160 +        <property name="LayoutStyle">End</property>
   5.161 +        <child>
   5.162 +          <widget class="Gtk.Button" id="buttonCancel">
   5.163 +            <property name="MemberName" />
   5.164 +            <property name="CanDefault">True</property>
   5.165 +            <property name="CanFocus">True</property>
   5.166 +            <property name="UseStock">True</property>
   5.167 +            <property name="Type">StockItem</property>
   5.168 +            <property name="StockId">gtk-cancel</property>
   5.169 +            <property name="ResponseId">-6</property>
   5.170 +            <signal name="Clicked" handler="OnButtonCancelClicked" />
   5.171 +            <property name="label">gtk-cancel</property>
   5.172 +          </widget>
   5.173 +          <packing>
   5.174 +            <property name="Expand">False</property>
   5.175 +            <property name="Fill">False</property>
   5.176 +          </packing>
   5.177 +        </child>
   5.178 +        <child>
   5.179 +          <widget class="Gtk.Button" id="buttonOk">
   5.180 +            <property name="MemberName" />
   5.181 +            <property name="CanDefault">True</property>
   5.182 +            <property name="CanFocus">True</property>
   5.183 +            <property name="UseStock">True</property>
   5.184 +            <property name="Type">StockItem</property>
   5.185 +            <property name="StockId">gtk-ok</property>
   5.186 +            <property name="ResponseId">-5</property>
   5.187 +            <signal name="Clicked" handler="OnButtonOkClicked" />
   5.188 +            <property name="label">gtk-ok</property>
   5.189 +          </widget>
   5.190 +          <packing>
   5.191 +            <property name="Position">1</property>
   5.192 +            <property name="Expand">False</property>
   5.193 +            <property name="Fill">False</property>
   5.194 +          </packing>
   5.195 +        </child>
   5.196 +      </widget>
   5.197 +    </child>
   5.198 +  </widget>
   5.199  </stetic-interface>
   5.200 \ No newline at end of file
     6.1 --- a/translations/en.translation	Tue Oct 11 20:24:11 2011 +0100
     6.2 +++ b/translations/en.translation	Tue Oct 11 21:05:10 2011 +0100
     6.3 @@ -25,6 +25,7 @@
     6.4  <!-- Main Window / Menus / Edit Menu -->
     6.5  <translation id="miUndo">_Undo</translation>
     6.6  <translation id="miRedo">_Redo</translation>
     6.7 +<translation id="miEditArmy">_Edit Army</translation>
     6.8  <translation id="miPreferences">_Preferences</translation>
     6.9  <!-- Main Window / Menus / Help Menu -->
    6.10  <translation id="miAbout">_About</translation>
    6.11 @@ -126,6 +127,8 @@
    6.12  <!-- Export / XML -->
    6.13  <translation id="lblTransform">Transformation:</translation>
    6.14  <translation id="doTransformWidget">Transform Output</translation>
    6.15 +<!-- Edit Army -->
    6.16 +<translation id="IBBoard.WarFoundry.GUI.GTK.FrmEditArmy">Edit Army</translation>
    6.17  <!-- API -->
    6.18  <translation id="defaultUnitName">Unit of {0} {1}</translation>
    6.19  <translation id="setEquipmentAmountCommandDescription">Set {0} amount for {1} to {2}</translation>