public EditCategoryDialog(ProjectLongoMatch project, DashboardButton tagger, Window parent) { TransientFor = parent; this.Build (); timenodeproperties2.Tagger = tagger; timenodeproperties2.Dashboard = project.Dashboard; }
public void TestSerialization() { DashboardButton db = new DashboardButton (); Utils.CheckSerialization (db); db = new PenaltyCardButton (); Utils.CheckSerialization (db); db = new PenaltyCardButton (); Utils.CheckSerialization (db); db = new ScoreButton (); Utils.CheckSerialization (db); }
void RemoveButton(DashboardButton button) { string msg = Catalog.GetString ("Do you want to delete: ") + button.Name + "?"; if (Config.GUIToolkit.QuestionMessage (msg, null, this)) { template.RemoveButton (button); Edited = true; Refresh (); } }
void HandleTaggersSelectedEvent(List<DashboardButton> taggers) { if (taggers.Count == 1) { selected = taggers [0]; tagproperties.Tagger = taggers [0]; propertiesnotebook.Page = PROPERTIES_NOTEBOOK_PAGE_TAGS; } else { selected = null; tagproperties.Tagger = null; propertiesnotebook.Page = PROPERTIES_NOTEBOOK_PAGE_EMPTY; } }
void HandleNewTagEvent(EventType evntType, List<Player> players, TeamType team, List<Tag> tags, Time start, Time stop, Time eventTime, Score score, PenaltyCard card, DashboardButton btn) { /* Forward event until we have players integrted in the dashboard layout */ if (NewTagEvent != null) { NewTagEvent (evntType, players, team, tags, start, stop, eventTime, score, card, btn); } //Config.EventsBroker.EmitNewTag (button, players, tags, start, stop); }
void EditEventSubcategories(DashboardButton dashboardButton) { AnalysisEventButton button = (dashboardButton as AnalysisEventButton); AnalysisEventType evt = button.AnalysisEventType; EventTypeTagsEditor dialog = new EventTypeTagsEditor (this.Toplevel as Window); dialog.EventType = evt; dialog.Run (); dialog.Destroy (); template.RemoveDeadLinks (button); Edited = true; Refresh (); }
public void Refresh(DashboardButton b = null) { tagger.Refresh (b); }
public void ClickButton(DashboardButton button, Tag tag = null) { tagger.Click (button, tag); }
void RemoveButton(DashboardButton button) { string msg = Catalog.GetString ("Do you want to delete: ") + button.Name + "?"; if (App.Current.Dialogs.QuestionMessage (msg, null, this).Result) { template.RemoveButton (button); Edited = true; Refresh (); } }
public void ClickButton(DashboardButton button, Tag tag = null) { codingwidget.ClickButton (button, tag); }
public void TestSerialization() { DashboardButton db = new DashboardButton (); Utils.CheckSerialization (db); db = new TimedDashboardButton (); Utils.CheckSerialization (db); db = new TagButton (); Utils.CheckSerialization (db); db = new TimerButton (); Utils.CheckSerialization (db); db = new EventButton (); Utils.CheckSerialization (db); db = new AnalysisEventButton (); Utils.CheckSerialization (db); db = new PenaltyCardButton (); Utils.CheckSerialization (db); db = new PenaltyCardButton (); Utils.CheckSerialization (db); db = new ScoreButton (); Utils.CheckSerialization (db); }
void HandleNewTagEvent(EventType eventType, List<Player> players, ObservableCollection<Team> teams, List<Tag> tags, Time start, Time stop, Time eventTime, DashboardButton btn) { TimelineEventLongoMatch play = project.AddEvent (eventType, start, stop, eventTime, null, false) as TimelineEventLongoMatch; play.Teams = new ObservableCollection<Team> (teamtagger.SelectedTeams); if (selectedPlayers != null) { play.Players = new ObservableCollection<Player> (selectedPlayers); } else { play.Players = new ObservableCollection<Player> (); } if (tags != null) { play.Tags = new ObservableCollection <Tag> (tags); } else { play.Tags = new ObservableCollection<Tag> (); } teamtagger.ResetSelection (); selectedPlayers = null; App.Current.EventsBroker.Publish<NewDashboardEvent> ( new NewDashboardEvent { TimelineEvent = play, DashboardButton = btn, Edit = true, DashboardButtons = null } ); }
public void HandleNewDashboardEvent(TimelineEvent play, DashboardButton btn, bool edit, List<DashboardButton> from) { if (openedProject == null) return; if (projectType == ProjectType.CaptureProject || projectType == ProjectType.URICaptureProject || projectType == ProjectType.FakeCaptureProject) { if (!capturer.Capturing) { guiToolkit.WarningMessage (Catalog.GetString ("Video capture is stopped")); return; } } if (!openedProject.Dashboard.DisablePopupWindow && edit) { if (projectType == ProjectType.FileProject) { bool playing = player.Playing; player.Pause (); Config.GUIToolkit.EditPlay (play, openedProject, true, true, true, true); if (playing) { player.Play (); } } else { Config.GUIToolkit.EditPlay (play, openedProject, true, true, true, true); } } Log.Debug (String.Format ("New play created start:{0} stop:{1} category:{2}", play.Start.ToMSecondsString (), play.Stop.ToMSecondsString (), play.EventType.Name)); openedProject.AddEvent (play); AddNewPlay (play); }
public void OnNewTag(EventType evType, List<Player> players, TeamType team, List<Tag> tags, Time start, Time stop, Time eventTime, Score score, PenaltyCard card, DashboardButton btn) { if (player == null || openedProject == null) return; if (projectType == ProjectType.CaptureProject || projectType == ProjectType.URICaptureProject) { if (!capturer.Capturing) { guiToolkit.WarningMessage (Catalog.GetString ("Video capture is stopped")); return; } } Log.Debug (String.Format ("New play created start:{0} stop:{1} category:{2}", start.ToMSecondsString (), stop.ToMSecondsString (), evType.Name)); /* Add the new created play to the project and update the GUI*/ var play = openedProject.AddEvent (evType, start, stop, eventTime, null, score, card); play.Team = team; if (players != null) { play.Players = players; } if (tags != null) { play.Tags = tags; } AddNewPlay (play); }
public void EmitNewDashboardEvent(TimelineEvent evt, DashboardButton btn, bool edit, List<DashboardButton> from) { if (NewDashboardEventEvent != null) { if (from == null) from = new List<DashboardButton> (); NewDashboardEventEvent (evt, btn, edit, from); } }
public void EmitPressButton(DashboardButton button) { }
void HandleNewTagEvent(EventType evntType, List<Player> players, ObservableCollection<Team> teams, List<Tag> tags, Time start, Time stop, Time eventTime, DashboardButton btn) { /* Forward event until we have players integrted in the dashboard layout */ if (NewTagEvent != null) { NewTagEvent (evntType, players, teams, tags, start, stop, eventTime, btn); } }