[svn-upgrade] Integrating new upstream version, teleschorsch (0.0.6) upstream/0.0.6
authorgregor herrmann <gregoa@debian.org>
Fri, 2 Mar 2007 15:15:34 +0000 (15:15 -0000)
committergregor herrmann <gregoa@debian.org>
Fri, 2 Mar 2007 15:15:34 +0000 (15:15 -0000)
main.cpp
teleschorschrc

index eca8087..a968403 100644 (file)
--- a/main.cpp
+++ b/main.cpp
@@ -134,6 +134,17 @@ QString substitudeStaticUrl(const QString& staticUrl, QDate date) {
                        lastPos = pos+1;
                }
        }
+
+       // Evaluate staticUrl - it might be dynamic despite its name :-)
+       if (result.left(1) == "`" && result.right(1) == "`") {
+               QProcess evalUrl(0);
+               QString command = "/bin/sh -c \"echo " + result + "\"";
+               evalUrl.start(command);
+               if (evalUrl.waitForFinished()) {
+                       QByteArray newResult = evalUrl.readAllStandardOutput();
+                       if (result != newResult) {result = newResult.trimmed();}
+               }
+       }
        return result;
 }
 
@@ -198,7 +209,6 @@ bool MainDialog::startAction() {
                QStringList arguments;
                arguments.append(substitudeStaticUrl(channel.staticUrl, date));
                appendPlayerOffsetOption(channel.player, teOffset->time(), arguments);
-               // arguments << "-style" << "motif";
                QProcess player(this);
                qDebug() << channel.player << arguments;
                player.start(channel.player, arguments);
index e577304..2d9d373 100644 (file)
@@ -40,7 +40,7 @@ PLAYER=vlc
 
 [M61250]
 FULLNAME=M6 - le 12 50
-STATICURL=mms://stream1.m6.fr.ipercast.net/m6.fr/6minutes/d/92/d${y}${m}${d}211150SARAV9200000.wmv
+STATICURL=mms://stream1.m6.fr.ipercast.net/m6.fr/6minutes/d/92/d${y}${m}${d}211151SARAV9200000.wmv
 PLAYER=vlc
 
 [M6six]
@@ -71,4 +71,4 @@ PLAYER=vlc
 [ORFoe118]
 FULLNAME=ORF - Ö1 Abendjournal (only current broadcast)
 STATICURL=`wget -q -O- "http://oe1.orf.at/konsole/journal?type=abend" | grep -Eo "mms://stream2\.orf\.at/oe1/demand/abend/.+\.WMA"`
-PLAYER=vlc
\ No newline at end of file
+PLAYER=vlc