[longomatch/test: 6/10] WIP: Everything compiles



commit fba54a9e23f217a36372a0baa899ea7f3f4ce682
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Sun Oct 17 18:14:27 2010 +0200

    WIP: Everything compiles

 LongoMatch/DB/Project.cs                           |   18 +++
 LongoMatch/DB/ProjectDescription.cs                |    6 +-
 LongoMatch/DB/Sections.cs                          |    4 +
 LongoMatch/DB/TeamTemplate.cs                      |    2 +-
 LongoMatch/Gui/Component/ButtonsWidget.cs          |   15 ++-
 LongoMatch/Gui/Component/CategoryProperties.cs     |    3 +-
 LongoMatch/Gui/Component/PlaysListTreeWidget.cs    |   14 +-
 LongoMatch/Gui/Component/ProjectDetailsWidget.cs   |   82 ++++++-----
 LongoMatch/Gui/Component/ProjectTemplateWidget.cs  |   86 ++++++------
 LongoMatch/Gui/Component/TaggerWidget.cs           |   14 ++-
 LongoMatch/Gui/Component/TagsTreeWidget.cs         |   16 +-
 LongoMatch/Gui/Component/TeamTemplateWidget.cs     |    4 +-
 LongoMatch/Gui/Component/TimeLineWidget.cs         |   46 ++++---
 LongoMatch/Gui/Component/TimeScale.cs              |   12 +-
 LongoMatch/Gui/Dialog/EditCategoryDialog.cs        |    2 +-
 LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs    |    2 +-
 .../Gui/Dialog/ProjectTemplateEditorDialog.cs      |    2 +-
 LongoMatch/Gui/Dialog/ProjectsManager.cs           |   15 ++-
 LongoMatch/Gui/Dialog/TemplatesEditor.cs           |    3 +-
 LongoMatch/Gui/TreeView/CategoriesTreeView.cs      |   20 ++--
 LongoMatch/Gui/TreeView/ListTreeViewBase.cs        |   56 ++++----
 LongoMatch/Gui/TreeView/PlayListTreeView.cs        |    4 +-
 LongoMatch/Gui/TreeView/PlayersTreeView.cs         |    4 +-
 LongoMatch/Gui/TreeView/PlaysTreeView.cs           |   24 ++--
 LongoMatch/Gui/TreeView/TagsTreeView.cs            |    2 +-
 LongoMatch/Handlers/EventsManager.cs               |   11 +-
 LongoMatch/Handlers/Handlers.cs                    |    2 +-
 LongoMatch/Handlers/HotKeysManager.cs              |    4 +-
 LongoMatch/IO/SectionsReader.cs                    |   16 +-
 LongoMatch/IO/SectionsWriter.cs                    |    2 +-
 LongoMatch/Main.cs                                 |    2 +-
 LongoMatch/Time/Tag.cs                             |    2 +-
 LongoMatch/Utils/ProjectUtils.cs                   |   15 +-
 LongoMatch/gtk-gui/gui.stetic                      |   14 +-
 LongoMatch/gtk-gui/objects.xml                     |  144 ++++++++++++++++++++
 35 files changed, 430 insertions(+), 238 deletions(-)
---
diff --git a/LongoMatch/DB/Project.cs b/LongoMatch/DB/Project.cs
index 2a66762..c6507b7 100644
--- a/LongoMatch/DB/Project.cs
+++ b/LongoMatch/DB/Project.cs
@@ -94,6 +94,11 @@ namespace LongoMatch.DB
 			set;
 		}
 		
+		public TagsTemplate Tags {
+			get;
+			set;
+		}
+		
 		#endregion
 
 		#region Public Methods
@@ -179,6 +184,19 @@ namespace LongoMatch.DB
 			foreach (var play in playsList)
 				playsList.Remove(play);
 		}
+		
+		public List<List<Play>> PlaysGroupedByCategory {
+			get {
+				var list = new List<List<Play>> ();
+				var queryPlaysByCategory = 
+					from play in playsList
+						group play by play.Category;
+				
+				foreach (var playsGroup in queryPlaysByCategory)
+					list.Add(playsGroup.ToList());
+				return list;
+			}
+		}
 
 		/// <summary>
 		/// Returns a <see cref="Gtk.TreeStore"/> in which project categories are
diff --git a/LongoMatch/DB/ProjectDescription.cs b/LongoMatch/DB/ProjectDescription.cs
index 725287f..8dad4c7 100644
--- a/LongoMatch/DB/ProjectDescription.cs
+++ b/LongoMatch/DB/ProjectDescription.cs
@@ -33,7 +33,7 @@ namespace LongoMatch.DB
 		
 		public String Title {
 			get {
-				return System.IO.Path.GetFileNameWithoutExtension(File);
+				return System.IO.Path.GetFileNameWithoutExtension(File.FilePath);
 			}
 		}
 
@@ -100,7 +100,7 @@ namespace LongoMatch.DB
 		
 		public String Format {
 			get{
-				String.Format("{0}x{1} {2}fps", 
+				return String.Format("{0}x{1} {2}fps", 
 				              File.VideoWidth, File.VideoHeight, File.Fps);
 			}
 		}
@@ -109,7 +109,7 @@ namespace LongoMatch.DB
 			if (obj is ProjectDescription) {
 				ProjectDescription project = (ProjectDescription) obj;
 
-				return this.File.CompareTo(project.File);
+				return this.File.FilePath.CompareTo(project.File.FilePath);
 			}
 			else
 				throw new ArgumentException("object is not a ProjectDescription and cannot be compared");
diff --git a/LongoMatch/DB/Sections.cs b/LongoMatch/DB/Sections.cs
index 31d371d..9685b8c 100644
--- a/LongoMatch/DB/Sections.cs
+++ b/LongoMatch/DB/Sections.cs
@@ -64,6 +64,10 @@ namespace LongoMatch.DB
 		public void AddCategory(Category category) {
 			categoriesList.Add(category);
 		}
+		
+		public void AddCategoryAtPos(int pos, Category category) {
+			categoriesList.Insert(pos, category);
+		}
 
 		/// <summary>
 		/// Delete a category from the templates using the it's index
diff --git a/LongoMatch/DB/TeamTemplate.cs b/LongoMatch/DB/TeamTemplate.cs
index 67c4842..84bbbfc 100644
--- a/LongoMatch/DB/TeamTemplate.cs
+++ b/LongoMatch/DB/TeamTemplate.cs
@@ -86,7 +86,7 @@ namespace LongoMatch.DB
 				playersList.Add(new Player{
 					Name = "Player " + i,
 					Birthday = new DateTime(),
-					Height = 1.80,
+					Height = 1.80f,
 					Weight = 80,
 					Number = 0,
 					Position = "",
diff --git a/LongoMatch/Gui/Component/ButtonsWidget.cs b/LongoMatch/Gui/Component/ButtonsWidget.cs
index df9bab6..04b098a 100644
--- a/LongoMatch/Gui/Component/ButtonsWidget.cs
+++ b/LongoMatch/Gui/Component/ButtonsWidget.cs
@@ -35,6 +35,7 @@ namespace LongoMatch.Gui.Component
 
 		private Categories categories;		
 		private TagMode tagMode;
+		private Dictionary<Widget, Category> buttonsDic;
 
 		public event NewMarkEventHandler NewMarkEvent;
 		public event NewMarkStartHandler NewMarkStartEvent;
@@ -45,6 +46,7 @@ namespace LongoMatch.Gui.Component
 		{
 			this.Build();
 			Mode = TagMode.Predifined;
+			buttonsDic = new Dictionary<Widget, Category>();
 		}
 		
 		public TagMode Mode{
@@ -66,7 +68,8 @@ namespace LongoMatch.Gui.Component
 				Categories = value;
 				if (value == null)
 					return;
-
+				
+				buttonsDic.Clear();
 				int sectionsCount = value.Count;
 
 				table1.NColumns =(uint) 10;
@@ -75,12 +78,14 @@ namespace LongoMatch.Gui.Component
 				for (int i=0;i<sectionsCount;i++) {
 					Button b = new Button();
 					Label l = new Label();
+					Category cat = value.CategoriesList[i];
+
 					uint row_top =(uint)(i/table1.NColumns);
 					uint row_bottom = (uint) row_top+1 ;
 					uint col_left = (uint) i%table1.NColumns;
 					uint col_right = (uint) col_left+1 ;
 
-					l.Markup = sections.GetName(i);
+					l.Markup = cat.Name;
 					l.Justify = Justification.Center;
 					l.Ellipsize = Pango.EllipsizeMode.Middle;
 					l.CanFocus = false;
@@ -94,6 +99,8 @@ namespace LongoMatch.Gui.Component
 					b.Show();
 
 					table1.Attach(b,col_left,col_right,row_top,row_bottom);
+
+					buttonsDic.Add(b, cat);
 				}
 			}
 		}
@@ -105,13 +112,13 @@ namespace LongoMatch.Gui.Component
 			Widget w = (Button)sender;
 			if (tagMode == TagMode.Predifined){
 				if (NewMarkEvent != null)
-					NewMarkEvent(int.Parse(w.Name));
+					NewMarkEvent(buttonsDic[w]);
 			} else {
 				starttagbutton.Visible = true;
 				table1.Visible = false;
 				cancelbutton.Visible = false;
 				if (NewMarkStopEvent != null)
-					NewMarkStopEvent(int.Parse(w.Name));
+					NewMarkStopEvent(buttonsDic[w]);
 			}			
 		}
 
diff --git a/LongoMatch/Gui/Component/CategoryProperties.cs b/LongoMatch/Gui/Component/CategoryProperties.cs
index 33d3c1b..ff3dba1 100644
--- a/LongoMatch/Gui/Component/CategoryProperties.cs
+++ b/LongoMatch/Gui/Component/CategoryProperties.cs
@@ -44,8 +44,7 @@ namespace LongoMatch.Gui.Component
 			this.Build();
 		}
 
