[longomatch] Fix handling of still images



commit a76c0fcc50ca23550d1ad89fa6a8fdd5661cbc99
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Mon Mar 23 13:52:09 2015 +0100

    Fix handling of still images

 LongoMatch.Services/Services/PlayerController.cs |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)
---
diff --git a/LongoMatch.Services/Services/PlayerController.cs 
b/LongoMatch.Services/Services/PlayerController.cs
index 8e74ff9..84c1694 100644
--- a/LongoMatch.Services/Services/PlayerController.cs
+++ b/LongoMatch.Services/Services/PlayerController.cs
@@ -227,6 +227,7 @@ namespace LongoMatch.Services
                        Log.Debug ("Play");
                        if (StillImageLoaded) {
                                ReconfigureTimeout (TIMEOUT_MS);
+                               EmitPlaybackStateChanged (true);
                        } else {
                                EmitLoadDrawings (null);
                                player.Play ();
@@ -239,6 +240,7 @@ namespace LongoMatch.Services
                        Log.Debug ("Pause");
                        if (StillImageLoaded) {
                                ReconfigureTimeout (0);
+                               EmitPlaybackStateChanged (false);
                        } else {
                                player.Pause ();
                        }
@@ -444,7 +446,10 @@ namespace LongoMatch.Services
                public void Previous ()
                {
                        Log.Debug ("Previous");
-                       if (loadedPlaylistElement != null) {
+                       if (StillImageLoaded) {
+                               imageLoadedTS = new Time (0);
+                               OnTick ();
+                       } else if (loadedPlaylistElement != null) {
                                if (loadedPlaylist.HasPrev ()) {
                                        Config.EventsBroker.EmitPreviousPlaylistElement (loadedPlaylist);
                                }
@@ -565,6 +570,7 @@ namespace LongoMatch.Services
                        set {
                                stillimageLoaded = value;
                                if (stillimageLoaded) {
+                                       EmitPlaybackStateChanged (true);
                                        player.Pause ();
                                        imageLoadedTS = new Time (0);
                                        ReconfigureTimeout (TIMEOUT_MS);


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