[tuxdroid-svn] r4562 - in softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk: exec
Status: Beta
Brought to you by:
ks156
|
From: remi <c2m...@c2...> - 2009-04-18 15:44:52
|
Author: remi
Date: 2009-04-18 17:44:44 +0200 (Sat, 18 Apr 2009)
New Revision: 4562
Modified:
softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/executables/tux-gadget-webradio.py
softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.pot
softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.xml
softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/help.html
Log:
* added a message on radio stream loosed
* updated translations and messages
Modified: softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/executables/tux-gadget-webradio.py
===================================================================
--- softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/executables/tux-gadget-webradio.py 2009-04-18 15:06:54 UTC (rev 4561)
+++ softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/executables/tux-gadget-webradio.py 2009-04-18 15:44:44 UTC (rev 4562)
@@ -91,6 +91,7 @@
SimpleGadget.__init__(self)
# Create a mplayer wrapper object
self.__player = Mplayer()
+ self.__player.onStreamLoosedCallback = self.__onStreamLoosed
def start(self):
if self.getCommand() == "run":
@@ -106,10 +107,15 @@
radioUrl = myRadio
if myRadio in WEBRADIO.keys():
radioUrl = WEBRADIO[myRadio]
- self.throwMessage("Web radio \"{0}\".", myRadio)
+ self.throwMessage("Starting the webradio \"{0}\".", myRadio)
# Start mplayer
self.__player.start(radioUrl, True)
+ def __onStreamLoosed(self):
+ self.throwMessage("Sorry, I loosed the radio stream.")
+ self.stop()
+ sys.exit(0)
+
def onGadgetStop(self):
"""Event on gadget stop.
"""
Modified: softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.pot
===================================================================
--- softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.pot 2009-04-18 15:06:54 UTC (rev 4561)
+++ softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.pot 2009-04-18 15:44:44 UTC (rev 4562)
@@ -1,11 +1,17 @@
msgid "Web Radio"
msgstr ""
-msgid "Use Tux as a webradio"
+msgid "Playing a webradio"
msgstr ""
-msgid "Web radio"
+msgid "Play the webradio"
msgstr ""
-msgid "Select radio"
+msgid "Select a webradio"
+msgstr ""
+
+msgid "Starting the web radio \"{0}\"."
+msgstr ""
+
+msgid "Sorry, I loosed the radio stream."
msgstr ""
Modified: softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.xml
===================================================================
--- softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.xml 2009-04-18 15:06:54 UTC (rev 4561)
+++ softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/gadget.xml 2009-04-18 15:44:44 UTC (rev 4562)
@@ -5,24 +5,23 @@
</interpreter>
<description>
<name>Web Radio</name>
- <description>Use Tux as a webradio</description>
+ <description>Playing a webradio</description>
<author>Gwadavel</author>
<version>0.0.6</version>
<iconFile>resources/webradio.png</iconFile>
- <executionMode>command</executionMode>
<uuid>8349ed52-572d-4c3f-a7b8-05c2a8aec2c6</uuid>
</description>
<parameters>
<parameter
name="radio"
- description="Select radio"
+ description="Select a webradio"
type="enum(BBC2,France-Bleu-Ile-de-France,France-Culture,France-Info,France-Inter,France-Musique,Le-Mouv,RFM,RMC-Info,Click'And'rock)"
defaultValue="France-Inter" />
</parameters>
<commands>
<command
name="run"
- description="Web radio"
+ description="Play the webradio"
daemon="true" />
</commands>
</gadget>
Modified: softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/help.html
===================================================================
--- softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/help.html 2009-04-18 15:06:54 UTC (rev 4561)
+++ softwares_suite_v3/community/gadget/tuxdroid-gadget-webradio/trunk/resources/help.html 2009-04-18 15:44:44 UTC (rev 4562)
@@ -1,6 +1,6 @@
<html>
<body>
-<font size="2" face="Verdana, Arial, Helvetica, sans-serif">This gadget will make Tux Droid play radio. Drag-and-drop the gadget into "My Favorites" to enable Webradio or into "My Alerts" to enable Clock Radio. <br>
+<font size="2" face="Verdana, Arial, Helvetica, sans-serif">This gadget will make Tux Droid play radio. Drag-and-drop the gadget into "My Favorites" to enable Webradio.<br>
</font>
</body>
</html>
|