[longomatch] Improved Templates GUI



commit c9b4c8c8284524841f66e30737dd78a5a7a165e7
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Mon Sep 14 02:03:09 2009 +0200

    Improved  Templates GUI

 LongoMatch/Gui/EditSectionsDialog.cs               |   61 ++
 LongoMatch/Gui/PlayerProperties.cs                 |   46 +-
 LongoMatch/Gui/SectionsPropertiesWidget.cs         |  193 ++---
 LongoMatch/Gui/SectionsTreeView.cs                 |  137 +++
 LongoMatch/Gui/TeamTemplateEditor.cs               |    4 +-
 LongoMatch/Gui/TeamTemplateWidget.cs               |   80 +-
 LongoMatch/Gui/TemplateEditorDialog.cs             |    8 +-
 LongoMatch/Gui/TemplatesEditor.cs                  |   40 +-
 LongoMatch/Gui/TimeNodeProperties.cs               |   45 +-
 LongoMatch/LongoMatch.mdp                          |    6 +
 LongoMatch/Makefile.am                             |    3 +
 LongoMatch/UpdateManager.cs                        |   21 -
 .../LongoMatch.Gui.Component.PlayerProperties.cs   |   26 +-
 ...Match.Gui.Component.SectionsPropertiesWidget.cs |  173 +++-
 .../LongoMatch.Gui.Component.TeamTemplateWidget.cs |   28 +-
 .../LongoMatch.Gui.Component.TimeNodeProperties.cs |  201 +---
 .../gtk-gui/LongoMatch.Gui.Dialog.DBManager.cs     |    2 +-
 .../LongoMatch.Gui.Dialog.EditSectionsDialog.cs    |   66 ++
 .../LongoMatch.Gui.Dialog.TeamTemplateEditor.cs    |   39 +-
 .../LongoMatch.Gui.Dialog.TemplateEditorDialog.cs  |    5 +-
 .../LongoMatch.Gui.Dialog.TemplatesManager.cs      |   58 +-
 LongoMatch/gtk-gui/gui.stetic                      | 1070 ++++++++++----------
 LongoMatch/gtk-gui/objects.xml                     |   39 +-
 23 files changed, 1304 insertions(+), 1047 deletions(-)
---
diff --git a/LongoMatch/Gui/EditSectionsDialog.cs b/LongoMatch/Gui/EditSectionsDialog.cs
new file mode 100644
index 0000000..424184a
--- /dev/null
+++ b/LongoMatch/Gui/EditSectionsDialog.cs
@@ -0,0 +1,61 @@
+// 
+//  Copyright (C) 2009 Andoni Morales Alastruey
+// 
+//  This program is free software; you can redistribute it and/or modify
+//  it under the terms of the GNU General Public License as published by
+//  the Free Software Foundation; either version 2 of the License, or
+//  (at your option) any later version.
+// 
+//  This program is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+//  GNU General Public License for more details.
+//  
+//  You should have received a copy of the GNU General Public License
+//  along with this program; if not, write to the Free Software
+//  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+// 
+
+using System;
+using System.Collections.Generic;
+using Gtk;
+using LongoMatch.TimeNodes;
+using LongoMatch.Handlers;
+using LongoMatch.Gui.Component;
+using LongoMatch.Gui;
+using Mono.Unix;
+
+namespace LongoMatch.Gui.Dialog
+{
+	
+	
+	public partial class EditSectionsDialog : Gtk.Dialog
+	{
+		private List<HotKey> hkList;
+		
+		public EditSectionsDialog()
+		{
+			this.Build();
+			timenodeproperties2.HotKeyChanged += OnHotKeyChanged;
+		}
+		
+		public SectionsTimeNode Section{
+			set{ timenodeproperties2.Section = value;}					
+		}
+		
+		public List<HotKey> HotKeysList{
+			set{hkList = value;}
+		}
+		
+		protected virtual void OnHotKeyChanged (HotKey prevHotKey,SectionsTimeNode section){
+			if (hkList.Contains(section.HotKey)){
+			    MessagePopup.PopupMessage(this,MessageType.Warning,
+				                        Catalog.GetString("This hotkey is already in use."));
+				section.HotKey=prevHotKey;
+				timenodeproperties2.Section=section; //Update Gui
+			}
+			else if (section.HotKey.Defined)
+				hkList.Add(section.HotKey);
+		}			
+	}	
+}
diff --git a/LongoMatch/Gui/PlayerProperties.cs b/LongoMatch/Gui/PlayerProperties.cs
index 540fb9c..5d81037 100644
--- a/LongoMatch/Gui/PlayerProperties.cs
+++ b/LongoMatch/Gui/PlayerProperties.cs
@@ -33,28 +33,22 @@ namespace LongoMatch.Gui.Component
 		private const int THUMBNAIL_MAX_WIDTH = 50;
 		private const int THUMBNAIL_MAX_HEIGHT = 50;
 		
+		private Player player;
+		
 		public PlayerProperties()
 		{
 			this.Build();
 		}
-		
-		public string Title{
-			set{
-				titlelabel.Text=value;	
-			}
-		}
-		
+				
 		public Player Player{
-			get{
-				return new Player (nameentry.Text, positionentry.Text, (int)numberspinbutton.Value, image.Pixbuf);
-			}
-			
 			set{
-				this.nameentry.Text = value.Name;
+				this.player = value;
+				nameentry.Text = value.Name;
 				positionentry.Text = value.Position;
 				numberspinbutton.Value = value.Number;
 				image.Pixbuf = value.Photo;
 			}
+			get{return player;}				
 		}
 		
 		private FileFilter FileFilter{
@@ -92,15 +86,33 @@ namespace LongoMatch.Gui.Component
 					w = pimage.Width;
 					rate = (double)w/(double)h;
 					if (h>w)
-						image.Pixbuf = pimage.ScaleSimple((int)(THUMBNAIL_MAX_HEIGHT*rate),THUMBNAIL_MAX_HEIGHT,InterpType.Bilinear);
+						player.Photo = pimage.ScaleSimple((int)(THUMBNAIL_MAX_HEIGHT*rate),THUMBNAIL_MAX_HEIGHT,InterpType.Bilinear);
 					else
-						image.Pixbuf = pimage.ScaleSimple(THUMBNAIL_MAX_WIDTH,(int)(THUMBNAIL_MAX_WIDTH/rate),InterpType.Bilinear);
+						player.Photo = pimage.ScaleSimple(THUMBNAIL_MAX_WIDTH,(int)(THUMBNAIL_MAX_WIDTH/rate),InterpType.Bilinear);
+					image.Pixbuf = player.Photo;
 				}
 			}
 			fChooser.Destroy();	
 		}
-		
-		
-	}
 
+		protected virtual void OnNameentryChanged (object sender, System.EventArgs e)
+		{
+			player.Name = nameentry.Text;
+		}
+
+		protected virtual void OnPositionentryChanged (object sender, System.EventArgs e)
+		{
+			player.Position = positionentry.Text;
+		}
+
+		protected virtual void OnNumberspinbuttonChanged (object sender, System.EventArgs e)
+		{
+			player.Number =(int) numberspinbutton.Value;
+		}
+
+		protected virtual void OnNumberspinbuttonValueChanged (object sender, System.EventArgs e)
+		{
+			player.Number =(int) numberspinbutton.Value;
+		}		
+	}
 }
diff --git a/LongoMatch/Gui/SectionsPropertiesWidget.cs b/LongoMatch/Gui/SectionsPropertiesWidget.cs
index c92cd3c..c28ec3b 100644
--- a/LongoMatch/Gui/SectionsPropertiesWidget.cs
+++ b/LongoMatch/Gui/SectionsPropertiesWidget.cs
@@ -23,6 +23,7 @@ using Mono.Unix;
 using Gdk;
 using LongoMatch.DB;
 using LongoMatch.TimeNodes;
+using LongoMatch.Gui.Dialog;
 
 
 namespace LongoMatch.Gui.Component
