summaryrefslogtreecommitdiffstats
path: root/abs/core/enlightenment/startup.patch
blob: 136f8488bbd204b3182cfd358724324c01fbd652 (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
--- src/startup.c.orig	2011-11-15 22:01:02.939243595 +0000
+++ src/startup.c	2011-11-15 22:01:33.682575674 +0000
@@ -173,5 +173,39 @@
 
    Mode.place.enable_features--;
    ESync(ESYNC_STARTUP);
+
+ //Start of MythVantage delay for ultra cool startup
+   printf("***\n");   
+   int ret = 1 ;
+ 
+   //checking for fname
+   int result;
+   const char *filename = "/tmp/nofe";
+   result = access (filename, F_OK);
+   
+   if( result != 0 ) 
+   {
+     printf("Waiting for Mythfrontend\n");
+     int i;
+     for (i = 0; i < 20; i++)
+     {
+       
+        sleep(1);
+        ret = system("xwininfo -name \"MythTV Frontend\" 2>/dev/null >/dev/null " );
+        if ( ret == 0 )
+            break;
+     }
+     if ( ret != 0 )
+      printf("Couldn't find mythfrontend, starting anyhow \n");
+     else
+       printf("MythFrontned found, continue startup\n");
+   } 
+   else 
+   {
+      printf("Found /tmp/nofe, skipping delay\n");
+   }
+   // End of delay code
+
+
    AnimatorAdd(doStartupWindowsOpen, NULL);
 }