-		public Category Section
-		{
+		public Category Category{
 			set {
 				stn = value;
 				UpdateGui();
diff --git a/LongoMatch/Gui/Component/PlaysListTreeWidget.cs b/LongoMatch/Gui/Component/PlaysListTreeWidget.cs
index 29999d6..0a15d1f 100644
--- a/LongoMatch/Gui/Component/PlaysListTreeWidget.cs
+++ b/LongoMatch/Gui/Component/PlaysListTreeWidget.cs
@@ -57,11 +57,12 @@ namespace LongoMatch.Gui.Component
             treeview.TagPlay += OnTagPlay;
 		}		
 
-		public void RemovePlay(Play play, Category category) {
+		public void RemovePlay(Play play) {
 			if (project != null) {
 				TreeIter iter;
 				TreeIter child;
 				
+				var category = play.Category;
 				var model = (TreeStore)treeview.Model;
 				model.GetIterFromString(out iter, category.Position.ToString());
 				model.IterChildren(out child, iter);
@@ -107,13 +108,12 @@ namespace LongoMatch.Gui.Component
 				project = value;
 				if (project != null) {
 					treeview.Model = project.GetModel();
-					treeview.Colors = project.Sections.GetColors();
-					treeview.VisitorTeam = project.VisitorName;
-					treeview.LocalTeam = project.LocalName;
+					treeview.Colors = true;
+					treeview.VisitorTeam = project.Description.VisitorName;
+					treeview.LocalTeam = project.Description.LocalName;
 				}
 				else {
 					treeview.Model = null;
-					treeview.Colors = null;
 				}
 			}
 		}
@@ -134,9 +134,9 @@ namespace LongoMatch.Gui.Component
 				TimeNodeSelected(tNode);
 		}
 
-		protected virtual void OnTimeNodeDeleted(Play tNode, Category category){
+		protected virtual void OnTimeNodeDeleted(Play tNode){
 			if (TimeNodeDeleted != null)
-				TimeNodeDeleted(tNode, category);
+				TimeNodeDeleted(tNode);
 		}
 
 		protected virtual void OnPlayListNodeAdded(Play tNode)
diff --git a/LongoMatch/Gui/Component/ProjectDetailsWidget.cs b/LongoMatch/Gui/Component/ProjectDetailsWidget.cs
index e96c4f1..766fb67 100644
--- a/LongoMatch/Gui/Component/ProjectDetailsWidget.cs
+++ b/LongoMatch/Gui/Component/ProjectDetailsWidget.cs
@@ -187,12 +187,12 @@ namespace LongoMatch.Gui.Component
 			}
 		}
 
-		public Category Category {
+		public Categories Categories {
 			get {
-				return actualSection;
+				return actualCategory;
 			}
 			set {
-				actualSection = value;
+				actualCategory = value;
 			}
 		}
 
@@ -297,31 +297,33 @@ namespace LongoMatch.Gui.Component
 		
 		public void SetProject(Project project) {
 			this.project = project;
-			mFile = project.File;
+			var desc = project.Description;
+			mFile = desc.File;
 			Filename = mFile != null ? mFile.FilePath : "";
-			LocalName = project.LocalName;
-			VisitorName = project.VisitorName;
-			LocalGoals = project.LocalGoals;
-			VisitorGoals = project.VisitorGoals;
-			Date = project.MatchDate;
-			Season = project.Season;
-			Competition = project.Competition;
-			Sections = project.Sections;
+			LocalName = desc.LocalName;
+			VisitorName = desc.VisitorName;
+			LocalGoals = desc.LocalGoals;
+			VisitorGoals = desc.VisitorGoals;
+			Date = desc.MatchDate;
+			Season = desc.Season;
+			Competition = desc.Competition;
+			Categories = project.Categories;
 			LocalTeamTemplate = project.LocalTeamTemplate;
 			VisitorTeamTemplate = project.VisitorTeamTemplate;
 			Edited = false;
 		}
 
 		public void UpdateProject() {
-			project.File= mFile;			
-			project.LocalName = localTeamEntry.Text;
-			project.VisitorName = visitorTeamEntry.Text;
-			project.LocalGoals = (int)localSpinButton.Value;
-			project.VisitorGoals = (int)visitorSpinButton.Value;
-			project.MatchDate = DateTime.Parse(dateEntry.Text);
-			project.Competition = competitionentry.Text;
-			project.Season = seasonentry.Text;
-			project.Sections = Sections;
+			var desc = project.Description;
+			desc.File= mFile;			
+			desc.LocalName = localTeamEntry.Text;
+			desc.VisitorName = visitorTeamEntry.Text;
+			desc.LocalGoals = (int)localSpinButton.Value;
+			desc.VisitorGoals = (int)visitorSpinButton.Value;
+			desc.MatchDate = DateTime.Parse(dateEntry.Text);
+			desc.Competition = competitionentry.Text;
+			desc.Season = seasonentry.Text;
+			project.Categories = Categories;
 			project.LocalTeamTemplate = LocalTeamTemplate;
 			project.VisitorTeamTemplate = VisitorTeamTemplate;
 		}
@@ -340,17 +342,21 @@ namespace LongoMatch.Gui.Component
 						mFile.FilePath = fileEntry.Text;
 						mFile.Fps = 25;
 					}
-					return new Project(mFile,
-					                   LocalName,
-					                   VisitorName,
-					                   Season,
-					                   Competition,
-					                   LocalGoals,
-					                   VisitorGoals,
-					                   Date,
-					                   Sections,
-					                   LocalTeamTemplate,
-					                   VisitorTeamTemplate);
+					var desc = new ProjectDescription {
+						File = mFile,
+						LocalName = LocalName,
+						VisitorName = VisitorName,
+						Season = Season,
+						Competition = Competition,
+						LocalGoals = LocalGoals,
+						MatchDate = Date
+					};
+					
+					return new Project{
+						Description = desc,
+						Categories = Categories,
+						LocalTeamTemplate = LocalTeamTemplate,
+						VisitorTeamTemplate = VisitorTeamTemplate};
 				}				
 			}
 			else {
@@ -408,8 +414,8 @@ namespace LongoMatch.Gui.Component
 				i++;
 			}
 			tagscombobox.Active = index;
