[longomatch] Only seek to the event time for substitutions
- From: Andoni Morales Alastruey <amorales src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [longomatch] Only seek to the event time for substitutions
- Date: Wed, 5 Nov 2014 19:03:38 +0000 (UTC)
commit 785eb90399b1c23432c6073f22665c4420d5867f
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date: Wed Nov 5 19:38:49 2014 +0100
Only seek to the event time for substitutions
LongoMatch.Services/Services/PlaylistManager.cs | 17 ++++++++++++-----
1 files changed, 12 insertions(+), 5 deletions(-)
---
diff --git a/LongoMatch.Services/Services/PlaylistManager.cs b/LongoMatch.Services/Services/PlaylistManager.cs
index d59d0b1..f830efa 100644
--- a/LongoMatch.Services/Services/PlaylistManager.cs
+++ b/LongoMatch.Services/Services/PlaylistManager.cs
@@ -128,13 +128,20 @@ namespace LongoMatch.Services
void HandleLoadPlayEvent (TimelineEvent play)
{
- Switch (play, null, null);
- if (play != null) {
- LoadPlay (play, play.Start, true);
+ if (play is SubstitutionEvent || play is LineupEvent) {
+ Switch (null, null, null);
+ Config.EventsBroker.EmitEventLoaded (null);
+ player.Seek (play.EventTime, true);
+ player.Play ();
} else {
- player.CloseSegment ();
+ Switch (play, null, null);
+ if (play != null) {
+ LoadPlay (play, play.Start, true);
+ } else {
+ player.CloseSegment ();
+ }
+ Config.EventsBroker.EmitEventLoaded (play);
}
- Config.EventsBroker.EmitEventLoaded (play);
}
void HandleNext (Playlist playlist)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]