tux-droid-svn Mailing List for Tux Droid CE (Page 57)
Status: Beta
Brought to you by:
ks156
You can subscribe to this list here.
| 2007 |
Jan
|
Feb
(32) |
Mar
(108) |
Apr
(71) |
May
(38) |
Jun
(128) |
Jul
(1) |
Aug
(14) |
Sep
(77) |
Oct
(104) |
Nov
(90) |
Dec
(71) |
|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 2008 |
Jan
(81) |
Feb
(18) |
Mar
(40) |
Apr
(102) |
May
(151) |
Jun
(74) |
Jul
(151) |
Aug
(257) |
Sep
(447) |
Oct
(379) |
Nov
(404) |
Dec
(430) |
| 2009 |
Jan
(173) |
Feb
(236) |
Mar
(519) |
Apr
(300) |
May
(112) |
Jun
(232) |
Jul
(314) |
Aug
(58) |
Sep
(203) |
Oct
(293) |
Nov
(26) |
Dec
(109) |
| 2010 |
Jan
(19) |
Feb
(25) |
Mar
(33) |
Apr
(1) |
May
|
Jun
(3) |
Jul
|
Aug
|
Sep
|
Oct
|
Nov
|
Dec
|
|
From: remi <c2m...@c2...> - 2009-05-05 08:01:43
|
Author: remi
Date: 2009-05-05 10:01:33 +0200 (Tue, 05 May 2009)
New Revision: 4630
Modified:
softwares_suite_v3/community/gadget/tuxdroid-gadget-lastfmradio/trunk/executables/tux-gadget-lastfmradio.py
Log:
* fixed host ip
* (Last fm has changed his business model, this gadget is now useless ...)
Modified: softwares_suite_v3/community/gadget/tuxdroid-gadget-lastfmradio/trunk/executables/tux-gadget-lastfmradio.py
===================================================================
--- softwares_suite_v3/community/gadget/tuxdroid-gadget-lastfmradio/trunk/executables/tux-gadget-lastfmradio.py 2009-05-05 07:59:32 UTC (rev 4629)
+++ softwares_suite_v3/community/gadget/tuxdroid-gadget-lastfmradio/trunk/executables/tux-gadget-lastfmradio.py 2009-05-05 08:01:33 UTC (rev 4630)
@@ -103,8 +103,12 @@
# Show the informations
if self.configuration().getRadioInfos():
self.__webViewer = WebViewer("Tux Droid Gadget : Last FM infos",
- "http://localhost:1881/", 370, -1)
- self.__webViewer.start()
+ "http://127.0.0.1:1881/", 370, -1)
+ def async():
+ time.sleep(1.0)
+ self.__webViewer.start()
+ t = threading.Thread(target = async)
+ t.start()
# Start mplayer
radioUrl = BASE_STREAM_LINK % self.configuration().getLikeThisArtist()
self.__player.start(radioUrl, True)
|
|
From: remi <c2m...@c2...> - 2009-05-05 07:59:44
|
Author: remi Date: 2009-05-05 09:59:32 +0200 (Tue, 05 May 2009) New Revision: 4629 Removed: softwares_suite_v3/community/script/ softwares_suite_v3/community/tool/ Log: * removed some directories |
|
From: remi <c2m...@c2...> - 2009-05-05 07:58:42
|
Author: remi Date: 2009-05-05 09:58:33 +0200 (Tue, 05 May 2009) New Revision: 4628 Added: software_suite_v3/software/script/pidgin/ Log: * moved pidgin script Copied: software_suite_v3/software/script/pidgin (from rev 4607, softwares_suite_v3/community/script/pidgin) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:56:56
|
Author: remi Date: 2009-05-05 09:56:42 +0200 (Tue, 05 May 2009) New Revision: 4627 Removed: softwares_suite_v3/kysoh/ Log: * removed some directories |
|
From: remi <c2m...@c2...> - 2009-05-05 07:54:05
|
Author: remi Date: 2009-05-05 09:53:54 +0200 (Tue, 05 May 2009) New Revision: 4626 Removed: softwares_suite_v3/kysoh/tuxware/api/python/trunk/ Log: * deleted old project |
Author: remi Date: 2009-05-05 09:53:02 +0200 (Tue, 05 May 2009) New Revision: 4625 Added: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChildResource.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/lib/Helper.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/Gadget.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetDescription.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetParameter.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetsContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/Task.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/TaskDescription.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/TasksContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/AttituneManager.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/Framework.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/Scheduler.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/TTS.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/const/ConstFramework.py Removed: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChildResource.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/lib/Helper.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/Gadget.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetDescription.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetParameter.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/gadgets/GadgetsContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/Task.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/TaskDescription.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/scheduler/TasksContainer.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/AttituneManager.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/Framework.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/Scheduler.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/TTS.py software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/tuxdroid/const/ConstFramework.py Log: * tagged the python api project in the state before the plugin/gadget new philosophy Copied: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring (from rev 4469, softwares_suite_v3/kysoh/tuxware/api/python/trunk) Deleted: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py =================================================================== --- softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/TuxAPI.py 2009-04-10 12:51:53 UTC (rev 4469) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -1,165 +0,0 @@ -# -*- coding: latin1 -*- - -import version -__author__ = version.author -__date__ = version.date -__version__ = version.version -__licence__ = version.licence -del version - -# Copyright (C) 2009 C2ME Sa -# Remi Jocaille <rem...@c2...> -# Distributed under the terms of the GNU General Public License -# http://www.gnu.org/copyleft/gpl.html - -from base.lib.Helper import Helper -from base.ApiBase import * -from tuxdroid.const.ConstTuxDriver import * -from tuxdroid.const.ConstTuxOsl import * -from tuxdroid.const.ConstFramework import * -from tuxdroid.const.ConstAttitunes import * -from tuxdroid.const.ConstScheduler import * -from tuxdroid.MouthEyes import MouthEyes -from tuxdroid.TTS import TTS -from tuxdroid.Wav import Wav -from tuxdroid.Attitune import Attitune -from tuxdroid.RawCommand import RawCommand -from tuxdroid.DongleRadio import DongleRadio -from tuxdroid.SoundFlash import SoundFlash -from tuxdroid.Led import Led -from tuxdroid.Button import Button -from tuxdroid.Flippers import Flippers -from tuxdroid.Spinning import Spinning -from tuxdroid.Framework import Framework -from tuxdroid.Light import Light -from tuxdroid.Battery import Battery -from tuxdroid.Charger import Charger -from tuxdroid.AttituneManager import AttituneManager -from tuxdroid.Scheduler import Scheduler -from tuxdroid.User import User - -# ------------------------------------------------------------------------------ -# Tux Droid API. -# ------------------------------------------------------------------------------ -class TuxAPI(ApiBase): - """Main module class to control Tuxdroid. - """ - # -------------------------------------------------------------------------- - # Constructor of the class. - # -------------------------------------------------------------------------- - def __init__(self, host = '127.0.0.1', port = 270): - """Constructor of the class. - @param host: host of the server. - @param port: port of the server. - """ - ApiBase.__init__(self, host, port) - # Register base status/events of the server - for statusName in SW_NAME_DRIVER: - self.getEventsHandler().insert(statusName) - for statusName in SW_NAME_OSL: - self.getEventsHandler().insert(statusName) - for statusName in SW_NAME_FRAMEWORK: - self.getEventsHandler().insert(statusName) - # Create the mouth object - self.mouth = MouthEyes(self, self.server, ST_NAME_MOUTH_POSITION, - ST_NAME_MOUTH_RM, "mouth") - # Create the eyes object - self.eyes = MouthEyes(self, self.server, ST_NAME_EYES_POSITION, - ST_NAME_EYES_RM, "eyes") - # Create the tts object - self.tts = TTS(self, self.server) - # Create the wav object - self.wav = Wav(self, self.server) - # Create the attitune object - self.attitune = Attitune(self, self.server) - # Create the raw command object - self.raw = RawCommand(self, self.server) - # Create the dongle object - self.dongle = DongleRadio(self, self.server, ST_NAME_DONGLE_PLUG) - # Create the radio object - self.radio = DongleRadio(self, self.server, ST_NAME_RADIO_STATE) - # Create the sound flash object - self.soundFlash = SoundFlash(self, self.server) - # Create led objects - self.led = Led(self, self.server) - # Create the button objects - self.button = Button(self, self.server) - # Create the flippers object - self.flippers = Flippers(self, self.server) - # Create the spinning object - self.spinning = Spinning(self, self.server) - # Create the light object - self.light = Light(self, self.server) - # Create the battery object - self.battery = Battery(self, self.server) - # Create the charger object - self.charger = Charger(self, self.server) - # Create the framework object - self.framework = Framework(self, self.server) - # Create the attitune manager object - self.attitunes = AttituneManager(self, self.server) - # Create the scheduler object - self.scheduler = Scheduler(self, self.server) - # Create the user object - self.user = User(self, self.server) - # Bind some methods - self.__bindSomeMethods() - # Initialize the helper - Helper.__init__(self) - - def __bindSomeMethods(self): - """Bind some methods in order to make more usefull some - functionalities. - """ - # Gadget framework bindings - self.showGadgets = self.framework.getGadgetsContainer().showGadgets - self.getGadget = self.framework.getGadgetsContainer().getGadget - # Attitune manager bindings - self.showAttitunes = self.attitunes.getAttitunesContainer().showAttitunes - self.getAttitune = self.attitunes.getAttitunesContainer().getAttitune - # Scheduler bindings - self.showTasks = self.scheduler.getTasksContainer().showTasks - self.getTask = self.scheduler.getTasksContainer().getTask - - # -------------------------------------------------------------------------- - # Get the version of this API. - # -------------------------------------------------------------------------- - def getVersion(self): - """Get the version of this api. - @return: A string. - """ - return "tuxisalive.api-%s" % __version__ - - # -------------------------------------------------------------------------- - # Get the Tux Droid system versions. - # -------------------------------------------------------------------------- - def getVersions(self): - """Get the Tux Droid system versions. - @return: a dictionary. - """ - verDict = {} - verDict["tuxapi"] = __version__ - verDict["tuxdroidserver"] = self.server.getVersion() - ver = self.server._requestOne(ST_NAME_DRIVER_SYMB_VER) - if ver == None: - verDict["tuxdriver"] = "Unknow" - else: - verDict["tuxdriver"] = ver[ver.find("_") + 1:] - ver = self.server._requestOne(ST_NAME_OSL_SYMB_VER) - if ver == None: - verDict["tuxosl"] = "Unknow" - else: - verDict["tuxosl"] = ver[ver.find("_") + 1:] - return verDict - - # -------------------------------------------------------------------------- - # Show the Tux Droid system versions. - # -------------------------------------------------------------------------- - def showVersions(self): - """Show the Tux Droid system versions. - """ - verDict = self.getVersions() - result = [] - for key in verDict.keys(): - result.append("%s : %s" % (key, verDict[key])) - self._showStringList("Tux Droid System :", result) Copied: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py (from rev 4558, softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/TuxAPI.py) =================================================================== --- software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py (rev 0) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/TuxAPI.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -0,0 +1,175 @@ +# -*- coding: latin1 -*- + +import version +__author__ = version.author +__date__ = version.date +__version__ = version.version +__licence__ = version.licence +del version + +# Copyright (C) 2009 C2ME Sa +# Remi Jocaille <rem...@c2...> +# Distributed under the terms of the GNU General Public License +# http://www.gnu.org/copyleft/gpl.html + +from base.lib.Helper import Helper +from base.ApiBase import * +from tuxdroid.const.ConstTuxDriver import * +from tuxdroid.const.ConstTuxOsl import * +from tuxdroid.const.ConstFramework import * +from tuxdroid.const.ConstAttitunes import * +from tuxdroid.const.ConstScheduler import * +from tuxdroid.MouthEyes import MouthEyes +from tuxdroid.TTS import TTS +from tuxdroid.Wav import Wav +from tuxdroid.Attitune import Attitune +from tuxdroid.RawCommand import RawCommand +from tuxdroid.DongleRadio import DongleRadio +from tuxdroid.SoundFlash import SoundFlash +from tuxdroid.Led import Led +from tuxdroid.Button import Button +from tuxdroid.Flippers import Flippers +from tuxdroid.Spinning import Spinning +from tuxdroid.Framework import Framework +from tuxdroid.Light import Light +from tuxdroid.Battery import Battery +from tuxdroid.Charger import Charger +from tuxdroid.AttituneManager import AttituneManager +from tuxdroid.Scheduler import Scheduler +from tuxdroid.User import User + +# ------------------------------------------------------------------------------ +# Tux Droid API. +# ------------------------------------------------------------------------------ +class TuxAPI(ApiBase): + """Main module class to control Tuxdroid. + """ + # -------------------------------------------------------------------------- + # Constructor of the class. + # -------------------------------------------------------------------------- + def __init__(self, host = '127.0.0.1', port = 270): + """Constructor of the class. + @param host: host of the server. + @param port: port of the server. + """ + ApiBase.__init__(self, host, port) + # Register base status/events of the server + for statusName in SW_NAME_DRIVER: + self.getEventsHandler().insert(statusName) + for statusName in SW_NAME_OSL: + self.getEventsHandler().insert(statusName) + for statusName in SW_NAME_FRAMEWORK: + self.getEventsHandler().insert(statusName) + # Create the mouth object + self.mouth = MouthEyes(self, self.server, ST_NAME_MOUTH_POSITION, + ST_NAME_MOUTH_RM, "mouth") + # Create the eyes object + self.eyes = MouthEyes(self, self.server, ST_NAME_EYES_POSITION, + ST_NAME_EYES_RM, "eyes") + # Create the tts object + self.tts = TTS(self, self.server) + # Create the wav object + self.wav = Wav(self, self.server) + # Create the attitune object + self.attitune = Attitune(self, self.server) + # Create the raw command object + self.raw = RawCommand(self, self.server) + # Create the dongle object + self.dongle = DongleRadio(self, self.server, ST_NAME_DONGLE_PLUG) + # Create the radio object + self.radio = DongleRadio(self, self.server, ST_NAME_RADIO_STATE) + # Create the sound flash object + self.soundFlash = SoundFlash(self, self.server) + # Create led objects + self.led = Led(self, self.server) + # Create the button objects + self.button = Button(self, self.server) + # Create the flippers object + self.flippers = Flippers(self, self.server) + # Create the spinning object + self.spinning = Spinning(self, self.server) + # Create the light object + self.light = Light(self, self.server) + # Create the battery object + self.battery = Battery(self, self.server) + # Create the charger object + self.charger = Charger(self, self.server) + # Create the framework object + self.framework = Framework(self, self.server) + # Create the attitune manager object + self.attitunes = AttituneManager(self, self.server) + # Create the scheduler object + self.scheduler = Scheduler(self, self.server) + # Create the user object + self.user = User(self, self.server) + # Bind some methods + self.__bindSomeMethods() + # Initialize the helper + Helper.__init__(self) + + def __bindSomeMethods(self): + """Bind some methods in order to make more usefull some + functionalities. + """ + # Gadget framework bindings + self.showGadgets = self.framework.getGadgetsContainer().showGadgets + self.getGadget = self.framework.getGadgetsContainer().getGadget + # Attitune manager bindings + self.showAttitunes = self.attitunes.getAttitunesContainer().showAttitunes + self.getAttitune = self.attitunes.getAttitunesContainer().getAttitune + # Scheduler bindings + self.showTasks = self.scheduler.getTasksContainer().showTasks + self.getTask = self.scheduler.getTasksContainer().getTask + # User method bind + def userWaitLoaded(): + ret = self.framework.waitLoaded(5.0, 0.0) + if not ret: + return False + ret = self.attitunes.waitLoaded(5.0, 0.0) + if not ret: + return False + return self.scheduler.waitLoaded(5.0, 1.0) + self.user.waitLoaded = userWaitLoaded + + # -------------------------------------------------------------------------- + # Get the version of this API. + # -------------------------------------------------------------------------- + def getVersion(self): + """Get the version of this api. + @return: A string. + """ + return "tuxisalive.api-%s" % __version__ + + # -------------------------------------------------------------------------- + # Get the Tux Droid system versions. + # -------------------------------------------------------------------------- + def getVersions(self): + """Get the Tux Droid system versions. + @return: a dictionary. + """ + verDict = {} + verDict["tuxapi"] = __version__ + verDict["tuxdroidserver"] = self.server.getVersion() + ver = self.server._requestOne(ST_NAME_DRIVER_SYMB_VER) + if ver == None: + verDict["tuxdriver"] = "Unknow" + else: + verDict["tuxdriver"] = ver[ver.find("_") + 1:] + ver = self.server._requestOne(ST_NAME_OSL_SYMB_VER) + if ver == None: + verDict["tuxosl"] = "Unknow" + else: + verDict["tuxosl"] = ver[ver.find("_") + 1:] + return verDict + + # -------------------------------------------------------------------------- + # Show the Tux Droid system versions. + # -------------------------------------------------------------------------- + def showVersions(self): + """Show the Tux Droid system versions. + """ + verDict = self.getVersions() + result = [] + for key in verDict.keys(): + result.append("%s : %s" % (key, verDict[key])) + self._showStringList("Tux Droid System :", result) Deleted: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py =================================================================== --- softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/attitunes/Attitune.py 2009-04-10 12:51:53 UTC (rev 4469) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -1,129 +0,0 @@ -# Copyright (C) 2009 C2ME Sa -# Remi Jocaille <rem...@c2...> -# Distributed under the terms of the GNU General Public License -# http://www.gnu.org/copyleft/gpl.html - -import time - -from tuxisalive.api.base.ApiBaseChildResource import ApiBaseChildResource -from tuxisalive.api.scheduler.Task import Task -from tuxisalive.api.tuxdroid.const.ConstAttitunes import * -from AttituneDescription import AttituneDescription - -# ------------------------------------------------------------------------------ -# Attitune -# ------------------------------------------------------------------------------ -class Attitune(ApiBaseChildResource): - - # -------------------------------------------------------------------------- - # Constructor of the class. - # -------------------------------------------------------------------------- - def __init__(self, apiBase, apiBaseServer, parent, infosStructure): - """Constructor of the class. - @param apiBase: ApiBase parent object. - @param apiBaseServer: ApiBaseServer object. - @param parent: Parent Attitunes container. - @param infosStructure: Attitune structure as dictionary. - """ - ApiBaseChildResource.__init__(self, apiBase, apiBaseServer) - self.__parent = parent - self.__description = AttituneDescription(self, infosStructure) - - # -------------------------------------------------------------------------- - # Get the parent attitunes container. - # -------------------------------------------------------------------------- - def getContainer(self): - """Get the parent attitunes container. - @return: The parent attitunes container. - """ - return self.__parent - - # -------------------------------------------------------------------------- - # Get the attitune description object. - # -------------------------------------------------------------------------- - def getDescription(self): - """Get the gadget description object. - @return: The gadget description object. - """ - return self.__description - - # -------------------------------------------------------------------------- - # Show the description in the console. - # -------------------------------------------------------------------------- - def showDescription(self): - """Show the description in the console. - """ - self.__description.show() - - # -------------------------------------------------------------------------- - # Start this attitune. - # -------------------------------------------------------------------------- - def startAsync(self, begin = 0.0): - """Start this attitune. - @param begin: Begin time. - @return: The success of the attitune start. - """ - if not self._checkObjectType('begin', begin, 'float'): - return False - if begin > self.__description.getDuration(): - return False - argsToSend = { - 'name' : self.__description.getName(), - 'begin' : begin, - } - cmd = "attitune_manager/start_attitune_by_name?" - return self._sendCommandBooleanResult(cmd, argsToSend) - - # -------------------------------------------------------------------------- - # Start this attitune. - # -------------------------------------------------------------------------- - def start(self, begin = 0.0): - """Start this attitune. - @param begin: Begin time. - @return: The success of the attitune start. - """ - if not self.startAsync(begin): - return False - time.sleep(0.5) - self._waitFor(ST_NAME_AM_ATTITUNE_STOPPED, self.__description.getName(), - 600.0) - return True - - # -------------------------------------------------------------------------- - # Stop the attitune. - # -------------------------------------------------------------------------- - def stop(self): - """Stop the attitune. - """ - cmd = "attitune_manager/stop_attitune?" - return self._sendCommandBooleanResult(cmd) - - # -------------------------------------------------------------------------- - # Schedule the start command of this attitune. - # -------------------------------------------------------------------------- - def scheduleStart(self, type = "ONCE DELAYED", name = None, - weekMask = [True, True, True, True, True, True, True], date = None, - time = "00:00:10"): - """Schedule the start command of this attitune. - @param type: <EVERY X|EVERY X FROM FULL HOUR|DAILY AT|ONCE AT| - ONCE DELAYED> - Default value is the "ONCE DELAYED". - @param name: Task name. - Default value is attitune name. - @param weekMask: Week mask as list of 7 booleans. - Default is [True, True, True, True, True, True, True] - @param date: Task date as string "YYYY/MM/DD". - Default is None (no date defined) - @param time: Task time as string "HH:MM:SS". - Default is "00:00:10". - @return: The success of the request. - """ - if name == None: - name = self.getDescription().getName() - argsToSend = Task.formatRequestArguments(type, name, weekMask, date, - time) - if argsToSend == None: - return False - argsToSend['attitune_name'] = self.getDescription().getName() - cmd = "task_creation/play_attitune?" - return self._sendCommandBooleanResult(cmd, argsToSend) Copied: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py (from rev 4593, softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/attitunes/Attitune.py) =================================================================== --- software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py (rev 0) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/Attitune.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -0,0 +1,134 @@ +# Copyright (C) 2009 C2ME Sa +# Remi Jocaille <rem...@c2...> +# Distributed under the terms of the GNU General Public License +# http://www.gnu.org/copyleft/gpl.html + +import time + +from tuxisalive.api.base.ApiBaseChildResource import ApiBaseChildResource +from tuxisalive.api.scheduler.Task import Task +from tuxisalive.api.tuxdroid.const.ConstAttitunes import * +from AttituneDescription import AttituneDescription + +# ------------------------------------------------------------------------------ +# Attitune +# ------------------------------------------------------------------------------ +class Attitune(ApiBaseChildResource): + + # -------------------------------------------------------------------------- + # Constructor of the class. + # -------------------------------------------------------------------------- + def __init__(self, apiBase, apiBaseServer, parent, infosStructure): + """Constructor of the class. + @param apiBase: ApiBase parent object. + @param apiBaseServer: ApiBaseServer object. + @param parent: Parent Attitunes container. + @param infosStructure: Attitune structure as dictionary. + """ + ApiBaseChildResource.__init__(self, apiBase, apiBaseServer) + self.__parent = parent + self.__description = AttituneDescription(self, infosStructure) + + # -------------------------------------------------------------------------- + # Get the parent attitunes container. + # -------------------------------------------------------------------------- + def getContainer(self): + """Get the parent attitunes container. + @return: The parent attitunes container. + """ + return self.__parent + + # -------------------------------------------------------------------------- + # Get the attitune description object. + # -------------------------------------------------------------------------- + def getDescription(self): + """Get the gadget description object. + @return: The gadget description object. + """ + return self.__description + + # -------------------------------------------------------------------------- + # Show the description in the console. + # -------------------------------------------------------------------------- + def showDescription(self): + """Show the description in the console. + """ + self.__description.show() + + # -------------------------------------------------------------------------- + # Start this attitune. + # -------------------------------------------------------------------------- + def startAsync(self, begin = 0.0): + """Start this attitune. + @param begin: Begin time. + @return: The success of the attitune start. + """ + if not self._checkObjectType('begin', begin, 'float'): + return False + if begin > self.__description.getDuration(): + return False + argsToSend = { + 'name' : self.__description.getName(), + 'begin' : begin, + } + cmd = "attitune_manager/start_attitune_by_name?" + return self._sendCommandBooleanResult(cmd, argsToSend) + + # -------------------------------------------------------------------------- + # Start this attitune. + # -------------------------------------------------------------------------- + def start(self, begin = 0.0): + """Start this attitune. + @param begin: Begin time. + @return: The success of the attitune start. + """ + if not self.startAsync(begin): + return False + time.sleep(0.5) + self._waitFor(ST_NAME_AM_ATTITUNE_STOPPED, self.__description.getName(), + 600.0) + return True + + # -------------------------------------------------------------------------- + # Stop the attitune. + # -------------------------------------------------------------------------- + def stop(self): + """Stop the attitune. + """ + cmd = "attitune_manager/stop_attitune?" + return self._sendCommandBooleanResult(cmd) + + # -------------------------------------------------------------------------- + # Schedule the start command of this attitune. + # -------------------------------------------------------------------------- + def scheduleStart(self, type = "ONCE DELAYED", name = None, + weekMask = [True, True, True, True, True, True, True], + date = "0000/00/00", hoursBegin = "00:00:00" , hoursEnd = "23:59:59", + delay = "00:01:00"): + """Schedule the start command of this attitune. + @param type: <EVERY X|EVERY X FROM FULL HOUR|DAILY AT|ONCE AT| + ONCE DELAYED> + Default value is the "ONCE DELAYED". + @param name: Task name. + Default value is attitune name. + @param weekMask: Week mask as list of 7 booleans. + Default is [True, True, True, True, True, True, True] + @param date: Task date as string "YYYY/MM/DD". + Default is "0000/00/00" (no date defined) + @param hoursBegin: Task hours begin as string "HH:MM:SS". + Default is "00:00:00". + @param hoursEnd: Task hours end as string "HH:MM:SS". + Default is "23:59:59". + @param delay: Task delay as string "HH:MM:SS". + Default is "00:01:00". + @return: The success of the request. + """ + if name == None: + name = self.getDescription().getName() + argsToSend = Task.formatRequestArguments(type, name, weekMask, date, + hoursBegin, hoursEnd, delay) + if argsToSend == None: + return False + argsToSend['attitune_name'] = self.getDescription().getName() + cmd = "task_creation/play_attitune?" + return self._sendCommandBooleanResult(cmd, argsToSend) Deleted: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py =================================================================== --- softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/attitunes/AttitunesContainer.py 2009-04-10 12:51:53 UTC (rev 4469) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -1,144 +0,0 @@ -# Copyright (C) 2009 C2ME Sa -# Remi Jocaille <rem...@c2...> -# Distributed under the terms of the GNU General Public License -# http://www.gnu.org/copyleft/gpl.html - -import threading - -from tuxisalive.api.base.ApiBaseChildResource import ApiBaseChildResource -from Attitune import Attitune - -# ------------------------------------------------------------------------------ -# Attitunes container. -# ------------------------------------------------------------------------------ -class AttitunesContainer(ApiBaseChildResource): - """Attitunes container. - """ - - # -------------------------------------------------------------------------- - # Constructor of the class. - # -------------------------------------------------------------------------- - def __init__(self, apiBase, apiBaseServer, structure): - """Constructor of the class. - @param apiBase: ApiBase parent object. - @param apiBaseServer: ApiBaseServer object. - @param structure: Attitunes container structure as dictionary. - """ - ApiBaseChildResource.__init__(self, apiBase, apiBaseServer) - self.__mutex = threading.Lock() - self.__attitunes = [] - self._update(structure) - - # -------------------------------------------------------------------------- - # Update the container structure. - # -------------------------------------------------------------------------- - def _update(self, structure): - """Update the container structure. - @param structure: The new container structure dictionary. - """ - self.__mutex.acquire() - self.__attitunes = [] - for key in structure.keys(): - if key.lower().find('data') == 0: - self.__attitunes.append(Attitune(self.getParent(), - self.getServer(), self, structure[key])) - self.__mutex.release() - - # -------------------------------------------------------------------------- - # Get the attitune objects list. - # -------------------------------------------------------------------------- - def getAttitunes(self): - """Get the attitune objects list. - @return: A list of Attitune objects. - """ - self.__mutex.acquire() - result = self.__attitunes - self.__mutex.release() - return result - - # -------------------------------------------------------------------------- - # Get the number of attitunes contains in the container. - # -------------------------------------------------------------------------- - def getCount(self): - """Get the number of attitunes contains in the container. - @return: An integer. - """ - self.__mutex.acquire() - result = len(self.__attitunes) - self.__mutex.release() - return result - - # -------------------------------------------------------------------------- - # Show the attitunes name list in the console. - # -------------------------------------------------------------------------- - def showAttitunes(self): - """Show the attitunes name list in the console. - """ - result = [] - self.__mutex.acquire() - for attitune in self.__attitunes: - result.append(attitune.getDescription().getName()) - self.__mutex.release() - self._showStringList("Attitune names :", result) - - # -------------------------------------------------------------------------- - # Get an attitune object by it name or index. - # -------------------------------------------------------------------------- - def getAttitune(self, attitune): - """Get an attitune object by it name or index. - @param attitune: The name or index of the attitune. - @return: An Attitune object or None. - """ - self.__mutex.acquire() - if str(type(attitune)) == "<type 'int'>": - if attitune in range(len(self.__attitunes)): - result = self.__attitunes[attitune] - self.__mutex.release() - return result - else: - for attObject in self.__attitunes: - if attObject.getDescription().getName() == attitune: - result = attObject - self.__mutex.release() - return result - self.__mutex.release() - return None - - # -------------------------------------------------------------------------- - # Stop played attitune. - # -------------------------------------------------------------------------- - def stopAttitune(self): - """Stop played attitune. - @return: The success of the command. - """ - cmd = "attitune_manager/stop_attitune?" - return self._sendCommandBooleanResult(cmd) - - # -------------------------------------------------------------------------- - # Insert an attitune in the container. - # -------------------------------------------------------------------------- - def insertAttitune(self, attituneFileName): - """Insert an attitune in the container. - @param attituneFileName: Attitune file name. Can be a local or a distant - file. - @return: The success of the command. - """ - argsToSend = { - 'path' : attituneFileName, - } - cmd = "attitune_manager/insert_attitune?" - return self._sendCommandBooleanResult(cmd, argsToSend) - - # -------------------------------------------------------------------------- - # Remove an attitune from the container. - # -------------------------------------------------------------------------- - def removeAttitune(self, attituneName): - """Remove an attitune from the container. - @param attituneName: The name of the attitune. - @return: The success of the command. - """ - argsToSend = { - 'name' : attituneName, - } - cmd = "attitune_manager/remove_attitune?" - return self._sendCommandBooleanResult(cmd, argsToSend) Copied: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py (from rev 4557, softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/attitunes/AttitunesContainer.py) =================================================================== --- software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py (rev 0) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/attitunes/AttitunesContainer.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -0,0 +1,149 @@ +# Copyright (C) 2009 C2ME Sa +# Remi Jocaille <rem...@c2...> +# Distributed under the terms of the GNU General Public License +# http://www.gnu.org/copyleft/gpl.html + +import threading + +from tuxisalive.api.base.ApiBaseChildResource import ApiBaseChildResource +from Attitune import Attitune + +# ------------------------------------------------------------------------------ +# Attitunes container. +# ------------------------------------------------------------------------------ +class AttitunesContainer(ApiBaseChildResource): + """Attitunes container. + """ + + # -------------------------------------------------------------------------- + # Constructor of the class. + # -------------------------------------------------------------------------- + def __init__(self, apiBase, apiBaseServer, structure): + """Constructor of the class. + @param apiBase: ApiBase parent object. + @param apiBaseServer: ApiBaseServer object. + @param structure: Attitunes container structure as dictionary. + """ + ApiBaseChildResource.__init__(self, apiBase, apiBaseServer) + self.__mutex = threading.Lock() + self.__attitunes = [] + + # -------------------------------------------------------------------------- + # Update the container structure. + # -------------------------------------------------------------------------- + def _update(self, structure): + """Update the container structure. + @param structure: The new container structure dictionary. + """ + self.__mutex.acquire() + self.__attitunes = [] + keys = structure.keys() + keys.remove("result") + for i, key in enumerate(keys): + keys[i] = "%.3d" % int(key.replace("data", "")) + keys.sort() + for i, key in enumerate(keys): + keys[i] = "data%d" % int(key) + for key in keys: + self.__attitunes.append(Attitune(self.getParent(), + self.getServer(), self, structure[key])) + self.__mutex.release() + + # -------------------------------------------------------------------------- + # Get the attitune objects list. + # -------------------------------------------------------------------------- + def getAttitunes(self): + """Get the attitune objects list. + @return: A list of Attitune objects. + """ + self.__mutex.acquire() + result = self.__attitunes + self.__mutex.release() + return result + + # -------------------------------------------------------------------------- + # Get the number of attitunes contains in the container. + # -------------------------------------------------------------------------- + def getCount(self): + """Get the number of attitunes contains in the container. + @return: An integer. + """ + self.__mutex.acquire() + result = len(self.__attitunes) + self.__mutex.release() + return result + + # -------------------------------------------------------------------------- + # Show the attitunes name list in the console. + # -------------------------------------------------------------------------- + def showAttitunes(self): + """Show the attitunes name list in the console. + """ + result = [] + self.__mutex.acquire() + for attitune in self.__attitunes: + result.append(attitune.getDescription().getName()) + self.__mutex.release() + self._showStringList("Attitune names :", result) + + # -------------------------------------------------------------------------- + # Get an attitune object by it name or index. + # -------------------------------------------------------------------------- + def getAttitune(self, attitune): + """Get an attitune object by it name or index. + @param attitune: The name or index of the attitune. + @return: An Attitune object or None. + """ + self.__mutex.acquire() + if str(type(attitune)) == "<type 'int'>": + if attitune in range(len(self.__attitunes)): + result = self.__attitunes[attitune] + self.__mutex.release() + return result + else: + for attObject in self.__attitunes: + if attObject.getDescription().getName() == attitune: + result = attObject + self.__mutex.release() + return result + self.__mutex.release() + return None + + # -------------------------------------------------------------------------- + # Stop played attitune. + # -------------------------------------------------------------------------- + def stopAttitune(self): + """Stop played attitune. + @return: The success of the command. + """ + cmd = "attitune_manager/stop_attitune?" + return self._sendCommandBooleanResult(cmd) + + # -------------------------------------------------------------------------- + # Insert an attitune in the container. + # -------------------------------------------------------------------------- + def insertAttitune(self, attituneFileName): + """Insert an attitune in the container. + @param attituneFileName: Attitune file name. Can be a local or a distant + file. + @return: The success of the command. + """ + argsToSend = { + 'path' : attituneFileName, + } + cmd = "attitune_manager/insert_attitune?" + return self._sendCommandBooleanResult(cmd, argsToSend) + + # -------------------------------------------------------------------------- + # Remove an attitune from the container. + # -------------------------------------------------------------------------- + def removeAttitune(self, attituneName): + """Remove an attitune from the container. + @param attituneName: The name of the attitune. + @return: The success of the command. + """ + argsToSend = { + 'name' : attituneName, + } + cmd = "attitune_manager/remove_attitune?" + return self._sendCommandBooleanResult(cmd, argsToSend) Deleted: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py =================================================================== --- softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/base/ApiBaseChild.py 2009-04-10 12:51:53 UTC (rev 4469) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -1,179 +0,0 @@ -# -*- coding: latin1 -*- - -# Copyright (C) 2009 C2ME Sa -# Remi Jocaille <rem...@c2...> -# Distributed under the terms of the GNU General Public License -# http://www.gnu.org/copyleft/gpl.html - -from lib.Helper import Helper - -# ------------------------------------------------------------------------------ -# Base class to add functionalities in the API. -# ------------------------------------------------------------------------------ -class ApiBaseChild(Helper): - """Base class to add functionalities in the API. - """ - - # -------------------------------------------------------------------------- - # Constructor of the class. - # -------------------------------------------------------------------------- - def __init__(self, apiBase): - """Constructor of the class. - @param apiBase: ApiBase parent object. - """ - Helper.__init__(self) - self.__apiBase = apiBase - self.__eventsHandler = self.__apiBase.getEventsHandler() - self.__encoding = "latin-1" - self.__methodsList = [] - oElementsList = dir(self) - self.__methodsList.append("__init__") - for element in oElementsList: - if element.find("__") == -1: - if str(type(getattr(self, element)))== "<type 'instancemethod'>": - self.__methodsList.append(element) - - # -------------------------------------------------------------------------- - # Get the parent ApiBase object. - # -------------------------------------------------------------------------- - def getParent(self): - """Get the parent ApiBase object. - @return: A ApiBase object. - """ - return self.__apiBase - - # -------------------------------------------------------------------------- - # Get the global events handler. - # -------------------------------------------------------------------------- - def getEventsHandler(self): - """Get the global events handler. - @return: The events handler. - """ - return self.__eventsHandler - - # -------------------------------------------------------------------------- - # Set the source encoding. - # -------------------------------------------------------------------------- - def setEncoding(self, encoding = "latin-1"): - """Set the source encoding. Texts need to be encoded in "utf-8" before - to sending it to the HTTP server. - @param encoding: source encoding - example : "latin-1", "utf-8", "cp1252", ... - """ - self.__encoding = encoding - - # -------------------------------------------------------------------------- - # Set the current console encoding. - # -------------------------------------------------------------------------- - def isConsole(self): - """Set the current console encoding. - (Only if the api run in an interactive python context) - """ - import sys - self.__encoding = sys.stdin.encoding - - # -------------------------------------------------------------------------- - # Fixe a text with the correct encoding. - # -------------------------------------------------------------------------- - def _reencodeText(self, text, removeReturns = False): - """Fixe a text with the correct encoding. - @param text: Text to fixe. - @param removeReturns: True or False. Replace the returns chars by ". " - @return: The fixed text. - """ - # Try to encode the string - try: - text = text.decode(self.__encoding) - text = text.encode("utf-8", 'replace') - except: - pass - # Remove ending lines - if removeReturns: - text = text.replace("\n", ". ") - return text - - # -------------------------------------------------------------------------- - # Wait for a specific value of a status. - # -------------------------------------------------------------------------- - def _waitFor(self, statusName, statusValue, timeout = 99999.0): - """Wait for a specific value of a status. - @param statusName: Status name. - @param statusValue: Status value. - @param timeout: Maximal delay to wait. - """ - return self.__eventsHandler.waitCondition(statusName, (statusValue, - None), timeout) - - # -------------------------------------------------------------------------- - # Check the type of an object. - # -------------------------------------------------------------------------- - def _checkObjectType(self, name, value, requestedType): - """Check the type of an object. - @param name: Name of the object. - @param value: Current value of the object. - @param requestedType: Requested type. - """ - # Get the type of the value to check - vType = str(type(value)) - vType = vType[vType.find("'") + 1:vType.rfind("'")] - # Check the type of the value - if vType != requestedType: - print "Invalid type for [%s] : Need <type'%s'>" % (name, - requestedType) - return False - return True - - # -------------------------------------------------------------------------- - # Register a callback to an event. - # -------------------------------------------------------------------------- - def _registerEvent(self, eventName, eventValue, funct, idx = None): - """Register a callback to an event. - @param eventName: Event name. - @param eventValue: Event value. (can be None) - @param funct: pointer to the function. - @param idx: index from a previous register. - @return: the new index of the callback in the handler. - """ - nIdx = self.__eventsHandler.register(eventName, funct, (eventValue, - None), idx) - return nIdx - - # -------------------------------------------------------------------------- - # Unregister a callback from an event. - # -------------------------------------------------------------------------- - def _unregisterEvent(self, eventName, idx): - """Unregister a callback from an event. - Not available for CLIENT_LEVEL_ANONYME level. - @param eventName: Event name. - @param idx: index from a previous register. - """ - self.__eventsHandler.unregister(eventName, idx) - - # -------------------------------------------------------------------------- - # Insert a new event/status name in the events handler. - # -------------------------------------------------------------------------- - def _insertNewEvent(self, eventName): - """Insert a new event/status name in the events handler. - @param eventName: Event name. - """ - self.__eventsHandler.insert(eventName) - - # -------------------------------------------------------------------------- - # Get the last knowed value of a status/event. - # -------------------------------------------------------------------------- - def _requestOne(self, statusName): - """Get the last knowed value of a status/event. - @param statusName: Name of the status.event. - @return: The value. - """ - if not self._checkObjectType('statusName', statusName, "str"): - return None - eventHandler = self.__eventsHandler.getEventHandler(statusName) - if eventHandler == None: - return None - statusStruct = eventHandler.getLastState() - if statusStruct == None: - return None - if len(statusStruct) == 0: - return None - return statusStruct[0] Copied: software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py (from rev 4495, softwares_suite_v3/kysoh/tuxware/api/python/trunk/tuxisalive/api/base/ApiBaseChild.py) =================================================================== --- software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py (rev 0) +++ software_suite_v3/smart-core/smart-api/python/tags/before-plugin-gadget-refactoring/tuxisalive/api/base/ApiBaseChild.py 2009-05-05 07:53:02 UTC (rev 4625) @@ -0,0 +1,180 @@ +# -*- coding: latin1 -*- + +# Copyright (C) 2009 C2ME Sa +# Remi Jocaille <rem...@c2...> +# Distributed under the terms of the GNU General Public License +# http://www.gnu.org/copyleft/gpl.html + +from lib.Helper import Helper + +# ------------------------------------------------------------------------------ +# Base class to add functionalities in the API. +# ------------------------------------------------------------------------------ +class ApiBaseChild(Helper): + """Base class to add functionalities in the API. + """ + + __ENCODING = "latin-1" + + # -------------------------------------------------------------------------- + # Constructor of the class. + # -------------------------------------------------------------------------- + def __init__(self, apiBase): + """Constructor of the class. + @param apiBase: ApiBase parent object. + """ + Helper.__init__(self) + self.__apiBase = apiBase + self.__eventsHandler = self.__apiBase.getEventsHandler() + self.__methodsList = [] + oElementsList = dir(self) + self.__methodsList.append("__init__") + for element in oElementsList: + if element.find("__") == -1: + if str(type(getattr(self, element)))== "<type 'instancemethod'>": + self.__methodsList.append(element) + + # -------------------------------------------------------------------------- + # Get the parent ApiBase object. + # -------------------------------------------------------------------------- + def getParent(self): + """Get the parent ApiBase object. + @return: A ApiBase object. + """ + return self.__apiBase + + # -------------------------------------------------------------------------- + # Get the global events handler. + # -------------------------------------------------------------------------- + def getEventsHandler(self): + """Get the global events handler. + @return: The events handler. + """ + return self.__eventsHandler + + # -------------------------------------------------------------------------- + # Set the source encoding. + # -------------------------------------------------------------------------- + def setEncoding(self, encoding = "latin-1"): + """Set the source encoding. Texts need to be encoded in "utf-8" before + to sending it to the HTTP server. + @param encoding: source encoding + example : "latin-1", "utf-8", "cp1252", ... + """ + ApiBaseChild.__ENCODING = encoding + + # -------------------------------------------------------------------------- + # Set the current console encoding. + # -------------------------------------------------------------------------- + def isConsole(self): + """Set the current console encoding. + (Only if the api run in an interactive python context) + """ + import sys + ApiBaseChild.__ENCODING = sys.stdin.encoding + + # -------------------------------------------------------------------------- + # Fixe a text with the correct encoding. + # -------------------------------------------------------------------------- + def _reencodeText(self, text, removeReturns = False): + """Fixe a text with the correct encoding. + @param text: Text to fixe. + @param removeReturns: True or False. Replace the returns chars by ". " + @return: The fixed text. + """ + # Try to encode the string + try: + text = text.decode(ApiBaseChild.__ENCODING) + text = text.encode("utf-8", 'replace') + except: + pass + # Remove ending lines + if removeReturns: + text = text.replace("\n", ". ") + return text + + # -------------------------------------------------------------------------- + # Wait for a specific value of a status. + # -------------------------------------------------------------------------- + def _waitFor(self, statusName, statusValue, timeout = 99999.0): + """Wait for a specific value of a status. + @param statusName: Status name. + @param statusValue: Status value. + @param timeout: Maximal delay to wait. + """ + return self.__eventsHandler.waitCondition(statusName, (statusValue, + None), timeout) + + # -------------------------------------------------------------------------- + # Check the type of an object. + # -------------------------------------------------------------------------- + def _checkObjectType(self, name, value, requestedType): + """Check the type of an object. + @param name: Name of the object. + @param value: Current value of the object. + @param requestedType: Requested type. + """ + # Get the type of the value to check + vType = str(type(value)) + vType = vType[vType.find("'") + 1:vType.rfind("'")] + # Check ... [truncated message content] |
|
From: remi <c2m...@c2...> - 2009-05-05 07:51:41
|
Author: remi Date: 2009-05-05 09:51:32 +0200 (Tue, 05 May 2009) New Revision: 4624 Added: software_suite_v3/smart-core/smart-api/python/tags/ Log: * added a tags directory |
|
From: remi <c2m...@c2...> - 2009-05-05 07:50:57
|
Author: remi Date: 2009-05-05 09:50:43 +0200 (Tue, 05 May 2009) New Revision: 4623 Removed: softwares_suite_v3/kysoh/tuxware/server/trunk/ Log: * deleted old project |
|
From: remi <c2m...@c2...> - 2009-05-05 07:50:24
|
Author: remi Date: 2009-05-05 09:50:14 +0200 (Tue, 05 May 2009) New Revision: 4622 Added: software_suite_v3/smart-core/smart-server/tags/before-plugin-gadget-refactoring/ Log: * tagged the server project in the state before the plugin/gadget new philosophy Copied: software_suite_v3/smart-core/smart-server/tags/before-plugin-gadget-refactoring (from rev 4594, softwares_suite_v3/kysoh/tuxware/server/trunk) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:48:20
|
Author: remi Date: 2009-05-05 09:48:10 +0200 (Tue, 05 May 2009) New Revision: 4621 Added: software_suite_v3/smart-core/smart-server/tags/ Log: * added a tags directory for smart-server |
|
From: remi <c2m...@c2...> - 2009-05-05 07:45:59
|
Author: remi Date: 2009-05-05 09:45:41 +0200 (Tue, 05 May 2009) New Revision: 4620 Removed: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/java/tuxdroid-gadget-java-kit/ Log: * deleted old project |
|
From: remi <c2m...@c2...> - 2009-05-05 07:45:30
|
Author: remi Date: 2009-05-05 09:45:21 +0200 (Tue, 05 May 2009) New Revision: 4619 Added: software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/simpleplugin-java-kit/ Log: * moved simpleplugin-java-kit project Copied: software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/simpleplugin-java-kit (from rev 4471, softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/java/tuxdroid-gadget-java-kit) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:44:12
|
Author: remi Date: 2009-05-05 09:43:55 +0200 (Tue, 05 May 2009) New Revision: 4618 Removed: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/java/skeleton/trunk/ Log: * deleted old project |
|
From: remi <c2m...@c2...> - 2009-05-05 07:43:54
|
Author: remi Date: 2009-05-05 09:43:39 +0200 (Tue, 05 May 2009) New Revision: 4617 Added: software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/skeleton/trunk/ Log: * moved java plugin skeleton Copied: software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/skeleton/trunk (from rev 4473, softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/java/skeleton/trunk) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:42:49
|
Author: remi Date: 2009-05-05 09:42:39 +0200 (Tue, 05 May 2009) New Revision: 4616 Removed: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/ Log: * deleted old project |
|
From: remi <c2m...@c2...> - 2009-05-05 07:41:53
|
Author: remi Date: 2009-05-05 09:41:38 +0200 (Tue, 05 May 2009) New Revision: 4615 Added: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/ software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/resources/ Removed: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/resources/ Log: * moved python plugin skeleton Copied: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk (from rev 4474, softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk) Deleted: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py =================================================================== --- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py 2009-04-10 13:25:17 UTC (rev 4474) +++ software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py 2009-05-05 07:41:38 UTC (rev 4615) @@ -1,11 +0,0 @@ -# -*- coding: utf-8 -*- - -# Copyleft (C) 2009 C2ME Sa -# Remi Jocaille <rem...@c2...> -# Distributed under the terms of the GNU General Public License -# http://www.gnu.org/copyleft/gpl.html - -from builder.GadgetPackager import GadgetPackager - -if __name__ == "__main__": - GadgetPackager().createTgf("tuxdroid-gadget-pySkeleton.tgf") Copied: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py (from rev 4613, softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py) =================================================================== --- software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py (rev 0) +++ software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/build.py 2009-05-05 07:41:38 UTC (rev 4615) @@ -0,0 +1,11 @@ +# -*- coding: utf-8 -*- + +# Copyleft (C) 2009 C2ME Sa +# Remi Jocaille <rem...@c2...> +# Distributed under the terms of the GNU General Public License +# http://www.gnu.org/copyleft/gpl.html + +from builder.GadgetPackager import GadgetPackager + +if __name__ == "__main__": + GadgetPackager().createTgf("tuxdroid-gadget-pySkeleton.tpg") Copied: software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/trunk/resources (from rev 4614, softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:39:11
|
Author: remi Date: 2009-05-05 09:39:02 +0200 (Tue, 05 May 2009) New Revision: 4614 Added: software_suite_v3/smart-core/smart-dev/plugin-toolkit/ software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/ software_suite_v3/smart-core/smart-dev/plugin-toolkit/java/skeleton/ software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/ software_suite_v3/smart-core/smart-dev/plugin-toolkit/python/skeleton/ Log: * preparing to insert plugin skeletons |
|
From: remi <c2m...@c2...> - 2009-05-05 07:37:06
|
Author: remi
Date: 2009-05-05 09:36:54 +0200 (Tue, 05 May 2009)
New Revision: 4613
Added:
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.wiki
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/icon.png
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.pot
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.xml
Removed:
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.png
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.pot
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.xml
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.html
Modified:
softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py
Log:
* commit of the last changes before to move the project
Modified: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py 2009-05-05 07:34:31 UTC (rev 4612)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/build.py 2009-05-05 07:36:54 UTC (rev 4613)
@@ -8,4 +8,4 @@
from builder.GadgetPackager import GadgetPackager
if __name__ == "__main__":
- GadgetPackager().createTgf("tuxdroid-gadget-pySkeleton.tgf")
+ GadgetPackager().createTgf("tuxdroid-gadget-pySkeleton.tpg")
Deleted: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.png
===================================================================
(Binary files differ)
Deleted: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.pot
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.pot 2009-05-05 07:34:31 UTC (rev 4612)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.pot 2009-05-05 07:36:54 UTC (rev 4613)
@@ -1,41 +0,0 @@
-msgid "Python gadget skeleton"
-msgstr ""
-
-msgid "Python skeleton."
-msgstr ""
-
-msgid "This is a skeleton to build a python gadget."
-msgstr ""
-
-msgid "Simple string parameter"
-msgstr ""
-
-msgid "Simple integer parameter"
-msgstr ""
-
-msgid "Simple boolean parameter"
-msgstr ""
-
-msgid "Simple enumerated parameter"
-msgstr ""
-
-msgid "Linux only parameter"
-msgstr ""
-
-msgid "Only for Linux"
-msgstr ""
-
-msgid "Windows only parameter"
-msgstr ""
-
-msgid "Only for Windows"
-msgstr ""
-
-msgid "Simple run command"
-msgstr ""
-
-msgid "Daemon run command"
-msgstr ""
-
-msgid "Simple check command"
-msgstr ""
Deleted: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.xml
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.xml 2009-05-05 07:34:31 UTC (rev 4612)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/gadget.xml 2009-05-05 07:36:54 UTC (rev 4613)
@@ -1,68 +0,0 @@
-<gadget>
- <interpreter
- kind="python">
- <executable>executables/tux-gadget-skeleton.py</executable>
- </interpreter>
- <description>
- <name>Python gadget skeleton</name>
- <ttsName>Python skeleton.</ttsName>
- <description>This is a skeleton to build a python gadget.</description>
- <author>Kysoh</author>
- <version>0.0.1</version>
- <iconFile>resources/gadget.png</iconFile>
- <uuid>23ab109b-9bad-41cb-bca6-ab6d4bbe632e</uuid>
- <platform>all</platform>
- </description>
- <parameters>
- <parameter
- name="stringParam"
- description="Simple string parameter"
- type="string"
- defaultValue="My string"
- platform="all"/>
- <parameter
- name="integerParam"
- description="Simple integer parameter"
- type="integer"
- defaultValue="0"
- platform="all"/>
- <parameter
- name="booleanParam"
- description="Simple boolean parameter"
- type="boolean"
- defaultValue="false"
- platform="all"/>
- <parameter
- name="enumeratedParam"
- description="Simple enumerated parameter"
- type="enum(value1,value2,value3,value4,valueN)"
- defaultValue="value1"
- platform="all"/>
- <parameter
- name="linuxParam"
- description="Linux only parameter"
- type="string"
- defaultValue="Only for Linux"
- platform="linux"/>
- <parameter
- name="windowsParam"
- description="Windows only parameter"
- type="string"
- defaultValue="Only for Windows"
- platform="windows"/>
- </parameters>
- <commands>
- <command
- name="run"
- description="Simple run command"
- daemon="false" />
- <command
- name="run_daemon"
- description="Daemon run command"
- daemon="true" />
- <command
- name="check"
- description="Simple check command"
- daemon="false" />
- </commands>
-</gadget>
Deleted: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.html
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.html 2009-05-05 07:34:31 UTC (rev 4612)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.html 2009-05-05 07:36:54 UTC (rev 4613)
@@ -1,6 +0,0 @@
-<html>
-<body>
-<font size="2" face="Verdana, Arial, Helvetica, sans-serif">This is a skeleton to build a python gadget.<br>
-</font>
-</body>
-</html>
Added: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.wiki
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.wiki (rev 0)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.wiki 2009-05-05 07:36:54 UTC (rev 4613)
@@ -0,0 +1,25 @@
+= Synopsis =
+This is a skeleton to help developpers to build they first plugin.
+
+== Some markup tests ==
+Some markup tests.
+* a mixed
+* multilevel
+*1. list
+*1I. with
+*1I. roman
+*1Ig. and
+*1Ig. greek
+*1. letters
+
+A plugin from the [http://www.kysoh.com, Kysoh] compagny.
+
+; '''Plugin definition''': ''A plugin is a set of functions stored in a tpg file.''
+
+== An example of table ==
+
+[{>,w:80\%,b}| '''Plugin name''' | '''On demand''' | '''Have alerts''' |
+| Battery monitor | ''No'' | ''Yes'' |
+| Feed RSS | ''Yes'' | ''Yes'' |
+| Webradio | ''Yes'' | ''Yes'' |
+| Clipboard | ''Yes'' | ''No'' |]
\ No newline at end of file
Property changes on: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/help.wiki
___________________________________________________________________
Name: svn:keywords
+ Id
Added: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/icon.png
===================================================================
(Binary files differ)
Property changes on: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/icon.png
___________________________________________________________________
Name: svn:mime-type
+ application/octet-stream
Name: svn:keywords
+ Id
Added: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.pot
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.pot (rev 0)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.pot 2009-05-05 07:36:54 UTC (rev 4613)
@@ -0,0 +1,41 @@
+msgid "Python plugin skeleton"
+msgstr ""
+
+msgid "Python skeleton."
+msgstr ""
+
+msgid "This is a skeleton to build a python plugin."
+msgstr ""
+
+msgid "Simple string parameter"
+msgstr ""
+
+msgid "Simple integer parameter"
+msgstr ""
+
+msgid "Simple boolean parameter"
+msgstr ""
+
+msgid "Simple enumerated parameter"
+msgstr ""
+
+msgid "Linux only parameter"
+msgstr ""
+
+msgid "Only for Linux"
+msgstr ""
+
+msgid "Windows only parameter"
+msgstr ""
+
+msgid "Only for Windows"
+msgstr ""
+
+msgid "Simple run command"
+msgstr ""
+
+msgid "Daemon run command"
+msgstr ""
+
+msgid "Simple check command"
+msgstr ""
Property changes on: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.pot
___________________________________________________________________
Name: svn:keywords
+ Id
Added: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.xml
===================================================================
--- softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.xml (rev 0)
+++ softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.xml 2009-05-05 07:36:54 UTC (rev 4613)
@@ -0,0 +1,174 @@
+<plugin>
+ <interpreter
+ kind="python">
+ <executable>executables/tux-gadget-skeleton.py</executable>
+ </interpreter>
+ <description>
+ <name>Python plugin skeleton</name>
+ <ttsName>Python plugin.</ttsName>
+ <description>This is a skeleton to build a python plugin.</description>
+ <author>Kysoh</author>
+ <version>0.0.1</version>
+ <iconFile>resources/icon.png</iconFile>
+ <uuid>23ab109b-9bad-41cb-bca6-ab6d4bbe632e</uuid>
+ <platform>all</platform>
+ </description>
+ <parameters>
+ <parameter
+ name="stringParam"
+ description="Simple string parameter"
+ type="string"
+ defaultValue="My string"
+ platform="all"/>
+ <parameter
+ name="integerParam"
+ description="Simple integer parameter"
+ type="integer"
+ defaultValue="0"
+ platform="all"/>
+ <parameter
+ name="booleanParam"
+ description="Simple boolean parameter"
+ type="boolean"
+ defaultValue="false"
+ platform="all"/>
+ <parameter
+ name="enumeratedParam"
+ description="Simple enumerated parameter"
+ type="enum(value1,value2,value3,value4,valueN)"
+ defaultValue="value1"
+ platform="all"/>
+ <parameter
+ name="linuxParam"
+ description="Linux only parameter"
+ type="string"
+ defaultValue="Only for Linux"
+ platform="linux"/>
+ <parameter
+ name="windowsParam"
+ description="Windows only parameter"
+ type="string"
+ defaultValue="Only for Windows"
+ platform="windows"/>
+ </parameters>
+ <commands>
+ <command
+ name="run"
+ description="Simple run command"
+ daemon="false" />
+ <command
+ name="run_daemon"
+ description="Daemon run command"
+ daemon="true" />
+ <command
+ name="check"
+ description="Simple check command"
+ daemon="false" />
+ </commands>
+ <tasks>
+ <task
+ name="My checker"
+ description="Check a condition every x minutes"
+ command="check"
+ type="every x"
+ activated="false"
+
+ weekMask="true,false,false,false,false,false,false"
+ weekMaskType="exclusive"
+ weekMaskVisible="true"
+
+ date="0000/00/00"
+ dateVisible="false"
+
+ hoursBegin="00:00:00"
+ hoursBeginMask="true,true,false"
+ hoursBeginVisible="true"
+
+ hoursEnd="23:59:00"
+ hoursEndMask="true,true,false"
+ hoursEndVisible="true"
+
+ delay="00:01:00"
+ delayMask="false,true,false"
+ delayVisible="true"
+ />
+ <task
+ name="My daemon"
+ description="Manages my daemon"
+ command="run_daemon"
+ type="daily at"
+ activated="false"
+
+ weekMask="true,true,true,true,true,true,true"
+ weekMaskType="weekpart"
+ weekMaskVisible="true"
+
+ date="2009/10/10"
+ dateVisible="false"
+
+ hoursBegin="07:00:00"
+ hoursBeginMask="true,true,false"
+ hoursBeginVisible="true"
+
+ hoursEnd="10:00:00"
+ hoursEndMask="true,true,false"
+ hoursEndVisible="true"
+
+ delay="00:01:00"
+ delayMask="false,true,false"
+ delayVisible="false"
+ />
+ <task
+ name="Anniversary"
+ description="Don't forget my anniversary !"
+ command="run"
+ type="once at"
+ activated="false"
+
+ weekMask="true,true,true,true,true,true,true"
+ weekMaskType="flat"
+ weekMaskVisible="false"
+
+ date="2009/10/10"
+ dateVisible="true"
+
+ hoursBegin="10:00:00"
+ hoursBeginMask="true,true,false"
+ hoursBeginVisible="true"
+
+ hoursEnd="23:59:00"
+ hoursEndMask="true,true,false"
+ hoursEndVisible="false"
+
+ delay="00:01:00"
+ delayMask="false,true,false"
+ delayVisible="false"
+ />
+ <task
+ name="A complete alert configuration"
+ description="This show a complet alert configuration"
+ command="run"
+ type="daily at"
+ activated="false"
+
+ weekMask="true,true,true,true,true,true,true"
+ weekMaskType="flat"
+ weekMaskVisible="true"
+
+ date="2009/12/31"
+ dateVisible="true"
+
+ hoursBegin="10:00:00"
+ hoursBeginMask="true,true,true"
+ hoursBeginVisible="true"
+
+ hoursEnd="11:59:00"
+ hoursEndMask="true,true,true"
+ hoursEndVisible="true"
+
+ delay="00:01:00"
+ delayMask="true,true,true"
+ delayVisible="true"
+ />
+ </tasks>
+</plugin>
Property changes on: softwares_suite_v3/kysoh/software/development_tool/gadget_toolkit/python/skeleton/trunk/resources/plugin.xml
___________________________________________________________________
Name: svn:keywords
+ Id
|
|
From: remi <c2m...@c2...> - 2009-05-05 07:34:52
|
Author: remi Date: 2009-05-05 09:34:31 +0200 (Tue, 05 May 2009) New Revision: 4612 Removed: softwares_suite_v3/kysoh/tuxware/api/python/branches/0.3.0-plugins-gadgets-conf/ Log: * removed useless branches |
|
From: remi <c2m...@c2...> - 2009-05-05 07:34:06
|
Author: remi Date: 2009-05-05 09:34:01 +0200 (Tue, 05 May 2009) New Revision: 4611 Added: software_suite_v3/smart-core/smart-api/python/trunk/ Log: * moved last branches from python api to this trunk Copied: software_suite_v3/smart-core/smart-api/python/trunk (from rev 4596, softwares_suite_v3/kysoh/tuxware/api/python/branches/0.3.0-plugins-gadgets-conf) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:31:49
|
Author: remi Date: 2009-05-05 09:31:38 +0200 (Tue, 05 May 2009) New Revision: 4610 Added: software_suite_v3/smart-core/smart-api/python/ Log: * added smart-api python repository |
|
From: remi <c2m...@c2...> - 2009-05-05 07:30:31
|
Author: remi Date: 2009-05-05 09:30:03 +0200 (Tue, 05 May 2009) New Revision: 4609 Removed: softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs/ Log: * removed this branches |
|
From: remi <c2m...@c2...> - 2009-05-05 07:29:51
|
Author: remi Date: 2009-05-05 09:29:41 +0200 (Tue, 05 May 2009) New Revision: 4608 Added: software_suite_v3/smart-core/smart-server/trunk/ Log: * moved smart-server from a preview branches to this trunk Copied: software_suite_v3/smart-core/smart-server/trunk (from rev 4607, softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs) |
|
From: remi <c2m...@c2...> - 2009-05-05 07:19:24
|
Author: remi Date: 2009-05-05 09:19:11 +0200 (Tue, 05 May 2009) New Revision: 4607 Added: software_suite_v3/ software_suite_v3/smart-core/ software_suite_v3/smart-core/smart-api/ software_suite_v3/smart-core/smart-dev/ software_suite_v3/smart-core/smart-server/ software_suite_v3/software/ software_suite_v3/software/plugin/ software_suite_v3/software/script/ software_suite_v3/software/tool/ Log: * started new software suite repository with "smart-core" terminology |
|
From: remi <c2m...@c2...> - 2009-05-01 08:46:30
|
Author: remi
Date: 2009-05-01 10:46:22 +0200 (Fri, 01 May 2009)
New Revision: 4606
Modified:
softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs/TuxDroidServer.py
Log:
* serve needed files for skin
Modified: softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs/TuxDroidServer.py
===================================================================
--- softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs/TuxDroidServer.py 2009-05-01 08:36:01 UTC (rev 4605)
+++ softwares_suite_v3/kysoh/tuxware/server/branches/0.3.0-plugins-gadgets-confs/TuxDroidServer.py 2009-05-01 08:46:22 UTC (rev 4606)
@@ -65,6 +65,12 @@
resourcesManager.addDirectoryToServe("/data/gif/")
resourcesManager.addFileToServe(os.path.join(TDS_APPLICATION_PATH,
"data", "favicon", "favicon.ico"), "/favicon.ico")
+ # Load wiky scripts
+ resourcesManager.addDirectoryToServe("/data/web_interface/common/wiky/")
+ # Load skins
+ resourcesManager.addDirectoryToServe("/data/web_interface/01/xsl/")
+ resourcesManager.addDirectoryToServe("/data/web_interface/01/css/")
+ resourcesManager.addDirectoryToServe("/data/web_interface/01/gif/")
resourcesManager.start()
# Start the clients manager
clientsManager.start()
|