-			SectionsReader reader = new SectionsReader(System.IO.Path.Combine(MainClass.TemplatesDir(),SectionsFile));
-			Sections= reader.GetSections();
+			var reader = new CategoriesReader(System.IO.Path.Combine(MainClass.TemplatesDir(),SectionsFile));
+			Categories = reader.GetCategories();
 		}
 
 		private void FillTeamsTemplate() {
@@ -529,8 +535,8 @@ namespace LongoMatch.Gui.Component
 
 		protected virtual void OnCombobox1Changed(object sender, System.EventArgs e)
 		{
-			SectionsReader reader = new SectionsReader(System.IO.Path.Combine(MainClass.TemplatesDir(),SectionsFile));
-			Sections= reader.GetSections();
+			var reader = new CategoriesReader(System.IO.Path.Combine(MainClass.TemplatesDir(),SectionsFile));
+			Categories = reader.GetCategories();
 		}
 
 		protected virtual void OnVisitorcomboboxChanged(object sender, System.EventArgs e)
@@ -548,11 +554,11 @@ namespace LongoMatch.Gui.Component
 		{
 			ProjectTemplateEditorDialog ted = new ProjectTemplateEditorDialog();
 			ted.TransientFor = (Window)Toplevel;
-			ted.Sections = Sections;
+			ted.Categories = Categories;
 			ted.Project = project;
 			ted.CanExport = Use == ProjectType.EditProject;
 			if (ted.Run() == (int)ResponseType.Apply) {
-				Sections = ted.Sections;
+				Categories = ted.Categories;
 			}
 			ted.Destroy();
 			OnEdited(this,null);
diff --git a/LongoMatch/Gui/Component/ProjectTemplateWidget.cs b/LongoMatch/Gui/Component/ProjectTemplateWidget.cs
index 853e7fe..842ec20 100644
--- a/LongoMatch/Gui/Component/ProjectTemplateWidget.cs
+++ b/LongoMatch/Gui/Component/ProjectTemplateWidget.cs
@@ -38,9 +38,8 @@ namespace LongoMatch.Gui.Component
 	{
 		private List<HotKey> hkList;
 		private Project project;
-		private Categories sections;
-		private List<Categories> selectedCategories;
-		private bool edited = false;
+		private Categories categories;
+		private List<Category> selectedCategories;
 
 		public ProjectTemplateWidget()
 		{
@@ -48,28 +47,32 @@ namespace LongoMatch.Gui.Component
 			hkList = new List<HotKey>();
 		}
 
-		public void SetProject(Project project) {
-			this.project = project;
-			if (project != null)
-				Categories=project.Categories;
+		public Project Project {
+			set{
+				project = project;
+				if (project != null)
+					Categories = project.Categories;
+			}
 		}
 
 		public Categories Categories {
 			get {
-				return sections;
+				return categories;
 			}
 			set {
-				this.sections = value;
-				edited = false;
-				Gtk.TreeStore sectionsListStore = new Gtk.TreeStore(typeof(Category));
+				categories = value;
+				Edited = false;
+				Gtk.TreeStore categoriesListStore = new Gtk.TreeStore(typeof(Category));
 				hkList.Clear();
-				for (int i=0;i<sections.Count;i++) {
-					sectionsListStore.AppendValues(sections.GetSection(i));
+				
+				foreach (var cat in categories.CategoriesList){
+					categoriesListStore.AppendValues(cat);
 					try {
-						hkList.Add(sections.GetSection(i).HotKey);
+						hkList.Add(cat.HotKey);
 					} catch {}; //Do not add duplicated hotkeys
 				}
-				sectionstreeview1.Model = sectionsListStore;
+				/* FIXME */
+				//categoriestreeview1.Model = categoriesListStore;
 				ButtonsSensitive = false;
 			}
 		}
@@ -81,35 +84,38 @@ namespace LongoMatch.Gui.Component
 			}
 		}
 		public bool Edited {
-			get {
-				return edited;
-			}
-			set {
-				edited=value;
-			}
+			get;
+			set;
 		}
 
 		private void UpdateModel() {
 			Categories = Categories;
 		}
 
-		private void AddSection(int index) {
+		private void AddCategory(int index) {
 			Category tn;
 			HotKey hkey = new HotKey();
 
 			Time start = new Time(10*Time.SECONDS_TO_TIME);
 			Time stop = new Time(10*Time.SECONDS_TO_TIME);
 
-			tn  = new Category("New Section",start,stop,hkey,new Color(Byte.MaxValue,Byte.MinValue,Byte.MinValue));
+			tn  = new Category{
+				Name = "New Section",
+				Start = start,
+				Stop = stop,
+				HotKey = hkey,
+				Color =	new Color(Byte.MaxValue,Byte.MinValue,Byte.MinValue)
+			};
 
 			if (project != null) {
-				project.AddSectionAtPos(tn,index);
-			}
-			else {
-				sections.AddSectionAtPos(tn,index);
+				/* Editing a project template */
+				project.Categories.AddCategoryAtPos(index,tn);
+			} else {
+				/* Editing a template in the templates editor */
+				categories.AddCategoryAtPos(index,tn);
 			}
 			UpdateModel();
-			edited = true;
+			Edited = true;
 		}
 
 		private void RemoveSelectedCategories() {
@@ -119,26 +125,26 @@ namespace LongoMatch.Gui.Component
 				                Catalog.GetString("You are about to delete a category and all the plays added to this category. Do you want to proceed?"));
 				if (dialog.Run() == (int)ResponseType.Yes){
 					try {
-						foreach (Category tNode in selectedCategories)
-							project.DeleteSection(sections.Categorys.IndexOf(tNode));
+						foreach (Category cat in selectedCategories)
+							project.Categories.RemoveCategory(cat);
 					} catch {
 						MessagePopup.PopupMessage(this,MessageType.Warning,
 						                          Catalog.GetString("A template needs at least one category"));
 					}
 				}
 				dialog.Destroy();
-				sections=project.Categories;
+				categories = project.Categories;
 			} else {
-				foreach (Category tNode in selectedCategories){
-					if (sections.Count == 1){
+				foreach (Category cat in selectedCategories){
+					if (categories.Count == 1){
 						MessagePopup.PopupMessage(this,MessageType.Warning,
 						                          Catalog.GetString("A template needs at least one category"));
 					} else 
-						sections.RemoveSection(sections.Categorys.IndexOf(tNode));
+						categories.RemoveCategory(cat);
 				}
 			}
 			UpdateModel();
-			edited = true;
+			Edited = true;
 			selectedCategories = null;
 			ButtonsSensitive=false;
 		}
@@ -154,12 +160,12 @@ namespace LongoMatch.Gui.Component
 
 		private void EditSelectedSection() {
 			EditCategoryDialog dialog = new EditCategoryDialog();
-			dialog.Section = selectedCategories[0];
+			dialog.Category = selectedCategories[0];
 			dialog.HotKeysList = hkList;
 			dialog.TransientFor = (Gtk.Window) Toplevel;
 			dialog.Run();
 			dialog.Destroy();
-			edited = true;
+			Edited = true;
 		}
 		
 		private void SaveTemplate(string templateName){
@@ -167,11 +173,11 @@ namespace LongoMatch.Gui.Component
 		}
 
 		protected virtual void OnNewAfter(object sender, EventArgs args) {
-			AddSection(sections.Categorys.IndexOf(selectedCategories[0])+1);
+			AddCategory(categories.CategoriesList.IndexOf(selectedCategories[0])+1);
 		}
 
 		protected virtual void OnNewBefore(object sender, EventArgs args) {
-			AddSection(sections.Categorys.IndexOf(selectedCategories[0]));
+			AddCategory(categories.CategoriesList.IndexOf(selectedCategories[0]));
 		}
 
 		protected virtual void OnRemove(object sender, EventArgs args) {
@@ -225,7 +231,7 @@ namespace LongoMatch.Gui.Component
 					                                     MessageType.Question,
 					                                     Gtk.ButtonsType.YesNo,
 					                                     Catalog.GetString("The template already exists. " +
-					                                     	"Do you want to overwrite it ?")
+					                                                       "Do you want to overwrite it ?")
 					                                   );
 					if (md.Run() == (int)ResponseType.Yes)
 						SaveTemplate(dialog.Text);
diff --git a/LongoMatch/Gui/Component/TaggerWidget.cs b/LongoMatch/Gui/Component/TaggerWidget.cs
index e881d56..ae83837 100644
--- a/LongoMatch/Gui/Component/TaggerWidget.cs
+++ b/LongoMatch/Gui/Component/TaggerWidget.cs
@@ -77,16 +77,18 @@ namespace LongoMatch.Gui.Component
 		}
 		
 		private void AddTag(string text, bool check){
-			Tag tag = new Tag(text);
+			Tag tag = new Tag {
+				Value = text,
+			};
 			if (tagsDict.ContainsKey(tag))
 				return;
 			AddTagWidget(tag, check);
 		}
 		
 		private void AddTagWidget(Tag tag, bool check){
-			CheckButton button = new CheckButton(tag.Text);					
-			button.Name = tag.Text;		
-			AddElementToTable(button);	
+			CheckButton button = new CheckButton(tag.Value);
+			button.Name = tag.Value;
+			AddElementToTable(button);
 			button.Active = check;
 			tagsDict.Add(tag, button);
 		}
@@ -118,7 +120,9 @@ namespace LongoMatch.Gui.Component
 				scrolledwindow1.Visible = true;
 				label1.Visible = false;
 			}
-			tag = new Tag(entry1.Text);
+			tag = new Tag{
+				Value = entry1.Text,
+			};
 			if (tagsDict.TryGetValue(tag, out button))
 				button.Active = true;
 			else
diff --git a/LongoMatch/Gui/Component/TagsTreeWidget.cs b/LongoMatch/Gui/Component/TagsTreeWidget.cs
index e8108ba..7627eb8 100644
--- a/LongoMatch/Gui/Component/TagsTreeWidget.cs
+++ b/LongoMatch/Gui/Component/TagsTreeWidget.cs
@@ -112,13 +112,13 @@ namespace LongoMatch.Gui.Component
 				project = value;
 				if (project != null) {
 					model.Clear();
-					foreach (List<Play> list in project.GetDataArray()){
+					foreach (List<Play> list in project.PlaysGroupedByCategory){
 						foreach (Play tNode in list)
 							model.AppendValues(tNode);
 					}
 					UpdateTagsList();
-					treeview.LocalTeam = value.LocalName;
-					treeview.VisitorTeam = value.VisitorName;
+					treeview.LocalTeam = project.Description.LocalName;
+					treeview.VisitorTeam = project.Description.VisitorName;
 				}
 			}
 		}
@@ -132,7 +132,7 @@ namespace LongoMatch.Gui.Component
 		public void UpdateTagsList(){
 			(tagscombobox.Model as ListStore).Clear();
 			foreach (Tag tag in project.Tags)
-				tagscombobox.AppendText(tag.Text);
+				tagscombobox.AppendText(tag.Value);
 		}
 		
 		private void AddFilterWidget(Tag tag){
@@ -141,11 +141,11 @@ namespace LongoMatch.Gui.Component
 			Label l;
 			
 			box = new HBox();
-			box.Name = tag.Text;
+			box.Name = tag.Value;
 			b = new Button();
 			b.Image =  new Image(Stetic.IconLoader.LoadIcon(this, "gtk-delete", Gtk.IconSize.Menu));
 			b.Clicked += OnDeleteClicked;
-			l = new Label(tag.Text);
+			l = new Label(tag.Value);
 			l.Justify = Justification.Left;
 			box.PackEnd(b,false,  false, 0);
 			box.PackStart(l,true, true, 0);
@@ -156,7 +156,7 @@ namespace LongoMatch.Gui.Component
 		protected virtual void OnDeleteClicked (object o, System.EventArgs e){
 			Widget parent = (o as Widget).Parent;
 		    tagscombobox.AppendText(parent.Name);
-			filterTags.Remove(new Tag(parent.Name));
+			filterTags.Remove(new Tag{Value = parent.Name});
 			filter.Refilter();
 			tagsvbox.Remove(parent);
 		}
@@ -167,7 +167,7 @@ namespace LongoMatch.Gui.Component
 			if (text == null || text == "")
 				return;
 			
-			Tag tag = new Tag(text);
+			Tag tag = new Tag{ Value = text};
 			if (!filterTags.Contains(tag)){
 				filterTags.Add(tag);
 				tagscombobox.RemoveText(tagscombobox.Active);
diff --git a/LongoMatch/Gui/Component/TeamTemplateWidget.cs b/LongoMatch/Gui/Component/TeamTemplateWidget.cs
index d3af265..b48e566 100644
--- a/LongoMatch/Gui/Component/TeamTemplateWidget.cs
+++ b/LongoMatch/Gui/Component/TeamTemplateWidget.cs
@@ -47,8 +47,8 @@ namespace LongoMatch.Gui.Component
 				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));
+				foreach (Player player in template.PlayersList)
+					playersListStore.AppendValues(player);
 				playerpropertiestreeview1.Model=playersListStore;
 			}
 		}
