[longomatch] Redesign subcategories
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Redesign subcategories
- Date: Wed, 9 Jul 2014 09:56:04 +0000 (UTC)
commit 796a10e034ccd36a41054cff0c9c50f0fd624883
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Tue Jul 8 18:24:46 2014 +0200
Redesign subcategories
Categories have now a single list of tags for subcategories
and common tags that can be used generic to all tagging categories
LongoMatch.Core/Common/Color.cs | 1 +
LongoMatch.Core/Common/Constants.cs | 1 +
LongoMatch.Core/Common/PlaysFilter.cs | 49 +-
LongoMatch.Core/Handlers/Handlers.cs | 4 -
LongoMatch.Core/LongoMatch.Core.mdp | 6 +-
LongoMatch.Core/Makefile.am | 2 -
LongoMatch.Core/Stats/ProjectStats.cs | 18 -
LongoMatch.Core/Stats/SubCategoryStat.cs | 12 +-
LongoMatch.Core/Store/Category.cs | 4 +-
LongoMatch.Core/Store/Play.cs | 7 -
LongoMatch.Core/Store/Project.cs | 10 -
LongoMatch.Core/Store/SubCategory.cs | 97 --
LongoMatch.Core/Store/Tag.cs | 12 +-
LongoMatch.Core/Store/TagStore.cs | 84 --
.../Store/Templates/CategoriesTemplate.cs | 37 +-
LongoMatch.GUI/Gui/Component/CategoryProperties.cs | 58 --
.../Gui/TreeView/CategoriesFilterTreeView.cs | 14 -
.../Gui/TreeView/SubCategoriesTreeView.cs | 133 ---
LongoMatch.GUI/LongoMatch.GUI.mdp | 1 -
LongoMatch.GUI/Makefile.am | 1 -
.../LongoMatch.Gui.Component.CategoryProperties.cs | 148 +---
.../LongoMatch.Gui.Component.CodingWidget.cs | 28 +-
.../LongoMatch.Gui.Component.Stats.Plotter.cs | 1 -
.../gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs | 1 +
...LongoMatch.Gui.Dialog.VideoEditionProperties.cs | 1 -
.../LongoMatch.Gui.Panel.NewProjectPanel.cs | 1 +
.../LongoMatch.Gui.Panel.ProjectsManagerPanel.cs | 1 +
.../gtk-gui/LongoMatch.Gui.Panel.WelcomePanel.cs | 1 +
LongoMatch.GUI/gtk-gui/gui.stetic | 1024 ++++++++------------
LongoMatch.GUI/gtk-gui/objects.xml | 21 +-
LongoMatch.Plugins/CSVExporter.cs | 19 +-
Tests/Core/TestCategory.cs | 20 +-
Tests/Core/TestPlay.cs | 3 +-
Tests/Core/TestTagStore.cs | 121 ---
Tests/Tests.mdp | 2 -
35 files changed, 509 insertions(+), 1434 deletions(-)
---
diff --git a/LongoMatch.Core/Common/Color.cs b/LongoMatch.Core/Common/Color.cs
index 915b079..f462fd7 100644
--- a/LongoMatch.Core/Common/Color.cs
+++ b/LongoMatch.Core/Common/Color.cs
@@ -93,6 +93,7 @@ namespace LongoMatch.Common
static public Color Green1 = new Color (99,192,56);
static public Color Red1 = new Color (255, 51, 0);
static public Color Blue1 = new Color (0, 153, 255);
+ static public Color Yellow = new Color (255, 255, 0);
}
}
diff --git a/LongoMatch.Core/Common/Constants.cs b/LongoMatch.Core/Common/Constants.cs
index fbcdeff..cce702c 100644
--- a/LongoMatch.Core/Common/Constants.cs
+++ b/LongoMatch.Core/Common/Constants.cs
@@ -106,6 +106,7 @@ Xavier Queralt Mateu (ca)";
public const string LINE_DOUBLE_ARROW = "line-double-arrow.svg";
public const string LINE_DOT = "line-dot.svg";
public const string LINE_DOUBLE_DOT = "line-double-dot.svg";
+ public const string COMMON_TAG = "LGM_COMMON";
public const int DB_MAYOR_VERSION = 3;
public const int DB_MINOR_VERSION = 1;
diff --git a/LongoMatch.Core/Common/PlaysFilter.cs b/LongoMatch.Core/Common/PlaysFilter.cs
index 8c6a243..a58d84f 100644
--- a/LongoMatch.Core/Common/PlaysFilter.cs
+++ b/LongoMatch.Core/Common/PlaysFilter.cs
@@ -32,7 +32,7 @@ namespace LongoMatch.Common
public event FilterUpdatedHandler FilterUpdated;
bool playersFiltered, categoriesFiltered;
- Dictionary<Category, List<SubCategoryTags>> categoriesFilter;
+ Dictionary<Category, List<Tag>> categoriesFilter;
List<Player> playersFilter;
Project project;
List<Category> visibleCategories;
@@ -42,7 +42,7 @@ namespace LongoMatch.Common
public PlaysFilter (Project project)
{
this.project = project;
- categoriesFilter = new Dictionary<Category, List<SubCategoryTags>>();
+ categoriesFilter = new Dictionary<Category, List<Tag>>();
playersFilter = new List<Player>();
ClearAll();
UpdateFilters();
@@ -76,14 +76,6 @@ namespace LongoMatch.Common
public void ClearCategoriesFilter () {
categoriesFilter.Clear();
foreach (Category cat in project.Categories.List) {
- List<SubCategoryTags> list = new List<SubCategoryTags>();
- categoriesFilter.Add(cat, list);
- foreach (SubCategory subcat in cat.SubCategories) {
- SubCategoryTags subcatTags = new SubCategoryTags{SubCategory =
subcat};
- list.Add(subcatTags);
- foreach (string option in subcat.Options)
- subcatTags.Add (option);
- }
}
}
@@ -109,15 +101,6 @@ namespace LongoMatch.Common
playersFilter.Add(player);
}
- public void FilterSubCategory (Category cat, SubCategory subcat, string option, bool
filtered) {
- SubCategoryTags tsub = categoriesFilter[cat].Find(s => s.SubCategory == subcat);
- if (filtered) {
- tsub.Add(option);
- } else {
- tsub.Remove(option);
- }
- }
-
public List<Category> VisibleCategories {
get {
return visibleCategories;
@@ -163,8 +146,6 @@ namespace LongoMatch.Common
visible = true;
} else {
foreach (var subcat in categoriesFilter[c]) {
- if (subcat.Count != 0)
- visible = true;
}
}
if (visible)
@@ -179,25 +160,6 @@ namespace LongoMatch.Common
foreach (Play play in project.Timeline) {
if (CategoriesFilterEnabled) {
cat_match = false;
- foreach (var subcat in categoriesFilter[play.Category]) {
- bool match = false;
- foreach (var option in subcat) {
- Tag tag = new Tag{SubCategory=subcat.SubCategory,
Value=option};
- if (play.Tags.Contains(tag)) {
- match = true;
- break;
- }
- }
- /* A single match in a subcategory is not enough as we want
to filter
- * all plays that have Period=1 and Type=Stroke. So if there
is a match
- * for Period we want a match for Type too */
- if (!match && subcat.Count != 0) {
- cat_match = false;
- break;
- }
- if (match)
- cat_match = true;
- }
}
if (PlayersFilterEnabled)
@@ -214,12 +176,5 @@ namespace LongoMatch.Common
FilterUpdated ();
}
}
-
- class SubCategoryTags: List<string> {
- public SubCategory SubCategory {
- get;
- set;
- }
- }
}
diff --git a/LongoMatch.Core/Handlers/Handlers.cs b/LongoMatch.Core/Handlers/Handlers.cs
index 0c1432f..f94b4e2 100644
--- a/LongoMatch.Core/Handlers/Handlers.cs
+++ b/LongoMatch.Core/Handlers/Handlers.cs
@@ -113,10 +113,6 @@ namespace LongoMatch.Handlers
public delegate void CategoryHandler(Category category);
public delegate void CategoriesHandler(List<Category> categoriesList);
- /* Edit Subcategory properties */
- public delegate void SubCategoryHandler(SubCategory subcat);
- public delegate void SubCategoriesHandler(List<SubCategory> subcat);
-
/* Edit player properties */
public delegate void PlayerPropertiesHandler(Player player);
public delegate void PlayersPropertiesHandler(List<Player> players);
diff --git a/LongoMatch.Core/LongoMatch.Core.mdp b/LongoMatch.Core/LongoMatch.Core.mdp
index 6ae13ee..a31d448 100644
--- a/LongoMatch.Core/LongoMatch.Core.mdp
+++ b/LongoMatch.Core/LongoMatch.Core.mdp
@@ -27,9 +27,6 @@
<File subtype="Code" buildaction="Compile" name="Store/PlayListPlay.cs" />
<File subtype="Code" buildaction="Compile" name="Store/Project.cs" />
<File subtype="Code" buildaction="Compile" name="Store/ProjectDescription.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/SubCategory.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/Tag.cs" />
- <File subtype="Code" buildaction="Compile" name="Store/TagStore.cs" />
<File subtype="Code" buildaction="Compile" name="Store/Time.cs" />
<File subtype="Code" buildaction="Compile" name="Store/TimeNode.cs" />
<File subtype="Code" buildaction="Compile" name="Store/Templates/CategoriesTemplate.cs" />
@@ -87,7 +84,6 @@
<File subtype="Code" buildaction="Compile" name="Stats/CategoryStats.cs" />
<File subtype="Code" buildaction="Compile" name="Stats/PercentualStat.cs" />
<File subtype="Code" buildaction="Compile" name="Stats/Stat.cs" />
- <File subtype="Code" buildaction="Compile" name="Stats/SubCategoryStat.cs" />
<File subtype="Code" buildaction="Compile" name="Stats/PlayersStats.cs" />
<File subtype="Code" buildaction="Compile" name="Common/PlaysFilter.cs" />
<File subtype="Code" buildaction="Compile" name="Interfaces/Multimedia/IRemuxer.cs" />
@@ -142,6 +138,8 @@
<File subtype="Code" buildaction="Compile" name="Store/ScoreEvent.cs" />
<File subtype="Code" buildaction="Compile" name="Store/PenaltyCard.cs" />
<File subtype="Code" buildaction="Compile" name="Store/PenaltyCardEvent.cs" />
+ <File subtype="Code" buildaction="Compile" name="Store/Tag.cs" />
+ <File subtype="Code" buildaction="Compile" name="Stats/SubCategoryStat.cs" />
</Contents>
<References>
<ProjectReference type="Package" localcopy="True" refto="System, Version=4.0.0.0, Culture=neutral,
PublicKeyToken=b77a5c561934e089" />
diff --git a/LongoMatch.Core/Makefile.am b/LongoMatch.Core/Makefile.am
index f96f895..d55fdf4 100644
--- a/LongoMatch.Core/Makefile.am
+++ b/LongoMatch.Core/Makefile.am
@@ -93,9 +93,7 @@ SOURCES = Common/Area.cs \
Store/ProjectDescription.cs \
Store/Score.cs \
Store/ScoreEvent.cs \
- Store/SubCategory.cs \
Store/Tag.cs \
- Store/TagStore.cs \
Store/Templates/CategoriesTemplate.cs \
Store/Templates/TeamTemplate.cs \
Store/Time.cs \
diff --git a/LongoMatch.Core/Stats/ProjectStats.cs b/LongoMatch.Core/Stats/ProjectStats.cs
index 4cc7655..488f3bb 100644
--- a/LongoMatch.Core/Stats/ProjectStats.cs
+++ b/LongoMatch.Core/Stats/ProjectStats.cs
@@ -163,24 +163,6 @@ namespace LongoMatch.Stats
stats.AwayHalfFieldCoordinates = awayPlays.Select (p =>
p.HalfFieldPosition).Where(p =>p != null).ToList();
stats.AwayGoalCoordinates = awayPlays.Select (p => p.GoalPosition).Where(p
=>p != null).ToList();
catStats.Add (stats);
-
- foreach (SubCategory subcat in cat.SubCategories) {
- SubCategoryStat subcatStat;
-
- subcatStat = new SubCategoryStat(subcat);
- stats.AddSubcatStat(subcatStat);
-
- foreach (string option in subcat.Options) {
- List<Play> subcatPlays;
- Tag tag;
-
- tag = new Tag{SubCategory=subcat, Value=option};
- subcatPlays = plays.Where(p =>
p.TagsStore.Tags.Contains(tag)).ToList();
- GetSubcategoryStats(subcatPlays, subcatStat, option,
- stats.TotalCount, out localTeamCount, out
visitorTeamCount);
- GetPlayersStats(project, subcatPlays, option, subcatStat,
cat);
- }
- }
}
}
diff --git a/LongoMatch.Core/Stats/SubCategoryStat.cs b/LongoMatch.Core/Stats/SubCategoryStat.cs
index fce5530..642f615 100644
--- a/LongoMatch.Core/Stats/SubCategoryStat.cs
+++ b/LongoMatch.Core/Stats/SubCategoryStat.cs
@@ -30,12 +30,12 @@ namespace LongoMatch.Stats
List<PercentualStat> optionStats;
Dictionary<string, List<PlayersStats>> localPlayersStats;
Dictionary<string, List<PlayersStats>> visitorPlayersStats;
- SubCategory subcat;
+ Tag tag;
- public SubCategoryStat (SubCategory subcat)
+ public SubCategoryStat (Tag tag)
{
- Name = subcat.Name;
- this.subcat = subcat;
+ Name = tag.Group;
+ this.tag = tag;
optionStats = new List<PercentualStat>();
localPlayersStats = new Dictionary<string, List<PlayersStats>>();
visitorPlayersStats = new Dictionary<string, List<PlayersStats>>();
@@ -53,9 +53,9 @@ namespace LongoMatch.Stats
}
}
- public SubCategory SubCategory {
+ public Tag Tag {
get {
- return subcat;
+ return tag;
}
}
diff --git a/LongoMatch.Core/Store/Category.cs b/LongoMatch.Core/Store/Category.cs
index 005ac58..4e4cbf4 100644
--- a/LongoMatch.Core/Store/Category.cs
+++ b/LongoMatch.Core/Store/Category.cs
@@ -42,7 +42,7 @@ namespace LongoMatch.Store
#region Constructors
public Category() {
ID = System.Guid.NewGuid();
- SubCategories = new List<SubCategory>();
+ Tags = new List<Tag>();
TagGoalPosition = false;
TagFieldPosition = true;
}
@@ -90,7 +90,7 @@ namespace LongoMatch.Store
set;
}
- public List<SubCategory> SubCategories {
+ public List<Tag> Tags {
get;
set;
}
diff --git a/LongoMatch.Core/Store/Play.cs b/LongoMatch.Core/Store/Play.cs
index 6ec4769..4b62e4d 100644
--- a/LongoMatch.Core/Store/Play.cs
+++ b/LongoMatch.Core/Store/Play.cs
@@ -127,13 +127,6 @@ namespace LongoMatch.Store
set;
}
- [JsonIgnore]
- public TagsStore TagsStore {
- get {
- return new TagsStore {Tags=Tags};
- }
- }
-
public Coordinates FieldPosition {
get;
set;
diff --git a/LongoMatch.Core/Store/Project.cs b/LongoMatch.Core/Store/Project.cs
index 4320b93..ad7f6b9 100644
--- a/LongoMatch.Core/Store/Project.cs
+++ b/LongoMatch.Core/Store/Project.cs
@@ -234,16 +234,6 @@ namespace LongoMatch.Store
}
}
- public void DeleteSubcategoryTags(Category cat, List<SubCategory> subcategories) {
- foreach (var play in Timeline.Where(p => p.Category == cat)) {
- foreach (var subcat in subcategories) {
- Log.Error(play.Name);
- if (subcat is SubCategory)
- play.TagsStore.RemoveBySubcategory(subcat);
- }
- }
- }
-
public List<Play> PlaysInCategory(Category category) {
return Timeline.Where(p => p.Category.ID == category.ID).ToList();
}
diff --git a/LongoMatch.Core/Store/Tag.cs b/LongoMatch.Core/Store/Tag.cs
index ec8b720..2b0cf3f 100644
--- a/LongoMatch.Core/Store/Tag.cs
+++ b/LongoMatch.Core/Store/Tag.cs
@@ -29,10 +29,12 @@ namespace LongoMatch.Store
[Serializable]
public class Tag
{
- public Tag() {
+ public Tag (string value, string grp="") {
+ Group = grp;
+ Value = value;
}
- public SubCategory SubCategory {
+ public string Group {
set;
get;
}
@@ -47,13 +49,13 @@ namespace LongoMatch.Store
Tag tag = obj as Tag;
if (tag == null)
return false;
- return Value.Equals (tag.Value) && SubCategory.Equals(tag.SubCategory);
+ return Value == tag.Value && Group == tag.Group;
}
public override int GetHashCode ()
{
- if (Value != null) {
- return Value.GetHashCode ();
+ if (Value != null && Group != null) {
+ return (Value + Group).GetHashCode ();
} else {
return base.GetHashCode ();
}
diff --git a/LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
b/LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
index dca7bf5..db4ac57 100644
--- a/LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
+++ b/LongoMatch.Core/Store/Templates/CategoriesTemplate.cs
@@ -54,6 +54,7 @@ namespace LongoMatch.Store.Templates
List = new List<Category>();
Scores = new List<Score> ();
PenaltyCards = new List<PenaltyCard> ();
+ CommonTags = new List<Tag>();
}
public Guid ID {
@@ -65,6 +66,11 @@ namespace LongoMatch.Store.Templates
get;
set;
}
+
+ public List<Tag> CommonTags {
+ get;
+ set;
+ }
public string Name {
get;
@@ -110,16 +116,9 @@ namespace LongoMatch.Store.Templates
Serializer.Save(this, filePath);
}
- public void AddDefaultSubcategories (Category cat) {
- SubCategory resultsubcat;
-
- resultsubcat = new SubCategory {
- Name = Catalog.GetString ("Outcome"),
- AllowMultiple = false,
- };
- resultsubcat.Options.Add (Catalog.GetString ("Success"));
- resultsubcat.Options.Add (Catalog.GetString ("Failure"));
- cat.SubCategories.Add(resultsubcat);
+ public void AddDefaultTags (Category cat) {
+ cat.Tags.Add (new Tag (Catalog.GetString ("Good")));
+ cat.Tags.Add (new Tag (Catalog.GetString ("Bad")));
}
public Category AddDefaultItem (int index) {
@@ -135,7 +134,7 @@ namespace LongoMatch.Store.Templates
HotKey = h,
Position = index-1,
};
- AddDefaultSubcategories(cat);
+ AddDefaultTags(cat);
List.Insert(index, cat);
return cat;
}
@@ -152,13 +151,21 @@ namespace LongoMatch.Store.Templates
public static Categories DefaultTemplate(int count) {
List<string> periods = new List<string>();
- Categories defaultTemplate = new Categories();
+ Categories template = new Categories();
- defaultTemplate.FillDefaultTemplate(count);
+ template.FillDefaultTemplate(count);
periods.Add ("1");
periods.Add ("2");
- defaultTemplate.GamePeriods = periods;
- return defaultTemplate;
+ template.GamePeriods = periods;
+ template.CommonTags.Add (new Tag (Catalog.GetString ("Attack"),
+ Constants.COMMON_TAG));
+ template.CommonTags.Add (new Tag (Catalog.GetString ("Defense"),
+ Constants.COMMON_TAG));
+ template.PenaltyCards.Add (new PenaltyCard (Catalog.GetString ("Red"),
+ Color.Red, CardShape.Rectangle));
+ template.PenaltyCards.Add (new PenaltyCard (Catalog.GetString ("Yellow"),
+ Color.Yellow, CardShape.Rectangle));
+ return template;
}
private void FillDefaultTemplate(int count) {
diff --git a/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
b/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
index 6699eae..4105601 100644
--- a/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
+++ b/LongoMatch.GUI/Gui/Component/CategoryProperties.cs
@@ -54,9 +54,6 @@ namespace LongoMatch.Gui.Component
public CategoryProperties()
{
this.Build();
- vbox2.Sensitive = false;
- subcategoriestreeview1.SubCategoriesDeleted += OnSubcategoriesDeleted;
- subcategoriestreeview1.SubCategorySelected += OnSubcategorySelected;
leadtimebutton.ValueChanged += OnLeadTimeChanged;;
lagtimebutton.ValueChanged += OnLagTimeChanged;
fieldcoordinatestagger = new CoordinatesTagger ();
@@ -77,7 +74,6 @@ namespace LongoMatch.Gui.Component
public Category Category {
set {
cat = value;
- vbox2.Sensitive = true;
UpdateGui();
}
get {
@@ -128,11 +124,6 @@ namespace LongoMatch.Gui.Component
if(cat.HotKey.Defined)
hotKeyLabel.Text = cat.HotKey.ToString();
else hotKeyLabel.Text = Catalog.GetString("none");
-
- list = subcategoriestreeview1.Model as ListStore;
- list.Clear();
- foreach (SubCategory subcat in cat.SubCategories)
- list.AppendValues(subcat);
}
void UpdatePosition (FieldPositionType position) {
@@ -163,26 +154,6 @@ namespace LongoMatch.Gui.Component
tagger.Tagger.Points = points;
}
- private void RenderSubcat(Gtk.TreeViewColumn column, Gtk.CellRenderer cell, Gtk.TreeModel
model, Gtk.TreeIter iter)
- {
- (cell as Gtk.CellRendererText).Markup =(string)model.GetValue(iter, 0);
- }
-
- private SubCategory EditSubCategoryTags (SubCategory template, bool checkName){
- return null;
-// SubCategoryTagsEditor se = new SubCategoryTagsEditor(template,
subcategoriesProvider.TemplatesNames);
-//
-// se.CheckName = checkName;
-// int ret = se.Run();
-//
-// var t = se.Template;
-// se.Destroy();
-//
-// if (ret != (int)ResponseType.Ok)
-// return null;
-// return t;
- }
-
protected virtual void OnChangebutonClicked(object sender, System.EventArgs e)
{
HotKeySelectorDialog dialog = new HotKeySelectorDialog();
@@ -223,37 +194,8 @@ namespace LongoMatch.Gui.Component
cat.SortMethodString = sortmethodcombobox.ActiveText;
}
- protected virtual void OnSubcategorySelected(SubCategory subcat) {
- EditSubCategoryTags((SubCategory)subcat, false);
- }
-
- protected virtual void OnSubcategoriesDeleted (List<SubCategory> subcats)
- {
- if (Project != null) {
- var msg = Catalog.GetString("If you delete this subcategory you will loose" +
- "all the tags associated with it. Do you want to
proceed?");
- if (!MessagesHelpers.QuestionMessage (this, msg)) {
- return;
- }
- Project.DeleteSubcategoryTags(Category, subcats);
- }
- Category.SubCategories.RemoveAll(s => subcats.Contains(s));
- }
-
protected virtual void OnAddbuttonClicked (object sender, System.EventArgs e)
{
- TreeIter iter;
-
- subcatcombobox.GetActiveIter(out iter);
- ListStore list = subcategoriestreeview1.Model as ListStore;
- var subcat = Cloner.Clone((SubCategory)model.GetValue(iter, 1));
- subcat.Name = subcatnameentry.Text;
- Category.SubCategories.Add(subcat);
- list.AppendValues(subcat);
- }
-
- protected virtual void OnSubcatcomboboxChanged (object sender, System.EventArgs e)
- {
}
protected void OnTaggoalcheckbuttonClicked (object sender, EventArgs e)
diff --git a/LongoMatch.GUI/Gui/TreeView/CategoriesFilterTreeView.cs
b/LongoMatch.GUI/Gui/TreeView/CategoriesFilterTreeView.cs
index 2fc3780..49a64a7 100644
--- a/LongoMatch.GUI/Gui/TreeView/CategoriesFilterTreeView.cs
+++ b/LongoMatch.GUI/Gui/TreeView/CategoriesFilterTreeView.cs
@@ -51,13 +51,6 @@ namespace LongoMatch.Gui.Component
TreeIter catIter;
catIter = store.AppendValues(cat, filter.VisibleCategories.Contains(cat));
- foreach (var subcat in cat.SubCategories) {
- TreeIter subcatIter;
- subcatIter = store.AppendValues(catIter, subcat, true);
- foreach (string desc in subcat.Options) {
- store.AppendValues(subcatIter, new StringObject{Value=desc,
SubCategory=subcat, Category=cat}, true);
- }
- }
}
Model = store;
}
@@ -69,8 +62,6 @@ namespace LongoMatch.Gui.Component
if (o is StringObject) {
StringObject so = o as StringObject;
-
- filter.FilterSubCategory(so.Category, so.SubCategory, so.Value, active);
} else {
/* don't do anything here and let the children do the filtering */
}
@@ -109,10 +100,6 @@ namespace LongoMatch.Gui.Component
Category cat = obj as Category;
text = cat.Name;
}
- else if (obj is SubCategory) {
- SubCategory subCat = obj as SubCategory;
- text = subCat.Name;
- }
else if (obj is StringObject){
text = (obj as StringObject).Value;
}
@@ -134,7 +121,6 @@ namespace LongoMatch.Gui.Component
class StringObject
{
public string Value {get;set;}
- public SubCategory SubCategory {get;set;}
public Category Category {get;set;}
}
}
diff --git a/LongoMatch.GUI/LongoMatch.GUI.mdp b/LongoMatch.GUI/LongoMatch.GUI.mdp
index b992515..2aaf88b 100644
--- a/LongoMatch.GUI/LongoMatch.GUI.mdp
+++ b/LongoMatch.GUI/LongoMatch.GUI.mdp
@@ -65,7 +65,6 @@
<File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.EndCaptureDialog.cs" />
<File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Dialog.BusyDialog.cs" />
<File subtype="Code" buildaction="Compile" name="Gui/TreeView/ListTreeViewBase.cs" />
- <File subtype="Code" buildaction="Compile" name="Gui/TreeView/SubCategoriesTreeView.cs" />
<File subtype="Code" buildaction="Compile" name="Gui/Component/RenderingStateBar.cs" />
<File subtype="Code" buildaction="Compile" name="gtk-gui/LongoMatch.Gui.Component.RenderingStateBar.cs"
/>
<File subtype="Code" buildaction="Compile" name="Gui/TreeView/RenderingJobsTreeView.cs" />
diff --git a/LongoMatch.GUI/Makefile.am b/LongoMatch.GUI/Makefile.am
index 4b9b703..56c1d4d 100644
--- a/LongoMatch.GUI/Makefile.am
+++ b/LongoMatch.GUI/Makefile.am
@@ -77,7 +77,6 @@ SOURCES = Gui/Cairo.cs \
Gui/TreeView/PlayersTreeView.cs \
Gui/TreeView/PlaysTreeView.cs \
Gui/TreeView/RenderingJobsTreeView.cs \
- Gui/TreeView/SubCategoriesTreeView.cs \
gtk-gui/LongoMatch.Gui.Component.AnalysisComponent.cs \
gtk-gui/LongoMatch.Gui.Component.AnalysisTemplateEditor.cs \
gtk-gui/LongoMatch.Gui.Component.BackgroundWidget.cs \
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
index 502a10b..308ec17 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
@@ -4,7 +4,6 @@ namespace LongoMatch.Gui.Component
{
public partial class CategoryProperties
{
- private global::Gtk.VBox vbox2;
private global::Gtk.Frame frame4;
private global::Gtk.Alignment GtkAlignment1;
private global::Gtk.VBox vbox3;
@@ -43,22 +42,6 @@ namespace LongoMatch.Gui.Component
private global::Gtk.Label GtkLabel13;
private global::Gtk.Table table1;
private global::Gtk.Label GtkLabel6;
- private global::Gtk.Frame frame3;
- private global::Gtk.Alignment GtkAlignment3;
- private global::Gtk.VBox vbox1;
- private global::Gtk.ScrolledWindow GtkScrolledWindow;
- private global::LongoMatch.Gui.SubCategoriesTreeView subcategoriestreeview1;
- private global::Gtk.HBox hbox3;
- private global::Gtk.Frame frame1;
- private global::Gtk.Alignment GtkAlignment4;
- private global::Gtk.Entry subcatnameentry;
- private global::Gtk.Label GtkLabel7;
- private global::Gtk.Frame frame2;
- private global::Gtk.Alignment GtkAlignment5;
- private global::Gtk.ComboBox subcatcombobox;
- private global::Gtk.Label GtkLabel8;
- private global::Gtk.Button addbutton;
- private global::Gtk.Label GtkLabel11;
protected virtual void Build ()
{
@@ -67,10 +50,6 @@ namespace LongoMatch.Gui.Component
global::Stetic.BinContainer.Attach (this);
this.Name = "LongoMatch.Gui.Component.CategoryProperties";
// Container child
LongoMatch.Gui.Component.CategoryProperties.Gtk.Container+ContainerChild
- this.vbox2 = new global::Gtk.VBox ();
- this.vbox2.Name = "vbox2";
- this.vbox2.Spacing = 6;
- // Container child vbox2.Gtk.Box+BoxChild
this.frame4 = new global::Gtk.Frame ();
this.frame4.Name = "frame4";
this.frame4.ShadowType = ((global::Gtk.ShadowType)(1));
@@ -414,130 +393,7 @@ namespace LongoMatch.Gui.Component
this.GtkLabel6.LabelProp = global::Mono.Unix.Catalog.GetString ("<b>Properties</b>");
this.GtkLabel6.UseMarkup = true;
this.frame4.LabelWidget = this.GtkLabel6;
- this.vbox2.Add (this.frame4);
- global::Gtk.Box.BoxChild w34 = ((global::Gtk.Box.BoxChild)(this.vbox2 [this.frame4]));
- w34.Position = 0;
- w34.Expand = false;
- w34.Fill = false;
- // Container child vbox2.Gtk.Box+BoxChild
- this.frame3 = new global::Gtk.Frame ();
- this.frame3.Name = "frame3";
- this.frame3.ShadowType = ((global::Gtk.ShadowType)(1));
- // Container child frame3.Gtk.Container+ContainerChild
- this.GtkAlignment3 = new global::Gtk.Alignment (0F, 0F, 1F, 1F);
- this.GtkAlignment3.Name = "GtkAlignment3";
- this.GtkAlignment3.LeftPadding = ((uint)(12));
- // Container child GtkAlignment3.Gtk.Container+ContainerChild
- this.vbox1 = new global::Gtk.VBox ();
- this.vbox1.Name = "vbox1";
- this.vbox1.Spacing = 6;
- // Container child vbox1.Gtk.Box+BoxChild
- this.GtkScrolledWindow = new global::Gtk.ScrolledWindow ();
- this.GtkScrolledWindow.Name = "GtkScrolledWindow";
- this.GtkScrolledWindow.ShadowType = ((global::Gtk.ShadowType)(1));
- // Container child GtkScrolledWindow.Gtk.Container+ContainerChild
- this.subcategoriestreeview1 = new global::LongoMatch.Gui.SubCategoriesTreeView ();
- this.subcategoriestreeview1.CanFocus = true;
- this.subcategoriestreeview1.Name = "subcategoriestreeview1";
- this.GtkScrolledWindow.Add (this.subcategoriestreeview1);
- this.vbox1.Add (this.GtkScrolledWindow);
- global::Gtk.Box.BoxChild w36 = ((global::Gtk.Box.BoxChild)(this.vbox1
[this.GtkScrolledWindow]));
- w36.Position = 0;
- // Container child vbox1.Gtk.Box+BoxChild
- this.hbox3 = new global::Gtk.HBox ();
- this.hbox3.Name = "hbox3";
- this.hbox3.Spacing = 6;
- // Container child hbox3.Gtk.Box+BoxChild
- this.frame1 = new global::Gtk.Frame ();
- this.frame1.Name = "frame1";
- this.frame1.ShadowType = ((global::Gtk.ShadowType)(0));
- // Container child frame1.Gtk.Container+ContainerChild
- this.GtkAlignment4 = new global::Gtk.Alignment (0F, 0F, 1F, 1F);
- this.GtkAlignment4.Name = "GtkAlignment4";
- this.GtkAlignment4.LeftPadding = ((uint)(12));
- // Container child GtkAlignment4.Gtk.Container+ContainerChild
- this.subcatnameentry = new global::Gtk.Entry ();
- this.subcatnameentry.CanFocus = true;
- this.subcatnameentry.Name = "subcatnameentry";
- this.subcatnameentry.IsEditable = true;
- this.subcatnameentry.InvisibleChar = '•';
- this.GtkAlignment4.Add (this.subcatnameentry);
- this.frame1.Add (this.GtkAlignment4);
- this.GtkLabel7 = new global::Gtk.Label ();
- this.GtkLabel7.Name = "GtkLabel7";
- this.GtkLabel7.LabelProp = global::Mono.Unix.Catalog.GetString ("<b>Subcategory
name</b>");
- this.GtkLabel7.UseMarkup = true;
- this.frame1.LabelWidget = this.GtkLabel7;
- this.hbox3.Add (this.frame1);
- global::Gtk.Box.BoxChild w39 = ((global::Gtk.Box.BoxChild)(this.hbox3 [this.frame1]));
- w39.Position = 0;
- w39.Expand = false;
- w39.Fill = false;
- // Container child hbox3.Gtk.Box+BoxChild
- this.frame2 = new global::Gtk.Frame ();
- this.frame2.Name = "frame2";
- this.frame2.ShadowType = ((global::Gtk.ShadowType)(0));
- // Container child frame2.Gtk.Container+ContainerChild
- this.GtkAlignment5 = new global::Gtk.Alignment (0F, 0F, 1F, 1F);
- this.GtkAlignment5.Name = "GtkAlignment5";
- this.GtkAlignment5.LeftPadding = ((uint)(12));
- // Container child GtkAlignment5.Gtk.Container+ContainerChild
- this.subcatcombobox = new global::Gtk.ComboBox ();
- this.subcatcombobox.Name = "subcatcombobox";
- this.GtkAlignment5.Add (this.subcatcombobox);
- this.frame2.Add (this.GtkAlignment5);
- this.GtkLabel8 = new global::Gtk.Label ();
- this.GtkLabel8.Name = "GtkLabel8";
- this.GtkLabel8.LabelProp = global::Mono.Unix.Catalog.GetString ("<b>Subcategory
type</b>");
- this.GtkLabel8.UseMarkup = true;
- this.frame2.LabelWidget = this.GtkLabel8;
- this.hbox3.Add (this.frame2);
- global::Gtk.Box.BoxChild w42 = ((global::Gtk.Box.BoxChild)(this.hbox3 [this.frame2]));
- w42.Position = 1;
- // Container child hbox3.Gtk.Box+BoxChild
- this.addbutton = new global::Gtk.Button ();
- this.addbutton.TooltipMarkup = "Add this subcategory";
- this.addbutton.Sensitive = false;
- this.addbutton.CanFocus = true;
- this.addbutton.Name = "addbutton";
- this.addbutton.UseUnderline = true;
- // Container child addbutton.Gtk.Container+ContainerChild
- global::Gtk.Alignment w43 = new global::Gtk.Alignment (0.5F, 0.5F, 0F, 0F);
- // Container child GtkAlignment.Gtk.Container+ContainerChild
- global::Gtk.HBox w44 = new global::Gtk.HBox ();
- w44.Spacing = 2;
- // Container child GtkHBox.Gtk.Container+ContainerChild
- global::Gtk.Image w45 = new global::Gtk.Image ();
- w45.Pixbuf = global::Stetic.IconLoader.LoadIcon (this, "gtk-add",
global::Gtk.IconSize.Menu);
- w44.Add (w45);
- // Container child GtkHBox.Gtk.Container+ContainerChild
- global::Gtk.Label w47 = new global::Gtk.Label ();
- w47.LabelProp = global::Mono.Unix.Catalog.GetString ("_Add subcategory");
- w47.UseUnderline = true;
- w44.Add (w47);
- w43.Add (w44);
- this.addbutton.Add (w43);
- this.hbox3.Add (this.addbutton);
- global::Gtk.Box.BoxChild w51 = ((global::Gtk.Box.BoxChild)(this.hbox3
[this.addbutton]));
- w51.Position = 2;
- w51.Expand = false;
- w51.Fill = false;
- this.vbox1.Add (this.hbox3);
- global::Gtk.Box.BoxChild w52 = ((global::Gtk.Box.BoxChild)(this.vbox1 [this.hbox3]));
- w52.Position = 1;
- w52.Expand = false;
- w52.Fill = false;
- this.GtkAlignment3.Add (this.vbox1);
- this.frame3.Add (this.GtkAlignment3);
- this.GtkLabel11 = new global::Gtk.Label ();
- this.GtkLabel11.Name = "GtkLabel11";
- this.GtkLabel11.LabelProp = global::Mono.Unix.Catalog.GetString
("<b>Subcategories</b>");
- this.GtkLabel11.UseMarkup = true;
- this.frame3.LabelWidget = this.GtkLabel11;
- this.vbox2.Add (this.frame3);
- global::Gtk.Box.BoxChild w55 = ((global::Gtk.Box.BoxChild)(this.vbox2 [this.frame3]));
- w55.Position = 1;
- this.Add (this.vbox2);
+ this.Add (this.frame4);
if ((this.Child != null)) {
this.Child.ShowAll ();
}
@@ -551,8 +407,6 @@ namespace LongoMatch.Gui.Component
this.taghalffieldcheckbutton.Clicked += new global::System.EventHandler
(this.OnTaghalffieldcheckbuttonClicked);
this.trajectoryhalfcheckbutton.Clicked += new global::System.EventHandler
(this.OnTrajectoryhalffieldcheckbuttonClicked);
this.taggoalcheckbutton.Clicked += new global::System.EventHandler
(this.OnTaggoalcheckbuttonClicked);
- this.subcatcombobox.Changed += new global::System.EventHandler
(this.OnSubcatcomboboxChanged);
- this.addbutton.Clicked += new global::System.EventHandler (this.OnAddbuttonClicked);
}
}
}
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CodingWidget.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CodingWidget.cs
index e29e158..1943ce8 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CodingWidget.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CodingWidget.cs
@@ -5,11 +5,11 @@ namespace LongoMatch.Gui.Component
public partial class CodingWidget
{
private global::Gtk.UIManager UIManager;
+ private global::Gtk.RadioAction positionMode;
private global::Gtk.RadioAction timelineMode;
private global::Gtk.RadioAction autoTaggingMode;
private global::Gtk.Action zoomFitAction;
private global::Gtk.RadioAction convertAction;
- private global::Gtk.RadioAction positionMode;
private global::Gtk.VBox vbox2;
private global::Gtk.HBox hbox1;
private global::Gtk.Toolbar codingtoolbar;
@@ -25,23 +25,23 @@ namespace LongoMatch.Gui.Component
// Widget LongoMatch.Gui.Component.CodingWidget
Stetic.BinContainer w1 = global::Stetic.BinContainer.Attach (this);
this.UIManager = new global::Gtk.UIManager ();
- global::Gtk.ActionGroup w2 = new global::Gtk.ActionGroup ("Default");
+ global::Gtk.ActionGroup w2 = new global::Gtk.ActionGroup ("Timeline");
+ this.positionMode = new global::Gtk.RadioAction ("positionMode", null, null,
"gtk-justify-fill", 0);
+ this.positionMode.Group = new global::GLib.SList (global::System.IntPtr.Zero);
+ w2.Add (this.positionMode, null);
+ this.UIManager.InsertActionGroup (w2, 0);
+ global::Gtk.ActionGroup w3 = new global::Gtk.ActionGroup ("Default");
this.timelineMode = new global::Gtk.RadioAction ("timelineMode", null,
global::Mono.Unix.Catalog.GetString ("Timeline view"), "gtk-justify-fill", 0);
- this.timelineMode.Group = new global::GLib.SList (global::System.IntPtr.Zero);
- w2.Add (this.timelineMode, null);
+ this.timelineMode.Group = this.positionMode.Group;
+ w3.Add (this.timelineMode, null);
this.autoTaggingMode = new global::Gtk.RadioAction ("autoTaggingMode", null,
global::Mono.Unix.Catalog.GetString ("Automatic tagging view"), "gtk-select-color", 0);
- this.autoTaggingMode.Group = this.timelineMode.Group;
- w2.Add (this.autoTaggingMode, null);
+ this.autoTaggingMode.Group = this.positionMode.Group;
+ w3.Add (this.autoTaggingMode, null);
this.zoomFitAction = new global::Gtk.Action ("zoomFitAction", null, null,
"gtk-zoom-fit");
- w2.Add (this.zoomFitAction, null);
+ w3.Add (this.zoomFitAction, null);
this.convertAction = new global::Gtk.RadioAction ("convertAction", null, null,
"gtk-convert", 0);
- this.convertAction.Group = this.autoTaggingMode.Group;
- w2.Add (this.convertAction, null);
- this.UIManager.InsertActionGroup (w2, 0);
- global::Gtk.ActionGroup w3 = new global::Gtk.ActionGroup ("Timeline");
- this.positionMode = new global::Gtk.RadioAction ("positionMode", null, null,
"gtk-justify-fill", 0);
- this.positionMode.Group = this.autoTaggingMode.Group;
- w3.Add (this.positionMode, null);
+ this.convertAction.Group = this.positionMode.Group;
+ w3.Add (this.convertAction, null);
this.UIManager.InsertActionGroup (w3, 1);
this.Name = "LongoMatch.Gui.Component.CodingWidget";
// Container child LongoMatch.Gui.Component.CodingWidget.Gtk.Container+ContainerChild
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.Stats.Plotter.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.Stats.Plotter.cs
index d9515ac..ab07947 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.Stats.Plotter.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.Stats.Plotter.cs
@@ -31,7 +31,6 @@ namespace LongoMatch.Gui.Component.Stats
this.historadiobutton = new global::Gtk.RadioButton
(global::Mono.Unix.Catalog.GetString ("Histogram"));
this.historadiobutton.CanFocus = true;
this.historadiobutton.Name = "historadiobutton";
- this.historadiobutton.Active = true;
this.historadiobutton.DrawIndicator = true;
this.historadiobutton.UseUnderline = true;
this.historadiobutton.Group = new global::GLib.SList (global::System.IntPtr.Zero);
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
index 5058524..cd400e9 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.DrawingTool.cs
@@ -102,6 +102,7 @@ namespace LongoMatch.Gui.Dialog
this.anglebutton.TooltipMarkup = "Angle tool";
this.anglebutton.CanFocus = true;
this.anglebutton.Name = "anglebutton";
+ this.anglebutton.Active = true;
this.anglebutton.DrawIndicator = false;
this.anglebutton.UseUnderline = true;
this.anglebutton.Group = new global::GLib.SList (global::System.IntPtr.Zero);
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
index 391af6e..89d5362 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.VideoEditionProperties.cs
@@ -132,7 +132,6 @@ namespace LongoMatch.Gui.Dialog
this.descriptioncheckbutton.CanFocus = true;
this.descriptioncheckbutton.Name = "descriptioncheckbutton";
this.descriptioncheckbutton.Label = global::Mono.Unix.Catalog.GetString ("Enable
title overlay");
- this.descriptioncheckbutton.Active = true;
this.descriptioncheckbutton.DrawIndicator = true;
this.descriptioncheckbutton.UseUnderline = true;
this.hbox6.Add (this.descriptioncheckbutton);
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.NewProjectPanel.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.NewProjectPanel.cs
index 9b7db32..a1212e1 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.NewProjectPanel.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.NewProjectPanel.cs
@@ -148,6 +148,7 @@ namespace LongoMatch.Gui.Panel
this.fromfileradiobutton = new global::Gtk.RadioButton
(global::Mono.Unix.Catalog.GetString ("New project using a video file"));
this.fromfileradiobutton.CanFocus = true;
this.fromfileradiobutton.Name = "fromfileradiobutton";
+ this.fromfileradiobutton.Active = true;
this.fromfileradiobutton.DrawIndicator = true;
this.fromfileradiobutton.UseUnderline = true;
this.fromfileradiobutton.FocusOnClick = false;
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.ProjectsManagerPanel.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.ProjectsManagerPanel.cs
index b6fbbb2..dc0a441 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.ProjectsManagerPanel.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.ProjectsManagerPanel.cs
@@ -463,6 +463,7 @@ namespace LongoMatch.Gui.Panel
w61.Position = 0;
// Container child rbox.Gtk.Box+BoxChild
this.hbuttonbox1 = new global::Gtk.HButtonBox ();
+ this.hbuttonbox1.Name = "hbuttonbox1";
// Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
this.savebutton = new global::Gtk.Button ();
this.savebutton.Sensitive = false;
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.WelcomePanel.cs
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.WelcomePanel.cs
index e755b6c..9588f2d 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.WelcomePanel.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Panel.WelcomePanel.cs
@@ -48,6 +48,7 @@ namespace LongoMatch.Gui.Panel
w2.Fill = false;
// Container child vbox1.Gtk.Box+BoxChild
this.hbuttonbox1 = new global::Gtk.HButtonBox ();
+ this.hbuttonbox1.Name = "hbuttonbox1";
this.hbuttonbox1.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(1));
// Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
this.newbutton = new global::Gtk.Button ();
diff --git a/LongoMatch.GUI/gtk-gui/gui.stetic b/LongoMatch.GUI/gtk-gui/gui.stetic
index ddb0405..3295274 100644
--- a/LongoMatch.GUI/gtk-gui/gui.stetic
+++ b/LongoMatch.GUI/gtk-gui/gui.stetic
@@ -9,7 +9,7 @@
<widget-library name="../../bin/LongoMatch.Multimedia.dll" />
<widget-library name="../../bin/LongoMatch.GUI.Helpers.dll" />
<widget-library name="../../LongoMatch.Drawing.Cairo/bin/Debug/LongoMatch.Drawing.Cairo.dll" />
- <widget-library name="../../bin/LongoMatch.Gui.dll" internal="true" />
+ <widget-library name="../../bin/LongoMatch.GUI.dll" internal="true" />
</import>
<widget class="Gtk.Bin" id="LongoMatch.Gui.Component.ProjectListWidget" design-size="572 300">
<property name="MemberName" />
@@ -468,639 +468,468 @@
</widget>
</child>
</widget>
- <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.CategoryProperties" design-size="674 579">
+ <widget class="Gtk.Bin" id="LongoMatch.Gui.Component.CategoryProperties" design-size="674 370">
<property name="MemberName" />
<child>
- <widget class="Gtk.VBox" id="vbox2">
+ <widget class="Gtk.Frame" id="frame4">
<property name="MemberName" />
- <property name="Spacing">6</property>
+ <property name="ShadowType">In</property>
<child>
- <widget class="Gtk.Frame" id="frame4">
+ <widget class="Gtk.Alignment" id="GtkAlignment1">
<property name="MemberName" />
- <property name="ShadowType">In</property>
+ <property name="Xalign">0</property>
+ <property name="Yalign">0</property>
+ <property name="LeftPadding">12</property>
<child>
- <widget class="Gtk.Alignment" id="GtkAlignment1">
+ <widget class="Gtk.VBox" id="vbox3">
<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.VBox" id="vbox3">
+ <widget class="Gtk.Table" id="table2">
<property name="MemberName" />
- <property name="Spacing">6</property>
+ <property name="NRows">3</property>
+ <property name="NColumns">4</property>
+ <property name="RowSpacing">6</property>
+ <property name="ColumnSpacing">6</property>
<child>
- <widget class="Gtk.Table" id="table2">
+ <widget class="Gtk.ColorButton" id="colorbutton1">
<property name="MemberName" />
- <property name="NRows">3</property>
- <property name="NColumns">4</property>
- <property name="RowSpacing">6</property>
- <property name="ColumnSpacing">6</property>
- <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="LeftAttach">3</property>
- <property name="RightAttach">4</property>
- <property name="AutoSize">False</property>
- <property name="XOptions">Fill</property>
- <property name="YOptions">0</property>
- <property name="XExpand">False</property>
- <property name="XFill">True</property>
- <property name="XShrink">False</property>
- <property name="YExpand">False</property>
- <property name="YFill">False</property>
- <property name="YShrink">False</property>
- </packing>
- </child>
- <child>
- <widget class="Gtk.HBox" id="hbox5">
- <property name="MemberName" />
- <property name="Spacing">6</property>
- <child>
- <widget class="Gtk.Label" id="hotKeyLabel">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes">none</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.Button" id="changebuton">
- <property name="MemberName" />
- <property name="Sensitive">False</property>
- <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="Position">1</property>
- <property name="AutoSize">False</property>
- <property name="Expand">False</property>
- <property name="Fill">False</property>
- </packing>
- </child>
- </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="XOptions">Fill</property>
- <property name="YOptions">0</property>
- <property name="XExpand">False</property>
- <property name="XFill">True</property>
- <property name="XShrink">False</property>
- <property name="YExpand">False</property>
- <property name="YFill">False</property>
- <property name="YShrink">False</property>
- </packing>
- </child>
- <child>
- <widget class="Gtk.Label" id="label1">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="LabelProp" translatable="yes"><b>Name:</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="AutoSize">False</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="Xalign">0</property>
- <property name="LabelProp" translatable="yes"><b>Color:</b>
</property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="LeftAttach">2</property>
- <property name="RightAttach">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="label6">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="LabelProp"
translatable="yes"><b>HotKey:</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="TopAttach">2</property>
- <property name="BottomAttach">3</property>
- <property name="AutoSize">False</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="label7">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="LabelProp" translatable="yes"><b>Lead
time:</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="TopAttach">1</property>
- <property name="BottomAttach">2</property>
- <property name="AutoSize">False</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="label8">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="LabelProp" translatable="yes"><b>Lag
time:</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="TopAttach">1</property>
- <property name="BottomAttach">2</property>
- <property name="LeftAttach">2</property>
- <property name="RightAttach">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="label9">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="LabelProp" translatable="yes"><b>Sort
Method</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="TopAttach">2</property>
- <property name="BottomAttach">3</property>
- <property name="LeftAttach">2</property>
- <property name="RightAttach">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.SpinButton" id="lagtimebutton">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Upper">1000</property>
- <property name="PageIncrement">1</property>
- <property name="StepIncrement">1</property>
- <property name="ClimbRate">1</property>
- <property name="Numeric">True</property>
- </widget>
- <packing>
- <property name="TopAttach">1</property>
- <property name="BottomAttach">2</property>
- <property name="LeftAttach">3</property>
- <property name="RightAttach">4</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>
+ <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="LeftAttach">3</property>
+ <property name="RightAttach">4</property>
+ <property name="AutoSize">False</property>
+ <property name="XOptions">Fill</property>
+ <property name="YOptions">0</property>
+ <property name="XExpand">False</property>
+ <property name="XFill">True</property>
+ <property name="XShrink">False</property>
+ <property name="YExpand">False</property>
+ <property name="YFill">False</property>
+ <property name="YShrink">False</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="Gtk.HBox" id="hbox5">
+ <property name="MemberName" />
+ <property name="Spacing">6</property>
<child>
- <widget class="Gtk.SpinButton" id="leadtimebutton">
+ <widget class="Gtk.Label" id="hotKeyLabel">
<property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Upper">1000</property>
- <property name="PageIncrement">1</property>
- <property name="StepIncrement">1</property>
- <property name="ClimbRate">1</property>
- <property name="Numeric">True</property>
+ <property name="LabelProp" translatable="yes">none</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="Position">0</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>
+ <property name="Expand">False</property>
+ <property name="Fill">False</property>
</packing>
</child>
<child>
- <widget class="Gtk.Entry" id="nameentry">
+ <widget class="Gtk.Button" id="changebuton">
<property name="MemberName" />
+ <property name="Sensitive">False</property>
<property name="CanFocus">True</property>
- <property name="IsEditable">True</property>
- <property name="InvisibleChar">●</property>
- <signal name="Changed" handler="OnNameentryChanged" />
+ <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="LeftAttach">1</property>
- <property name="RightAttach">2</property>
+ <property name="Position">1</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>
+ <property name="Expand">False</property>
+ <property name="Fill">False</property>
</packing>
</child>
- <child>
- <widget class="Gtk.ComboBox" id="sortmethodcombobox">
- <property name="MemberName" />
- <property name="IsTextCombo">True</property>
- <property name="Items" translatable="yes">Sort by name
+ </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="XOptions">Fill</property>
+ <property name="YOptions">0</property>
+ <property name="XExpand">False</property>
+ <property name="XFill">True</property>
+ <property name="XShrink">False</property>
+ <property name="YExpand">False</property>
+ <property name="YFill">False</property>
+ <property name="YShrink">False</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="Gtk.Label" id="label1">
+ <property name="MemberName" />
+ <property name="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>Name:</b></property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="AutoSize">False</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="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>Color:</b>
</property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="LeftAttach">2</property>
+ <property name="RightAttach">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="label6">
+ <property name="MemberName" />
+ <property name="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>HotKey:</b></property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="TopAttach">2</property>
+ <property name="BottomAttach">3</property>
+ <property name="AutoSize">False</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="label7">
+ <property name="MemberName" />
+ <property name="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>Lead
time:</b></property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="TopAttach">1</property>
+ <property name="BottomAttach">2</property>
+ <property name="AutoSize">False</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="label8">
+ <property name="MemberName" />
+ <property name="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>Lag time:</b></property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="TopAttach">1</property>
+ <property name="BottomAttach">2</property>
+ <property name="LeftAttach">2</property>
+ <property name="RightAttach">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="label9">
+ <property name="MemberName" />
+ <property name="Xalign">0</property>
+ <property name="LabelProp" translatable="yes"><b>Sort
Method</b></property>
+ <property name="UseMarkup">True</property>
+ </widget>
+ <packing>
+ <property name="TopAttach">2</property>
+ <property name="BottomAttach">3</property>
+ <property name="LeftAttach">2</property>
+ <property name="RightAttach">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.SpinButton" id="lagtimebutton">
+ <property name="MemberName" />
+ <property name="CanFocus">True</property>
+ <property name="Upper">1000</property>
+ <property name="PageIncrement">1</property>
+ <property name="StepIncrement">1</property>
+ <property name="ClimbRate">1</property>
+ <property name="Numeric">True</property>
+ </widget>
+ <packing>
+ <property name="TopAttach">1</property>
+ <property name="BottomAttach">2</property>
+ <property name="LeftAttach">3</property>
+ <property name="RightAttach">4</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.SpinButton" id="leadtimebutton">
+ <property name="MemberName" />
+ <property name="CanFocus">True</property>
+ <property name="Upper">1000</property>
+ <property name="PageIncrement">1</property>
+ <property name="StepIncrement">1</property>
+ <property name="ClimbRate">1</property>
+ <property name="Numeric">True</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>
+ <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">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.ComboBox" id="sortmethodcombobox">
+ <property name="MemberName" />
+ <property name="IsTextCombo">True</property>
+ <property name="Items" translatable="yes">Sort by name
Sort by start time
Sort by stop time
Sort by duration</property>
- <property name="Active">3</property>
- <signal name="Changed" handler="OnSortmethodcomboboxChanged" />
- </widget>
- <packing>
- <property name="TopAttach">2</property>
- <property name="BottomAttach">3</property>
- <property name="LeftAttach">3</property>
- <property name="RightAttach">4</property>
- <property name="AutoSize">False</property>
- <property name="XOptions">Fill</property>
- <property name="YOptions">0</property>
- <property name="XExpand">False</property>
- <property name="XFill">True</property>
- <property name="XShrink">False</property>
- <property name="YExpand">False</property>
- <property name="YFill">False</property>
- <property name="YShrink">False</property>
- </packing>
- </child>
+ <property name="Active">3</property>
+ <signal name="Changed" handler="OnSortmethodcomboboxChanged" />
</widget>
<packing>
- <property name="Position">0</property>
- <property name="AutoSize">True</property>
- <property name="Expand">False</property>
- <property name="Fill">False</property>
+ <property name="TopAttach">2</property>
+ <property name="BottomAttach">3</property>
+ <property name="LeftAttach">3</property>
+ <property name="RightAttach">4</property>
+ <property name="AutoSize">False</property>
+ <property name="XOptions">Fill</property>
+ <property name="YOptions">0</property>
+ <property name="XExpand">False</property>
+ <property name="XFill">True</property>
+ <property name="XShrink">False</property>
+ <property name="YExpand">False</property>
+ <property name="YFill">False</property>
+ <property name="YShrink">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="vbox5">
+ <property name="MemberName" />
+ <property name="Spacing">6</property>
<child>
- <widget class="Gtk.VBox" id="vbox5">
+ <widget class="Gtk.HBox" id="hbox1">
<property name="MemberName" />
<property name="Spacing">6</property>
<child>
- <widget class="Gtk.HBox" id="hbox1">
+ <widget class="Gtk.Frame" id="frame5">
<property name="MemberName" />
- <property name="Spacing">6</property>
+ <property name="ShadowType">None</property>
<child>
- <widget class="Gtk.Frame" id="frame5">
+ <widget class="Gtk.Alignment" id="GtkAlignment7">
<property name="MemberName" />
- <property name="ShadowType">None</property>
+ <property name="Xalign">0</property>
+ <property name="Yalign">0</property>
+ <property name="LeftPadding">12</property>
<child>
- <widget class="Gtk.Alignment" id="GtkAlignment7">
+ <widget class="Gtk.VBox" id="vbox4">
<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.VBox" id="vbox4">
+ <widget class="Gtk.CheckButton" id="tagfieldcheckbutton">
<property name="MemberName" />
- <property name="Spacing">6</property>
- <child>
- <widget class="Gtk.CheckButton" id="tagfieldcheckbutton">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Label" translatable="yes">Enable</property>
- <property name="DrawIndicator">True</property>
- <property name="HasLabel">True</property>
- <property name="UseUnderline">True</property>
- <signal name="Clicked" handler="OnTagfieldcheckbuttonClicked" />
- </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.CheckButton" id="trajectorycheckbutton">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Label" translatable="yes">Trajectory</property>
- <property name="DrawIndicator">True</property>
- <property name="HasLabel">True</property>
- <property name="UseUnderline">True</property>
- <signal name="Clicked" handler="OnTrajectorycheckbuttonClicked"
/>
- </widget>
- <packing>
- <property name="Position">1</property>
- <property name="AutoSize">True</property>
- <property name="Expand">False</property>
- <property name="Fill">False</property>
- </packing>
- </child>
+ <property name="CanFocus">True</property>
+ <property name="Label" translatable="yes">Enable</property>
+ <property name="DrawIndicator">True</property>
+ <property name="HasLabel">True</property>
+ <property name="UseUnderline">True</property>
+ <signal name="Clicked" handler="OnTagfieldcheckbuttonClicked" />
</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>
- <widget class="Gtk.Label" id="GtkLabel9">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Field
position</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="Position">0</property>
- <property name="AutoSize">False</property>
- </packing>
- </child>
- <child>
- <widget class="Gtk.Frame" id="frame6">
- <property name="MemberName" />
- <property name="ShadowType">None</property>
- <child>
- <widget class="Gtk.Alignment" id="GtkAlignment8">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="Yalign">0</property>
- <property name="LeftPadding">12</property>
<child>
- <widget class="Gtk.VBox" id="vbox6">
- <property name="MemberName" />
- <property name="Spacing">6</property>
- <child>
- <widget class="Gtk.CheckButton" id="taghalffieldcheckbutton">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Label" translatable="yes">Enable</property>
- <property name="DrawIndicator">True</property>
- <property name="HasLabel">True</property>
- <property name="UseUnderline">True</property>
- <signal name="Clicked"
handler="OnTaghalffieldcheckbuttonClicked" />
- </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.CheckButton" id="trajectoryhalfcheckbutton">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="Label" translatable="yes">Trajectory</property>
- <property name="DrawIndicator">True</property>
- <property name="HasLabel">True</property>
- <property name="UseUnderline">True</property>
- <signal name="Clicked"
handler="OnTrajectoryhalffieldcheckbuttonClicked" />
- </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>
- </child>
- </widget>
- </child>
- <child>
- <widget class="Gtk.Label" id="GtkLabel12">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Half field
position</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="Position">1</property>
- <property name="AutoSize">False</property>
- </packing>
- </child>
- <child>
- <widget class="Gtk.Frame" id="frame7">
- <property name="MemberName" />
- <property name="ShadowType">None</property>
- <child>
- <widget class="Gtk.Alignment" id="GtkAlignment9">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="Yalign">0</property>
- <property name="LeftPadding">12</property>
- <child>
- <widget class="Gtk.CheckButton" id="taggoalcheckbutton">
+ <widget class="Gtk.CheckButton" id="trajectorycheckbutton">
<property name="MemberName" />
<property name="CanFocus">True</property>
- <property name="Label" translatable="yes">Enable</property>
+ <property name="Label" translatable="yes">Trajectory</property>
<property name="DrawIndicator">True</property>
<property name="HasLabel">True</property>
<property name="UseUnderline">True</property>
- <signal name="Clicked" handler="OnTaggoalcheckbuttonClicked" />
+ <signal name="Clicked" handler="OnTrajectorycheckbuttonClicked" />
</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>
</child>
- <child>
- <widget class="Gtk.Label" id="GtkLabel13">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Goal
Position</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
+ </widget>
+ </child>
+ <child>
+ <widget class="Gtk.Label" id="GtkLabel9">
+ <property name="MemberName" />
+ <property name="LabelProp" translatable="yes"><b>Field
position</b></property>
+ <property name="UseMarkup">True</property>
</widget>
<packing>
- <property name="Position">2</property>
- <property name="AutoSize">False</property>
+ <property name="type">label_item</property>
</packing>
</child>
</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.Table" id="table1">
- <property name="MemberName" />
- <property name="NColumns">3</property>
- <property name="RowSpacing">6</property>
- <property name="ColumnSpacing">6</property>
- <child>
- <placeholder />
- </child>
- <child>
- <placeholder />
- </child>
- <child>
- <placeholder />
- </child>
- </widget>
- <packing>
- <property name="Position">1</property>
- <property name="AutoSize">True</property>
- </packing>
- </child>
- </widget>
- <packing>
- <property name="Position">1</property>
- <property name="AutoSize">True</property>
- </packing>
- </child>
- </widget>
- </child>
- </widget>
- </child>
- <child>
- <widget class="Gtk.Label" id="GtkLabel6">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Properties</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
- </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.Frame" id="frame3">
- <property name="MemberName" />
- <property name="ShadowType">In</property>
- <child>
- <widget class="Gtk.Alignment" id="GtkAlignment3">
- <property name="MemberName" />
- <property name="Xalign">0</property>
- <property name="Yalign">0</property>
- <property name="LeftPadding">12</property>
- <child>
- <widget class="Gtk.VBox" id="vbox1">
- <property name="MemberName" />
- <property name="Spacing">6</property>
- <child>
- <widget class="Gtk.ScrolledWindow" id="GtkScrolledWindow">
- <property name="MemberName" />
- <property name="ShadowType">In</property>
- <child>
- <widget class="LongoMatch.Gui.SubCategoriesTreeView" id="subcategoriestreeview1">
- <property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="ShowScrollbars">True</property>
- </widget>
- </child>
- </widget>
- <packing>
- <property name="Position">0</property>
- <property name="AutoSize">True</property>
- </packing>
- </child>
- <child>
- <widget class="Gtk.HBox" id="hbox3">
- <property name="MemberName" />
- <property name="Spacing">6</property>
- <child>
- <widget class="Gtk.Frame" id="frame1">
+ <widget class="Gtk.Frame" id="frame6">
<property name="MemberName" />
<property name="ShadowType">None</property>
<child>
- <widget class="Gtk.Alignment" id="GtkAlignment4">
+ <widget class="Gtk.Alignment" id="GtkAlignment8">
<property name="MemberName" />
<property name="Xalign">0</property>
<property name="Yalign">0</property>
<property name="LeftPadding">12</property>
<child>
- <widget class="Gtk.Entry" id="subcatnameentry">
+ <widget class="Gtk.VBox" id="vbox6">
<property name="MemberName" />
- <property name="CanFocus">True</property>
- <property name="IsEditable">True</property>
- <property name="InvisibleChar">•</property>
+ <property name="Spacing">6</property>
+ <child>
+ <widget class="Gtk.CheckButton" id="taghalffieldcheckbutton">
+ <property name="MemberName" />
+ <property name="CanFocus">True</property>
+ <property name="Label" translatable="yes">Enable</property>
+ <property name="DrawIndicator">True</property>
+ <property name="HasLabel">True</property>
+ <property name="UseUnderline">True</property>
+ <signal name="Clicked" handler="OnTaghalffieldcheckbuttonClicked" />
+ </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.CheckButton" id="trajectoryhalfcheckbutton">
+ <property name="MemberName" />
+ <property name="CanFocus">True</property>
+ <property name="Label" translatable="yes">Trajectory</property>
+ <property name="DrawIndicator">True</property>
+ <property name="HasLabel">True</property>
+ <property name="UseUnderline">True</property>
+ <signal name="Clicked"
handler="OnTrajectoryhalffieldcheckbuttonClicked" />
+ </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>
</child>
</widget>
</child>
<child>
- <widget class="Gtk.Label" id="GtkLabel7">
+ <widget class="Gtk.Label" id="GtkLabel12">
<property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Subcategory
name</b></property>
+ <property name="LabelProp" translatable="yes"><b>Half field
position</b></property>
<property name="UseMarkup">True</property>
</widget>
<packing>
@@ -1109,36 +938,37 @@ Sort by duration</property>
</child>
</widget>
<packing>
- <property name="Position">0</property>
- <property name="AutoSize">True</property>
- <property name="Expand">False</property>
- <property name="Fill">False</property>
+ <property name="Position">1</property>
+ <property name="AutoSize">False</property>
</packing>
</child>
<child>
- <widget class="Gtk.Frame" id="frame2">
+ <widget class="Gtk.Frame" id="frame7">
<property name="MemberName" />
<property name="ShadowType">None</property>
<child>
- <widget class="Gtk.Alignment" id="GtkAlignment5">
+ <widget class="Gtk.Alignment" id="GtkAlignment9">
<property name="MemberName" />
<property name="Xalign">0</property>
<property name="Yalign">0</property>
<property name="LeftPadding">12</property>
<child>
- <widget class="Gtk.ComboBox" id="subcatcombobox">
+ <widget class="Gtk.CheckButton" id="taggoalcheckbutton">
<property name="MemberName" />
- <property name="IsTextCombo">False</property>
- <property name="Items" translatable="yes" />
- <signal name="Changed" handler="OnSubcatcomboboxChanged" />
+ <property name="CanFocus">True</property>
+ <property name="Label" translatable="yes">Enable</property>
+ <property name="DrawIndicator">True</property>
+ <property name="HasLabel">True</property>
+ <property name="UseUnderline">True</property>
+ <signal name="Clicked" handler="OnTaggoalcheckbuttonClicked" />
</widget>
</child>
</widget>
</child>
<child>
- <widget class="Gtk.Label" id="GtkLabel8">
+ <widget class="Gtk.Label" id="GtkLabel13">
<property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Subcategory
type</b></property>
+ <property name="LabelProp" translatable="yes"><b>Goal
Position</b></property>
<property name="UseMarkup">True</property>
</widget>
<packing>
@@ -1147,55 +977,57 @@ Sort by duration</property>
</child>
</widget>
<packing>
- <property name="Position">1</property>
+ <property name="Position">2</property>
<property name="AutoSize">False</property>
</packing>
</child>
+ </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.Table" id="table1">
+ <property name="MemberName" />
+ <property name="NColumns">3</property>
+ <property name="RowSpacing">6</property>
+ <property name="ColumnSpacing">6</property>
+ <child>
+ <placeholder />
+ </child>
<child>
- <widget class="Gtk.Button" id="addbutton">
- <property name="MemberName" />
- <property name="Sensitive">False</property>
- <property name="Tooltip" translatable="yes">Add this subcategory</property>
- <property name="CanFocus">True</property>
- <property name="Type">TextAndIcon</property>
- <property name="Icon">stock:gtk-add Menu</property>
- <property name="Label" translatable="yes">_Add subcategory</property>
- <property name="UseUnderline">True</property>
- <signal name="Clicked" handler="OnAddbuttonClicked" />
- </widget>
- <packing>
- <property name="Position">2</property>
- <property name="AutoSize">True</property>
- <property name="Expand">False</property>
- <property name="Fill">False</property>
- </packing>
+ <placeholder />
+ </child>
+ <child>
+ <placeholder />
</child>
</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="Position">1</property>
+ <property name="AutoSize">True</property>
+ </packing>
</child>
</widget>
</child>
- <child>
- <widget class="Gtk.Label" id="GtkLabel11">
- <property name="MemberName" />
- <property name="LabelProp" translatable="yes"><b>Subcategories</b></property>
- <property name="UseMarkup">True</property>
- </widget>
- <packing>
- <property name="type">label_item</property>
- </packing>
- </child>
+ </widget>
+ </child>
+ <child>
+ <widget class="Gtk.Label" id="GtkLabel6">
+ <property name="MemberName" />
+ <property name="LabelProp" translatable="yes"><b>Properties</b></property>
+ <property name="UseMarkup">True</property>
</widget>
<packing>
- <property name="Position">1</property>
- <property name="AutoSize">True</property>
+ <property name="type">label_item</property>
</packing>
</child>
</widget>
diff --git a/LongoMatch.GUI/gtk-gui/objects.xml b/LongoMatch.GUI/gtk-gui/objects.xml
index 087387a..e87fe76 100644
--- a/LongoMatch.GUI/gtk-gui/objects.xml
+++ b/LongoMatch.GUI/gtk-gui/objects.xml
@@ -71,15 +71,6 @@
<itemgroups />
<signals />
</object>
- <object type="LongoMatch.Gui.SubCategoriesTreeView" palette-category="General" allow-children="false"
base-type="Gtk.TreeView">
- <itemgroups />
- <signals>
- <itemgroup label="SubCategoriesTreeView Signals">
- <signal name="SubCategoriesDeleted" />
- <signal name="SubCategorySelected" />
- </itemgroup>
- </signals>
- </object>
<object type="LongoMatch.Gui.Component.RenderingStateBar" palette-category="General"
allow-children="false" base-type="Gtk.Bin">
<itemgroups>
<itemgroup label="IRenderingStateBar Properties">
@@ -148,10 +139,6 @@
</itemgroups>
<signals />
</object>
- <object type="LongoMatch.Gui.Component.Stats.SubCategoryViewer" palette-category="General"
allow-children="false" base-type="Gtk.Bin">
- <itemgroups />
- <signals />
- </object>
<object type="LongoMatch.Gui.Component.Stats.CategoriesViewer" palette-category="General"
allow-children="false" base-type="Gtk.Bin">
<itemgroups />
<signals />
@@ -305,6 +292,14 @@
</itemgroup>
</signals>
</object>
+ <object type="LongoMatch.Gui.Component.Stats.SubCategoryViewer" palette-category="General"
allow-children="false" base-type="Gtk.Bin">
+ <itemgroups />
+ <signals />
+ </object>
+ <object type="LongoMatch.Gui.SubCategoriesTreeView" palette-category="General" allow-children="false"
base-type="Gtk.TreeView">
+ <itemgroups />
+ <signals />
+ </object>
<object type="LongoMatch.Gui.CapturerBin" palette-category="General" allow-children="false"
base-type="Gtk.Bin">
<itemgroups>
<itemgroup label="CapturerBin Properties">
diff --git a/LongoMatch.Plugins/CSVExporter.cs b/LongoMatch.Plugins/CSVExporter.cs
index d1e8878..fb2c164 100644
--- a/LongoMatch.Plugins/CSVExporter.cs
+++ b/LongoMatch.Plugins/CSVExporter.cs
@@ -91,13 +91,8 @@ namespace LongoMatch.Plugins
/* Write Headers for this category */
headers = "Name;Start;Stop;Team";
- foreach (SubCategory subcat in cat.SubCategories) {
- if (subcat == null)
- continue;
-
- foreach (string desc in subcat.Options) {
- headers += String.Format (";{0}:{1}", subcat.Name, desc);
- }
+ foreach (Tag tag in cat.Tags) {
+ headers += String.Format (";{0}", tag.Value);
}
foreach (Play play in plays.OrderBy(p=>p.Start)) {
@@ -109,14 +104,8 @@ namespace LongoMatch.Plugins
play.Team);
/* Strings Tags */
- foreach (SubCategory subcat in cat.SubCategories) {
- if (subcat == null)
- continue;
-
- foreach (string desc in subcat.Options) {
- Tag t = new Tag{SubCategory=subcat, Value = desc};
- line += ";" + (play.Tags.Contains(t) ? "1" : "0");
- }
+ foreach (Tag tag in cat.Tags) {
+ line += ";" + (play.Tags.Contains(tag) ? "1" : "0");
}
output.Add (line);
diff --git a/Tests/Core/TestCategory.cs b/Tests/Core/TestCategory.cs
index a39b31f..8e8bb1d 100644
--- a/Tests/Core/TestCategory.cs
+++ b/Tests/Core/TestCategory.cs
@@ -22,6 +22,7 @@ using Newtonsoft.Json;
using LongoMatch.Common;
using LongoMatch.Store;
using System.IO;
+using System.Collections.Generic;
namespace Tests.Core
{
@@ -44,14 +45,13 @@ namespace Tests.Core
cat.SortMethod = SortMethodType.SortByDuration;
cat.Start = new Time (3000);
cat.Stop = new Time (4000);
- cat.SubCategories = null;
+ cat.Tags = new List<Tag>();
+ cat.Tags.Add (new Tag ("foo", "bar"));
cat.TagFieldPosition = true;
cat.TagGoalPosition = true;
cat.TagHalfFieldPosition = true;
cat.FieldPositionIsDistance = true;
cat.HalfFieldPositionIsDistance = false;
- cat.SubCategories = new System.Collections.Generic.List<SubCategory>();
- cat.SubCategories.Add (new SubCategory {Name="TestSubcat"});
Utils.CheckSerialization (cat);
@@ -79,17 +79,9 @@ namespace Tests.Core
Assert.AreEqual (255, newcat.Color.R);
Assert.AreEqual (0, newcat.Color.G);
Assert.AreEqual (0, newcat.Color.B);
- Assert.AreEqual (newcat.SubCategories.Count, 1);
- Assert.AreEqual (newcat.SubCategories[0].Name, "TestSubcat");
- }
-
- [Test()]
- public void TestNullList ()
- {
- Category cat = new Category();
- Assert.AreNotEqual (cat.SubCategories, null);
- Category newcat = Utils.SerializeDeserialize (cat);
- Assert.AreNotEqual (newcat.SubCategories, null);
+ Assert.AreEqual (newcat.Tags.Count, 1);
+ Assert.AreEqual (newcat.Tags[0].Value, "foo");
+ Assert.AreEqual (newcat.Tags[0].Group, "bar");
}
public static void Main (string [] args)
diff --git a/Tests/Core/TestPlay.cs b/Tests/Core/TestPlay.cs
index c991e9a..d40ff35 100644
--- a/Tests/Core/TestPlay.cs
+++ b/Tests/Core/TestPlay.cs
@@ -47,7 +47,7 @@ namespace Tests.Core
play.Stop = new Time(2000);
play.Rate = 2.3f;
- play.Tags.Add(new Tag {Value = "test"});
+ play.Tags.Add(new Tag ("test"));
return play;
}
@@ -62,7 +62,6 @@ namespace Tests.Core
Assert.AreEqual (p.Category.ID, newp.Category.ID);
Assert.AreEqual (p.Notes, newp.Notes);
- Assert.AreEqual (p.Fps, newp.Fps);
Assert.AreEqual (p.Team, newp.Team);
Assert.AreEqual (p.FieldPosition, newp.FieldPosition);
Assert.AreEqual (p.HalfFieldPosition, newp.HalfFieldPosition);
diff --git a/Tests/Tests.mdp b/Tests/Tests.mdp
index 7b0d1be..dd349bb 100644
--- a/Tests/Tests.mdp
+++ b/Tests/Tests.mdp
@@ -25,8 +25,6 @@
<File subtype="Code" buildaction="Compile" name="Core/TestPoint.cs" />
<File subtype="Code" buildaction="Compile" name="Core/TestProject.cs" />
<File subtype="Code" buildaction="Compile" name="Core/TestProjectDescription.cs" />
- <File subtype="Code" buildaction="Compile" name="Core/TestSubCategory.cs" />
- <File subtype="Code" buildaction="Compile" name="Core/TestTagStore.cs" />
<File subtype="Code" buildaction="Compile" name="Core/TestTimeNode.cs" />
<File subtype="Code" buildaction="Compile" name="Core/TestCategoriesTemplate.cs" />
<File subtype="Code" buildaction="Compile" name="Core/TestTeamTemplate.cs" />
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]