[longomatch] Emit error with cameras missconfiguration



commit db5341cf0474e940e3589dad5191b23814fc696a
Author: Andoni Morales Alastruey <ylatuya gmail com>
Date:   Tue Mar 24 12:41:43 2015 +0100

    Emit error with cameras missconfiguration

 LongoMatch.Services/Services/PlayerController.cs |    9 +++++++++
 1 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/LongoMatch.Services/Services/PlayerController.cs 
b/LongoMatch.Services/Services/PlayerController.cs
index c0b82fa..5e2976e 100644
--- a/LongoMatch.Services/Services/PlayerController.cs
+++ b/LongoMatch.Services/Services/PlayerController.cs
@@ -26,6 +26,7 @@ using LongoMatch.Core.Interfaces.Multimedia;
 using LongoMatch.Core.Store;
 using LongoMatch.Core.Store.Playlists;
 using Timer = System.Threading.Timer;
+using Mono.Unix;
 
 namespace LongoMatch.Services
 {
@@ -603,6 +604,11 @@ namespace LongoMatch.Services
                        EmitMediaFileSetLoaded (fileSet);
                        if (fileSet != this.FileSet || force) {
                                readyToSeek = false;
+                               if (CamerasVisible == null) {
+                                       Config.EventsBroker.EmitMultimediaError (Catalog.GetString ("Invalid 
camera configuration"));
+                                       FileSet = null;
+                                       return;
+                               }
                                foreach (int index in CamerasVisible) {
                                        try {
                                                MediaFile file = fileSet [index];
@@ -613,7 +619,10 @@ namespace LongoMatch.Services
                                                        EmitPARChanged (windowHandle, 1);
                                                }
                                        } catch (Exception ex) {
+                                               Config.EventsBroker.EmitMultimediaError (Catalog.GetString 
("Invalid camera configuration"));
+                                               FileSet = null;
                                                Log.Exception (ex);
+                                               return;
                                        }
                                }
                                try {


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