[longomatch] Show coordinates tags in stats



commit a7dd56f2aed1ded494f4d281f9da9e49518cdf86
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Mon Jul 29 21:33:37 2013 +0200

    Show coordinates tags in stats

 LongoMatch.Core/Stats/CategoryStats.cs             |   49 +++++++
 LongoMatch.Core/Stats/ProjectStats.cs              |   30 +++-
 LongoMatch.GUI/Gui/Component/CoordinatesTagger.cs  |   17 +++
 .../Gui/Component/PlaysCoordinatesTagger.cs        |   50 +++++---
 .../Gui/Component/Stats/CategoryViewer.cs          |   13 ++-
 LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs          |    6 +-
 LongoMatch.GUI/Gui/MainWindow.cs                   |    5 +-
 .../LongoMatch.Gui.Component.CategoryProperties.cs |    6 +
 .../gtk-gui/LongoMatch.Gui.Component.GameViewer.cs |    1 +
 .../gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs  |   55 +++++---
 LongoMatch.GUI/gtk-gui/gui.stetic                  |  139 +++++++++++---------
 LongoMatch.GUI/gtk-gui/objects.xml                 |    6 +-
 12 files changed, 262 insertions(+), 115 deletions(-)
---
diff --git a/LongoMatch.Core/Stats/CategoryStats.cs b/LongoMatch.Core/Stats/CategoryStats.cs
index 5c52c0e..943e16b 100644
--- a/LongoMatch.Core/Stats/CategoryStats.cs
+++ b/LongoMatch.Core/Stats/CategoryStats.cs
@@ -20,6 +20,7 @@ using System.Collections.Generic;
 
 using LongoMatch.Interfaces;
 using LongoMatch.Store;
+using LongoMatch.Common;
 
 namespace LongoMatch.Stats
 {
@@ -47,6 +48,54 @@ namespace LongoMatch.Stats
                        }
                }
                
+               public Image Field {
+                       get; set;
+               }
+               
+               public Image HalfField {
+                       get; set;
+               }
+               
+               public Image Goal {
+                       get; set;
+               }
+               
+               public List<Coordinates> FieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> HalfFieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> GoalCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> HomeFieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> HomeHalfFieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> HomeGoalCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> AwayFieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> AwayHalfFieldCoordinates {
+                       get; set;
+               }
+               
+               public List<Coordinates> AwayGoalCoordinates {
+                       get; set;
+               }
+               
                public void AddSubcatStat (SubCategoryStat subcatStat) {
                        subcatStats.Add(subcatStat);
                }
diff --git a/LongoMatch.Core/Stats/ProjectStats.cs b/LongoMatch.Core/Stats/ProjectStats.cs
index 4975ef5..1107be3 100644
--- a/LongoMatch.Core/Stats/ProjectStats.cs
+++ b/LongoMatch.Core/Stats/ProjectStats.cs
@@ -93,26 +93,40 @@ namespace LongoMatch.Stats
                        }
                }
                
-               void CountPlaysInTeam (List<Play> plays, out int localTeamCount, out int visitorTeamCount) {
-                       localTeamCount = plays.Where(p => p.Team == Team.LOCAL || p.Team == 
Team.BOTH).Count();
-                       visitorTeamCount = plays.Where(p => p.Team == Team.VISITOR || p.Team == 
Team.BOTH).Count();
-               }
-               
                void UpdateGameUnitsStats (Project project) {
                        guStats = new GameUnitsStats(project.GameUnits, (int)project.Description.File.Length);
                }
                