@@ -34,117 +35,68 @@ namespace LongoMatch.Gui.Component
 	public partial class SectionsPropertiesWidget : Gtk.Bin
 	{
 		private List<HotKey> hkList;
-		private List<TimeNodeProperties> tnplist;
 		private Project project;
-		
+		private Sections sections;
+		private SectionsTimeNode selectedSection;		
+		private bool edited = false;
 		
 		public SectionsPropertiesWidget()
 		{
 			this.Build();
-			tnplist = new List<TimeNodeProperties>();
 			hkList = new List<HotKey>();
-			table1.NColumns =(uint) 5;						
 		}
 		
 		public void SetProject(Project project){
 			this.project = project;
-			SetSections(project.Sections);
-		}
-		
-		public void SetSections(Sections sections){
-			int sectionsCount = sections.Count;
-			
-			tnplist.Clear();
-			hkList.Clear();
-			
-			foreach (Widget w in table1.AllChildren){
-					w.Unrealize();
-					table1.Remove(w);
-			}
-			
-			for( int i=0;i<sectionsCount;i++){
-				TimeNodeProperties tnp = new TimeNodeProperties();
-				HotKey hk = sections.GetHotKey(i);
-				
-				tnp.Name = i.ToString();
-				tnp.Title =  "Section "+(i+1);			
-				tnp.Section = sections.GetSection(i);
-				ConnectTimeNodePropertiesEvents(tnp);
-				
-				
-				if (hk.Defined)
-					hkList.Add(sections.GetHotKey(i));
-				
-				AddTimeNodeToTable(i,sections.Count,tnp);			
-			}			
-		}
-		
-		
-		
-		public Sections GetSections (){
-			Sections sections = new Sections();
-			foreach (TimeNodeProperties tnp in tnplist){
-				sections.AddSection(tnp.Section);					
+			Sections=project.Sections;
+		}	
+		
+		public Sections Sections{
+			get{return sections;}
+			set{
+				this.sections = value;
+				edited = false;
+				Gtk.TreeStore sectionsListStore = new Gtk.TreeStore (typeof (SectionsTimeNode));
+				hkList.Clear();
+				for (int i=0;i<sections.Count;i++){
+					sectionsListStore.AppendValues (sections.GetSection(i));
+					try{
+						hkList.Add(sections.GetSection(i).HotKey);
+					}catch{}; //Do not add duplicated hotkeys
+				}
+				sectionstreeview1.Model = sectionsListStore;
 			}
-			return sections;
 		}
 		
-		private void AddTimeNodeToTable(int index, int count, TimeNodeProperties tnp){
-			uint row_top,row_bottom,col_left,col_right;
-			
-			tnplist.Insert(index,tnp);
-			table1.NRows =(uint) (count/5);			
-			row_top =(uint) (index/table1.NColumns);
-			row_bottom = (uint) row_top+1 ;
-			col_left = (uint) index%table1.NColumns;
-			col_right = (uint) col_left+1 ;
-			
-			table1.Attach(tnp,col_left,col_right,row_top,row_bottom);	
-			tnp.Show();
+		public bool Edited{
+			get{return edited;}
+			set{edited=value;}
 		}
 		
-		private void ConnectTimeNodePropertiesEvents(TimeNodeProperties tnp){
-			tnp.DeleteSection += new EventHandler(OnDelete);
-			tnp.InsertAfter += new EventHandler(OnInsertAfter);
-			tnp.InsertBefore += new EventHandler(OnInsertBefore);
-			tnp.HotKeyChanged += new HotKeyChangeHandler(OnHotKeyChanged);
+		private void UpdateModel(){
+			Sections = Sections;
 		}
 		
 		private void AddSection (int index){
-			Sections sections;
 			SectionsTimeNode tn;
-			TimeNodeProperties tnp;
 			HotKey hkey = new HotKey();
 			
 			Time start = new Time(10*Time.SECONDS_TO_TIME);
-			Time stop = new Time(10*Time.SECONDS_TO_TIME);
-			
+			Time stop = new Time(10*Time.SECONDS_TO_TIME);			
 			
 			tn  = new SectionsTimeNode("New Section",start,stop,hkey,new Color(Byte.MaxValue,Byte.MinValue,Byte.MinValue));
-			tnp = new TimeNodeProperties();
-			ConnectTimeNodePropertiesEvents(tnp);
-			
+		
 			if (project != null){
 				project.AddSectionAtPos(tn,index);
-				AddTimeNodeToTable(project.Sections.Count-1,project.Sections.Count,tnp);
-				UpdateGui(project.Sections);
 			}
 			else{				
-				sections = GetSections();
 				sections.AddSectionAtPos(tn,index);
-				AddTimeNodeToTable(sections.Count-1,sections.Count,tnp);
-				UpdateGui(sections);
-			}			
+			}		
+			UpdateModel();
+			edited = true;
 		}
 		
-		private void DeleteSection(TimeNodeProperties tnp){
-			Sections sections;
-			int index = int.Parse(tnp.Name);
-			int count;
-			
-			//Remove the last TimeNodeProperties Widget and clean-up
-			
-
+		private void RemoveSection(int index){
 			if(project!= null){
 				try{
 					project.DeleteSection(index);
@@ -155,54 +107,65 @@ namespace LongoMatch.Gui.Component
 					return;
 				}
 				sections=project.Sections;
-			}
-			else{
-				sections = GetSections();
+			}else{
 				sections.RemoveSection(index);
 			}
-			count = tnplist.Count;
-			table1.Remove(tnplist[count-1]);
-			tnplist.Remove(tnplist[count-1]);
-			
-			UpdateGui(sections);
-			
+			UpdateModel();
+			edited = true;
+			selectedSection = null;
+			ButtonsSensitive=false;
 		}
 		
-		private void UpdateGui(Sections sections){
-			//After delting/adding a TimeNodeProperties we need to update
-			//both the widget names and their position in the table
-			TimeNodeProperties tnp;			
-			
-			for( int i=0;i< sections.Count;i++){
-				tnp=tnplist[i];
-				tnp.Name = i.ToString();
-				tnp.Title =  "Section "+(i+1);
-				tnp.Section = sections.GetSection(i);				
+		private bool ButtonsSensitive{
+			set{
+				newprevbutton.Sensitive = value;
+				newafterbutton.Sensitive = value;
+				removebutton.Sensitive = value;
+				editbutton.Sensitive = value;
 			}
-			
 		}
 		
-		protected virtual void OnDelete(object sender, EventArgs args){			
-			DeleteSection((TimeNodeProperties)sender);
+		private void EditSelectedSection(){
+			EditSectionsDialog dialog = new EditSectionsDialog();
+			dialog.Section=selectedSection;
+			dialog.HotKeysList = hkList;
+			dialog.TransientFor = (Gtk.Window) Toplevel;
+			dialog.Run();
+			dialog.Destroy();
+			edited = true;
 		}
 		
-		protected virtual void OnInsertAfter(object sender, EventArgs args){
-			AddSection(int.Parse(((Widget)sender).Name)+1);
+		protected virtual void OnNewAfter(object sender, EventArgs args){
+			AddSection(sections.SectionsTimeNodes.IndexOf(selectedSection)+1);
 		}
 		
-		protected virtual void OnInsertBefore(object sender, EventArgs args){
-			AddSection(int.Parse(((Widget)sender).Name));
+		protected virtual void OnNewBefore(object sender, EventArgs args){
+			AddSection(sections.SectionsTimeNodes.IndexOf(selectedSection));
 		}
 		
-		protected virtual void OnHotKeyChanged(TimeNodeProperties sender, HotKey prevHotKey, SectionsTimeNode section){
-			if (hkList.Contains(section.HotKey)){
-			    MessagePopup.PopupMessage(this,MessageType.Warning,
-				                        Catalog.GetString("This hotkey is already in use."));
-				section.HotKey = prevHotKey;
-				sender.Section = section;			
-			}
-			else if (section.HotKey.Defined)
-				hkList.Add(section.HotKey);
+		protected virtual void OnRemove(object sender, EventArgs args){			
+			RemoveSection(sections.SectionsTimeNodes.IndexOf(selectedSection));
+		}
+		
+		protected virtual void OnEdit(object sender, EventArgs args){			
+			EditSelectedSection();
+		}	
+
+		protected virtual void OnSectionstreeview1SectionClicked (LongoMatch.TimeNodes.SectionsTimeNode tNode)
+		{
+			EditSelectedSection();
+		}
+
+		protected virtual void OnSectionstreeview1SectionSelected (LongoMatch.TimeNodes.SectionsTimeNode tNode)
+		{
+			selectedSection = tNode;
+			ButtonsSensitive = selectedSection != null;
+		}
+
+		protected virtual void OnKeyPressEvent (object o, Gtk.KeyPressEventArgs args)
+		{
+			if (args.Event.Key == Gdk.Key.Delete && selectedSection != null)
+				RemoveSection(sections.SectionsTimeNodes.IndexOf(selectedSection));
 		}
 	}
 }
diff --git a/LongoMatch/Gui/SectionsTreeView.cs b/LongoMatch/Gui/SectionsTreeView.cs
new file mode 100644
index 0000000..f15f332
--- /dev/null
+++ b/LongoMatch/Gui/SectionsTreeView.cs
@@ -0,0 +1,137 @@
+// TreeWidgetPopup.cs
+//
+//  Copyright (C) 2007-2009 Andoni Morales Alastruey
+//
+// This program is free software; you can redistribute it and/or modify
+// it under the terms of the GNU General Public License as published by
+// the Free Software Foundation; either version 2 of the License, or
+// (at your option) any later version.
+//
+// This program is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+// GNU General Public License for more details.
+// 
+// You should have received a copy of the GNU General Public License
+// along with this program; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
+//
+//
+
+using System;
+using Gdk;
+using Gtk;
+using Mono.Unix;
+using LongoMatch.Handlers;
+using LongoMatch.TimeNodes;
+
+namespace LongoMatch.Gui.Component
+{
+	
+	public delegate void SectionHandler (SectionsTimeNode tNode);
+	
+	[System.ComponentModel.Category("LongoMatch")]
+	[System.ComponentModel.ToolboxItem(true)]
+	public class SectionsTreeView : Gtk.TreeView
+	{
+		public event SectionHandler SectionClicked;
+		public event SectionHandler SectionSelected;
+		
+		public SectionsTreeView(){
+			
+			RowActivated += OnTreeviewRowActivated;
+			CursorChanged += OnCursorChanged;
+			
+			Gtk.TreeViewColumn nameColumn = new Gtk.TreeViewColumn ();
+			nameColumn.Title = Catalog.GetString("Name");
+			Gtk.CellRendererText nameCell = new Gtk.CellRendererText ();
+			nameColumn.PackStart (nameCell, true);
+
+			Gtk.TreeViewColumn startTimeColumn = new Gtk.TreeViewColumn ();
+			startTimeColumn.Title = Catalog.GetString("Lead Time");
+			Gtk.CellRendererText startTimeCell = new Gtk.CellRendererText ();
+			startTimeColumn.PackStart (startTimeCell, true);
+			
+			Gtk.TreeViewColumn stopTimeColumn = new Gtk.TreeViewColumn ();
+			stopTimeColumn.Title = Catalog.GetString("Lag Time");
+			Gtk.CellRendererText stopTimeCell = new Gtk.CellRendererText ();
+			stopTimeColumn.PackStart (stopTimeCell, true);		
+			
+			Gtk.TreeViewColumn colorColumn = new Gtk.TreeViewColumn ();
+			colorColumn.Title = Catalog.GetString("Color");
+			Gtk.CellRendererText colorCell = new Gtk.CellRendererText ();
+			colorColumn.PackStart (colorCell, true);
+			
+			Gtk.TreeViewColumn hotKeyColumn = new Gtk.TreeViewColumn ();
+			hotKeyColumn.Title = Catalog.GetString("Hotkey");
+			Gtk.CellRendererText hotKeyCell = new Gtk.CellRendererText ();
+			hotKeyColumn.PackStart (hotKeyCell, true);
+	
+			nameColumn.SetCellDataFunc (nameCell, new Gtk.TreeCellDataFunc (RenderName));
+			startTimeColumn.SetCellDataFunc (startTimeCell, new Gtk.TreeCellDataFunc (RenderStartTime));
+			stopTimeColumn.SetCellDataFunc (stopTimeCell, new Gtk.TreeCellDataFunc (RenderStopTime));
+			colorColumn.SetCellDataFunc(colorCell, new Gtk.TreeCellDataFunc(RenderColor));
+			hotKeyColumn.SetCellDataFunc(hotKeyCell, new Gtk.TreeCellDataFunc(RenderHotKey));
+
+			AppendColumn (nameColumn);
+			AppendColumn (startTimeColumn);
+			AppendColumn (stopTimeColumn);
+			AppendColumn(colorColumn);
+			AppendColumn(hotKeyColumn);		
+		}					
+			
+		private void RenderName (Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
+		{
+			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue (iter, 0);
+	 
+			(cell as Gtk.CellRendererText).Text = tNode.Name;						
+		}
+ 
+		
+		private void RenderStartTime (Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
+		{
+			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue (iter, 0);
+			
+			(cell as Gtk.CellRendererText).Text =tNode.Start.Seconds.ToString();
+		}
+		
+		private void RenderStopTime (Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
+		{
+			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue (iter, 0);
+			
+			(cell as Gtk.CellRendererText).Text = tNode.Stop.Seconds.ToString();
+		}	
+		
+		private void RenderColor (Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
+		{
+			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue (iter, 0);
+			
+			(cell as Gtk.CellRendererText).CellBackgroundGdk = tNode.Color;
+		}	
+		
+		private void RenderHotKey (Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
+		{
+			SectionsTimeNode tNode = (SectionsTimeNode) Model.GetValue (iter, 0);
+			
+			(cell as Gtk.CellRendererText).Text = tNode.HotKey.ToString();			
+		}	
+		
+		protected virtual void OnCursorChanged (object o, System.EventArgs e){
+			TreeIter iter;
+			Selection.GetSelected(out iter);
+			SectionsTimeNode tNode = (SectionsTimeNode) Model.GetValue (iter, 0);
+			if (SectionSelected != null)
+				SectionSelected(tNode);
+		}
+		
+		protected virtual void OnTreeviewRowActivated(object o, Gtk.RowActivatedArgs args)
+		{
+			Gtk.TreeIter iter;
+			Model.GetIter (out iter, args.Path);
+			SectionsTimeNode tNode = (SectionsTimeNode)Model.GetValue (iter, 0);
+			
+			if (SectionClicked != null)
+				SectionClicked(tNode);				
+		}
+	}
+}
\ No newline at end of file
diff --git a/LongoMatch/Gui/TeamTemplateEditor.cs b/LongoMatch/Gui/TeamTemplateEditor.cs
index 54d619b..1ebd4b1 100644
--- a/LongoMatch/Gui/TeamTemplateEditor.cs
+++ b/LongoMatch/Gui/TeamTemplateEditor.cs
@@ -32,11 +32,11 @@ namespace LongoMatch.Gui.Dialog
 		}
 		
 		public void SetTeamTemplate (TeamTemplate template){
-			teamtemplatewidget1.SetTeamTemplate(template);
+			teamtemplatewidget1.TeamTemplate=template;
 		}
 		
 		public TeamTemplate GetTeamTemplate (){
-			return teamtemplatewidget1.GetTeamTemplate();
+			return teamtemplatewidget1.TeamTemplate;
 		}
 	}
 }
diff --git a/LongoMatch/Gui/TeamTemplateWidget.cs b/LongoMatch/Gui/TeamTemplateWidget.cs
index 302f24f..e8d068a 100644
--- a/LongoMatch/Gui/TeamTemplateWidget.cs
+++ b/LongoMatch/Gui/TeamTemplateWidget.cs
@@ -30,57 +30,55 @@ namespace LongoMatch.Gui.Component
 	[System.ComponentModel.ToolboxItem(true)]
 	public partial class TeamTemplateWidget : Gtk.Bin
 	{
-		private List<PlayerProperties> pplist;
+		private TeamTemplate template;
+		private Player selectedPlayer;
+		private bool edited;
 		
 		public TeamTemplateWidget()
 		{
-			this.Build();
-			pplist = new List<PlayerProperties>();
-			table1.NColumns =(uint) 5;
+			this.Build();			
 		}
 		
-		public void SetTeamTemplate(TeamTemplate template){
-			int playersCount = template.PlayersCount;
-			
-			pplist.Clear();
-			
-			foreach (Widget w in table1.AllChildren){
-					w.Unrealize();
-					table1.Remove(w);
+		public TeamTemplate TeamTemplate{
+			get{return template;}
+			set{
+				this.template= value;
+				edited = false;
+				Gtk.TreeStore playersListStore = new Gtk.TreeStore (typeof (Player));
+				for (int i=0;i<template.PlayersCount;i++)
+					playersListStore.AppendValues (template.GetPlayer(i));				
+				playerpropertiestreeview1.Model=playersListStore;
 			}
-			
-			for( int i=0;i<playersCount;i++){
-				PlayerProperties pp = new PlayerProperties();
-				
-				pp.Name = i.ToString();
-				pp.Title =  "Player "+(i+1);			
-				pp.Player = template.GetPlayer(i);
-			
-				AddPlayerToTable(i,template.PlayersCount,pp);			
-			}		
-			
 		}
 		
-		public TeamTemplate GetTeamTemplate(){
-			TeamTemplate template = new TeamTemplate();
-			foreach (PlayerProperties pp in pplist){
-				template.AddPlayer(pp.Player);					
-			}
-			return template;
+		public bool Edited{
+			get{return edited;}
+			set{edited=value;}
 		}
 		
-		private void AddPlayerToTable(int index, int count, PlayerProperties pp){
-			uint row_top,row_bottom,col_left,col_right;
-			
-			pplist.Insert(index,pp);
-			table1.NRows =(uint) (count/5);			
-			row_top =(uint) (index/table1.NColumns);
-			row_bottom = (uint) row_top+1 ;
-			col_left = (uint) index%table1.NColumns;
-			col_right = (uint) col_left+1 ;
-			
-			table1.Attach(pp,col_left,col_right,row_top,row_bottom);	
-			pp.Show();
+		private void UpdateModel(){
+			TeamTemplate = template;
+		}
+						
+		private void EditSelectedPlayer(){
+			LongoMatch.Gui.Dialog.EditPlayerDialog dialog = new LongoMatch.Gui.Dialog.EditPlayerDialog();
+			dialog.Player=selectedPlayer;
+			dialog.TransientFor = (Gtk.Window) Toplevel;
+			dialog.Run();
+			dialog.Destroy();
+			edited = true;
+		}
+
+		protected virtual void OnPlayerpropertiestreeview1PlayerClicked (LongoMatch.TimeNodes.Player player)
+		{
+			selectedPlayer = player;
+			EditSelectedPlayer();
 		}
+
+		protected virtual void OnPlayerpropertiestreeview1PlayerSelected (LongoMatch.TimeNodes.Player player)
+		{
+			selectedPlayer = player;
+		}	
+
 	}
 }
diff --git a/LongoMatch/Gui/TemplateEditorDialog.cs b/LongoMatch/Gui/TemplateEditorDialog.cs
index 7fc21b4..2666898 100644
--- a/LongoMatch/Gui/TemplateEditorDialog.cs
+++ b/LongoMatch/Gui/TemplateEditorDialog.cs
@@ -38,8 +38,12 @@ namespace LongoMatch.Gui.Dialog
 		}
 		
 		public Sections Sections{
-			set{this.sectionspropertieswidget3.SetSections(value);}
-			get{return this.sectionspropertieswidget3.GetSections();}
+			set{this.sectionspropertieswidget3.Sections=value;}
+			get{return this.sectionspropertieswidget3.Sections;}
+		}
+
+		protected virtual void OnButtonOkClicked (object sender, System.EventArgs e)
+		{
 		}
 	
 	}
diff --git a/LongoMatch/Gui/TemplatesEditor.cs b/LongoMatch/Gui/TemplatesEditor.cs
index a1cec81..4a02aef 100644
--- a/LongoMatch/Gui/TemplatesEditor.cs
+++ b/LongoMatch/Gui/TemplatesEditor.cs
@@ -97,13 +97,13 @@ namespace LongoMatch.Gui.Dialog
 		public void SetSectionsTemplate(Sections sections){	
 			if (useType != UseType.SectionsTemplate)
 				return;
-			sectionspropertieswidget1.SetSections(sections);			
+			sectionspropertieswidget1.Sections=sections;			
 		}	
 		
 		public void SetTeamTemplate(TeamTemplate template){
 			if (useType != UseType.TeamTemplate)
 				return;
-			teamtemplatewidget1.SetTeamTemplate(template);
+			teamtemplatewidget1.TeamTemplate=template;
 		}
 		
 		private void UpdateSections(){
@@ -148,17 +148,32 @@ namespace LongoMatch.Gui.Dialog
 				model.IterNext(ref iter);
 			}
 		}
-
-		protected virtual void OnSavebuttonClicked (object sender, System.EventArgs e)
-		{
+		
+		private void SaveTemplate(){
 			if (useType == UseType.SectionsTemplate){
-				selectedSectionsTemplate = sectionspropertieswidget1.GetSections();
+				selectedSectionsTemplate = sectionspropertieswidget1.Sections;
 				SectionsWriter.UpdateTemplate (templateName,selectedSectionsTemplate);	
 			}
 			else{
-				selectedTeamTemplate = teamtemplatewidget1.GetTeamTemplate();
+				selectedTeamTemplate = teamtemplatewidget1.TeamTemplate;
 				selectedTeamTemplate.Save(templateName);
-			}		
+			}
+		}
+		
+		private void PromptForSave(){
+			MessageDialog mes = new MessageDialog(this,DialogFlags.Modal,MessageType.Question,ButtonsType.YesNo,
+			                                      Catalog.GetString("The template has been modified. Do you want to save it? "));
+			if (mes.Run() == (int)ResponseType.Yes){
+				SaveTemplate();					
+			}
+			mes.Destroy();		
+		}
+
+		protected virtual void OnSavebuttonClicked (object sender, System.EventArgs e)
+		{
+			SaveTemplate();		
+			sectionspropertieswidget1.Edited=false;
+			teamtemplatewidget1.Edited=false;
 		}
 
 		protected virtual void OnNewbuttonClicked (object sender, System.EventArgs e)
@@ -219,8 +234,7 @@ namespace LongoMatch.Gui.Dialog
 				//properties.
 				SelectTemplate("default");
 			}
-			mes.Destroy();	
-		
+			mes.Destroy();			
 		}
 
 		protected virtual void OnButtonCancelClicked (object sender, System.EventArgs e)
@@ -232,17 +246,23 @@ namespace LongoMatch.Gui.Dialog
 		{			
 			TreeIter iter;
 
+			if (sectionspropertieswidget1.Edited || teamtemplatewidget1.Edited)
+				PromptForSave();			
+				
 			treeview.Selection.GetSelected(out iter);
 			templateName = (string) this.dataFileListStore.GetValue (iter, 0);
 			
 			if (useType == UseType.SectionsTemplate)
 				UpdateSections();
+			
 			else
 				UpdateTeamTemplate();
 		}
 
 		protected virtual void OnButtonOkClicked (object sender, System.EventArgs e)
 		{
+			if (sectionspropertieswidget1.Edited)
+				PromptForSave();
 			this.Destroy();
 		}
 
diff --git a/LongoMatch/Gui/TimeNodeProperties.cs b/LongoMatch/Gui/TimeNodeProperties.cs
index 0ec8f29..620eb56 100644
--- a/LongoMatch/Gui/TimeNodeProperties.cs
+++ b/LongoMatch/Gui/TimeNodeProperties.cs
@@ -28,16 +28,13 @@ using LongoMatch.Gui.Dialog;
 namespace LongoMatch.Gui.Component
 {
 	
-	public delegate void HotKeyChangeHandler (TimeNodeProperties  sender,HotKey prevHotKey, SectionsTimeNode newSection);
+	public delegate void HotKeyChangeHandler (HotKey prevHotKey, SectionsTimeNode newSection);
 	
 	[System.ComponentModel.Category("LongoMatch")]
 	[System.ComponentModel.ToolboxItem(true)]
 	public partial  class TimeNodeProperties : Gtk.Bin
 	{
 
-		public event EventHandler DeleteSection;
-		public event EventHandler InsertBefore;
-		public event EventHandler InsertAfter;
 		public event HotKeyChangeHandler HotKeyChanged;
 		
 		private SectionsTimeNode stn;
@@ -45,24 +42,15 @@ namespace LongoMatch.Gui.Component
 		public TimeNodeProperties()
 		{
 			this.Build();
-		}
-		
-		public string Title {
-			set{
-				titlelabel.Text=value;	
-			}
-		}
+		}				
 		
 		public SectionsTimeNode Section
 		{
 			set{
 				stn = value;
 				UpdateGui();	
-			}
-			
-			get{
-				return stn;
-			}
+			}			
+			get{return stn;	}
 		}
 
 		private void  UpdateGui(){
@@ -89,30 +77,9 @@ namespace LongoMatch.Gui.Component
 			}
 			dialog.Destroy();	
 			if (HotKeyChanged != null)
-					HotKeyChanged(this,prevHotKey,stn);
-		}
-
-		protected virtual void OnDeletebuttonClicked (object sender, System.EventArgs e)
-		{
-			if (DeleteSection !=  null){
-				DeleteSection(this, e);
-			}
+					HotKeyChanged(prevHotKey,stn);
 		}
-
-		protected virtual void OnNewleftbuttonClicked (object sender, System.EventArgs e)
-		{
-			if(InsertAfter != null){
-				InsertAfter(this, e);
-			}
-		}
-
-		protected virtual void OnNewleftbutton1Clicked (object sender, System.EventArgs e)
-		{
-			if (InsertBefore != null){
-				InsertBefore(this, e);
-			}
-		}
-
+	
 		protected virtual void OnColorbutton1ColorSet (object sender, System.EventArgs e)
 		{
 			if (stn != null)
diff --git a/LongoMatch/LongoMatch.mdp b/LongoMatch/LongoMatch.mdp
index 93c59c8..a080a22 100644
--- a/LongoMatch/LongoMatch.mdp
+++ b/LongoMatch/LongoMatch.mdp
@@ -147,6 +147,12 @@
     <File name="gtk-gui/LongoMatch.Gui.Component.DrawingToolBox.cs" subtype="Code" buildaction="Compile" />
     <File name="Gui/DrawingToolBox.cs" subtype="Code" buildaction="Compile" />
     <File name="Handlers/DrawingManager.cs" subtype="Code" buildaction="Compile" />
+    <File name="Gui/SectionsTreeView.cs" subtype="Code" buildaction="Compile" />
+    <File name="gtk-gui/LongoMatch.Gui.Dialog.EditSectionsDialog.cs" subtype="Code" buildaction="Compile" />
+    <File name="Gui/EditSectionsDialog.cs" subtype="Code" buildaction="Compile" />
+    <File name="Gui/PlayerPropertiesTreeView.cs" subtype="Code" buildaction="Compile" />
+    <File name="Gui/EditPlayerDialog.cs" subtype="Code" buildaction="Compile" />
+    <File name="gtk-gui/LongoMatch.Gui.Dialog.EditPlayerDialog.cs" subtype="Code" buildaction="Compile" />
   </Contents>
   <References>
     <ProjectReference type="Gac" localcopy="True" refto="Mono.Posix, Version=2.0.0.0, Culture=neutral, PublicKeyToken=0738eb9f132ed756" />
diff --git a/LongoMatch/Makefile.am b/LongoMatch/Makefile.am
index 0bf7687..1a24508 100644
--- a/LongoMatch/Makefile.am
+++ b/LongoMatch/Makefile.am
@@ -81,6 +81,7 @@ FILES = \
 	Gui/CalendarPopup.cs \
 	Gui/DBManager.cs \
 	Gui/DrawingToolBox.cs\
+	Gui/EditSectionsDialog.cs\
 	Gui/ProjectListWidget.cs \
 	Gui/FileDescriptionWidget.cs \
 	Gui/FramesCaptureProgressDialog.cs \
@@ -98,6 +99,7 @@ FILES = \
 	Gui/PlayListTreeView.cs \
 	Gui/PlayListWidget.cs \
 	Gui/SectionsPropertiesWidget.cs \
+	Gui/SectionsTreeView.cs\
 	Gui/SnapshotsDialog.cs \
 	Gui/TeamTemplateEditor.cs \
 	Gui/TeamTemplateWidget.cs \
@@ -132,6 +134,7 @@ FILES = \
 	gtk-gui/LongoMatch.Gui.Component.FileDescriptionWidget.cs \
 	gtk-gui/LongoMatch.Gui.Component.ProjectListWidget.cs \
 	gtk-gui/LongoMatch.Gui.Component.TreeWidget.cs \
+	gtk-gui/LongoMatch.Gui.Dialog.EditSectionsDialog.cs\
 	gtk-gui/LongoMatch.Gui.Popup.CalendarPopup.cs \
 	gtk-gui/LongoMatch.Gui.Popup.TransparentDrawingArea.cs\
 	gtk-gui/LongoMatch.Gui.Component.ButtonsWidget.cs \
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
index 8b7d535..72cf103 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.PlayerProperties.cs
@@ -13,10 +13,6 @@ namespace LongoMatch.Gui.Component {
     
     public partial class PlayerProperties {
         
-        private Gtk.Frame frame1;
-        
-        private Gtk.Alignment GtkAlignment;
-        
         private Gtk.Table table1;
         
         private Gtk.HBox hbox1;
@@ -39,21 +35,12 @@ namespace LongoMatch.Gui.Component {
         
         private Gtk.Entry positionentry;
         
-        private Gtk.Label titlelabel;
-        
         protected virtual void Build() {
             Stetic.Gui.Initialize(this);
             // Widget LongoMatch.Gui.Component.PlayerProperties
             Stetic.BinContainer.Attach(this);
             this.Name = "LongoMatch.Gui.Component.PlayerProperties";
             // Container child LongoMatch.Gui.Component.PlayerProperties.Gtk.Container+ContainerChild
-            this.frame1 = new Gtk.Frame();
-            this.frame1.Name = "frame1";
-            // Container child frame1.Gtk.Container+ContainerChild
-            this.GtkAlignment = new Gtk.Alignment(0F, 0F, 1F, 1F);
-            this.GtkAlignment.Name = "GtkAlignment";
-            this.GtkAlignment.LeftPadding = ((uint)(12));
-            // Container child GtkAlignment.Gtk.Container+ContainerChild
             this.table1 = new Gtk.Table(((uint)(4)), ((uint)(2)), false);
             this.table1.Name = "table1";
             this.table1.RowSpacing = ((uint)(6));
@@ -166,18 +153,15 @@ namespace LongoMatch.Gui.Component {
             w10.RightAttach = ((uint)(2));
             w10.XOptions = ((Gtk.AttachOptions)(4));
             w10.YOptions = ((Gtk.AttachOptions)(4));
-            this.GtkAlignment.Add(this.table1);
-            this.frame1.Add(this.GtkAlignment);
-            this.titlelabel = new Gtk.Label();
-            this.titlelabel.Name = "titlelabel";
-            this.titlelabel.LabelProp = Mono.Unix.Catalog.GetString("<b>frame1</b>");
-            this.titlelabel.UseMarkup = true;
-            this.frame1.LabelWidget = this.titlelabel;
-            this.Add(this.frame1);
+            this.Add(this.table1);
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
             this.Hide();
+            this.positionentry.Changed += new System.EventHandler(this.OnPositionentryChanged);
+            this.numberspinbutton.EditingDone += new System.EventHandler(this.OnNumberspinbuttonChanged);
+            this.numberspinbutton.ValueChanged += new System.EventHandler(this.OnNumberspinbuttonValueChanged);
+            this.nameentry.Changed += new System.EventHandler(this.OnNameentryChanged);
             this.openbutton.Clicked += new System.EventHandler(this.OnOpenbuttonClicked);
         }
     }
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.SectionsPropertiesWidget.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.SectionsPropertiesWidget.cs
index 1722305..c3587ce 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.SectionsPropertiesWidget.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.SectionsPropertiesWidget.cs
@@ -13,9 +13,21 @@ namespace LongoMatch.Gui.Component {
     
     public partial class SectionsPropertiesWidget {
         
-        private Gtk.ScrolledWindow scrolledwindow1;
+        private Gtk.HBox hbox1;
         
-        private Gtk.Table table1;
+        private Gtk.ScrolledWindow scrolledwindow2;
+        
+        private LongoMatch.Gui.Component.SectionsTreeView sectionstreeview1;
+        
+        private Gtk.VBox vbox2;
+        
+        private Gtk.Button newprevbutton;
+        
+        private Gtk.Button newafterbutton;
+        
+        private Gtk.Button removebutton;
+        
+        private Gtk.Button editbutton;
         
         protected virtual void Build() {
             Stetic.Gui.Initialize(this);
@@ -23,25 +35,152 @@ namespace LongoMatch.Gui.Component {
             Stetic.BinContainer.Attach(this);
             this.Name = "LongoMatch.Gui.Component.SectionsPropertiesWidget";
             // Container child LongoMatch.Gui.Component.SectionsPropertiesWidget.Gtk.Container+ContainerChild
-            this.scrolledwindow1 = new Gtk.ScrolledWindow();
-            this.scrolledwindow1.CanFocus = true;
-            this.scrolledwindow1.Name = "scrolledwindow1";
-            this.scrolledwindow1.ShadowType = ((Gtk.ShadowType)(1));
-            // Container child scrolledwindow1.Gtk.Container+ContainerChild
-            Gtk.Viewport w1 = new Gtk.Viewport();
-            w1.ShadowType = ((Gtk.ShadowType)(0));
-            // Container child GtkViewport.Gtk.Container+ContainerChild
-            this.table1 = new Gtk.Table(((uint)(3)), ((uint)(3)), true);
-            this.table1.Name = "table1";
-            this.table1.RowSpacing = ((uint)(6));
-            this.table1.ColumnSpacing = ((uint)(6));
-            w1.Add(this.table1);
-            this.scrolledwindow1.Add(w1);
-            this.Add(this.scrolledwindow1);
+            this.hbox1 = new Gtk.HBox();
+            this.hbox1.Name = "hbox1";
+            this.hbox1.Spacing = 6;
+            // Container child hbox1.Gtk.Box+BoxChild
+            this.scrolledwindow2 = new Gtk.ScrolledWindow();
+            this.scrolledwindow2.CanFocus = true;
+            this.scrolledwindow2.Name = "scrolledwindow2";
+            this.scrolledwindow2.ShadowType = ((Gtk.ShadowType)(1));
+            // Container child scrolledwindow2.Gtk.Container+ContainerChild
+            this.sectionstreeview1 = new LongoMatch.Gui.Component.SectionsTreeView();
+            this.sectionstreeview1.CanFocus = true;
+            this.sectionstreeview1.Name = "sectionstreeview1";
+            this.scrolledwindow2.Add(this.sectionstreeview1);
+            this.hbox1.Add(this.scrolledwindow2);
+            Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(this.hbox1[this.scrolledwindow2]));
+            w2.Position = 0;
+            // Container child hbox1.Gtk.Box+BoxChild
+            this.vbox2 = new Gtk.VBox();
+            this.vbox2.Name = "vbox2";
+            this.vbox2.Spacing = 6;
+            // Container child vbox2.Gtk.Box+BoxChild
+            this.newprevbutton = new Gtk.Button();
+            this.newprevbutton.Sensitive = false;
+            this.newprevbutton.CanFocus = true;
+            this.newprevbutton.Name = "newprevbutton";
+            this.newprevbutton.UseUnderline = true;
+            // Container child newprevbutton.Gtk.Container+ContainerChild
+            Gtk.Alignment w3 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
+            // Container child GtkAlignment.Gtk.Container+ContainerChild
+            Gtk.HBox w4 = new Gtk.HBox();
+            w4.Spacing = 2;
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Image w5 = new Gtk.Image();
+            w5.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-goto-top", Gtk.IconSize.Menu, 16);
+            w4.Add(w5);
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Label w7 = new Gtk.Label();
+            w7.LabelProp = Mono.Unix.Catalog.GetString("New Before");
+            w7.UseUnderline = true;
+            w4.Add(w7);
+            w3.Add(w4);
+            this.newprevbutton.Add(w3);
+            this.vbox2.Add(this.newprevbutton);
+            Gtk.Box.BoxChild w11 = ((Gtk.Box.BoxChild)(this.vbox2[this.newprevbutton]));
+            w11.Position = 0;
+            w11.Expand = false;
+            w11.Fill = false;
+            // Container child vbox2.Gtk.Box+BoxChild
+            this.newafterbutton = new Gtk.Button();
+            this.newafterbutton.Sensitive = false;
+            this.newafterbutton.CanFocus = true;
+            this.newafterbutton.Name = "newafterbutton";
+            this.newafterbutton.UseUnderline = true;
+            // Container child newafterbutton.Gtk.Container+ContainerChild
+            Gtk.Alignment w12 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
+            // Container child GtkAlignment.Gtk.Container+ContainerChild
+            Gtk.HBox w13 = new Gtk.HBox();
+            w13.Spacing = 2;
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Image w14 = new Gtk.Image();
+            w14.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-goto-bottom", Gtk.IconSize.Menu, 16);
+            w13.Add(w14);
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Label w16 = new Gtk.Label();
+            w16.LabelProp = Mono.Unix.Catalog.GetString("New After");
+            w16.UseUnderline = true;
+            w13.Add(w16);
+            w12.Add(w13);
+            this.newafterbutton.Add(w12);
+            this.vbox2.Add(this.newafterbutton);
+            Gtk.Box.BoxChild w20 = ((Gtk.Box.BoxChild)(this.vbox2[this.newafterbutton]));
+            w20.Position = 1;
+            w20.Expand = false;
+            w20.Fill = false;
+            // Container child vbox2.Gtk.Box+BoxChild
+            this.removebutton = new Gtk.Button();
+            this.removebutton.Sensitive = false;
+            this.removebutton.CanFocus = true;
+            this.removebutton.Name = "removebutton";
+            this.removebutton.UseUnderline = true;
+            // Container child removebutton.Gtk.Container+ContainerChild
+            Gtk.Alignment w21 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
+            // Container child GtkAlignment.Gtk.Container+ContainerChild
+            Gtk.HBox w22 = new Gtk.HBox();
+            w22.Spacing = 2;
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Image w23 = new Gtk.Image();
+            w23.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-remove", Gtk.IconSize.Menu, 16);
+            w22.Add(w23);
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Label w25 = new Gtk.Label();
+            w25.LabelProp = Mono.Unix.Catalog.GetString("Remove");
+            w25.UseUnderline = true;
+            w22.Add(w25);
+            w21.Add(w22);
+            this.removebutton.Add(w21);
+            this.vbox2.Add(this.removebutton);
+            Gtk.Box.BoxChild w29 = ((Gtk.Box.BoxChild)(this.vbox2[this.removebutton]));
+            w29.Position = 2;
+            w29.Expand = false;
+            w29.Fill = false;
+            // Container child vbox2.Gtk.Box+BoxChild
+            this.editbutton = new Gtk.Button();
+            this.editbutton.Sensitive = false;
+            this.editbutton.CanFocus = true;
+            this.editbutton.Name = "editbutton";
+            this.editbutton.UseUnderline = true;
+            // Container child editbutton.Gtk.Container+ContainerChild
+            Gtk.Alignment w30 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
+            // Container child GtkAlignment.Gtk.Container+ContainerChild
+            Gtk.HBox w31 = new Gtk.HBox();
+            w31.Spacing = 2;
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Image w32 = new Gtk.Image();
+            w32.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-edit", Gtk.IconSize.Menu, 16);
+            w31.Add(w32);
+            // Container child GtkHBox.Gtk.Container+ContainerChild
+            Gtk.Label w34 = new Gtk.Label();
+            w34.LabelProp = Mono.Unix.Catalog.GetString("Edit");
+            w34.UseUnderline = true;
+            w31.Add(w34);
+            w30.Add(w31);
+            this.editbutton.Add(w30);
+            this.vbox2.Add(this.editbutton);
+            Gtk.Box.BoxChild w38 = ((Gtk.Box.BoxChild)(this.vbox2[this.editbutton]));
+            w38.Position = 3;
+            w38.Expand = false;
+            w38.Fill = false;
+            this.hbox1.Add(this.vbox2);
+            Gtk.Box.BoxChild w39 = ((Gtk.Box.BoxChild)(this.hbox1[this.vbox2]));
+            w39.Position = 1;
+            w39.Expand = false;
+            w39.Fill = false;
+            this.Add(this.hbox1);
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
             this.Show();
+            this.KeyPressEvent += new Gtk.KeyPressEventHandler(this.OnKeyPressEvent);
+            this.sectionstreeview1.SectionClicked += new LongoMatch.Gui.Component.SectionHandler(this.OnSectionstreeview1SectionClicked);
+            this.sectionstreeview1.SectionSelected += new LongoMatch.Gui.Component.SectionHandler(this.OnSectionstreeview1SectionSelected);
+            this.newprevbutton.Clicked += new System.EventHandler(this.OnNewBefore);
+            this.newafterbutton.Clicked += new System.EventHandler(this.OnNewAfter);
+            this.newafterbutton.Activated += new System.EventHandler(this.OnNewBefore);
+            this.removebutton.Clicked += new System.EventHandler(this.OnRemove);
+            this.editbutton.Clicked += new System.EventHandler(this.OnEdit);
         }
     }
 }
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTemplateWidget.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTemplateWidget.cs
index 623e45b..b52f120 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTemplateWidget.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TeamTemplateWidget.cs
@@ -13,9 +13,11 @@ namespace LongoMatch.Gui.Component {
     
     public partial class TeamTemplateWidget {
         
+        private Gtk.HBox hbox1;
+        
         private Gtk.ScrolledWindow scrolledwindow2;
         
-        private Gtk.Table table1;
+        private LongoMatch.Gui.Component.PlayerPropertiesTreeView playerpropertiestreeview1;
         
         protected virtual void Build() {
             Stetic.Gui.Initialize(this);
@@ -23,25 +25,29 @@ namespace LongoMatch.Gui.Component {
             Stetic.BinContainer.Attach(this);
             this.Name = "LongoMatch.Gui.Component.TeamTemplateWidget";
             // Container child LongoMatch.Gui.Component.TeamTemplateWidget.Gtk.Container+ContainerChild
+            this.hbox1 = new Gtk.HBox();
+            this.hbox1.Name = "hbox1";
+            this.hbox1.Spacing = 6;
+            // Container child hbox1.Gtk.Box+BoxChild
             this.scrolledwindow2 = new Gtk.ScrolledWindow();
             this.scrolledwindow2.CanFocus = true;
             this.scrolledwindow2.Name = "scrolledwindow2";
             this.scrolledwindow2.ShadowType = ((Gtk.ShadowType)(1));
             // Container child scrolledwindow2.Gtk.Container+ContainerChild
-            Gtk.Viewport w1 = new Gtk.Viewport();
-            w1.ShadowType = ((Gtk.ShadowType)(0));
-            // Container child GtkViewport.Gtk.Container+ContainerChild
-            this.table1 = new Gtk.Table(((uint)(3)), ((uint)(3)), false);
-            this.table1.Name = "table1";
-            this.table1.RowSpacing = ((uint)(6));
-            this.table1.ColumnSpacing = ((uint)(6));
-            w1.Add(this.table1);
-            this.scrolledwindow2.Add(w1);
-            this.Add(this.scrolledwindow2);
+            this.playerpropertiestreeview1 = new LongoMatch.Gui.Component.PlayerPropertiesTreeView();
+            this.playerpropertiestreeview1.CanFocus = true;
+            this.playerpropertiestreeview1.Name = "playerpropertiestreeview1";
+            this.scrolledwindow2.Add(this.playerpropertiestreeview1);
+            this.hbox1.Add(this.scrolledwindow2);
+            Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(this.hbox1[this.scrolledwindow2]));
+            w2.Position = 0;
+            this.Add(this.hbox1);
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
             this.Hide();
+            this.playerpropertiestreeview1.PlayerClicked += new LongoMatch.Gui.Component.PlayerPropertiesHandler(this.OnPlayerpropertiestreeview1PlayerClicked);
+            this.playerpropertiestreeview1.PlayerSelected += new LongoMatch.Gui.Component.PlayerPropertiesHandler(this.OnPlayerpropertiestreeview1PlayerSelected);
         }
     }
 }
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeNodeProperties.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeNodeProperties.cs
index 2880234..08c5ea3 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeNodeProperties.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Component.TimeNodeProperties.cs
@@ -13,20 +13,6 @@ namespace LongoMatch.Gui.Component {
     
     public partial class TimeNodeProperties {
         
-        private Gtk.Frame frame1;
-        
-        private Gtk.Alignment GtkAlignment;
-        
-        private Gtk.HBox hbox1;
-        
-        private Gtk.VBox vbox2;
-        
-        private Gtk.Button newleftbutton;
-        
-        private Gtk.Button newleftbutton1;
-        
-        private Gtk.Button deletebutton;
-        
         private Gtk.VBox vbox3;
         
         private Gtk.HBox hbox4;
@@ -49,108 +35,12 @@ namespace LongoMatch.Gui.Component {
         
         private Gtk.Label label6;
         
-        private Gtk.Label titlelabel;
-        
         protected virtual void Build() {
             Stetic.Gui.Initialize(this);
             // Widget LongoMatch.Gui.Component.TimeNodeProperties
             Stetic.BinContainer.Attach(this);
             this.Name = "LongoMatch.Gui.Component.TimeNodeProperties";
             // Container child LongoMatch.Gui.Component.TimeNodeProperties.Gtk.Container+ContainerChild
-            this.frame1 = new Gtk.Frame();
-            this.frame1.Name = "frame1";
-            this.frame1.BorderWidth = ((uint)(1));
-            // Container child frame1.Gtk.Container+ContainerChild
-            this.GtkAlignment = new Gtk.Alignment(0F, 0F, 1F, 1F);
-            this.GtkAlignment.Name = "GtkAlignment";
-            this.GtkAlignment.LeftPadding = ((uint)(12));
-            // Container child GtkAlignment.Gtk.Container+ContainerChild
-            this.hbox1 = new Gtk.HBox();
-            this.hbox1.Name = "hbox1";
-            this.hbox1.Spacing = 6;
-            // Container child hbox1.Gtk.Box+BoxChild
-            this.vbox2 = new Gtk.VBox();
-            this.vbox2.Name = "vbox2";
-            this.vbox2.Spacing = 6;
-            // Container child vbox2.Gtk.Box+BoxChild
-            this.newleftbutton = new Gtk.Button();
-            this.newleftbutton.TooltipMarkup = "Insert After";
-            this.newleftbutton.CanFocus = true;
-            this.newleftbutton.Name = "newleftbutton";
-            this.newleftbutton.UseUnderline = true;
-            // Container child newleftbutton.Gtk.Container+ContainerChild
-            Gtk.Alignment w1 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
-            // Container child GtkAlignment.Gtk.Container+ContainerChild
-            Gtk.HBox w2 = new Gtk.HBox();
-            w2.Spacing = 2;
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Image w3 = new Gtk.Image();
-            w3.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-goto-last", Gtk.IconSize.Menu, 16);
-            w2.Add(w3);
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Label w5 = new Gtk.Label();
-            w2.Add(w5);
-            w1.Add(w2);
-            this.newleftbutton.Add(w1);
-            this.vbox2.Add(this.newleftbutton);
-            Gtk.Box.BoxChild w9 = ((Gtk.Box.BoxChild)(this.vbox2[this.newleftbutton]));
-            w9.Position = 0;
-            w9.Fill = false;
-            // Container child vbox2.Gtk.Box+BoxChild
-            this.newleftbutton1 = new Gtk.Button();
-            this.newleftbutton1.TooltipMarkup = "InsertBefore";
-            this.newleftbutton1.CanFocus = true;
-            this.newleftbutton1.Name = "newleftbutton1";
-            this.newleftbutton1.UseUnderline = true;
-            // Container child newleftbutton1.Gtk.Container+ContainerChild
-            Gtk.Alignment w10 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
-            // Container child GtkAlignment.Gtk.Container+ContainerChild
-            Gtk.HBox w11 = new Gtk.HBox();
-            w11.Spacing = 2;
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Image w12 = new Gtk.Image();
-            w12.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-goto-first", Gtk.IconSize.Menu, 16);
-            w11.Add(w12);
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Label w14 = new Gtk.Label();
-            w11.Add(w14);
-            w10.Add(w11);
-            this.newleftbutton1.Add(w10);
-            this.vbox2.Add(this.newleftbutton1);
-            Gtk.Box.BoxChild w18 = ((Gtk.Box.BoxChild)(this.vbox2[this.newleftbutton1]));
-            w18.Position = 1;
-            w18.Fill = false;
-            // Container child vbox2.Gtk.Box+BoxChild
-            this.deletebutton = new Gtk.Button();
-            this.deletebutton.TooltipMarkup = "Delete";
-            this.deletebutton.CanFocus = true;
-            this.deletebutton.Name = "deletebutton";
-            this.deletebutton.UseUnderline = true;
-            // Container child deletebutton.Gtk.Container+ContainerChild
-            Gtk.Alignment w19 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
-            // Container child GtkAlignment.Gtk.Container+ContainerChild
-            Gtk.HBox w20 = new Gtk.HBox();
-            w20.Spacing = 2;
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Image w21 = new Gtk.Image();
-            w21.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-delete", Gtk.IconSize.Menu, 16);
-            w20.Add(w21);
-            // Container child GtkHBox.Gtk.Container+ContainerChild
-            Gtk.Label w23 = new Gtk.Label();
-            w20.Add(w23);
-            w19.Add(w20);
-            this.deletebutton.Add(w19);
-            this.vbox2.Add(this.deletebutton);
-            Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(this.vbox2[this.deletebutton]));
-            w27.Position = 2;
-            w27.Expand = false;
-            w27.Fill = false;
-            this.hbox1.Add(this.vbox2);
-            Gtk.Box.BoxChild w28 = ((Gtk.Box.BoxChild)(this.hbox1[this.vbox2]));
-            w28.Position = 0;
-            w28.Expand = false;
-            w28.Fill = false;
-            // Container child hbox1.Gtk.Box+BoxChild
             this.vbox3 = new Gtk.VBox();
             this.vbox3.Name = "vbox3";
             this.vbox3.Spacing = 6;
@@ -163,10 +53,10 @@ namespace LongoMatch.Gui.Component {
             this.label1.Name = "label1";
             this.label1.LabelProp = Mono.Unix.Catalog.GetString("Name:");
             this.hbox4.Add(this.label1);
-            Gtk.Box.BoxChild w29 = ((Gtk.Box.BoxChild)(this.hbox4[this.label1]));
-            w29.Position = 0;
-            w29.Expand = false;
-            w29.Fill = false;
+            Gtk.Box.BoxChild w1 = ((Gtk.Box.BoxChild)(this.hbox4[this.label1]));
+            w1.Position = 0;
+            w1.Expand = false;
+            w1.Fill = false;
             // Container child hbox4.Gtk.Box+BoxChild
             this.nameentry = new Gtk.Entry();
             this.nameentry.CanFocus = true;
@@ -174,20 +64,20 @@ namespace LongoMatch.Gui.Component {
             this.nameentry.IsEditable = true;
             this.nameentry.InvisibleChar = 'â??';
             this.hbox4.Add(this.nameentry);
-            Gtk.Box.BoxChild w30 = ((Gtk.Box.BoxChild)(this.hbox4[this.nameentry]));
-            w30.Position = 1;
+            Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(this.hbox4[this.nameentry]));
+            w2.Position = 1;
             this.vbox3.Add(this.hbox4);
-            Gtk.Box.BoxChild w31 = ((Gtk.Box.BoxChild)(this.vbox3[this.hbox4]));
-            w31.Position = 0;
-            w31.Fill = false;
+            Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(this.vbox3[this.hbox4]));
+            w3.Position = 0;
+            w3.Fill = false;
             // Container child vbox3.Gtk.Box+BoxChild
             this.timeadjustwidget1 = new LongoMatch.Gui.Component.TimeAdjustWidget();
             this.timeadjustwidget1.Events = ((Gdk.EventMask)(256));
             this.timeadjustwidget1.Name = "timeadjustwidget1";
             this.vbox3.Add(this.timeadjustwidget1);
-            Gtk.Box.BoxChild w32 = ((Gtk.Box.BoxChild)(this.vbox3[this.timeadjustwidget1]));
-            w32.Position = 1;
-            w32.Fill = false;
+            Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(this.vbox3[this.timeadjustwidget1]));
+            w4.Position = 1;
+            w4.Fill = false;
             // Container child vbox3.Gtk.Box+BoxChild
             this.hbox2 = new Gtk.HBox();
             this.hbox2.Name = "hbox2";
@@ -197,20 +87,20 @@ namespace LongoMatch.Gui.Component {
             this.label4.Name = "label4";
             this.label4.LabelProp = Mono.Unix.Catalog.GetString("Color:        ");
             this.hbox2.Add(this.label4);
-            Gtk.Box.BoxChild w33 = ((Gtk.Box.BoxChild)(this.hbox2[this.label4]));
-            w33.Position = 0;
-            w33.Expand = false;
-            w33.Fill = false;
+            Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(this.hbox2[this.label4]));
+            w5.Position = 0;
+            w5.Expand = false;
+            w5.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
             this.colorbutton1 = new Gtk.ColorButton();
             this.colorbutton1.CanFocus = true;
             this.colorbutton1.Events = ((Gdk.EventMask)(784));
             this.colorbutton1.Name = "colorbutton1";
             this.hbox2.Add(this.colorbutton1);
-            Gtk.Box.BoxChild w34 = ((Gtk.Box.BoxChild)(this.hbox2[this.colorbutton1]));
-            w34.Position = 1;
-            w34.Expand = false;
-            w34.Fill = false;
+            Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(this.hbox2[this.colorbutton1]));
+            w6.Position = 1;
+            w6.Expand = false;
+            w6.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
             this.changebuton = new Gtk.Button();
             this.changebuton.CanFocus = true;
@@ -218,53 +108,40 @@ namespace LongoMatch.Gui.Component {
             this.changebuton.UseUnderline = true;
             this.changebuton.Label = Mono.Unix.Catalog.GetString("Change");
             this.hbox2.Add(this.changebuton);
-            Gtk.Box.BoxChild w35 = ((Gtk.Box.BoxChild)(this.hbox2[this.changebuton]));
-            w35.PackType = ((Gtk.PackType)(1));
-            w35.Position = 2;
-            w35.Expand = false;
-            w35.Fill = false;
+            Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(this.hbox2[this.changebuton]));
+            w7.PackType = ((Gtk.PackType)(1));
+            w7.Position = 2;
+            w7.Expand = false;
+            w7.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
             this.hotKeyLabel = new Gtk.Label();
             this.hotKeyLabel.Name = "hotKeyLabel";
             this.hotKeyLabel.LabelProp = Mono.Unix.Catalog.GetString("none");
             this.hbox2.Add(this.hotKeyLabel);
-            Gtk.Box.BoxChild w36 = ((Gtk.Box.BoxChild)(this.hbox2[this.hotKeyLabel]));
-            w36.PackType = ((Gtk.PackType)(1));
-            w36.Position = 3;
-            w36.Expand = false;
-            w36.Fill = false;
+            Gtk.Box.BoxChild w8 = ((Gtk.Box.BoxChild)(this.hbox2[this.hotKeyLabel]));
+            w8.PackType = ((Gtk.PackType)(1));
+            w8.Position = 3;
+            w8.Expand = false;
+            w8.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
             this.label6 = new Gtk.Label();
             this.label6.Name = "label6";
             this.label6.LabelProp = Mono.Unix.Catalog.GetString("HotKey:");
             this.hbox2.Add(this.label6);
-            Gtk.Box.BoxChild w37 = ((Gtk.Box.BoxChild)(this.hbox2[this.label6]));
-            w37.PackType = ((Gtk.PackType)(1));
-            w37.Position = 4;
-            w37.Expand = false;
-            w37.Fill = false;
+            Gtk.Box.BoxChild w9 = ((Gtk.Box.BoxChild)(this.hbox2[this.label6]));
+            w9.PackType = ((Gtk.PackType)(1));
+            w9.Position = 4;
+            w9.Expand = false;
+            w9.Fill = false;
             this.vbox3.Add(this.hbox2);
-            Gtk.Box.BoxChild w38 = ((Gtk.Box.BoxChild)(this.vbox3[this.hbox2]));
-            w38.Position = 2;
-            w38.Fill = false;
-            this.hbox1.Add(this.vbox3);
-            Gtk.Box.BoxChild w39 = ((Gtk.Box.BoxChild)(this.hbox1[this.vbox3]));
-            w39.Position = 1;
-            this.GtkAlignment.Add(this.hbox1);
-            this.frame1.Add(this.GtkAlignment);
-            this.titlelabel = new Gtk.Label();
-            this.titlelabel.Name = "titlelabel";
-            this.titlelabel.LabelProp = Mono.Unix.Catalog.GetString("<b>frame1</b>");
-            this.titlelabel.UseMarkup = true;
-            this.frame1.LabelWidget = this.titlelabel;
-            this.Add(this.frame1);
+            Gtk.Box.BoxChild w10 = ((Gtk.Box.BoxChild)(this.vbox3[this.hbox2]));
+            w10.Position = 2;
+            w10.Fill = false;
+            this.Add(this.vbox3);
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
             this.Show();
-            this.newleftbutton.Clicked += new System.EventHandler(this.OnNewleftbuttonClicked);
-            this.newleftbutton1.Clicked += new System.EventHandler(this.OnNewleftbutton1Clicked);
-            this.deletebutton.Clicked += new System.EventHandler(this.OnDeletebuttonClicked);
             this.nameentry.Changed += new System.EventHandler(this.OnNameentryChanged);
             this.timeadjustwidget1.LeadTimeChanged += new System.EventHandler(this.OnTimeadjustwidget1LeadTimeChanged);
             this.timeadjustwidget1.LagTimeChanged += new System.EventHandler(this.OnTimeadjustwidget1LagTimeChanged);
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DBManager.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DBManager.cs
index 763cdee..7b0a180 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DBManager.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.DBManager.cs
@@ -99,7 +99,7 @@ namespace LongoMatch.Gui.Dialog {
             this.frame1.Add(this.GtkAlignment2);
             this.GtkLabel6 = new Gtk.Label();
             this.GtkLabel6.Name = "GtkLabel6";
-            this.GtkLabel6.LabelProp = Mono.Unix.Catalog.GetString("<b>Propiedades</b>");
+            this.GtkLabel6.LabelProp = Mono.Unix.Catalog.GetString("<b>Project Details</b>");
             this.GtkLabel6.UseMarkup = true;
             this.frame1.LabelWidget = this.GtkLabel6;
             this.vbox2.Add(this.frame1);
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditSectionsDialog.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditSectionsDialog.cs
new file mode 100644
index 0000000..9d3bb98
--- /dev/null
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.EditSectionsDialog.cs
@@ -0,0 +1,66 @@
+// ------------------------------------------------------------------------------
+//  <autogenerated>
+//      This code was generated by a tool.
+//      
+// 
+//      Changes to this file may cause incorrect behavior and will be lost if 
+//      the code is regenerated.
+//  </autogenerated>
+// ------------------------------------------------------------------------------
+
+namespace LongoMatch.Gui.Dialog {
+    
+    
+    public partial class EditSectionsDialog {
+        
+        private LongoMatch.Gui.Component.TimeNodeProperties timenodeproperties2;
+        
+        private Gtk.Button buttonOk;
+        
+        protected virtual void Build() {
+            Stetic.Gui.Initialize(this);
+            // Widget LongoMatch.Gui.Dialog.EditSectionsDialog
+            this.Name = "LongoMatch.Gui.Dialog.EditSectionsDialog";
+            this.Title = Mono.Unix.Catalog.GetString("Section Properties");
+            this.Icon = Gdk.Pixbuf.LoadFromResource("longomatch.png");
+            this.WindowPosition = ((Gtk.WindowPosition)(4));
+            this.Modal = true;
+            this.HasSeparator = false;
+            // Internal child LongoMatch.Gui.Dialog.EditSectionsDialog.VBox
+            Gtk.VBox w1 = this.VBox;
+            w1.Name = "dialog1_VBox";
+            w1.BorderWidth = ((uint)(2));
+            // Container child dialog1_VBox.Gtk.Box+BoxChild
+            this.timenodeproperties2 = new LongoMatch.Gui.Component.TimeNodeProperties();
+            this.timenodeproperties2.Events = ((Gdk.EventMask)(256));
+            this.timenodeproperties2.Name = "timenodeproperties2";
+            w1.Add(this.timenodeproperties2);
+            Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(w1[this.timenodeproperties2]));
+            w2.Position = 0;
+            // Internal child LongoMatch.Gui.Dialog.EditSectionsDialog.ActionArea
+            Gtk.HButtonBox w3 = this.ActionArea;
+            w3.Name = "dialog1_ActionArea";
+            w3.Spacing = 6;
+            w3.BorderWidth = ((uint)(5));
+            w3.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
+            // Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
+            this.buttonOk = new Gtk.Button();
+            this.buttonOk.CanDefault = true;
+            this.buttonOk.CanFocus = true;
+            this.buttonOk.Name = "buttonOk";
+            this.buttonOk.UseStock = true;
+            this.buttonOk.UseUnderline = true;
+            this.buttonOk.Label = "gtk-ok";
+            this.AddActionWidget(this.buttonOk, -5);
+            Gtk.ButtonBox.ButtonBoxChild w4 = ((Gtk.ButtonBox.ButtonBoxChild)(w3[this.buttonOk]));
+            w4.Expand = false;
+            w4.Fill = false;
+            if ((this.Child != null)) {
+                this.Child.ShowAll();
+            }
+            this.DefaultWidth = 264;
+            this.DefaultHeight = 137;
+            this.Show();
+        }
+    }
+}
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TeamTemplateEditor.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TeamTemplateEditor.cs
index 2adc4ab..62f7cf3 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TeamTemplateEditor.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TeamTemplateEditor.cs
@@ -13,8 +13,6 @@ namespace LongoMatch.Gui.Dialog {
     
     public partial class TeamTemplateEditor {
         
-        private Gtk.ScrolledWindow scrolledwindow1;
-        
         private LongoMatch.Gui.Component.TeamTemplateWidget teamtemplatewidget1;
         
         private Gtk.Button buttonOk;
@@ -23,7 +21,9 @@ namespace LongoMatch.Gui.Dialog {
             Stetic.Gui.Initialize(this);
             // Widget LongoMatch.Gui.Dialog.TeamTemplateEditor
             this.Name = "LongoMatch.Gui.Dialog.TeamTemplateEditor";
+            this.Icon = Gdk.Pixbuf.LoadFromResource("longomatch.png");
             this.WindowPosition = ((Gtk.WindowPosition)(4));
+            this.Modal = true;
             this.Gravity = ((Gdk.Gravity)(5));
             this.SkipPagerHint = true;
             this.SkipTaskbarHint = true;
@@ -33,28 +33,19 @@ namespace LongoMatch.Gui.Dialog {
             w1.Name = "dialog1_VBox";
             w1.BorderWidth = ((uint)(2));
             // Container child dialog1_VBox.Gtk.Box+BoxChild
-            this.scrolledwindow1 = new Gtk.ScrolledWindow();
-            this.scrolledwindow1.CanFocus = true;
-            this.scrolledwindow1.Name = "scrolledwindow1";
-            this.scrolledwindow1.ShadowType = ((Gtk.ShadowType)(1));
-            // Container child scrolledwindow1.Gtk.Container+ContainerChild
-            Gtk.Viewport w2 = new Gtk.Viewport();
-            w2.ShadowType = ((Gtk.ShadowType)(0));
-            // Container child GtkViewport.Gtk.Container+ContainerChild
             this.teamtemplatewidget1 = new LongoMatch.Gui.Component.TeamTemplateWidget();
             this.teamtemplatewidget1.Events = ((Gdk.EventMask)(256));
             this.teamtemplatewidget1.Name = "teamtemplatewidget1";
-            w2.Add(this.teamtemplatewidget1);
-            this.scrolledwindow1.Add(w2);
-            w1.Add(this.scrolledwindow1);
-            Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(w1[this.scrolledwindow1]));
-            w5.Position = 0;
+            this.teamtemplatewidget1.Edited = false;
+            w1.Add(this.teamtemplatewidget1);
+            Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(w1[this.teamtemplatewidget1]));
+            w2.Position = 0;
             // Internal child LongoMatch.Gui.Dialog.TeamTemplateEditor.ActionArea
-            Gtk.HButtonBox w6 = this.ActionArea;
-            w6.Name = "dialog1_ActionArea";
-            w6.Spacing = 6;
-            w6.BorderWidth = ((uint)(5));
-            w6.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
+            Gtk.HButtonBox w3 = this.ActionArea;
+            w3.Name = "dialog1_ActionArea";
+            w3.Spacing = 6;
+            w3.BorderWidth = ((uint)(5));
+            w3.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
             // Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
             this.buttonOk = new Gtk.Button();
             this.buttonOk.CanDefault = true;
@@ -64,13 +55,13 @@ namespace LongoMatch.Gui.Dialog {
             this.buttonOk.UseUnderline = true;
             this.buttonOk.Label = "gtk-apply";
             this.AddActionWidget(this.buttonOk, -10);
-            Gtk.ButtonBox.ButtonBoxChild w7 = ((Gtk.ButtonBox.ButtonBoxChild)(w6[this.buttonOk]));
-            w7.Expand = false;
-            w7.Fill = false;
+            Gtk.ButtonBox.ButtonBoxChild w4 = ((Gtk.ButtonBox.ButtonBoxChild)(w3[this.buttonOk]));
+            w4.Expand = false;
+            w4.Fill = false;
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
-            this.DefaultWidth = 873;
+            this.DefaultWidth = 436;
             this.DefaultHeight = 313;
             this.Show();
         }
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
index 9f37b4b..d81adaf 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplateEditorDialog.cs
@@ -37,6 +37,7 @@ namespace LongoMatch.Gui.Dialog {
             this.sectionspropertieswidget3 = new LongoMatch.Gui.Component.SectionsPropertiesWidget();
             this.sectionspropertieswidget3.Events = ((Gdk.EventMask)(256));
             this.sectionspropertieswidget3.Name = "sectionspropertieswidget3";
+            this.sectionspropertieswidget3.Edited = false;
             w1.Add(this.sectionspropertieswidget3);
             Gtk.Box.BoxChild w2 = ((Gtk.Box.BoxChild)(w1[this.sectionspropertieswidget3]));
             w2.Position = 0;
@@ -61,8 +62,8 @@ namespace LongoMatch.Gui.Dialog {
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
-            this.DefaultWidth = 758;
-            this.DefaultHeight = 404;
+            this.DefaultWidth = 470;
+            this.DefaultHeight = 243;
             this.Show();
         }
     }
diff --git a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
index b6aee27..3124271 100644
--- a/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
+++ b/LongoMatch/gtk-gui/LongoMatch.Gui.Dialog.TemplatesManager.cs
@@ -23,10 +23,10 @@ namespace LongoMatch.Gui.Dialog {
         
         private Gtk.Button newbutton;
         
-        private Gtk.Button savebutton;
-        
         private Gtk.Button deletebutton;
         
+        private Gtk.Button savebutton;
+        
         private Gtk.HBox hbox1;
         
         private LongoMatch.Gui.Component.SectionsPropertiesWidget sectionspropertieswidget1;
@@ -55,7 +55,7 @@ namespace LongoMatch.Gui.Dialog {
             this.hpaned1 = new Gtk.HPaned();
             this.hpaned1.CanFocus = true;
             this.hpaned1.Name = "hpaned1";
-            this.hpaned1.Position = 182;
+            this.hpaned1.Position = 144;
             // Container child hpaned1.Gtk.Paned+PanedChild
             this.vbox2 = new Gtk.VBox();
             this.vbox2.Name = "vbox2";
@@ -97,54 +97,54 @@ namespace LongoMatch.Gui.Dialog {
             w11.Expand = false;
             w11.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
-            this.savebutton = new Gtk.Button();
-            this.savebutton.TooltipMarkup = "Save this template";
-            this.savebutton.Sensitive = false;
-            this.savebutton.CanFocus = true;
-            this.savebutton.Name = "savebutton";
-            this.savebutton.UseUnderline = true;
-            // Container child savebutton.Gtk.Container+ContainerChild
+            this.deletebutton = new Gtk.Button();
+            this.deletebutton.TooltipMarkup = "Delete this template";
+            this.deletebutton.Sensitive = false;
+            this.deletebutton.CanFocus = true;
+            this.deletebutton.Name = "deletebutton";
+            this.deletebutton.UseUnderline = true;
+            // Container child deletebutton.Gtk.Container+ContainerChild
             Gtk.Alignment w12 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
             // Container child GtkAlignment1.Gtk.Container+ContainerChild
             Gtk.HBox w13 = new Gtk.HBox();
             w13.Spacing = 2;
             // Container child GtkHBox1.Gtk.Container+ContainerChild
             Gtk.Image w14 = new Gtk.Image();
-            w14.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-save", Gtk.IconSize.Button, 20);
+            w14.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-delete", Gtk.IconSize.Button, 20);
             w13.Add(w14);
             // Container child GtkHBox1.Gtk.Container+ContainerChild
             Gtk.Label w16 = new Gtk.Label();
             w13.Add(w16);
             w12.Add(w13);
-            this.savebutton.Add(w12);
-            this.hbox2.Add(this.savebutton);
-            Gtk.Box.BoxChild w20 = ((Gtk.Box.BoxChild)(this.hbox2[this.savebutton]));
+            this.deletebutton.Add(w12);
+            this.hbox2.Add(this.deletebutton);
+            Gtk.Box.BoxChild w20 = ((Gtk.Box.BoxChild)(this.hbox2[this.deletebutton]));
             w20.Position = 1;
             w20.Expand = false;
             w20.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
-            this.deletebutton = new Gtk.Button();
-            this.deletebutton.TooltipMarkup = "Delete this template";
-            this.deletebutton.Sensitive = false;
-            this.deletebutton.CanFocus = true;
-            this.deletebutton.Name = "deletebutton";
-            this.deletebutton.UseUnderline = true;
-            // Container child deletebutton.Gtk.Container+ContainerChild
+            this.savebutton = new Gtk.Button();
+            this.savebutton.TooltipMarkup = "Save this template";
+            this.savebutton.Sensitive = false;
+            this.savebutton.CanFocus = true;
+            this.savebutton.Name = "savebutton";
+            this.savebutton.UseUnderline = true;
+            // Container child savebutton.Gtk.Container+ContainerChild
             Gtk.Alignment w21 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
             // Container child GtkAlignment2.Gtk.Container+ContainerChild
             Gtk.HBox w22 = new Gtk.HBox();
             w22.Spacing = 2;
             // Container child GtkHBox2.Gtk.Container+ContainerChild
             Gtk.Image w23 = new Gtk.Image();
-            w23.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-delete", Gtk.IconSize.Button, 20);
+            w23.Pixbuf = Stetic.IconLoader.LoadIcon(this, "gtk-save", Gtk.IconSize.Button, 20);
             w22.Add(w23);
             // Container child GtkHBox2.Gtk.Container+ContainerChild
             Gtk.Label w25 = new Gtk.Label();
             w22.Add(w25);
             w21.Add(w22);
-            this.deletebutton.Add(w21);
-            this.hbox2.Add(this.deletebutton);
-            Gtk.Box.BoxChild w29 = ((Gtk.Box.BoxChild)(this.hbox2[this.deletebutton]));
+            this.savebutton.Add(w21);
+            this.hbox2.Add(this.savebutton);
+            Gtk.Box.BoxChild w29 = ((Gtk.Box.BoxChild)(this.hbox2[this.savebutton]));
             w29.Position = 2;
             w29.Expand = false;
             w29.Fill = false;
@@ -165,6 +165,7 @@ namespace LongoMatch.Gui.Dialog {
             this.sectionspropertieswidget1.Sensitive = false;
             this.sectionspropertieswidget1.Events = ((Gdk.EventMask)(256));
             this.sectionspropertieswidget1.Name = "sectionspropertieswidget1";
+            this.sectionspropertieswidget1.Edited = false;
             this.hbox1.Add(this.sectionspropertieswidget1);
             Gtk.Box.BoxChild w32 = ((Gtk.Box.BoxChild)(this.hbox1[this.sectionspropertieswidget1]));
             w32.Position = 0;
@@ -173,6 +174,7 @@ namespace LongoMatch.Gui.Dialog {
             this.teamtemplatewidget1.Sensitive = false;
             this.teamtemplatewidget1.Events = ((Gdk.EventMask)(256));
             this.teamtemplatewidget1.Name = "teamtemplatewidget1";
+            this.teamtemplatewidget1.Edited = false;
             this.hbox1.Add(this.teamtemplatewidget1);
             Gtk.Box.BoxChild w33 = ((Gtk.Box.BoxChild)(this.hbox1[this.teamtemplatewidget1]));
             w33.Position = 1;
@@ -201,16 +203,16 @@ namespace LongoMatch.Gui.Dialog {
             if ((this.Child != null)) {
                 this.Child.ShowAll();
             }
-            this.DefaultWidth = 803;
-            this.DefaultHeight = 388;
+            this.DefaultWidth = 483;
+            this.DefaultHeight = 336;
             this.sectionspropertieswidget1.Hide();
             this.teamtemplatewidget1.Hide();
             this.Show();
             this.treeview.RowActivated += new Gtk.RowActivatedHandler(this.OnTreeviewRowActivated);
             this.treeview.CursorChanged += new System.EventHandler(this.OnTreeviewCursorChanged);
             this.newbutton.Clicked += new System.EventHandler(this.OnNewbuttonClicked);
-            this.savebutton.Clicked += new System.EventHandler(this.OnSavebuttonClicked);
             this.deletebutton.Clicked += new System.EventHandler(this.OnDeletebuttonClicked);
+            this.savebutton.Clicked += new System.EventHandler(this.OnSavebuttonClicked);
             this.buttonOk.Clicked += new System.EventHandler(this.OnButtonOkClicked);
         }
     }
diff --git a/LongoMatch/gtk-gui/gui.stetic b/LongoMatch/gtk-gui/gui.stetic
index 9f9a143..f02a94c 100755
--- a/LongoMatch/gtk-gui/gui.stetic
+++ b/LongoMatch/gtk-gui/gui.stetic
@@ -937,7 +937,7 @@
                             <child>
                               <widget class="Gtk.Label" id="GtkLabel6">
                                 <property name="MemberName" />
-                                <property name="LabelProp" translatable="yes">&lt;b&gt;Propiedades&lt;/b&gt;</property>
+                                <property name="LabelProp" translatable="yes">&lt;b&gt;Project Details&lt;/b&gt;</property>
                                 <property name="UseMarkup">True</property>
                               </widget>
                               <packing>
@@ -1305,55 +1305,116 @@
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.SectionsPropertiesWidget" design-size="1185 535">
+  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.SectionsPropertiesWidget" design-size="436 138">
     <property name="MemberName" />
+    <signal name="KeyPressEvent" handler="OnKeyPressEvent" />
     <child>
-      <widget class="Gtk.ScrolledWindow" id="scrolledwindow1">
+      <widget class="Gtk.HBox" id="hbox1">
         <property name="MemberName" />
-        <property name="CanFocus">True</property>
-        <property name="ShadowType">In</property>
+        <property name="Spacing">6</property>
         <child>
-          <widget class="Gtk.Viewport" id="GtkViewport">
+          <widget class="Gtk.ScrolledWindow" id="scrolledwindow2">
             <property name="MemberName" />
-            <property name="ShadowType">None</property>
+            <property name="CanFocus">True</property>
+            <property name="ShadowType">In</property>
             <child>
-              <widget class="Gtk.Table" id="table1">
+              <widget class="LongoMatch.Gui.Component.SectionsTreeView" id="sectionstreeview1">
                 <property name="MemberName" />
-                <property name="NRows">3</property>
-                <property name="NColumns">3</property>
-                <property name="Homogeneous">True</property>
-                <property name="RowSpacing">6</property>
-                <property name="ColumnSpacing">6</property>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
+                <property name="CanFocus">True</property>
+                <signal name="SectionClicked" handler="OnSectionstreeview1SectionClicked" />
+                <signal name="SectionSelected" handler="OnSectionstreeview1SectionSelected" />
               </widget>
             </child>
           </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">True</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.VBox" id="vbox2">
+            <property name="MemberName" />
+            <property name="Spacing">6</property>
+            <child>
+              <widget class="Gtk.Button" id="newprevbutton">
+                <property name="MemberName" />
+                <property name="Sensitive">False</property>
+                <property name="CanFocus">True</property>
+                <property name="Type">TextAndIcon</property>
+                <property name="Icon">stock:gtk-goto-top Menu</property>
+                <property name="Label" translatable="yes">New Before</property>
+                <property name="UseUnderline">True</property>
+                <signal name="Clicked" handler="OnNewBefore" />
+              </widget>
+              <packing>
+                <property name="Position">0</property>
+                <property name="AutoSize">False</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Button" id="newafterbutton">
+                <property name="MemberName" />
+                <property name="Sensitive">False</property>
+                <property name="CanFocus">True</property>
+                <property name="Type">TextAndIcon</property>
+                <property name="Icon">stock:gtk-goto-bottom Menu</property>
+                <property name="Label" translatable="yes">New After</property>
+                <property name="UseUnderline">True</property>
+                <signal name="Clicked" handler="OnNewAfter" />
+                <signal name="Activated" handler="OnNewBefore" />
+              </widget>
+              <packing>
+                <property name="Position">1</property>
+                <property name="AutoSize">False</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Button" id="removebutton">
+                <property name="MemberName" />
+                <property name="Sensitive">False</property>
+                <property name="CanFocus">True</property>
+                <property name="Type">TextAndIcon</property>
+                <property name="Icon">stock:gtk-remove Menu</property>
+                <property name="Label" translatable="yes">Remove</property>
+                <property name="UseUnderline">True</property>
+                <signal name="Clicked" handler="OnRemove" />
+              </widget>
+              <packing>
+                <property name="Position">2</property>
+                <property name="AutoSize">False</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Button" id="editbutton">
+                <property name="MemberName" />
+                <property name="Sensitive">False</property>
+                <property name="CanFocus">True</property>
+                <property name="Type">TextAndIcon</property>
+                <property name="Icon">stock:gtk-edit Menu</property>
+                <property name="Label" translatable="yes">Edit</property>
+                <property name="UseUnderline">True</property>
+                <signal name="Clicked" handler="OnEdit" />
+              </widget>
+              <packing>
+                <property name="Position">3</property>
+                <property name="AutoSize">False</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+          </widget>
+          <packing>
+            <property name="Position">1</property>
+            <property name="AutoSize">False</property>
+            <property name="Expand">False</property>
+            <property name="Fill">False</property>
+          </packing>
         </child>
       </widget>
     </child>
@@ -1822,244 +1883,146 @@
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.TimeNodeProperties" design-size="314 135">
+  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.TimeNodeProperties" design-size="260 135">
     <property name="MemberName" />
     <child>
-      <widget class="Gtk.Frame" id="frame1">
+      <widget class="Gtk.VBox" id="vbox3">
         <property name="MemberName" />
-        <property name="BorderWidth">1</property>
+        <property name="Spacing">6</property>
         <child>
-          <widget class="Gtk.Alignment" id="GtkAlignment">
+          <widget class="Gtk.HBox" id="hbox4">
             <property name="MemberName" />
-            <property name="Xalign">0</property>
-            <property name="Yalign">0</property>
-            <property name="LeftPadding">12</property>
+            <property name="Spacing">6</property>
             <child>
-              <widget class="Gtk.HBox" id="hbox1">
+              <widget class="Gtk.Label" id="label1">
                 <property name="MemberName" />
-                <property name="Spacing">6</property>
-                <child>
-                  <widget class="Gtk.VBox" id="vbox2">
-                    <property name="MemberName" />
-                    <property name="Spacing">6</property>
-                    <child>
-                      <widget class="Gtk.Button" id="newleftbutton">
-                        <property name="MemberName" />
-                        <property name="Tooltip" translatable="yes">Insert After</property>
-                        <property name="CanFocus">True</property>
-                        <property name="Type">TextAndIcon</property>
-                        <property name="Icon">stock:gtk-goto-last Menu</property>
-                        <property name="Label" translatable="yes" />
-                        <property name="UseUnderline">True</property>
-                        <signal name="Clicked" handler="OnNewleftbuttonClicked" />
-                      </widget>
-                      <packing>
-                        <property name="Position">0</property>
-                        <property name="AutoSize">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="Gtk.Button" id="newleftbutton1">
-                        <property name="MemberName" />
-                        <property name="Tooltip" translatable="yes">InsertBefore</property>
-                        <property name="CanFocus">True</property>
-                        <property name="Type">TextAndIcon</property>
-                        <property name="Icon">stock:gtk-goto-first Menu</property>
-                        <property name="Label" translatable="yes" />
-                        <property name="UseUnderline">True</property>
-                        <signal name="Clicked" handler="OnNewleftbutton1Clicked" />
-                      </widget>
-                      <packing>
-                        <property name="Position">1</property>
-                        <property name="AutoSize">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="Gtk.Button" id="deletebutton">
-                        <property name="MemberName" />
-                        <property name="Tooltip" translatable="yes">Delete</property>
-                        <property name="CanFocus">True</property>
-                        <property name="Type">TextAndIcon</property>
-                        <property name="Icon">stock:gtk-delete Menu</property>
-                        <property name="Label" translatable="yes" />
-                        <property name="UseUnderline">True</property>
-                        <signal name="Clicked" handler="OnDeletebuttonClicked" />
-                      </widget>
-                      <packing>
-                        <property name="Position">2</property>
-                        <property name="AutoSize">True</property>
-                        <property name="Expand">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                  </widget>
-                  <packing>
-                    <property name="Position">0</property>
-                    <property name="AutoSize">True</property>
-                    <property name="Expand">False</property>
-                    <property name="Fill">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.VBox" id="vbox3">
-                    <property name="MemberName" />
-                    <property name="Spacing">6</property>
-                    <child>
-                      <widget class="Gtk.HBox" id="hbox4">
-                        <property name="MemberName" />
-                        <property name="Spacing">6</property>
-                        <child>
-                          <widget class="Gtk.Label" id="label1">
-                            <property name="MemberName" />
-                            <property name="LabelProp" translatable="yes">Name:</property>
-                          </widget>
-                          <packing>
-                            <property name="Position">0</property>
-                            <property name="AutoSize">True</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <widget class="Gtk.Entry" id="nameentry">
-                            <property name="MemberName" />
-                            <property name="CanFocus">True</property>
-                            <property name="IsEditable">True</property>
-                            <property name="InvisibleChar">â??</property>
-                            <signal name="Changed" handler="OnNameentryChanged" />
-                          </widget>
-                          <packing>
-                            <property name="Position">1</property>
-                            <property name="AutoSize">True</property>
-                          </packing>
-                        </child>
-                      </widget>
-                      <packing>
-                        <property name="Position">0</property>
-                        <property name="AutoSize">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="LongoMatch.Gui.Component.TimeAdjustWidget" id="timeadjustwidget1">
-                        <property name="MemberName" />
-                        <property name="Events">ButtonPressMask</property>
-                        <signal name="LeadTimeChanged" handler="OnTimeadjustwidget1LeadTimeChanged" />
-                        <signal name="LagTimeChanged" handler="OnTimeadjustwidget1LagTimeChanged" />
-                      </widget>
-                      <packing>
-                        <property name="Position">1</property>
-                        <property name="AutoSize">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="Gtk.HBox" id="hbox2">
-                        <property name="MemberName" />
-                        <property name="Spacing">6</property>
-                        <child>
-                          <widget class="Gtk.Label" id="label4">
-                            <property name="MemberName" />
-                            <property name="LabelProp" translatable="yes">Color:        </property>
-                          </widget>
-                          <packing>
-                            <property name="Position">0</property>
-                            <property name="AutoSize">False</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <widget class="Gtk.ColorButton" id="colorbutton1">
-                            <property name="MemberName" />
-                            <property name="CanFocus">True</property>
-                            <property name="Events">ButtonMotionMask, ButtonPressMask, ButtonReleaseMask</property>
-                            <property name="Alpha">-1</property>
-                            <signal name="ColorSet" handler="OnColorbutton1ColorSet" />
-                          </widget>
-                          <packing>
-                            <property name="Position">1</property>
-                            <property name="AutoSize">True</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <widget class="Gtk.Button" id="changebuton">
-                            <property name="MemberName" />
-                            <property name="CanFocus">True</property>
-                            <property name="Type">TextOnly</property>
-                            <property name="Label" translatable="yes">Change</property>
-                            <property name="UseUnderline">True</property>
-                            <signal name="Clicked" handler="OnChangebutonClicked" />
-                          </widget>
-                          <packing>
-                            <property name="PackType">End</property>
-                            <property name="Position">2</property>
-                            <property name="AutoSize">True</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <widget class="Gtk.Label" id="hotKeyLabel">
-                            <property name="MemberName" />
-                            <property name="LabelProp" translatable="yes">none</property>
-                          </widget>
-                          <packing>
-                            <property name="PackType">End</property>
-                            <property name="Position">3</property>
-                            <property name="AutoSize">True</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                        <child>
-                          <widget class="Gtk.Label" id="label6">
-                            <property name="MemberName" />
-                            <property name="LabelProp" translatable="yes">HotKey:</property>
-                          </widget>
-                          <packing>
-                            <property name="PackType">End</property>
-                            <property name="Position">4</property>
-                            <property name="AutoSize">True</property>
-                            <property name="Expand">False</property>
-                            <property name="Fill">False</property>
-                          </packing>
-                        </child>
-                      </widget>
-                      <packing>
-                        <property name="Position">2</property>
-                        <property name="AutoSize">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                  </widget>
-                  <packing>
-                    <property name="Position">1</property>
-                    <property name="AutoSize">False</property>
-                  </packing>
-                </child>
+                <property name="LabelProp" translatable="yes">Name:</property>
               </widget>
+              <packing>
+                <property name="Position">0</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
             </child>
+            <child>
+              <widget class="Gtk.Entry" id="nameentry">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="IsEditable">True</property>
+                <property name="InvisibleChar">â??</property>
+                <signal name="Changed" handler="OnNameentryChanged" />
+              </widget>
+              <packing>
+                <property name="Position">1</property>
+                <property name="AutoSize">True</property>
+              </packing>
+            </child>
+          </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">False</property>
+            <property name="Fill">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="LongoMatch.Gui.Component.TimeAdjustWidget" id="timeadjustwidget1">
+            <property name="MemberName" />
+            <property name="Events">ButtonPressMask</property>
+            <signal name="LeadTimeChanged" handler="OnTimeadjustwidget1LeadTimeChanged" />
+            <signal name="LagTimeChanged" handler="OnTimeadjustwidget1LagTimeChanged" />
           </widget>
+          <packing>
+            <property name="Position">1</property>
+            <property name="AutoSize">False</property>
+            <property name="Fill">False</property>
+          </packing>
         </child>
         <child>
-          <widget class="Gtk.Label" id="titlelabel">
+          <widget class="Gtk.HBox" id="hbox2">
             <property name="MemberName" />
-            <property name="LabelProp" translatable="yes">&lt;b&gt;frame1&lt;/b&gt;</property>
-            <property name="UseMarkup">True</property>
+            <property name="Spacing">6</property>
+            <child>
+              <widget class="Gtk.Label" id="label4">
+                <property name="MemberName" />
+                <property name="LabelProp" translatable="yes">Color:        </property>
+              </widget>
+              <packing>
+                <property name="Position">0</property>
+                <property name="AutoSize">False</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.ColorButton" id="colorbutton1">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="Events">ButtonMotionMask, ButtonPressMask, ButtonReleaseMask</property>
+                <property name="Alpha">-1</property>
+                <signal name="ColorSet" handler="OnColorbutton1ColorSet" />
+              </widget>
+              <packing>
+                <property name="Position">1</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Button" id="changebuton">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="Type">TextOnly</property>
+                <property name="Label" translatable="yes">Change</property>
+                <property name="UseUnderline">True</property>
+                <signal name="Clicked" handler="OnChangebutonClicked" />
+              </widget>
+              <packing>
+                <property name="PackType">End</property>
+                <property name="Position">2</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Label" id="hotKeyLabel">
+                <property name="MemberName" />
+                <property name="LabelProp" translatable="yes">none</property>
+              </widget>
+              <packing>
+                <property name="PackType">End</property>
+                <property name="Position">3</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+            <child>
+              <widget class="Gtk.Label" id="label6">
+                <property name="MemberName" />
+                <property name="LabelProp" translatable="yes">HotKey:</property>
+              </widget>
+              <packing>
+                <property name="PackType">End</property>
+                <property name="Position">4</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
           </widget>
           <packing>
-            <property name="type">label_item</property>
+            <property name="Position">2</property>
+            <property name="AutoSize">False</property>
+            <property name="Fill">False</property>
           </packing>
         </child>
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TemplateEditorDialog" design-size="758 404">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TemplateEditorDialog" design-size="470 243">
     <property name="MemberName" />
     <property name="Title" translatable="yes">Template Editor</property>
     <property name="Icon">stock:longomatch Dialog</property>
@@ -2079,6 +2042,7 @@
           <widget class="LongoMatch.Gui.Component.SectionsPropertiesWidget" id="sectionspropertieswidget3">
             <property name="MemberName" />
             <property name="Events">ButtonPressMask</property>
+            <property name="Edited">False</property>
           </widget>
           <packing>
             <property name="Position">0</property>
@@ -3276,284 +3240,243 @@ You can download it using this direct link:</property>
     <property name="MemberName" />
     <property name="Visible">False</property>
     <child>
-      <widget class="Gtk.Frame" id="frame1">
+      <widget class="Gtk.Table" id="table1">
         <property name="MemberName" />
+        <property name="NRows">4</property>
+        <property name="NColumns">2</property>
+        <property name="RowSpacing">6</property>
+        <property name="ColumnSpacing">6</property>
         <child>
-          <widget class="Gtk.Alignment" id="GtkAlignment">
+          <widget class="Gtk.HBox" id="hbox1">
             <property name="MemberName" />
-            <property name="Xalign">0</property>
-            <property name="Yalign">0</property>
-            <property name="LeftPadding">12</property>
+            <property name="Spacing">6</property>
             <child>
-              <widget class="Gtk.Table" id="table1">
+              <widget class="Gtk.Image" id="image">
                 <property name="MemberName" />
-                <property name="NRows">4</property>
-                <property name="NColumns">2</property>
-                <property name="RowSpacing">6</property>
-                <property name="ColumnSpacing">6</property>
-                <child>
-                  <widget class="Gtk.HBox" id="hbox1">
-                    <property name="MemberName" />
-                    <property name="Spacing">6</property>
-                    <child>
-                      <widget class="Gtk.Image" id="image">
-                        <property name="MemberName" />
-                      </widget>
-                      <packing>
-                        <property name="Position">0</property>
-                        <property name="AutoSize">False</property>
-                      </packing>
-                    </child>
-                    <child>
-                      <widget class="Gtk.Button" id="openbutton">
-                        <property name="MemberName" />
-                        <property name="CanFocus">True</property>
-                        <property name="UseStock">True</property>
-                        <property name="Type">StockItem</property>
-                        <property name="StockId">gtk-open</property>
-                        <signal name="Clicked" handler="OnOpenbuttonClicked" />
-                        <property name="label">gtk-open</property>
-                      </widget>
-                      <packing>
-                        <property name="Position">1</property>
-                        <property name="AutoSize">True</property>
-                        <property name="Expand">False</property>
-                        <property name="Fill">False</property>
-                      </packing>
-                    </child>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">3</property>
-                    <property name="BottomAttach">4</property>
-                    <property name="LeftAttach">1</property>
-                    <property name="RightAttach">2</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Label" id="label1">
-                    <property name="MemberName" />
-                    <property name="LabelProp" translatable="yes">Name:</property>
-                  </widget>
-                  <packing>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Label" id="label2">
-                    <property name="MemberName" />
-                    <property name="LabelProp" translatable="yes">Position:</property>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">1</property>
-                    <property name="BottomAttach">2</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Label" id="label3">
-                    <property name="MemberName" />
-                    <property name="LabelProp" translatable="yes">Number:</property>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">2</property>
-                    <property name="BottomAttach">3</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Label" id="label4">
-                    <property name="MemberName" />
-                    <property name="LabelProp" translatable="yes">Photo:</property>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">3</property>
-                    <property name="BottomAttach">4</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Entry" id="nameentry">
-                    <property name="MemberName" />
-                    <property name="CanFocus">True</property>
-                    <property name="IsEditable">True</property>
-                    <property name="InvisibleChar">â??</property>
-                  </widget>
-                  <packing>
-                    <property name="LeftAttach">1</property>
-                    <property name="RightAttach">2</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.SpinButton" id="numberspinbutton">
-                    <property name="MemberName" />
-                    <property name="CanFocus">True</property>
-                    <property name="Upper">100</property>
-                    <property name="PageIncrement">10</property>
-                    <property name="StepIncrement">1</property>
-                    <property name="ClimbRate">1</property>
-                    <property name="Numeric">True</property>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">2</property>
-                    <property name="BottomAttach">3</property>
-                    <property name="LeftAttach">1</property>
-                    <property name="RightAttach">2</property>
-                    <property name="AutoSize">False</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">True</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
-                <child>
-                  <widget class="Gtk.Entry" id="positionentry">
-                    <property name="MemberName" />
-                    <property name="CanFocus">True</property>
-                    <property name="IsEditable">True</property>
-                    <property name="InvisibleChar">â??</property>
-                  </widget>
-                  <packing>
-                    <property name="TopAttach">1</property>
-                    <property name="BottomAttach">2</property>
-                    <property name="LeftAttach">1</property>
-                    <property name="RightAttach">2</property>
-                    <property name="AutoSize">True</property>
-                    <property name="XOptions">Fill</property>
-                    <property name="YOptions">Fill</property>
-                    <property name="XExpand">False</property>
-                    <property name="XFill">True</property>
-                    <property name="XShrink">False</property>
-                    <property name="YExpand">False</property>
-                    <property name="YFill">True</property>
-                    <property name="YShrink">False</property>
-                  </packing>
-                </child>
               </widget>
+              <packing>
+                <property name="Position">0</property>
+                <property name="AutoSize">False</property>
+              </packing>
             </child>
+            <child>
+              <widget class="Gtk.Button" id="openbutton">
+                <property name="MemberName" />
+                <property name="CanFocus">True</property>
+                <property name="UseStock">True</property>
+                <property name="Type">StockItem</property>
+                <property name="StockId">gtk-open</property>
+                <signal name="Clicked" handler="OnOpenbuttonClicked" />
+                <property name="label">gtk-open</property>
+              </widget>
+              <packing>
+                <property name="Position">1</property>
+                <property name="AutoSize">True</property>
+                <property name="Expand">False</property>
+                <property name="Fill">False</property>
+              </packing>
+            </child>
+          </widget>
+          <packing>
+            <property name="TopAttach">3</property>
+            <property name="BottomAttach">4</property>
+            <property name="LeftAttach">1</property>
+            <property name="RightAttach">2</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.Label" id="label1">
+            <property name="MemberName" />
+            <property name="LabelProp" translatable="yes">Name:</property>
           </widget>
+          <packing>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
         </child>
         <child>
-          <widget class="Gtk.Label" id="titlelabel">
+          <widget class="Gtk.Label" id="label2">
             <property name="MemberName" />
-            <property name="LabelProp" translatable="yes">&lt;b&gt;frame1&lt;/b&gt;</property>
-            <property name="UseMarkup">True</property>
+            <property name="LabelProp" translatable="yes">Position:</property>
           </widget>
           <packing>
-            <property name="type">label_item</property>
+            <property name="TopAttach">1</property>
+            <property name="BottomAttach">2</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.Label" id="label3">
+            <property name="MemberName" />
+            <property name="LabelProp" translatable="yes">Number:</property>
+          </widget>
+          <packing>
+            <property name="TopAttach">2</property>
+            <property name="BottomAttach">3</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.Label" id="label4">
+            <property name="MemberName" />
+            <property name="LabelProp" translatable="yes">Photo:</property>
+          </widget>
+          <packing>
+            <property name="TopAttach">3</property>
+            <property name="BottomAttach">4</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.Entry" id="nameentry">
+            <property name="MemberName" />
+            <property name="CanFocus">True</property>
+            <property name="IsEditable">True</property>
+            <property name="InvisibleChar">â??</property>
+            <signal name="Changed" handler="OnNameentryChanged" />
+          </widget>
+          <packing>
+            <property name="LeftAttach">1</property>
+            <property name="RightAttach">2</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.SpinButton" id="numberspinbutton">
+            <property name="MemberName" />
+            <property name="CanFocus">True</property>
+            <property name="Upper">100</property>
+            <property name="PageIncrement">10</property>
+            <property name="StepIncrement">1</property>
+            <property name="ClimbRate">1</property>
+            <property name="Numeric">True</property>
+            <signal name="EditingDone" handler="OnNumberspinbuttonChanged" />
+            <signal name="ValueChanged" handler="OnNumberspinbuttonValueChanged" />
+          </widget>
+          <packing>
+            <property name="TopAttach">2</property>
+            <property name="BottomAttach">3</property>
+            <property name="LeftAttach">1</property>
+            <property name="RightAttach">2</property>
+            <property name="AutoSize">False</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">True</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
+          </packing>
+        </child>
+        <child>
+          <widget class="Gtk.Entry" id="positionentry">
+            <property name="MemberName" />
+            <property name="CanFocus">True</property>
+            <property name="IsEditable">True</property>
+            <property name="InvisibleChar">â??</property>
+            <signal name="Changed" handler="OnPositionentryChanged" />
+          </widget>
+          <packing>
+            <property name="TopAttach">1</property>
+            <property name="BottomAttach">2</property>
+            <property name="LeftAttach">1</property>
+            <property name="RightAttach">2</property>
+            <property name="AutoSize">True</property>
+            <property name="XOptions">Fill</property>
+            <property name="YOptions">Fill</property>
+            <property name="XExpand">False</property>
+            <property name="XFill">True</property>
+            <property name="XShrink">False</property>
+            <property name="YExpand">False</property>
+            <property name="YFill">True</property>
+            <property name="YShrink">False</property>
           </packing>
         </child>
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.TeamTemplateWidget" design-size="300 300">
+  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.TeamTemplateWidget" design-size="365 186">
     <property name="MemberName" />
     <property name="Visible">False</property>
     <child>
-      <widget class="Gtk.ScrolledWindow" id="scrolledwindow2">
+      <widget class="Gtk.HBox" id="hbox1">
         <property name="MemberName" />
-        <property name="CanFocus">True</property>
-        <property name="ShadowType">In</property>
+        <property name="Spacing">6</property>
         <child>
-          <widget class="Gtk.Viewport" id="GtkViewport">
+          <widget class="Gtk.ScrolledWindow" id="scrolledwindow2">
             <property name="MemberName" />
-            <property name="ShadowType">None</property>
+            <property name="CanFocus">True</property>
+            <property name="ShadowType">In</property>
             <child>
-              <widget class="Gtk.Table" id="table1">
+              <widget class="LongoMatch.Gui.Component.PlayerPropertiesTreeView" id="playerpropertiestreeview1">
                 <property name="MemberName" />
-                <property name="NRows">3</property>
-                <property name="NColumns">3</property>
-                <property name="RowSpacing">6</property>
-                <property name="ColumnSpacing">6</property>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
-                <child>
-                  <placeholder />
-                </child>
+                <property name="CanFocus">True</property>
+                <signal name="PlayerClicked" handler="OnPlayerpropertiestreeview1PlayerClicked" />
+                <signal name="PlayerSelected" handler="OnPlayerpropertiestreeview1PlayerSelected" />
               </widget>
             </child>
           </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">True</property>
+          </packing>
         </child>
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TeamTemplateEditor" design-size="873 313">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TeamTemplateEditor" design-size="436 313">
     <property name="MemberName" />
+    <property name="Icon">resource:longomatch.png</property>
     <property name="WindowPosition">CenterOnParent</property>
+    <property name="Modal">True</property>
     <property name="Gravity">Center</property>
     <property name="SkipPagerHint">True</property>
     <property name="SkipTaskbarHint">True</property>
@@ -3565,22 +3488,10 @@ You can download it using this direct link:</property>
         <property name="MemberName" />
         <property name="BorderWidth">2</property>
         <child>
-          <widget class="Gtk.ScrolledWindow" id="scrolledwindow1">
+          <widget class="LongoMatch.Gui.Component.TeamTemplateWidget" id="teamtemplatewidget1">
             <property name="MemberName" />
-            <property name="CanFocus">True</property>
-            <property name="ShadowType">In</property>
-            <child>
-              <widget class="Gtk.Viewport" id="GtkViewport">
-                <property name="MemberName" />
-                <property name="ShadowType">None</property>
-                <child>
-                  <widget class="LongoMatch.Gui.Component.TeamTemplateWidget" id="teamtemplatewidget1">
-                    <property name="MemberName" />
-                    <property name="Events">ButtonPressMask</property>
-                  </widget>
-                </child>
-              </widget>
-            </child>
+            <property name="Events">ButtonPressMask</property>
+            <property name="Edited">False</property>
           </widget>
           <packing>
             <property name="Position">0</property>
@@ -3615,7 +3526,7 @@ You can download it using this direct link:</property>
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TemplatesManager" design-size="803 388">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.TemplatesManager" design-size="483 336">
     <property name="MemberName" />
     <property name="Title" translatable="yes">Templates Manager</property>
     <property name="Icon">stock:longomatch Dialog</property>
@@ -3635,7 +3546,7 @@ You can download it using this direct link:</property>
           <widget class="Gtk.HPaned" id="hpaned1">
             <property name="MemberName" />
             <property name="CanFocus">True</property>
-            <property name="Position">182</property>
+            <property name="Position">144</property>
             <child>
               <widget class="Gtk.VBox" id="vbox2">
                 <property name="MemberName" />
@@ -3675,16 +3586,16 @@ You can download it using this direct link:</property>
                       </packing>
                     </child>
                     <child>
-                      <widget class="Gtk.Button" id="savebutton">
+                      <widget class="Gtk.Button" id="deletebutton">
                         <property name="MemberName" />
                         <property name="Sensitive">False</property>
-                        <property name="Tooltip" translatable="yes">Save this template</property>
+                        <property name="Tooltip" translatable="yes">Delete this template</property>
                         <property name="CanFocus">True</property>
                         <property name="Type">TextAndIcon</property>
-                        <property name="Icon">stock:gtk-save Button</property>
+                        <property name="Icon">stock:gtk-delete Button</property>
                         <property name="Label" translatable="yes" />
                         <property name="UseUnderline">True</property>
-                        <signal name="Clicked" handler="OnSavebuttonClicked" />
+                        <signal name="Clicked" handler="OnDeletebuttonClicked" />
                       </widget>
                       <packing>
                         <property name="Position">1</property>
@@ -3694,16 +3605,16 @@ You can download it using this direct link:</property>
                       </packing>
                     </child>
                     <child>
-                      <widget class="Gtk.Button" id="deletebutton">
+                      <widget class="Gtk.Button" id="savebutton">
                         <property name="MemberName" />
                         <property name="Sensitive">False</property>
-                        <property name="Tooltip" translatable="yes">Delete this template</property>
+                        <property name="Tooltip" translatable="yes">Save this template</property>
                         <property name="CanFocus">True</property>
                         <property name="Type">TextAndIcon</property>
-                        <property name="Icon">stock:gtk-delete Button</property>
+                        <property name="Icon">stock:gtk-save Button</property>
                         <property name="Label" translatable="yes" />
                         <property name="UseUnderline">True</property>
-                        <signal name="Clicked" handler="OnDeletebuttonClicked" />
+                        <signal name="Clicked" handler="OnSavebuttonClicked" />
                       </widget>
                       <packing>
                         <property name="Position">2</property>
@@ -3735,6 +3646,7 @@ You can download it using this direct link:</property>
                     <property name="Visible">False</property>
                     <property name="Sensitive">False</property>
                     <property name="Events">ButtonPressMask</property>
+                    <property name="Edited">False</property>
                   </widget>
                   <packing>
                     <property name="Position">0</property>
@@ -3747,6 +3659,7 @@ You can download it using this direct link:</property>
                     <property name="Visible">False</property>
                     <property name="Sensitive">False</property>
                     <property name="Events">ButtonPressMask</property>
+                    <property name="Edited">False</property>
                   </widget>
                   <packing>
                     <property name="Position">1</property>
@@ -4527,4 +4440,109 @@ Show-&gt;&lt;b&gt; S&lt;/b&gt;
       </widget>
     </child>
   </widget>
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.EditSectionsDialog" design-size="264 137">
+    <property name="MemberName" />
+    <property name="Title" translatable="yes">Section Properties</property>
+    <property name="Icon">resource:longomatch.png</property>
+    <property name="WindowPosition">CenterOnParent</property>
+    <property name="Modal">True</property>
+    <property name="Buttons">1</property>
+    <property name="HelpButton">False</property>
+    <property name="HasSeparator">False</property>
+    <child internal-child="VBox">
+      <widget class="Gtk.VBox" id="dialog1_VBox">
+        <property name="MemberName" />
+        <property name="BorderWidth">2</property>
+        <child>
+          <widget class="LongoMatch.Gui.Component.TimeNodeProperties" id="timenodeproperties2">
+            <property name="MemberName" />
+            <property name="Events">ButtonPressMask</property>
+          </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">False</property>
+          </packing>
+        </child>
+      </widget>
+    </child>
+    <child internal-child="ActionArea">
+      <widget class="Gtk.HButtonBox" id="dialog1_ActionArea">
+        <property name="MemberName" />
+        <property name="Spacing">6</property>
+        <property name="BorderWidth">5</property>
+        <property name="Size">1</property>
+        <property name="LayoutStyle">End</property>
+        <child>
+          <widget class="Gtk.Button" id="buttonOk">
+            <property name="MemberName" />
+            <property name="CanDefault">True</property>
+            <property name="CanFocus">True</property>
+            <property name="UseStock">True</property>
+            <property name="Type">StockItem</property>
+            <property name="StockId">gtk-ok</property>
+            <property name="ResponseId">-5</property>
+            <property name="label">gtk-ok</property>
+          </widget>
+          <packing>
+            <property name="Expand">False</property>
+            <property name="Fill">False</property>
+          </packing>
+        </child>
+      </widget>
+    </child>
+  </widget>
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.EditPlayerDialog" design-size="254 185">
+    <property name="MemberName" />
+    <property name="Icon">resource:longomatch.png</property>
+    <property name="WindowPosition">CenterOnParent</property>
+    <property name="Modal">True</property>
+    <property name="SkipPagerHint">True</property>
+    <property name="SkipTaskbarHint">True</property>
+    <property name="Buttons">1</property>
+    <property name="HelpButton">False</property>
+    <property name="HasSeparator">False</property>
+    <child internal-child="VBox">
+      <widget class="Gtk.VBox" id="dialog1_VBox">
+        <property name="MemberName" />
+        <property name="BorderWidth">2</property>
+        <child>
+          <widget class="LongoMatch.Gui.Component.PlayerProperties" id="playerproperties1">
+            <property name="MemberName" />
+            <property name="Events">ButtonPressMask</property>
+          </widget>
+          <packing>
+            <property name="Position">0</property>
+            <property name="AutoSize">True</property>
+            <property name="Expand">False</property>
+            <property name="Fill">False</property>
+          </packing>
+        </child>
+      </widget>
+    </child>
+    <child internal-child="ActionArea">
+      <widget class="Gtk.HButtonBox" id="dialog1_ActionArea">
+        <property name="MemberName" />
+        <property name="Spacing">6</property>
+        <property name="BorderWidth">5</property>
+        <property name="Size">1</property>
+        <property name="LayoutStyle">End</property>
+        <child>
+          <widget class="Gtk.Button" id="buttonOk">
+            <property name="MemberName" />
+            <property name="CanDefault">True</property>
+            <property name="CanFocus">True</property>
+            <property name="UseStock">True</property>
+            <property name="Type">StockItem</property>
+            <property name="StockId">gtk-ok</property>
+            <property name="ResponseId">-5</property>
+            <property name="label">gtk-ok</property>
+          </widget>
+          <packing>
+            <property name="Expand">False</property>
+            <property name="Fill">False</property>
+          </packing>
+        </child>
+      </widget>
+    </child>
+  </widget>
 </stetic-interface>
\ No newline at end of file
diff --git a/LongoMatch/gtk-gui/objects.xml b/LongoMatch/gtk-gui/objects.xml
index 2d5091f..e22802e 100755
--- a/LongoMatch/gtk-gui/objects.xml
+++ b/LongoMatch/gtk-gui/objects.xml
@@ -32,9 +32,6 @@
     <itemgroups />
     <signals>
       <itemgroup label="TimeNodeProperties Signals">
-        <signal name="DeleteSection" />
-        <signal name="InsertBefore" />
-        <signal name="InsertAfter" />
         <signal name="HotKeyChanged" />
       </itemgroup>
     </signals>
@@ -64,10 +61,6 @@
       </itemgroup>
     </signals>
   </object>
-  <object type="LongoMatch.Gui.Component.SectionsPropertiesWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
-    <itemgroups />
-    <signals />
-  </object>
   <object type="LongoMatch.Gui.Component.TimeAdjustWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups />
     <signals>
@@ -136,7 +129,11 @@
     <signals />
   </object>
   <object type="LongoMatch.Gui.Component.TeamTemplateWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
-    <itemgroups />
+    <itemgroups>
+      <itemgroup label="TeamTemplateWidget Properties">
+        <property name="Edited" />
+      </itemgroup>
+    </itemgroups>
     <signals />
   </object>
   <object type="LongoMatch.Gui.Component.PlayersTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
@@ -188,4 +185,30 @@
       </itemgroup>
     </signals>
   </object>
+  <object type="LongoMatch.Gui.Component.SectionsPropertiesWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups>
+      <itemgroup label="SectionsPropertiesWidget Properties">
+        <property name="Edited" />
+      </itemgroup>
+    </itemgroups>
+    <signals />
+  </object>
+  <object type="LongoMatch.Gui.Component.SectionsTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+    <itemgroups />
+    <signals>
+      <itemgroup label="SectionsTreeView Signals">
+        <signal name="SectionClicked" />
+        <signal name="SectionSelected" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.PlayerPropertiesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+    <itemgroups />
+    <signals>
+      <itemgroup label="PlayerPropertiesTreeView Signals">
+        <signal name="PlayerClicked" />
+        <signal name="PlayerSelected" />
+      </itemgroup>
+    </signals>
+  </object>
 </objects>
\ No newline at end of file



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]