summaryrefslogtreecommitdiff
path: root/vdr-image-0.2.3.diff
blob: 52359a3aa27487277563f7c26569e6bf91ea472c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
diff -ruN image-0.2.3/menu-image.c image-0.2.3-mg/menu-image.c
--- image-0.2.3/menu-image.c	2004-07-29 18:51:58.000000000 +0200
+++ image-0.2.3-mg/menu-image.c	2005-10-04 22:40:20.000000000 +0200
@@ -27,6 +27,7 @@
 #include <sys/ioctl.h>
 #include <sys/types.h>
 #include <unistd.h>
+#include <libgen.h>
 #include <typeinfo>
 
 #include "image.h"
@@ -37,6 +38,7 @@
 #include "i18n.h"
 
 #include <vdr/status.h>
+#include <vdr/plugin.h>
 
 
 // --- cMenuImageBrowse ---------------------------------------------------------
@@ -88,24 +90,31 @@
     char *name = lastselect->Path();
     char *full = source->BuildName(name);
     cDirItem *item = cMenuBrowse::GetSelected();
-    if(item) {
-    
-      //FIXME use a nonblocking way
-      //OSD_InfoMsg(tr("Building SlideShow..."));
-    
-      cSlideShow *newss = new cSlideShow(item);
-      if(newss->Load() && newss->Count()) {
-
-        cImageControl::SetSlideShow(newss);
-        state = osEnd;
-      } 
-			else {
-				OSD_ErrorMsg(tr("No Files!"));
-				delete newss;
-				state = osContinue;
-			}
-			lastselect = NULL;
-		}
+    if(item) 
+      {
+	
+	//FIXME use a nonblocking way
+	//OSD_InfoMsg(tr("Building SlideShow..."));
+
+	// check, whether we can use a different plugin for replay
+	if( !cPluginManager::CallFirstService( "ReplayDirectoryImages", dirname(full) ) )
+	  {
+	
+	    cSlideShow *newss = new cSlideShow(item);
+	    if(newss->Load() && newss->Count()) 
+	      {
+		cImageControl::SetSlideShow(newss);
+		state = osEnd;
+	      } 
+	    else 
+	      {
+		OSD_ErrorMsg(tr("No Files!"));
+		delete newss;
+		state = osContinue;
+	      }
+	    lastselect = NULL;
+	  }
+      }
   free(full);
   free(name);
   }