+               void CountPlaysInTeam (List<Play> plays, out int localTeamCount, out int visitorTeamCount) {
+                       localTeamCount = plays.Where(p => p.Team == Team.LOCAL || p.Team == 
Team.BOTH).Count();
+                       visitorTeamCount = plays.Where(p => p.Team == Team.VISITOR || p.Team == 
Team.BOTH).Count();
+               }
+
                void UpdateStats (Project project) {
                        catStats.Clear();
                        
                        foreach (Category cat in project.Categories) {
                                CategoryStats stats;
-                               List<Play> plays;
+                               List<Play> plays, homePlays, awayPlays;
                                int localTeamCount, visitorTeamCount;
                                
                                plays = project.PlaysInCategory (cat);
-                               CountPlaysInTeam(plays, out localTeamCount, out visitorTeamCount);
-                               stats = new CategoryStats(cat, plays.Count, localTeamCount, visitorTeamCount);
+                               homePlays =plays.Where(p => p.Team == Team.LOCAL || p.Team == 
Team.BOTH).ToList();
+                               awayPlays =plays.Where(p => p.Team == Team.VISITOR || p.Team == 
Team.BOTH).ToList();
+                               stats = new CategoryStats(cat, plays.Count, homePlays.Count(), 
awayPlays.Count());
+                               /* Fill zonal tagging stats */
+                               stats.Field = project.Categories.FieldBackgroundImage;
+                               stats.HalfField = project.Categories.HalfFieldBackgroundImage;
+                               stats.Goal = project.Categories.GoalBackgroundImage;
+                               stats.FieldCoordinates = plays.Select (p => p.FieldPosition).ToList();
+                               stats.HalfFieldCoordinates = plays.Select (p => p.HalfFieldPosition).ToList();
+                               stats.GoalCoordinates = plays.Select (p => p.GoalPosition).ToList();
+                               stats.HomeFieldCoordinates = homePlays.Select (p => p.FieldPosition).ToList();
+                               stats.HomeHalfFieldCoordinates = homePlays.Select (p => 
p.HalfFieldPosition).ToList();
+                               stats.HomeGoalCoordinates = homePlays.Select (p => p.GoalPosition).ToList();
+                               stats.AwayFieldCoordinates = awayPlays.Select (p => p.FieldPosition).ToList();
+                               stats.AwayHalfFieldCoordinates = awayPlays.Select (p => 
p.HalfFieldPosition).ToList();
+                               stats.AwayGoalCoordinates = awayPlays.Select (p => p.GoalPosition).ToList();
                                catStats.Add (stats);
                                
                                foreach (ISubCategory subcat in cat.SubCategories) {
diff --git a/LongoMatch.GUI/Gui/Component/CoordinatesTagger.cs 
b/LongoMatch.GUI/Gui/Component/CoordinatesTagger.cs
index aafa9f2..5d4880c 100644
--- a/LongoMatch.GUI/Gui/Component/CoordinatesTagger.cs
+++ b/LongoMatch.GUI/Gui/Component/CoordinatesTagger.cs
@@ -52,15 +52,23 @@ namespace LongoMatch.Gui.Component
                        drawingarea.MotionNotifyEvent += OnDrawingareaMotionNotifyEvent;
                        HeightRequest = 100;
                        WidthRequest = 100;
+                       Sensitive = true;
                }
                
                ~CoordinatesTagger() {
                        if (source != null)
                                source.Destroy();
                }
+               
+               public new bool Sensitive {
+                       get;
+                       set;
+               }
 
                public Pixbuf Background {
                        set {
+                               if (value == null || value.Width == -1 || value.Height == -1)
+                                       return;
                                sourceWidth = value.Width;
                                sourceHeight = value.Height;
                                sourceDAR = (double) sourceWidth / sourceHeight;
@@ -188,6 +196,9 @@ namespace LongoMatch.Gui.Component
                
                protected virtual void OnDrawingareaButtonPressEvent(object o, Gtk.ButtonPressEventArgs args)
                {
+                       if (!Sensitive)
+                               return;
+                               
                        FindNearestPoint (new Point((int) args.Event.X, (int) args.Event.Y),
                                          out selectedCoords, out selectedPoint);
 
@@ -196,6 +207,9 @@ namespace LongoMatch.Gui.Component
 
                protected virtual void OnDrawingareaButtonReleaseEvent(object o, Gtk.ButtonReleaseEventArgs 
args)
                {
+                       if (!Sensitive)
+                               return;
+                               
                        selectedCoords = null;
                        QueueDraw ();
                }
@@ -204,6 +218,9 @@ namespace LongoMatch.Gui.Component
                {
                        Point point;
                        
+                       if (!Sensitive)
+                               return;
+                               
                        if (selectedCoords == null) {
                                return;
                        }
diff --git a/LongoMatch.GUI/Gui/Component/PlaysCoordinatesTagger.cs 
b/LongoMatch.GUI/Gui/Component/PlaysCoordinatesTagger.cs
index 13ca6fd..602668b 100644
--- a/LongoMatch.GUI/Gui/Component/PlaysCoordinatesTagger.cs
+++ b/LongoMatch.GUI/Gui/Component/PlaysCoordinatesTagger.cs
@@ -25,6 +25,7 @@ using LongoMatch.Store.Templates;
 using LongoMatch.Common;
 
 using Point = LongoMatch.Common.Point;
+using Image = LongoMatch.Common.Image;
 
 namespace LongoMatch.Gui.Component
 {
@@ -41,6 +42,14 @@ namespace LongoMatch.Gui.Component
                        SetMode (true);
                }
                
+               public bool CoordinatesSensitive {
+                       set {
+                               field.Sensitive = value;
+                               hfield.Sensitive = value;
+                               goal.Sensitive = value;
+                       }
+               }
+               
                public void SetMode (bool horizontal) {
                        if (box != null) {
                                mainbox.Remove (box);
@@ -61,35 +70,40 @@ namespace LongoMatch.Gui.Component
                        ShowAll ();
                }
                
-               public void LoadPlays (List<Play> plays, Categories template, bool horizontal=true) {
-                       field.Visible = hfield.Visible = goal.Visible = false;
-                       SetBackgrounds (template);
-                       foreach (Play play in plays) {
-                               AddPlay (play, false);
-                       }
-               }
-               
-               public void LoadPlay (Play play, Categories template, bool horizontal=true) {
+               public void LoadPlay (Play play, bool horizontal=true) {
                        field.Visible = hfield.Visible = goal.Visible = false;
                        
-                       SetBackgrounds (template);
                        AddPlay (play, true);
-                       
+               }
+               
+               public void LoadFieldCoordinates (List<Coordinates> coords) {
+                       field.Coordinates = coords;
+                       field.Visible = coords.Count != 0;
                }
 
-               void SetBackgrounds (Categories template) {
-                       if (template.FieldBackgroundImage != null) {
-                               field.Background = template.FieldBackgroundImage.Value;
+               public void LoadHalfFieldCoordinates (List<Coordinates> coords) {
+                       hfield.Coordinates = coords;
+                       hfield.Visible = coords.Count != 0;
+               }
+               
+               public void LoadGoalCoordinates (List<Coordinates> coords) {
+                       goal.Coordinates = coords;
+                       goal.Visible = coords.Count != 0;
+               }
+               
+               public void LoadBackgrounds (Image fieldImage, Image halfFieldImage, Image goalImage) {
+                       if (fieldImage != null) {
+                               field.Background = fieldImage.Value;
                        } else {
                                field.Background = Gdk.Pixbuf.LoadFromResource (Constants.FIELD_BACKGROUND);
                        }
-                       if (template.HalfFieldBackgroundImage != null) {
-                               hfield.Background = template.HalfFieldBackgroundImage.Value;
+                       if (halfFieldImage != null) {
+                               hfield.Background = halfFieldImage.Value;
                        } else {
                                hfield.Background = Gdk.Pixbuf.LoadFromResource 
(Constants.HALF_FIELD_BACKGROUND);
                        }
-                       if (template.GoalBackgroundImage != null) {
-                               goal.Background = template.GoalBackgroundImage.Value;
+                       if (goalImage != null) {
+                               goal.Background = goalImage.Value;
                        } else {
                                goal.Background = Gdk.Pixbuf.LoadFromResource (Constants.GOAL_BACKGROUND);
                        }
diff --git a/LongoMatch.GUI/Gui/Component/Stats/CategoryViewer.cs 
b/LongoMatch.GUI/Gui/Component/Stats/CategoryViewer.cs
index ac75216..be836d5 100644
--- a/LongoMatch.GUI/Gui/Component/Stats/CategoryViewer.cs
+++ b/LongoMatch.GUI/Gui/Component/Stats/CategoryViewer.cs
@@ -35,14 +35,19 @@ namespace LongoMatch.Gui.Component.Stats
                public void LoadStats (CategoryStats stats) {
                        PlaysCoordinatesTagger tagger;
                        
-                       tagger = new PlaysCoordinatesTagger();
-                       vbox1.PackStart (tagger);
-                       subcatViewers = new List<SubCategoryViewer>();
-                                               
                        foreach (Widget child in vbox1.AllChildren) {
                                vbox1.Remove (child);
                        }
                        
+                       tagger = new PlaysCoordinatesTagger();
+                       tagger.LoadBackgrounds (stats.Field, stats.HalfField, stats.Goal);
+                       tagger.LoadFieldCoordinates (stats.FieldCoordinates);
+                       tagger.LoadHalfFieldCoordinates (stats.HalfFieldCoordinates);
+                       tagger.LoadGoalCoordinates (stats.GoalCoordinates);
+                       tagger.CoordinatesSensitive = false;
+                       vbox1.PackStart (tagger);
+                       subcatViewers = new List<SubCategoryViewer>();
+                                               
                        foreach (SubCategoryStat st in stats.SubcategoriesStats) {
                                SubCategoryViewer subcatviewer = new SubCategoryViewer();
                                subcatviewer.LoadStats (st);
diff --git a/LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs b/LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs
index 33272f5..79be02f 100644
--- a/LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs
+++ b/LongoMatch.GUI/Gui/Dialog/TaggerDialog.cs
@@ -19,6 +19,7 @@
 using System;
 using System.Linq;
 using System.Collections.Generic;
+using Gdk;
 
 using LongoMatch.Common;
 using LongoMatch.Gui.Component;
@@ -77,7 +78,10 @@ namespace LongoMatch.Gui.Dialog
                                coordstagger.Visible = false;
                                (mainvbox[hbox] as Gtk.Box.BoxChild).Expand = true;
                        } else {
-                               coordstagger.LoadPlay (play, categoriesTemplate);
+                               coordstagger.LoadBackgrounds (categoriesTemplate.FieldBackgroundImage,
+                                                             categoriesTemplate.HalfFieldBackgroundImage,
+                                                             categoriesTemplate.GoalBackgroundImage);
+                               coordstagger.LoadPlay (play);
                        }
                        
                        if (subcategoryAdded || playersnotebook.Visible) {
diff --git a/LongoMatch.GUI/Gui/MainWindow.cs b/LongoMatch.GUI/Gui/MainWindow.cs
index fc68eb0..873b87c 100644
--- a/LongoMatch.GUI/Gui/MainWindow.cs
+++ b/LongoMatch.GUI/Gui/MainWindow.cs
@@ -167,7 +167,10 @@ namespace LongoMatch.Gui
                public void UpdateSelectedPlay (Play play) {
                        selectedTimeNode = play;
                        timeline.SelectedTimeNode = play;
-                       postagger.LoadPlay (play, openedProject.Categories, false);
+                       postagger.LoadBackgrounds (openedProject.Categories.FieldBackgroundImage,
+                                                  openedProject.Categories.HalfFieldBackgroundImage,
+                                                  openedProject.Categories.GoalBackgroundImage);
+                       postagger.LoadPlay (play, false);
                        SetTagsBoxVisibility (true);
                        notes.Play= play;
                }
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs 
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
index e33603b..93d05b0 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.CategoryProperties.cs
@@ -408,21 +408,27 @@ namespace LongoMatch.Gui.Component
                        this.table3.ColumnSpacing = ((uint)(6));
                        // Container child table3.Gtk.Table+TableChild
                        this.fieldcoordinatestagger = new global::LongoMatch.Gui.Component.CoordinatesTagger 
();
+                       this.fieldcoordinatestagger.Sensitive = false;
                        this.fieldcoordinatestagger.Events = ((global::Gdk.EventMask)(256));
                        this.fieldcoordinatestagger.Name = "fieldcoordinatestagger";
+                       this.fieldcoordinatestagger.Sensitive = false;
                        this.table3.Add (this.fieldcoordinatestagger);
                        // Container child table3.Gtk.Table+TableChild
                        this.goalcoordinatestagger = new global::LongoMatch.Gui.Component.CoordinatesTagger 
();
+                       this.goalcoordinatestagger.Sensitive = false;
                        this.goalcoordinatestagger.Events = ((global::Gdk.EventMask)(256));
                        this.goalcoordinatestagger.Name = "goalcoordinatestagger";
+                       this.goalcoordinatestagger.Sensitive = false;
                        this.table3.Add (this.goalcoordinatestagger);
                        global::Gtk.Table.TableChild w31 = ((global::Gtk.Table.TableChild)(this.table3 
[this.goalcoordinatestagger]));
                        w31.LeftAttach = ((uint)(2));
                        w31.RightAttach = ((uint)(3));
                        // Container child table3.Gtk.Table+TableChild
                        this.halffieldcoordinatestagger = new 
global::LongoMatch.Gui.Component.CoordinatesTagger ();
+                       this.halffieldcoordinatestagger.Sensitive = false;
                        this.halffieldcoordinatestagger.Events = ((global::Gdk.EventMask)(256));
                        this.halffieldcoordinatestagger.Name = "halffieldcoordinatestagger";
+                       this.halffieldcoordinatestagger.Sensitive = false;
                        this.table3.Add (this.halffieldcoordinatestagger);
                        global::Gtk.Table.TableChild w32 = ((global::Gtk.Table.TableChild)(this.table3 
[this.halffieldcoordinatestagger]));
                        w32.LeftAttach = ((uint)(1));
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.GameViewer.cs 
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.GameViewer.cs
index 9a2f7c5..6441022 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.GameViewer.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Component.GameViewer.cs
@@ -54,6 +54,7 @@ namespace LongoMatch.Gui.Component
                        this.topbox.Add (this.subcatscheckbutton);
                        global::Gtk.Box.BoxChild w3 = ((global::Gtk.Box.BoxChild)(this.topbox 
[this.subcatscheckbutton]));
                        w3.Position = 2;
+                       w3.Fill = false;
                        // Container child topbox.Gtk.Box+BoxChild
                        this.awaylabel = new global::Gtk.Label ();
                        this.awaylabel.Name = "awaylabel";
diff --git a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs 
b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
index f57d5e3..d251154 100644
--- a/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
+++ b/LongoMatch.GUI/gtk-gui/LongoMatch.Gui.Dialog.TaggerDialog.cs
@@ -4,6 +4,7 @@ namespace LongoMatch.Gui.Dialog
 {
        public partial class TaggerDialog
        {
+               private global::Gtk.ScrolledWindow scrolledwindow3;
                private global::Gtk.VBox mainvbox;
                private global::Gtk.HBox hbox;
                private global::Gtk.Notebook tagsnotebook;
@@ -28,6 +29,14 @@ namespace LongoMatch.Gui.Dialog
                        w1.Name = "dialog1_VBox";
                        w1.BorderWidth = ((uint)(2));
                        // Container child dialog1_VBox.Gtk.Box+BoxChild
+                       this.scrolledwindow3 = new global::Gtk.ScrolledWindow ();
+                       this.scrolledwindow3.CanFocus = true;
+                       this.scrolledwindow3.Name = "scrolledwindow3";
+                       this.scrolledwindow3.ShadowType = ((global::Gtk.ShadowType)(1));
+                       // Container child scrolledwindow3.Gtk.Container+ContainerChild
+                       global::Gtk.Viewport w2 = new global::Gtk.Viewport ();
+                       w2.ShadowType = ((global::Gtk.ShadowType)(0));
+                       // Container child GtkViewport.Gtk.Container+ContainerChild
                        this.mainvbox = new global::Gtk.VBox ();
                        this.mainvbox.Name = "mainvbox";
                        // Container child mainvbox.Gtk.Box+BoxChild
@@ -51,8 +60,8 @@ namespace LongoMatch.Gui.Dialog
                        this.tagsnotebook.SetTabLabel (this.taggerwidget1, this.label1);
                        this.label1.ShowAll ();
                        this.hbox.Add (this.tagsnotebook);
-                       global::Gtk.Box.BoxChild w3 = ((global::Gtk.Box.BoxChild)(this.hbox 
[this.tagsnotebook]));
-                       w3.Position = 0;
+                       global::Gtk.Box.BoxChild w4 = ((global::Gtk.Box.BoxChild)(this.hbox 
[this.tagsnotebook]));
+                       w4.Position = 0;
                        // Container child hbox.Gtk.Box+BoxChild
                        this.playersnotebook = new global::Gtk.Notebook ();
                        this.playersnotebook.CanFocus = true;
@@ -70,28 +79,30 @@ namespace LongoMatch.Gui.Dialog
                        this.playersnotebook.SetTabLabel (this.playersbox, this.label2);
                        this.label2.ShowAll ();
                        this.hbox.Add (this.playersnotebook);
-                       global::Gtk.Box.BoxChild w5 = ((global::Gtk.Box.BoxChild)(this.hbox 
[this.playersnotebook]));
-                       w5.Position = 1;
+                       global::Gtk.Box.BoxChild w6 = ((global::Gtk.Box.BoxChild)(this.hbox 
[this.playersnotebook]));
+                       w6.Position = 1;
                        this.mainvbox.Add (this.hbox);
-                       global::Gtk.Box.BoxChild w6 = ((global::Gtk.Box.BoxChild)(this.mainvbox [this.hbox]));
-                       w6.Position = 0;
-                       w6.Expand = false;
+                       global::Gtk.Box.BoxChild w7 = ((global::Gtk.Box.BoxChild)(this.mainvbox [this.hbox]));
+                       w7.Position = 0;
+                       w7.Expand = false;
                        // Container child mainvbox.Gtk.Box+BoxChild
                        this.coordstagger = new global::LongoMatch.Gui.Component.PlaysCoordinatesTagger ();
                        this.coordstagger.Events = ((global::Gdk.EventMask)(256));
                        this.coordstagger.Name = "coordstagger";
                        this.mainvbox.Add (this.coordstagger);
-                       global::Gtk.Box.BoxChild w7 = ((global::Gtk.Box.BoxChild)(this.mainvbox 
[this.coordstagger]));
-                       w7.Position = 1;
-                       w1.Add (this.mainvbox);
-                       global::Gtk.Box.BoxChild w8 = ((global::Gtk.Box.BoxChild)(w1 [this.mainvbox]));
-                       w8.Position = 0;
+                       global::Gtk.Box.BoxChild w8 = ((global::Gtk.Box.BoxChild)(this.mainvbox 
[this.coordstagger]));
+                       w8.Position = 1;
+                       w2.Add (this.mainvbox);
+                       this.scrolledwindow3.Add (w2);
+                       w1.Add (this.scrolledwindow3);
+                       global::Gtk.Box.BoxChild w11 = ((global::Gtk.Box.BoxChild)(w1 
[this.scrolledwindow3]));
+                       w11.Position = 0;
                        // Internal child LongoMatch.Gui.Dialog.TaggerDialog.ActionArea
-                       global::Gtk.HButtonBox w9 = this.ActionArea;
-                       w9.Name = "dialog1_ActionArea";
-                       w9.Spacing = 6;
-                       w9.BorderWidth = ((uint)(5));
-                       w9.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4));
+                       global::Gtk.HButtonBox w12 = this.ActionArea;
+                       w12.Name = "dialog1_ActionArea";
+                       w12.Spacing = 6;
+                       w12.BorderWidth = ((uint)(5));
+                       w12.LayoutStyle = ((global::Gtk.ButtonBoxStyle)(4));
                        // Container child dialog1_ActionArea.Gtk.ButtonBox+ButtonBoxChild
                        this.buttonOk = new global::Gtk.Button ();
                        this.buttonOk.CanDefault = true;
@@ -101,14 +112,14 @@ namespace LongoMatch.Gui.Dialog
                        this.buttonOk.UseUnderline = true;
                        this.buttonOk.Label = "gtk-ok";
                        this.AddActionWidget (this.buttonOk, -5);
-                       global::Gtk.ButtonBox.ButtonBoxChild w10 = ((global::Gtk.ButtonBox.ButtonBoxChild)(w9 
[this.buttonOk]));
-                       w10.Expand = false;
-                       w10.Fill = false;
+                       global::Gtk.ButtonBox.ButtonBoxChild w13 = 
((global::Gtk.ButtonBox.ButtonBoxChild)(w12 [this.buttonOk]));
+                       w13.Expand = false;
+                       w13.Fill = false;
                        if ((this.Child != null)) {
                                this.Child.ShowAll ();
                        }
-                       this.DefaultWidth = 644;
-                       this.DefaultHeight = 569;
+                       this.DefaultWidth = 1073;
+                       this.DefaultHeight = 709;
                        this.Show ();
                }
        }
diff --git a/LongoMatch.GUI/gtk-gui/gui.stetic b/LongoMatch.GUI/gtk-gui/gui.stetic
index 58b83e6..4888d1b 100644
--- a/LongoMatch.GUI/gtk-gui/gui.stetic
+++ b/LongoMatch.GUI/gtk-gui/gui.stetic
@@ -2668,7 +2668,9 @@ Sort by duration</property>
                             <child>
                               <widget class="LongoMatch.Gui.Component.CoordinatesTagger" 
id="fieldcoordinatestagger">
                                 <property name="MemberName" />
+                                <property name="Sensitive">False</property>
                                 <property name="Events">ButtonPressMask</property>
+                                <property name="Sensitive">False</property>
                               </widget>
                               <packing>
                                 <property name="AutoSize">True</property>
@@ -2683,7 +2685,9 @@ Sort by duration</property>
                             <child>
                               <widget class="LongoMatch.Gui.Component.CoordinatesTagger" 
id="goalcoordinatestagger">
                                 <property name="MemberName" />
+                                <property name="Sensitive">False</property>
                                 <property name="Events">ButtonPressMask</property>
+                                <property name="Sensitive">False</property>
                               </widget>
                               <packing>
                                 <property name="LeftAttach">2</property>
@@ -2700,7 +2704,9 @@ Sort by duration</property>
                             <child>
                               <widget class="LongoMatch.Gui.Component.CoordinatesTagger" 
id="halffieldcoordinatestagger">
                                 <property name="MemberName" />
+                                <property name="Sensitive">False</property>
                                 <property name="Events">ButtonPressMask</property>
+                                <property name="Sensitive">False</property>
                               </widget>
                               <packing>
                                 <property name="LeftAttach">1</property>
@@ -5659,89 +5665,102 @@ Show-&gt;&lt;b&gt; S&lt;/b&gt;
         <property name="MemberName" />
         <property name="BorderWidth">2</property>
         <child>
-          <widget class="Gtk.VBox" id="mainvbox">
+          <widget class="Gtk.ScrolledWindow" id="scrolledwindow3">
             <property name="MemberName" />
+            <property name="CanFocus">True</property>
+            <property name="ShadowType">In</property>
             <child>
-              <widget class="Gtk.HBox" id="hbox">
+              <widget class="Gtk.Viewport" id="GtkViewport">
                 <property name="MemberName" />
-                <property name="Spacing">6</property>
-                <child>
-                  <widget class="Gtk.Notebook" id="tagsnotebook">
-                    <property name="MemberName" />
-                    <property name="CanFocus">True</property>
-                    <property name="CurrentPage">0</property>
-                    <child>
-                      <widget class="LongoMatch.Gui.Component.TaggerWidget" id="taggerwidget1">
-                        <property name="MemberName" />
-                        <property name="Events">ButtonPressMask</property>
-                      </widget>
-                    </child>
-                    <child>
-                      <widget class="Gtk.Label" id="label1">
-                        <property name="MemberName" />
-                        <property name="LabelProp" translatable="yes">Tags</property>
-                      </widget>
-                      <packing>
-                        <property name="type">tab</property>
-                      </packing>
-                    </child>
-                  </widget>
-                  <packing>
-                    <property name="Position">0</property>
-                    <property name="AutoSize">False</property>
-                  </packing>
-                </child>
+                <property name="ShadowType">None</property>
                 <child>
-                  <widget class="Gtk.Notebook" id="playersnotebook">
+                  <widget class="Gtk.VBox" id="mainvbox">
                     <property name="MemberName" />
-                    <property name="CanFocus">True</property>
-                    <property name="CurrentPage">0</property>
                     <child>
-                      <widget class="Gtk.VBox" id="playersbox">
+                      <widget class="Gtk.HBox" id="hbox">
                         <property name="MemberName" />
                         <property name="Spacing">6</property>
                         <child>
-                          <placeholder />
-                        </child>
-                        <child>
-                          <placeholder />
+                          <widget class="Gtk.Notebook" id="tagsnotebook">
+                            <property name="MemberName" />
+                            <property name="CanFocus">True</property>
+                            <property name="CurrentPage">0</property>
+                            <child>
+                              <widget class="LongoMatch.Gui.Component.TaggerWidget" id="taggerwidget1">
+                                <property name="MemberName" />
+                                <property name="Events">ButtonPressMask</property>
+                              </widget>
+                            </child>
+                            <child>
+                              <widget class="Gtk.Label" id="label1">
+                                <property name="MemberName" />
+                                <property name="LabelProp" translatable="yes">Tags</property>
+                              </widget>
+                              <packing>
+                                <property name="type">tab</property>
+                              </packing>
+                            </child>
+                          </widget>
+                          <packing>
+                            <property name="Position">0</property>
+                            <property name="AutoSize">False</property>
+                          </packing>
                         </child>
                         <child>
-                          <placeholder />
+                          <widget class="Gtk.Notebook" id="playersnotebook">
+                            <property name="MemberName" />
+                            <property name="CanFocus">True</property>
+                            <property name="CurrentPage">0</property>
+                            <child>
+                              <widget class="Gtk.VBox" id="playersbox">
+                                <property name="MemberName" />
+                                <property name="Spacing">6</property>
+                                <child>
+                                  <placeholder />
+                                </child>
+                                <child>
+                                  <placeholder />
+                                </child>
+                                <child>
+                                  <placeholder />
+                                </child>
+                              </widget>
+                            </child>
+                            <child>
+                              <widget class="Gtk.Label" id="label2">
+                                <property name="MemberName" />
+                                <property name="LabelProp" translatable="yes">Players</property>
+                              </widget>
+                              <packing>
+                                <property name="type">tab</property>
+                              </packing>
+                            </child>
+                          </widget>
+                          <packing>
+                            <property name="Position">1</property>
+                            <property name="AutoSize">True</property>
+                          </packing>
                         </child>
                       </widget>
+                      <packing>
+                        <property name="Position">0</property>
+                        <property name="AutoSize">False</property>
+                        <property name="Expand">False</property>
+                      </packing>
                     </child>
                     <child>
-                      <widget class="Gtk.Label" id="label2">
+                      <widget class="LongoMatch.Gui.Component.PlaysCoordinatesTagger" id="coordstagger">
                         <property name="MemberName" />
-                        <property name="LabelProp" translatable="yes">Players</property>
+                        <property name="Events">ButtonPressMask</property>
                       </widget>
                       <packing>
-                        <property name="type">tab</property>
+                        <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>
-              <packing>
-                <property name="Position">0</property>
-                <property name="AutoSize">False</property>
-                <property name="Expand">False</property>
-              </packing>
-            </child>
-            <child>
-              <widget class="LongoMatch.Gui.Component.PlaysCoordinatesTagger" id="coordstagger">
-                <property name="MemberName" />
-                <property name="Events">ButtonPressMask</property>
-              </widget>
-              <packing>
-                <property name="Position">1</property>
-                <property name="AutoSize">True</property>
-              </packing>
             </child>
           </widget>
           <packing>
diff --git a/LongoMatch.GUI/gtk-gui/objects.xml b/LongoMatch.GUI/gtk-gui/objects.xml
index a808414..fc08eef 100644
--- a/LongoMatch.GUI/gtk-gui/objects.xml
+++ b/LongoMatch.GUI/gtk-gui/objects.xml
@@ -309,7 +309,11 @@
     <signals />
   </object>
   <object type="LongoMatch.Gui.Component.CoordinatesTagger" palette-category="General" 
allow-children="false" base-type="Gtk.Bin">
-    <itemgroups />
+    <itemgroups>
+      <itemgroup label="CoordinatesTagger Properties">
+        <property name="Sensitive" />
+      </itemgroup>
+    </itemgroups>
     <signals />
   </object>
   <object type="LongoMatch.Gui.Component.GeneralPreferencesPanel" palette-category="General" 
allow-children="false" base-type="Gtk.Bin">


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