diff --git a/LongoMatch/Gui/Component/TimeLineWidget.cs b/LongoMatch/Gui/Component/TimeLineWidget.cs
index f6ab96a..9bf81dd 100644
--- a/LongoMatch/Gui/Component/TimeLineWidget.cs
+++ b/LongoMatch/Gui/Component/TimeLineWidget.cs
@@ -38,8 +38,8 @@ namespace LongoMatch.Gui.Component {
 		public event NewMarkAtFrameEventHandler NewMarkEvent;
 		//public event PlayListNodeAddedHandler PlayListNodeAdded;
 
-		private TimeScale[] tsArray;
-		private List<List<Play>> tnArray;
+		private List<TimeScale> tsList;
+		private List<List<Play>> playsByCategory;
 		private Categories sections;
 		private TimeReferenceWidget tr;
 		private uint frames;
@@ -61,8 +61,8 @@ namespace LongoMatch.Gui.Component {
 			}
 			set {
 				selected = value;
-				if (tsArray != null && tnArray != null) {
-					foreach (TimeScale  ts in tsArray) {
+				if (tsList != null && playsByCategory != null) {
+					foreach (TimeScale  ts in tsList) {
 						ts.SelectedTimeNode = value;
 					}
 				}
@@ -83,8 +83,8 @@ namespace LongoMatch.Gui.Component {
 			set {
 				currentFrame = value;
 
-				if (tsArray != null && tnArray != null) {
-					foreach (TimeScale  ts in tsArray) {
+				if (tsList != null && playsByCategory != null) {
+					foreach (TimeScale  ts in tsList) {
 						ts.CurrentFrame = value;
 					}
 					tr.CurrentFrame = value;
@@ -114,10 +114,10 @@ namespace LongoMatch.Gui.Component {
 
 
 		private void SetPixelRatio(uint pixelRatio) {
-			if (tsArray != null && tnArray != null) {
+			if (tsList != null && playsByCategory != null) {
 				this.pixelRatio = pixelRatio;
 				tr.PixelRatio = pixelRatio;
-				foreach (TimeScale  ts in tsArray) {
+				foreach (TimeScale  ts in tsList) {
 					ts.PixelRatio = pixelRatio;
 				}
 				vscale1.Value=pixelRatio;
@@ -127,34 +127,38 @@ namespace LongoMatch.Gui.Component {
 
 		public Project Project {
 			set {
+				int i = 0;
+				
 				ResetGui();
 
 				if (value == null) {
 					sections = null;
-					tnArray = null;
-					tsArray=null;
+					playsByCategory = null;
+					tsList=null;
 					return;
 				}
 
 				sections = value.Categories;
-				tnArray = value.GetDataArray();
-				tsArray = new TimeScale[sections.Count];
+				playsByCategory = value.PlaysGroupedByCategory;
+				tsList = new List<TimeScale>();
 
-				frames = value.File.GetFrames();
-				ushort fps = value.File.Fps;
+				frames = value.Description.File.GetFrames();
+				ushort fps = value.Description.File.Fps;
 
 				tr = new TimeReferenceWidget(frames,fps);
 				vbox1.PackStart(tr,false,false,0);
 				tr.Show();
-				for (int i=0; i<sections.Count; i++) {
-					TimeScale ts = new TimeScale(i,tnArray[i],frames,sections.GetColor(i));
-					tsArray[i]=ts;
+				
+				foreach (List<Play> playsList in playsByCategory) {
+					TimeScale ts = new TimeScale(i, playsList ,frames);					
+					tsList[i]=ts;
 					ts.TimeNodeChanged += new TimeNodeChangedHandler(OnTimeNodeChanged);
 					ts.TimeNodeSelected += new TimeNodeSelectedHandler(OnTimeNodeSelected);
 					ts.TimeNodeDeleted += new TimeNodeDeletedHandler(OnTimeNodeDeleted);
 					ts.NewMarkAtFrameEvent += new NewMarkAtFrameEventHandler(OnNewMark);
 					vbox1.PackStart(ts,true,true,0);
 					ts.Show();
+					i++;
 				}
 				SetPixelRatio(3);
 			}
@@ -168,9 +172,9 @@ namespace LongoMatch.Gui.Component {
 			}
 		}
 
-		protected virtual void OnNewMark(int section, int frame) {
+		protected virtual void OnNewMark(Category category, int frame) {
 			if (NewMarkEvent != null)
-				NewMarkEvent(section,frame);
+				NewMarkEvent(category,frame);
 		}
 
 		protected virtual void OnTimeNodeChanged(TimeNode tn, object val) {
@@ -182,9 +186,9 @@ namespace LongoMatch.Gui.Component {
 			if (TimeNodeSelected != null)
 				TimeNodeSelected(tn);
 		}
-		protected virtual void OnTimeNodeDeleted(Play tn, int section) {
+		protected virtual void OnTimeNodeDeleted(Play tn) {
 			if (TimeNodeDeleted != null)
-				TimeNodeDeleted(tn,section);
+				TimeNodeDeleted(tn);
 		}
 
 		protected virtual void OnFitbuttonClicked(object sender, System.EventArgs e)
diff --git a/LongoMatch/Gui/Component/TimeScale.cs b/LongoMatch/Gui/Component/TimeScale.cs
index c16b1f0..7a95441 100644
--- a/LongoMatch/Gui/Component/TimeScale.cs
+++ b/LongoMatch/Gui/Component/TimeScale.cs
@@ -44,7 +44,7 @@ namespace LongoMatch.Gui.Component
 
 		private object locker;
 
-		private int section;
+		private Category category;
 		private Cairo.Color color;
 		private List<Play> list;
 
@@ -70,14 +70,14 @@ namespace LongoMatch.Gui.Component
 		public event TimeNodeDeletedHandler TimeNodeDeleted;
 
 
-		public TimeScale(int section,List<Play> list, uint frames,Gdk.Color color)
+		public TimeScale(int section,List<Play> list, uint frames)
 		{
-			this.section = section;
+			this.category = list[0].Category;
 			this.frames = frames;
 			this.list = list;
 			HeightRequest= SECTION_HEIGHT;
 			Size((int)(frames/pixelRatio),SECTION_HEIGHT);
-			this.color = RGBToCairoColor(color);
+			this.color = RGBToCairoColor(category.Color);
 			this.color.A = ALPHA;
 			Events = EventMask.PointerMotionMask | EventMask.ButtonPressMask | EventMask.ButtonReleaseMask ;
 
@@ -316,14 +316,14 @@ namespace LongoMatch.Gui.Component
 
 		protected void OnNewPlay(object obj, EventArgs args) {
 			if (NewMarkAtFrameEvent != null)
-				NewMarkAtFrameEvent(section,cursorFrame);
+				NewMarkAtFrameEvent(category,cursorFrame);
 		}
 
 		protected void OnDelete(object obj, EventArgs args) {
 			Play tNode;
 			dic.TryGetValue((MenuItem)obj, out tNode);
 			if (TimeNodeDeleted != null && tNode != null) {
-				TimeNodeDeleted(tNode, section);
+				TimeNodeDeleted(tNode);
 			}
 		}
 
diff --git a/LongoMatch/Gui/Dialog/EditCategoryDialog.cs b/LongoMatch/Gui/Dialog/EditCategoryDialog.cs
index 3e10dc4..631f3e8 100644
--- a/LongoMatch/Gui/Dialog/EditCategoryDialog.cs
+++ b/LongoMatch/Gui/Dialog/EditCategoryDialog.cs
@@ -52,7 +52,7 @@ namespace LongoMatch.Gui.Dialog
 		}
 
 		protected virtual void OnHotKeyChanged(HotKey prevHotKey, Category category) {
-			if (hkList.Contains(section.HotKey)) {
+			if (hkList.Contains(category.HotKey)) {
 				MessagePopup.PopupMessage(this,MessageType.Warning,
 				                          Catalog.GetString("This hotkey is already in use."));
 				category.HotKey=prevHotKey;
diff --git a/LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs b/LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs
index 7d5ce56..3145a15 100644
--- a/LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs
+++ b/LongoMatch/Gui/Dialog/PlayersSelectionDialog.cs
@@ -77,7 +77,7 @@ namespace LongoMatch.Gui.Dialog
 					pair.Key.Active = value.Contains(pair.Value);
 			}
 			get {
-				var playersList = new List<Players>();
+				List<Player> playersList = new List<Player>();
 				foreach (var pair in checkButtonsDict){
 					if (pair.Key.Active)
 						playersList.Add(pair.Value);
diff --git a/LongoMatch/Gui/Dialog/ProjectTemplateEditorDialog.cs b/LongoMatch/Gui/Dialog/ProjectTemplateEditorDialog.cs
index efc54ce..f8c5d69 100644
--- a/LongoMatch/Gui/Dialog/ProjectTemplateEditorDialog.cs
+++ b/LongoMatch/Gui/Dialog/ProjectTemplateEditorDialog.cs
@@ -36,7 +36,7 @@ namespace LongoMatch.Gui.Dialog
 
 		public Project Project {
 			set {
-				projecttemplatewidget.SetProject(value);
+				projecttemplatewidget.Project = value;
 			}
 		}
 
diff --git a/LongoMatch/Gui/Dialog/ProjectsManager.cs b/LongoMatch/Gui/Dialog/ProjectsManager.cs
index 2c0ecbb..dd72244 100644
--- a/LongoMatch/Gui/Dialog/ProjectsManager.cs
+++ b/LongoMatch/Gui/Dialog/ProjectsManager.cs
@@ -25,6 +25,7 @@ using Mono.Unix;
 using LongoMatch.Common;
 using LongoMatch.DB;
 using LongoMatch.Gui.Component;
+using LongoMatch.Video.Utils;
 
 namespace LongoMatch.Gui.Dialog
 {
@@ -81,7 +82,7 @@ namespace LongoMatch.Gui.Dialog
 			if (project == null)
 				return;
 
-			if (project.File.FilePath == originalFilePath) {
+			if (project.Description.File.FilePath == originalFilePath) {
 				MainClass.DB.UpdateProject(project);
 				saveButton.Sensitive = false;
 			}
@@ -107,7 +108,8 @@ namespace LongoMatch.Gui.Dialog
 			    return;
 			
 			foreach (ProjectDescription selectedProject in selectedProjects) {
-				if (openedProject != null && selectedProject.File == openedProject.File.FilePath) {
+				if (openedProject != null &&
+				    selectedProject.File.FilePath == openedProject.Description.File.FilePath) {
 					MessagePopup.PopupMessage(this, MessageType.Warning,
 					                          Catalog.GetString("This Project is actually in use.")+"\n"+
 					                          Catalog.GetString("Close it first to allow its removal from the database"));
@@ -119,7 +121,7 @@ namespace LongoMatch.Gui.Dialog
 				                                     Catalog.GetString("Do you really want to delete:")+
 				                                     "\n"+selectedProject.Title);
 				if (md.Run()== (int)ResponseType.Yes) {
-					MainClass.DB.RemoveProject(selectedProject.File);
+					MainClass.DB.RemoveProject(selectedProject.File.FilePath);
 					deletedProjects.Add (selectedProject);
 				} 
 				md.Destroy();
@@ -171,15 +173,16 @@ namespace LongoMatch.Gui.Dialog
 			/* if only one project is selected try to load it in the editor */
 			project = projects[0];
 			
-			if (openedProject != null && project.File == openedProject.File.FilePath) {
+			if (openedProject != null && 
+			    project.File.FilePath == openedProject.Description.File.FilePath) {
 				MessagePopup.PopupMessage(this, MessageType.Warning,
 				                          Catalog.GetString("The Project you are trying to load is actually in use.")+"\n" +Catalog.GetString("Close it first to edit it"));
 				Clear();
 			}
 			else {
 				projectdetails.Sensitive = true;
-				projectdetails.SetProject(MainClass.DB.GetProject(project.File));
-				originalFilePath = project.File;
+				projectdetails.SetProject(MainClass.DB.GetProject(project.File.FilePath));
+				originalFilePath = project.File.FilePath;
 				saveButton.Sensitive = false;
 				deleteButton.Sensitive = true;
 				exportbutton.Sensitive = true;
diff --git a/LongoMatch/Gui/Dialog/TemplatesEditor.cs b/LongoMatch/Gui/Dialog/TemplatesEditor.cs
index 48954ba..63b6d71 100644
--- a/LongoMatch/Gui/Dialog/TemplatesEditor.cs
+++ b/LongoMatch/Gui/Dialog/TemplatesEditor.cs
@@ -219,8 +219,7 @@ namespace LongoMatch.Gui.Dialog
 					CategoriesWriter.CreateNewTemplate(name+fileExtension);
 				}
 				else {
-					TeamTemplate tt = new TeamTemplate();
-					tt.CreateDefaultTemplate(count);
+					TeamTemplate tt = TeamTemplate.DefautlTemplate(count);
 					tt.Save(System.IO.Path.Combine(MainClass.TemplatesDir(), name+fileExtension));
 				}
 
diff --git a/LongoMatch/Gui/TreeView/CategoriesTreeView.cs b/LongoMatch/Gui/TreeView/CategoriesTreeView.cs
index 0f0f3aa..5c0cbdd 100644
--- a/LongoMatch/Gui/TreeView/CategoriesTreeView.cs
+++ b/LongoMatch/Gui/TreeView/CategoriesTreeView.cs
@@ -91,7 +91,7 @@ namespace LongoMatch.Gui.Component
 
 		private void RenderName(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
 		{
-			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue(iter, 0);
+			Category tNode = (Category) model.GetValue(iter, 0);
 
 			(cell as Gtk.CellRendererText).Text = tNode.Name;
 		}
@@ -99,50 +99,50 @@ namespace LongoMatch.Gui.Component
 
 		private void RenderStartTime(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
 		{
-			SectionsTimeNode tNode = (SectionsTimeNode) model.GetValue(iter, 0);
+			Category tNode = (Category) 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);
+			Category tNode = (Category) 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);
+			Category tNode = (Category) 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);
+			Category tNode = (Category) Model.GetValue(iter, 0);
 
 			(cell as Gtk.CellRendererText).Text = tNode.HotKey.ToString();
 		}
 		
 		private void RenderSortMethod(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
 		{
-			SectionsTimeNode tNode = (SectionsTimeNode) Model.GetValue(iter, 0);
+			Category tNode = (Category) Model.GetValue(iter, 0);
 
 			(cell as Gtk.CellRendererText).Text = tNode.SortMethodString;
 		}
 
 		protected virtual void OnSelectionChanged(object o, System.EventArgs e) {
 			TreeIter iter;
-			List<SectionsTimeNode> list;
+			List<Category> list;
 			TreePath[] pathArray;
 			
-			list = new List<SectionsTimeNode>();
+			list = new List<Category>();
 			pathArray = Selection.GetSelectedRows();
 			
 			for (int i=0; i< pathArray.Length; i++){
 				Model.GetIterFromString (out iter, pathArray[i].ToString());
-				list.Add((SectionsTimeNode) Model.GetValue(iter, 0));
+				list.Add((Category) Model.GetValue(iter, 0));
 			}
 			if (SectionsSelected != null)
 				SectionsSelected(list);
@@ -152,7 +152,7 @@ namespace LongoMatch.Gui.Component
 		{
 			Gtk.TreeIter iter;
 			Model.GetIter(out iter, args.Path);
-			SectionsTimeNode tNode = (SectionsTimeNode)Model.GetValue(iter, 0);
+			Category tNode = (Category)Model.GetValue(iter, 0);
 
 			if (SectionClicked != null)
 				SectionClicked(tNode);
diff --git a/LongoMatch/Gui/TreeView/ListTreeViewBase.cs b/LongoMatch/Gui/TreeView/ListTreeViewBase.cs
index b8fdb3d..e9c23c9 100644
--- a/LongoMatch/Gui/TreeView/ListTreeViewBase.cs
+++ b/LongoMatch/Gui/TreeView/ListTreeViewBase.cs
@@ -49,7 +49,6 @@ namespace LongoMatch.Gui.Component
 		
 		protected Gtk.CellRendererText nameCell;
 		protected Gtk.TreeViewColumn nameColumn;
-		protected Color[] colors;
 		protected String[] teams_name;
 		protected bool editing;
 		protected bool projectIsLive;
@@ -75,7 +74,6 @@ namespace LongoMatch.Gui.Component
 			SetMenu();
 			ProjectIsLive = false;
 			PlayListLoaded = false;
-			colors = null;
 
 			teams_name = new String[3];
 			teams_name[(int)Team.NONE] = Catalog.GetString(Catalog.GetString("None"));
@@ -98,11 +96,6 @@ namespace LongoMatch.Gui.Component
 
 		}
 
-		public Color[]  Colors {
-			set {
-				this.colors = value;
-			}
-		}
 		public bool ProjectIsLive{
 			set{
 				projectIsLive = value;
@@ -111,6 +104,11 @@ namespace LongoMatch.Gui.Component
 			}
 		}
 		
+		public bool Colors{
+			get;
+			set;
+		}
+		
 		public String LocalTeam {
 			set{
 				Label l1 = (local.Children[0] as Label);
@@ -225,10 +223,10 @@ namespace LongoMatch.Gui.Component
 			var item = model.GetValue(iter, 0);
 			var c = cell as CellRendererPixbuf;
 
-			if (item is MediaTimeNode){
-				c.Pixbuf = (item as MediaTimeNode).Miniature;
-				if (colors !=null) {
-					c.CellBackgroundGdk = colors[GetSectionFromIter(iter)];
+			if (item is Play){
+				c.Pixbuf = (item as Play).Miniature;
+				if (Colors) {
+					c.CellBackgroundGdk = (item as Play).Category.Color;
 				} else{ 
 					c.CellBackground = "white";
 				}
@@ -258,11 +256,10 @@ namespace LongoMatch.Gui.Component
 				return;
 			} 			
 			
-			if (o is MediaTimeNode){
-				var mtn = o as MediaTimeNode;
-				/* FIXME: the colors array is set externally and might not match the model!!! */
-				if (colors !=null) {
-					Color col = colors[GetSectionFromIter(iter)];
+			if (o is Play){
+				var mtn = o as Play;
+				if (Colors) {
+					Color col = mtn.Category.Color;
 					c.CellBackgroundGdk = col;
 					c.BackgroundGdk = col;
 				} else{ 
@@ -274,7 +271,7 @@ namespace LongoMatch.Gui.Component
 				c.Background = "white";
 				c.CellBackground = "white";
 				c.Markup = String.Format("{0} ({1})", (o as Player).Name, Model.IterNChildren(iter));
-			}else if (o is SectionsTimeNode) {
+			}else if (o is Category) {
 				c.Background = "white";
 				c.CellBackground = "white";
 				c.Markup = String.Format("{0} ({1})", (o as TimeNode).Name, Model.IterNChildren(iter));
@@ -306,26 +303,27 @@ namespace LongoMatch.Gui.Component
 			this.Model.GetIter(out iter, args.Path);
 			object item = this.Model.GetValue(iter, 0);
 			
-			if (!(item is MediaTimeNode))
+			if (!(item is Play))
 				return;
 
 			if (TimeNodeSelected != null && !projectIsLive)
-				this.TimeNodeSelected(item as MediaTimeNode);
+				this.TimeNodeSelected(item as Play);
 		}
 
 		protected void OnDeleted(object obj, EventArgs args) {
 			if (TimeNodeDeleted == null)
 				return;
-			List<MediaTimeNode> list = new List<MediaTimeNode>();
+			List<Play> list = new List<Play>();
 			TreePath[] paths = Selection.GetSelectedRows();
 			for (int i=0; i<paths.Length; i++){	
-				list.Add((MediaTimeNode)GetValueFromPath(paths[i]));
+				list.Add((Play)GetValueFromPath(paths[i]));
 			}
 			// When a TimeNode is deleted from the tree the path changes.
 			// We need first to retrieve all the TimeNodes to delete using the 
 			// current path of each one and then send the TimeNodeDeleted event
 			for (int i=0; i<paths.Length; i++){	
-				TimeNodeDeleted(list[i], int.Parse(paths[i].ToString().Split(':')[0]));
+				/*FIXME*/
+				//TimeNodeDeleted(list[i], int.Parse(paths[i].ToString().Split(':')[0]));
 			}			
 		}
 
@@ -340,7 +338,7 @@ namespace LongoMatch.Gui.Component
 			if (md.Run() == (int)ResponseType.Yes){
 				TreePath[] paths = Selection.GetSelectedRows();
 				for (int i=0; i<paths.Length; i++){	
-					MediaTimeNode tNode = (MediaTimeNode)GetValueFromPath(paths[i]);
+					Play tNode = (Play)GetValueFromPath(paths[i]);
 					tNode.KeyFrameDrawing = null;
 				}
 				// Refresh the thumbnails
@@ -369,7 +367,7 @@ namespace LongoMatch.Gui.Component
 			
 			TreePath[] paths = Selection.GetSelectedRows();
 			for (int i=0; i<paths.Length; i++){	
-					MediaTimeNode tNode = (MediaTimeNode)GetValueFromPath(paths[i]);
+					Play tNode = (Play)GetValueFromPath(paths[i]);
 					tNode.Team = team;
 			}
 		}
@@ -378,7 +376,7 @@ namespace LongoMatch.Gui.Component
 			if (PlayListNodeAdded != null){
 				TreePath[] paths = Selection.GetSelectedRows();
 				for (int i=0; i<paths.Length; i++){	
-					MediaTimeNode tNode = (MediaTimeNode)GetValueFromPath(paths[i]);
+					Play tNode = (Play)GetValueFromPath(paths[i]);
 					PlayListNodeAdded(tNode);
 				}
 			}
@@ -386,22 +384,22 @@ namespace LongoMatch.Gui.Component
 		
 		protected void OnTag (object obj, EventArgs args){
 			if (TagPlay != null)
-				TagPlay((MediaTimeNode)GetValueFromPath(Selection.GetSelectedRows()[0]));
+				TagPlay((Play)GetValueFromPath(Selection.GetSelectedRows()[0]));
 		}
 
 		protected void OnSnapshot(object obj, EventArgs args) {
 			if (SnapshotSeriesEvent != null)
-				SnapshotSeriesEvent((MediaTimeNode)GetValueFromPath(Selection.GetSelectedRows()[0]));
+				SnapshotSeriesEvent((Play)GetValueFromPath(Selection.GetSelectedRows()[0]));
 		}
 
 		protected virtual void OnLocalPlayers(object o, EventArgs args) {
 			if (PlayersTagged != null)
-				PlayersTagged((MediaTimeNode)GetValueFromPath(Selection.GetSelectedRows()[0]), Team.LOCAL);
+				PlayersTagged((Play)GetValueFromPath(Selection.GetSelectedRows()[0]), Team.LOCAL);
 		}
 
 		protected virtual void OnVisitorPlayers(object o, EventArgs args) {
 			if (PlayersTagged != null)
-				PlayersTagged((MediaTimeNode)GetValueFromPath(Selection.GetSelectedRows()[0]), Team.VISITOR);
+				PlayersTagged((Play)GetValueFromPath(Selection.GetSelectedRows()[0]), Team.VISITOR);
 		}
 		
 		protected abstract bool SelectFunction(TreeSelection selection, TreeModel model, TreePath path, bool selected);
diff --git a/LongoMatch/Gui/TreeView/PlayListTreeView.cs b/LongoMatch/Gui/TreeView/PlayListTreeView.cs
index a49728c..8cdcb25 100644
--- a/LongoMatch/Gui/TreeView/PlayListTreeView.cs
+++ b/LongoMatch/Gui/TreeView/PlayListTreeView.cs
@@ -102,7 +102,7 @@ namespace LongoMatch.Gui.Component
 				if (path!=null) {
 					ListStore list = ((ListStore)Model);
 					Model.GetIter(out selectedIter,path);
-					selectedTimeNode = (PlayListTimeNode)(list.GetValue(selectedIter,0));
+					selectedTimeNode = (PlayListPlay)(list.GetValue(selectedIter,0));
 					setRate.Sensitive = selectedTimeNode == loadedTimeNode;
 					menu.Popup();
 				}
@@ -134,7 +134,7 @@ namespace LongoMatch.Gui.Component
 
 		private void RenderName(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel model, Gtk.TreeIter iter)
 		{
-			PlayListTimeNode tNode = (PlayListTimeNode) model.GetValue(iter, 0);
+			PlayListPlay tNode = (PlayListPlay) model.GetValue(iter, 0);
 			(cell as Gtk.CellRendererText).Text = 	Catalog.GetString("Title")+": "+tNode.Name +"\n"+
 			                                       Catalog.GetString("Start")+": "+tNode.Start.ToMSecondsString()+Catalog.GetString(" sec")+"\n"+
 			                                       Catalog.GetString("Duration")+": "+tNode.Duration.ToMSecondsString()+Catalog.GetString(" sec")+"\n"+
diff --git a/LongoMatch/Gui/TreeView/PlayersTreeView.cs b/LongoMatch/Gui/TreeView/PlayersTreeView.cs
index 93a050c..0a36674 100644
--- a/LongoMatch/Gui/TreeView/PlayersTreeView.cs
+++ b/LongoMatch/Gui/TreeView/PlayersTreeView.cs
@@ -128,8 +128,8 @@ namespace LongoMatch.Gui.Component
 				
 				if (paths.Length == 1) {
 					TimeNode selectedTimeNode = GetValueFromPath(paths[0]) as TimeNode;
-					if (selectedTimeNode is MediaTimeNode) {
-						deleteKeyFrame.Sensitive = (selectedTimeNode as MediaTimeNode).KeyFrameDrawing != null;
+					if (selectedTimeNode is Play) {
+						deleteKeyFrame.Sensitive = (selectedTimeNode as Play).KeyFrameDrawing != null;
 						MultiSelectMenu(false);
 						menu.Popup();
 					} else {
diff --git a/LongoMatch/Gui/TreeView/PlaysTreeView.cs b/LongoMatch/Gui/TreeView/PlaysTreeView.cs
index 587ca13..c54f909 100644
--- a/LongoMatch/Gui/TreeView/PlaysTreeView.cs
+++ b/LongoMatch/Gui/TreeView/PlaysTreeView.cs
@@ -56,15 +56,15 @@ namespace LongoMatch.Gui.Component
 		}
 
 		private void SetCategoriesMenu(){
-			Action edit, sortMenu;			
+			Gtk.Action edit, sortMenu;			
 			UIManager manager;
 			ActionGroup g;
 			
 			manager= new UIManager();
 			g = new ActionGroup("CategoriesMenuGroup");
 			
-			edit = new Action("EditAction", Mono.Unix.Catalog.GetString("Edit name"), null, "gtk-edit");
-			sortMenu = new Action("SortMenuAction", Mono.Unix.Catalog.GetString("Sort Method"), null, null);
+			edit = new Gtk.Action("EditAction", Mono.Unix.Catalog.GetString("Edit name"), null, "gtk-edit");
+			sortMenu = new Gtk.Action("SortMenuAction", Mono.Unix.Catalog.GetString("Sort Method"), null, null);
 			sortByName = new Gtk.RadioAction("SortByNameAction", Mono.Unix.Catalog.GetString("Sort by name"), null, null, 1);
 			sortByStart = new Gtk.RadioAction("SortByStartAction", Mono.Unix.Catalog.GetString("Sort by start time"), null, null, 2);
 			sortByStop = new Gtk.RadioAction("SortByStopAction", Mono.Unix.Catalog.GetString("Sort by stop time"), null, null, 3);
@@ -128,7 +128,7 @@ namespace LongoMatch.Gui.Component
 			TimeNode tna, tnb;
 			TreeIter parent;
 			int depth;
-			SectionsTimeNode category;
+			Category category;
 			
 			if (model == null)
 				return 0;	
@@ -152,7 +152,7 @@ namespace LongoMatch.Gui.Component
 				return int.Parse(model.GetPath(a).ToString()) 
 					- int.Parse(model.GetPath(b).ToString());
 			
-			category = model.GetValue(parent,0) as SectionsTimeNode;
+			category = model.GetValue(parent,0) as Category;
 			tna = model.GetValue (a, 0)as TimeNode;
 			tnb = model.GetValue (b, 0) as TimeNode;
 			
@@ -171,11 +171,11 @@ namespace LongoMatch.Gui.Component
 		}
 		
 		private void OnSortActivated (object o, EventArgs args){
-			SectionsTimeNode category;
+			Category category;
 			RadioAction sender;
 			
 			sender = o as RadioAction;
-			category = GetValueFromPath(Selection.GetSelectedRows()[0]) as SectionsTimeNode;
+			category = GetValueFromPath(Selection.GetSelectedRows()[0]) as Category;
 			
 			if (sender == sortByName)
 				category.SortMethod = SortMethodType.SortByName;
@@ -193,9 +193,9 @@ namespace LongoMatch.Gui.Component
 			// Don't allow multiselect for categories
 			if (!selected && selection.GetSelectedRows().Length > 0){
 				if (selection.GetSelectedRows().Length == 1 &&
-				    GetValueFromPath(selection.GetSelectedRows()[0]) is SectionsTimeNode)
+				    GetValueFromPath(selection.GetSelectedRows()[0]) is Category)
 					return false;	
-				return !(GetValueFromPath(path) is SectionsTimeNode);										
+				return !(GetValueFromPath(path) is Category);										
 			}
 			// Always unselect
 			else
@@ -224,13 +224,13 @@ namespace LongoMatch.Gui.Component
 				
 				if (paths.Length == 1) {
 					TimeNode selectedTimeNode = GetValueFromPath(paths[0]) as TimeNode;
-					if (selectedTimeNode is MediaTimeNode) {
-						deleteKeyFrame.Sensitive = (selectedTimeNode as MediaTimeNode).KeyFrameDrawing != null;
+					if (selectedTimeNode is Play) {
+						deleteKeyFrame.Sensitive = (selectedTimeNode as Play).KeyFrameDrawing != null;
 						MultiSelectMenu(false);
 						menu.Popup();
 					}
 					else{
-						SetupSortMenu((selectedTimeNode as SectionsTimeNode).SortMethod);
+						SetupSortMenu((selectedTimeNode as Category).SortMethod);
 						categoriesMenu.Popup();
 					}
 				}
diff --git a/LongoMatch/Gui/TreeView/TagsTreeView.cs b/LongoMatch/Gui/TreeView/TagsTreeView.cs
index bbc67f7..8ae6195 100644
--- a/LongoMatch/Gui/TreeView/TagsTreeView.cs
+++ b/LongoMatch/Gui/TreeView/TagsTreeView.cs
@@ -52,7 +52,7 @@ namespace LongoMatch.Gui.Component
 				}
 				
 				if (paths.Length == 1) {
-					MediaTimeNode selectedTimeNode = GetValueFromPath(paths[0]) as MediaTimeNode;
+					Play selectedTimeNode = GetValueFromPath(paths[0]) as Play;
 					deleteKeyFrame.Sensitive = selectedTimeNode.KeyFrameDrawing != null;
 					MultiSelectMenu(false);
 					menu.Popup();
diff --git a/LongoMatch/Handlers/EventsManager.cs b/LongoMatch/Handlers/EventsManager.cs
index ec6b794..2cb1da8 100644
--- a/LongoMatch/Handlers/EventsManager.cs
+++ b/LongoMatch/Handlers/EventsManager.cs
@@ -306,7 +306,7 @@ namespace LongoMatch
 			}
 		}
 
-		protected virtual void OnTimeNodeDeleted(Play play, Category category)
+		protected virtual void OnTimeNodeDeleted(Play play)
 		{
 			/* FIXME: WIP*/
 			treewidget.RemovePlay(play);
@@ -332,7 +332,6 @@ namespace LongoMatch
 				Start = play.Start,
 				Stop = play.Stop,
 				Name = play.Name,
-				Duration = play.Stop - play.Start,
 				Rate = 1.0f,
 			});
 		}
@@ -444,7 +443,7 @@ namespace LongoMatch
 		}
 		
 		protected virtual void OnTagPlay(Play tNode){
-			TaggerDialog tagger = new TaggerDialog();
+			/*TaggerDialog tagger = new TaggerDialog();
 			tagger.ProjectTags = openedProject.Tags;
 			tagger.Tags = tNode.Tags;
 			tagger.TransientFor = (Gtk.Window)player.Toplevel;
@@ -454,7 +453,7 @@ namespace LongoMatch
 				openedProject.Tags.AddTag(tag);
 			}
 			tagsTreeWidget.UpdateTagsList();
-			tagger.Destroy();
+			tagger.Destroy();*/
 		}
 
 		protected virtual void OnPlayersTagged(Play tNode, Team team) {
@@ -463,7 +462,7 @@ namespace LongoMatch
 				dialog.SetPlayersInfo(openedProject.LocalTeamTemplate);
 				dialog.PlayersChecked = tNode.LocalPlayers;
 				if (dialog.Run() == (int) ResponseType.Ok) {
-					tNode.LocalPlayers = dialog.PlayersChecked;
+					//tNode.LocalPlayers = dialog.PlayersChecked;
 					localPlayersList.UpdatePlaysList(openedProject.GetLocalTeamModel());
 				}
 			}
@@ -472,7 +471,7 @@ namespace LongoMatch
 				dialog.SetPlayersInfo(openedProject.VisitorTeamTemplate);
 				dialog.PlayersChecked = tNode.VisitorPlayers;
 				if (dialog.Run() == (int) ResponseType.Ok) {
-					tNode.VisitorPlayers = dialog.PlayersChecked;
+					//tNode.VisitorPlayers = dialog.PlayersChecked;
 					visitorPlayersList.UpdatePlaysList(openedProject.GetVisitorTeamModel());
 				}
 			}
diff --git a/LongoMatch/Handlers/Handlers.cs b/LongoMatch/Handlers/Handlers.cs
index 6f179e4..822eebe 100644
--- a/LongoMatch/Handlers/Handlers.cs
+++ b/LongoMatch/Handlers/Handlers.cs
@@ -44,7 +44,7 @@ namespace LongoMatch.Handlers
 	//A play was edited
 	public delegate void TimeNodeChangedHandler(TimeNode tNode, object val);
 	//A play was deleted
-	public delegate void TimeNodeDeletedHandler(Play play, Category category);
+	public delegate void TimeNodeDeletedHandler(Play play);
 	//Players needs to be tagged
 	public delegate void PlayersTaggedHandler(Play play, Team team);
 	//Tag a play
diff --git a/LongoMatch/Handlers/HotKeysManager.cs b/LongoMatch/Handlers/HotKeysManager.cs
index a9912f6..0977532 100644
--- a/LongoMatch/Handlers/HotKeysManager.cs
+++ b/LongoMatch/Handlers/HotKeysManager.cs
@@ -45,7 +45,7 @@ namespace LongoMatch.Handlers
 				dic.Clear();
 				if (value == null)
 					return;
-				foreach (Category cat in value) {
+				foreach (Category cat in value.CategoriesList) {
 					if (cat.HotKey.Defined &&
 					                !dic.ContainsKey(cat.HotKey))
 						dic.Add(cat.HotKey, cat);
@@ -61,7 +61,7 @@ namespace LongoMatch.Handlers
 			
 			hotkey.Key=args.Event.Key;
 			hotkey.Modifier=args.Event.State & (ModifierType.Mod1Mask | ModifierType.Mod5Mask | ModifierType.ShiftMask);
-			if (dic.TryGetValue(hotkey, cat)) {
+			if (dic.TryGetValue(hotkey, out cat)) {
 				if (newMarkEvent != null) {
 					newMarkEvent(cat);
 				}
diff --git a/LongoMatch/IO/SectionsReader.cs b/LongoMatch/IO/SectionsReader.cs
index 9ab11ed..60e01a3 100644
--- a/LongoMatch/IO/SectionsReader.cs
+++ b/LongoMatch/IO/SectionsReader.cs
@@ -79,26 +79,26 @@ namespace LongoMatch.IO
 		#endregion
 
 		#region Public methods
-		public Categories GetSections() {
-			Sections sections = new Sections();
+		public Categories GetCategories() {
+			Categories categories = new Categories();
 			bool tryNext = true;
 			string name;
-			Category tn;
+			Category cat;
 			for (int i=1;tryNext;i++) {
 				name = GetName(i);
 				if (name != null) {
-					tn = new Category{
+					cat = new Category{
 					                  Name = name,
 					                  Start = GetStartTime(i),
 					                  Stop = GetStopTime(i),
 					                  HotKey = GetHotKey(i), 
-					                  Color  = ColorGetColor(i)};
-					tn.SortMethodString = GetSortMethod(i);
-					sections.AddSection(tn);
+					                  Color  = GetColor(i)};
+					cat.SortMethodString = GetSortMethod(i);
+					categories.AddCategory(cat);
 				}
 				else tryNext=false;
 			}
-			return sections;
+			return categories;
 		}
 		#endregion
 
diff --git a/LongoMatch/IO/SectionsWriter.cs b/LongoMatch/IO/SectionsWriter.cs
index df2dc9f..96a816e 100644
--- a/LongoMatch/IO/SectionsWriter.cs
+++ b/LongoMatch/IO/SectionsWriter.cs
@@ -31,7 +31,7 @@ namespace LongoMatch.IO
 {
 
 
-	public class SectionsWriter
+	public class CategoriesWriter
 	{
 
 
diff --git a/LongoMatch/Main.cs b/LongoMatch/Main.cs
index 20aa18d..19ba188 100644
--- a/LongoMatch/Main.cs
+++ b/LongoMatch/Main.cs
@@ -141,7 +141,7 @@ namespace LongoMatch
 			string fConfig;
 			fConfig = System.IO.Path.Combine(TemplatesDir(),"default.sct");
 			if (!System.IO.File.Exists(fConfig)) {
-				SectionsWriter.CreateNewTemplate("default.sct");
+				CategoriesWriter.CreateNewTemplate("default.sct");
 			}
 
 			fConfig = System.IO.Path.Combine(TemplatesDir(),"default.tem");
diff --git a/LongoMatch/Time/Tag.cs b/LongoMatch/Time/Tag.cs
index 2ce2776..a230107 100644
--- a/LongoMatch/Time/Tag.cs
+++ b/LongoMatch/Time/Tag.cs
@@ -54,7 +54,7 @@ namespace LongoMatch.TimeNodes
 
 		public override int GetHashCode()
 		{
-			return TagCategory.GetHashCode() &&  Text.GetHashCode();
+			return TagCategory.GetHashCode() + Value.GetHashCode();
 		}
 	}
 }
diff --git a/LongoMatch/Utils/ProjectUtils.cs b/LongoMatch/Utils/ProjectUtils.cs
index 0951148..6c45a74 100644
--- a/LongoMatch/Utils/ProjectUtils.cs
+++ b/LongoMatch/Utils/ProjectUtils.cs
@@ -107,12 +107,12 @@ namespace LongoMatch.Utils
 				return;
 			}
 			
-			isFake = (project.File.FilePath == Constants.FAKE_PROJECT);
+			isFake = (project.Description.File.FilePath == Constants.FAKE_PROJECT);
 			
 			/* If it's a fake live project prompt for a video file and
 			 * create a new PreviewMediaFile for this project */
 			if (isFake){				
-				project.File = null;
+				project.Description.File = null;
 				npd = new NewProjectDialog();						
 				npd.TransientFor = window;
 				npd.Use = ProjectType.EditProject;
@@ -140,8 +140,9 @@ namespace LongoMatch.Utils
 				                                     DialogFlags.Modal,
 				                                     MessageType.Question,
 				                                     Gtk.ButtonsType.YesNo,
-				                                     Catalog.GetString("A project already exists for the file:")+project.File.FilePath+
-				                                     "\n"+Catalog.GetString("Do you want to overwrite it?"));
+				                                     Catalog.GetString("A project already exists for the file:")+
+				                                     project.Description.File.FilePath+ "\n" +
+				                                     Catalog.GetString("Do you want to overwrite it?"));
 				md.Icon=Stetic.IconLoader.LoadIcon(window, "longomatch", Gtk.IconSize.Dialog);
 				res = md.Run();
 				md.Destroy();
@@ -277,9 +278,9 @@ namespace LongoMatch.Utils
 			/* Create all the thumbnails */
 			factory = new MultimediaFactory();
 			capturer = factory.getFramesCapturer();
-			capturer.Open (project.File.FilePath);
-			foreach (List<MediaTimeNode> list in project.GetDataArray()){
-				foreach (MediaTimeNode play in list){
+			capturer.Open (project.Description.File.FilePath);
+			foreach (List<Play> list in project.PlaysGroupedByCategory){
+				foreach (Play play in list){
 					try{
 						capturer.SeekTime(play.Start.MSeconds + ((play.Stop - play.Start).MSeconds/2),
 						                  true);
diff --git a/LongoMatch/gtk-gui/gui.stetic b/LongoMatch/gtk-gui/gui.stetic
index b44dbe4..587c0e4 100644
--- a/LongoMatch/gtk-gui/gui.stetic
+++ b/LongoMatch/gtk-gui/gui.stetic
@@ -1106,7 +1106,7 @@
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.ProjectsManager" design-size="804 597">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.ProjectsManager" design-size="1006 597">
     <property name="MemberName" />
     <property name="Title" translatable="yes">Projects Manager</property>
     <property name="Icon">stock:longomatch Dialog</property>
@@ -2225,7 +2225,7 @@
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.CategoryProperties" design-size="284 120">
+  <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.CategoryProperties" design-size="479 120">
     <property name="MemberName" />
     <child>
       <widget class="Gtk.VBox" id="vbox3">
@@ -2271,12 +2271,11 @@
           <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="AutoSize">True</property>
+            <property name="Expand">False</property>
             <property name="Fill">False</property>
           </packing>
         </child>
@@ -2404,7 +2403,7 @@ Sort by duration</property>
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.ProjectTemplateEditorDialog" design-size="516 243">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.ProjectTemplateEditorDialog" design-size="518 243">
     <property name="MemberName" />
     <property name="Title" translatable="yes">Categories Template</property>
     <property name="Icon">stock:longomatch Dialog</property>
@@ -4567,6 +4566,7 @@ No</property>
                 <property name="MemberName" />
                 <property name="CanFocus">True</property>
                 <property name="Label" translatable="yes" />
+                <property name="Active">True</property>
                 <property name="DrawIndicator">False</property>
                 <property name="HasLabel">False</property>
                 <property name="UseUnderline">True</property>
@@ -4893,7 +4893,7 @@ Show-&gt;&lt;b&gt; S&lt;/b&gt;
       </widget>
     </child>
   </widget>
-  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.EditCategoryDialog" design-size="266 191">
+  <widget class="Gtk.Dialog" id="LongoMatch.Gui.Dialog.EditCategoryDialog" design-size="492 191">
     <property name="MemberName" />
     <property name="Title" translatable="yes">Category Details</property>
     <property name="Icon">resource:longomatch.png</property>
diff --git a/LongoMatch/gtk-gui/objects.xml b/LongoMatch/gtk-gui/objects.xml
index 45894a6..971dc6a 100644
--- a/LongoMatch/gtk-gui/objects.xml
+++ b/LongoMatch/gtk-gui/objects.xml
@@ -15,6 +15,27 @@
       </itemgroup>
     </signals>
   </object>
+<<<<<<< HEAD
+=======
+  <object type="LongoMatch.Gui.Component.PlayersTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+    <itemgroups>
+      <itemgroup label="ListTreeViewBase Properties">
+        <property name="Colors" />
+      </itemgroup>
+    </itemgroups>
+    <signals>
+      <itemgroup label="PlayersTreeView Signals">
+        <signal name="TimeNodeSelected" />
+        <signal name="TimeNodeChanged" />
+        <signal name="SnapshotSeriesEvent" />
+        <signal name="PlayListNodeAdded" />
+        <signal name="TimeNodeDeleted" />
+        <signal name="PlayersTagged" />
+        <signal name="TagPlay" />
+      </itemgroup>
+    </signals>
+  </object>
+>>>>>>> f15643a... WIP: Everything compiles
   <object type="LongoMatch.Gui.Component.PlayerPropertiesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
     <itemgroups />
     <signals>
@@ -32,6 +53,27 @@
       </itemgroup>
     </signals>
   </object>
+<<<<<<< HEAD
+=======
+  <object type="LongoMatch.Gui.Component.PlaysTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+    <itemgroups>
+      <itemgroup label="ListTreeViewBase Properties">
+        <property name="Colors" />
+      </itemgroup>
+    </itemgroups>
+    <signals>
+      <itemgroup label="PlaysTreeView Signals">
+        <signal name="TimeNodeChanged" />
+        <signal name="TimeNodeSelected" />
+        <signal name="TimeNodeDeleted" />
+        <signal name="PlayListNodeAdded" />
+        <signal name="SnapshotSeriesEvent" />
+        <signal name="PlayersTagged" />
+        <signal name="TagPlay" />
+      </itemgroup>
+    </signals>
+  </object>
+>>>>>>> f15643a... WIP: Everything compiles
   <object type="LongoMatch.Gui.Component.CategoriesTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
     <itemgroups />
     <signals>
@@ -98,8 +140,17 @@
       </itemgroup>
     </signals>
   </object>
+<<<<<<< HEAD
   <object type="LongoMatch.Gui.Component.ButtonsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups />
+=======
+  <object type="LongoMatch.Gui.Component.TagsTreeView" palette-category="LongoMatch" allow-children="false" base-type="Gtk.TreeView">
+    <itemgroups>
+      <itemgroup label="ListTreeViewBase Properties">
+        <property name="Colors" />
+      </itemgroup>
+    </itemgroups>
+>>>>>>> f15643a... WIP: Everything compiles
     <signals>
       <itemgroup label="ButtonsWidget Signals">
         <signal name="NewMarkEvent" />
@@ -112,6 +163,77 @@
     <itemgroups />
     <signals />
   </object>
+<<<<<<< HEAD
+=======
+  <object type="LongoMatch.Gui.Component.ProjectListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="ProjectListWidget Signals">
+        <signal name="ProjectsSelected" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.CategoryProperties" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="CategoryProperties Signals">
+        <signal name="HotKeyChanged" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.DrawingToolBox" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="DrawingToolBox Signals">
+        <signal name="LineWidthChanged" />
+        <signal name="DrawToolChanged" />
+        <signal name="ColorChanged" />
+        <signal name="VisibilityChanged" />
+        <signal name="ClearDrawing" />
+        <signal name="TransparencyChanged" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.TaggerWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals />
+  </object>
+  <object type="LongoMatch.Gui.Component.DrawingWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals />
+  </object>
+  <object type="LongoMatch.Gui.Component.ButtonsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="ButtonsWidget Signals">
+        <signal name="NewMarkEvent" />
+        <signal name="NewMarkStartEvent" />
+        <signal name="NewMarkStopEvent" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.PlayListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="PlayListWidget Signals">
+        <signal name="PlayListNodeSelected" />
+        <signal name="ApplyCurrentRate" />
+        <signal name="Progress" />
+      </itemgroup>
+    </signals>
+  </object>
+  <object type="LongoMatch.Gui.Component.PlayersListTreeWidget" palette-category="General" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups />
+    <signals>
+      <itemgroup label="PlayersListTreeWidget Signals">
+        <signal name="TimeNodeSelected" />
+        <signal name="TimeNodeChanged" />
+        <signal name="PlayListNodeAdded" />
+        <signal name="SnapshotSeriesEvent" />
+      </itemgroup>
+    </signals>
+  </object>
+>>>>>>> f15643a... WIP: Everything compiles
   <object type="LongoMatch.Gui.Component.ProjectDetailsWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups>
       <itemgroup label="ProjectDetailsWidget Properties">
@@ -131,6 +253,7 @@
       </itemgroup>
     </signals>
   </object>
+<<<<<<< HEAD
   <object type="LongoMatch.Gui.Component.ProjectListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups />
     <signals>
@@ -140,6 +263,9 @@
     </signals>
   </object>
   <object type="LongoMatch.Gui.Component.CategoryProperties" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+=======
+  <object type="LongoMatch.Gui.Popup.TransparentDrawingArea" palette-category="General" allow-children="false" base-type="Gtk.Window">
+>>>>>>> f15643a... WIP: Everything compiles
     <itemgroups />
     <signals>
       <itemgroup label="CategoryProperties Signals">
@@ -147,6 +273,7 @@
       </itemgroup>
     </signals>
   </object>
+<<<<<<< HEAD
   <object type="LongoMatch.Gui.Component.DrawingToolBox" palette-category="General" allow-children="false" base-type="Gtk.Bin">
     <itemgroups />
     <signals>
@@ -160,6 +287,8 @@
       </itemgroup>
     </signals>
   </object>
+=======
+>>>>>>> f15643a... WIP: Everything compiles
   <object type="LongoMatch.Gui.Component.ProjectTemplateWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups>
       <itemgroup label="ProjectTemplateWidget Properties">
@@ -168,6 +297,7 @@
     </itemgroups>
     <signals />
   </object>
+<<<<<<< HEAD
   <object type="LongoMatch.Gui.Component.PlayListWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
     <itemgroups />
     <signals>
@@ -186,6 +316,20 @@
         <signal name="TimeNodeChanged" />
         <signal name="PlayListNodeAdded" />
         <signal name="SnapshotSeriesEvent" />
+=======
+  <object type="LongoMatch.Gui.Component.TimeLineWidget" palette-category="LongoMatch" allow-children="false" base-type="Gtk.Bin">
+    <itemgroups>
+      <itemgroup label="TimeLineWidget Properties">
+        <property name="CurrentFrame" />
+      </itemgroup>
+    </itemgroups>
+    <signals>
+      <itemgroup label="TimeLineWidget Signals">
+        <signal name="TimeNodeChanged" />
+        <signal name="TimeNodeSelected" />
+        <signal name="TimeNodeDeleted" />
+        <signal name="NewMarkEvent" />
+>>>>>>> f15643a... WIP: Everything compiles
       </itemgroup>
     </signals>
   </object>



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