The branch, eden has been updated
via 5a1c0aff8b1f2122346986b831ab0b8f2b5adfba (commit)
via 963b529bad0a2ae719f8e19d219d176e3b95394f (commit)
via 4b1f9c0841f7653498089753c78be2e64104b3e0 (commit)
from 9b3bf123574e445db89878bda6ff3021d601bdf5 (commit)
- Log -----------------------------------------------------------------
http://xbmc.git.sourceforge.net/git/gitweb.cgi?p=xbmc/scripts;a=commit;h=5a1c0aff8b1f2122346986b831ab0b8f2b5adfba
http://xbmc.git.sourceforge.net/git/gitweb.cgi?p=xbmc/scripts;a=commit;h=963b529bad0a2ae719f8e19d219d176e3b95394f
commit 963b529bad0a2ae719f8e19d219d176e3b95394f
Author: amet <[email protected]>
Date: Tue Jun 19 11:06:51 2012 +0400
[script.commands] -v1.0.1
- Added parameter for mapping multiple buttons
diff --git a/script.commands/addon.xml b/script.commands/addon.xml
index c2dd88e..9a24bfc 100644
--- a/script.commands/addon.xml
+++ b/script.commands/addon.xml
@@ -1,20 +1,20 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="script.commands"
name="Commands"
- version="1.0.0"
+ version="1.0.1"
provider-name="AddonScriptorDE">
<requires>
<import addon="xbmc.python" version="2.0"/>
</requires>
- <extension point="xbmc.python.script"
+ <extension point="xbmc.python.pluginsource"
library="default.py">
<provides>executable</provides>
</extension>
<extension point="xbmc.addon.metadata">
- <summary lang="en">Add multiple XBMC commands to one remote button. All
availabe commands:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</summary>
+ <summary lang="en">Map multiple XBMC commands to one remote button. All
availabe commands:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</summary>
<summary lang="de">Mehrere XBMC Befehle einer Taste zuweisen. Alle
verfügbaren Befehle:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</summary>
<language></language>
- <description lang="en">Add multiple XBMC commands to one remote button.
All availabe commands:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</description>
+ <description lang="en">Map multiple XBMC commands to one remote button.
All availabe commands:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</description>
<description lang="de">Mehrere XBMC Befehle einer Taste zuweisen. Alle
verfügbaren Befehle:
http://wiki.xbmc.org/?title=List_of_Built_In_Functions</description>
<platform>all</platform>
</extension>
diff --git a/script.commands/changelog.txt b/script.commands/changelog.txt
index 5905898..e09285d 100644
--- a/script.commands/changelog.txt
+++ b/script.commands/changelog.txt
@@ -1,2 +1,4 @@
1.0.0
-- First Try
\ No newline at end of file
+- First Try
+1.0.1
+- Added parameter for mapping multiple buttons
\ No newline at end of file
diff --git a/script.commands/default.py b/script.commands/default.py
index 04ab66a..681fbb5 100644
--- a/script.commands/default.py
+++ b/script.commands/default.py
@@ -13,19 +13,19 @@ translation = settings.getLocalizedString
if not os.path.isdir(addon_work_folder):
os.mkdir(addon_work_folder)
-def importCommands():
+def importCommands(key):
global myCommands
myCommands=[]
- if os.path.exists(commandsFile):
- fh = open(commandsFile, 'r')
+ if os.path.exists(commandsFile+key):
+ fh = open(commandsFile+key, 'r')
for line in fh:
myCommands.append(line.replace("\n",""))
fh.close()
myCommands.append("- "+translation(30001))
myCommands.append("- "+translation(30005))
-def commandsMain():
- importCommands()
+def commandsMain(key):
+ importCommands(key)
myCommandsTemp=[]
for temp in myCommands:
if temp.find("###")>=0:
@@ -41,26 +41,26 @@ def commandsMain():
command = entry[entry.find("###")+3:]
xbmc.executebuiltin(command)
if entry=="- "+translation(30001):
- addCommand()
+ addCommand(key)
elif entry=="- "+translation(30005):
- manageCommands()
+ manageCommands(key)
-def addCommand():
+def addCommand(key):
dialog = xbmcgui.Dialog()
modes=[translation(30002),translation(30003),translation(30004)]
nr=dialog.select(translation(30001), modes)
if nr>=0:
mode = modes[nr]
if mode==translation(30002):
- addCommandList()
+ addCommandList(key)
elif mode==translation(30003):
- addCommandFavs()
+ addCommandFavs(key)
elif mode==translation(30004):
- addCommandEnter()
+ addCommandEnter(key)
else:
- commandsMain()
+ commandsMain(key)
-def addCommandList():
+def addCommandList(key):
if os.path.exists(commandsList):
favs=[]
fh = open(commandsList, 'r')
@@ -77,14 +77,14 @@ def addCommandList():
title = entry[:entry.find("###")]
command = entry[entry.find("###")+3:]
if title+"###"+command not in myCommands:
- fh = open(commandsFile, 'a')
+ fh = open(commandsFile+key, 'a')
fh.write(title+"###"+command+"\n")
fh.close()
- commandsMain()
+ commandsMain(key)
else:
- addCommand()
+ addCommand(key)
-def addCommandFavs():
+def addCommandFavs(key):
if os.path.exists(favsFile):
favs=[]
fh = open(favsFile, 'r')
@@ -106,15 +106,15 @@ def addCommandFavs():
title = entry[:entry.find("###")]
command = entry[entry.find("###")+3:]
if title+"###"+command not in myCommands:
- fh = open(commandsFile, 'a')
+ fh = open(commandsFile+key, 'a')
fh.write(title+"###"+command+"\n")
fh.close()
- commandsMain()
+ commandsMain(key)
else:
- addCommand()
+ addCommand(key)
-def addCommandEnter():
- kb = xbmc.Keyboard("", "Title")
+def addCommandEnter(key):
+ kb = xbmc.Keyboard("", translation(30010))
kb.doModal()
if kb.isConfirmed():
title=kb.getText()
@@ -123,31 +123,31 @@ def addCommandEnter():
if kb.isConfirmed():
command=kb.getText()
if title+"###"+command not in myCommands:
- fh = open(commandsFile, 'a')
+ fh = open(commandsFile+key, 'a')
fh.write(title+"###"+command+"\n")
fh.close()
- commandsMain()
+ commandsMain(key)
else:
- addCommand()
+ addCommand(key)
else:
- addCommand()
+ addCommand(key)
-def manageCommands():
+def manageCommands(key):
dialog = xbmcgui.Dialog()
modes=[translation(30006),translation(30007),translation(30008)]
nr=dialog.select(translation(30005), modes)
if nr>=0:
mode = modes[nr]
if mode==translation(30006):
- manageCommandsEdit()
+ manageCommandsEdit(key)
elif mode==translation(30007):
- manageCommandsRemove()
+ manageCommandsRemove(key)
elif mode==translation(30008):
- manageCommandsSort()
+ manageCommandsSort(key)
else:
- commandsMain()
+ commandsMain(key)
-def manageCommandsEdit():
+def manageCommandsEdit(key):
myCommandsTemp=[]
for temp in myCommands:
if temp.find("###")>=0:
@@ -170,22 +170,22 @@ def manageCommandsEdit():
if kb.isConfirmed():
command=kb.getText()
newContent=""
- fh = open(commandsFile, 'r')
+ fh = open(commandsFile+key, 'r')
for line in fh:
if line.find(oldTitle+"###")==0:
newContent+=line.replace(oldTitle,title).replace(oldCommand,command)
else:
newContent+=line
fh.close()
- fh=open(commandsFile, 'w')
+ fh=open(commandsFile+key, 'w')
fh.write(newContent)
fh.close()
- importCommands()
- manageCommandsEdit()
+ importCommands(key)
+ manageCommandsEdit(key)
else:
- manageCommands()
+ manageCommands(key)
-def manageCommandsRemove():
+def manageCommandsRemove(key):
myCommandsTemp=[]
for temp in myCommands:
if temp.find("###")>=0:
@@ -198,22 +198,22 @@ def manageCommandsRemove():
title = entry[:entry.find("###")]
command = entry[entry.find("###")+3:]
newContent=""
- fh = open(commandsFile, 'r')
+ fh = open(commandsFile+key, 'r')
for line in fh:
if line.find(title+"###")==0:
pass
else:
newContent+=line
fh.close()
- fh=open(commandsFile, 'w')
+ fh=open(commandsFile+key, 'w')
fh.write(newContent)
fh.close()
- importCommands()
- manageCommandsRemove()
+ importCommands(key)
+ manageCommandsRemove(key)
else:
- manageCommands()
+ manageCommands(key)
-def manageCommandsSort():
+def manageCommandsSort(key):
myCommandsTemp=[]
for temp in myCommands:
if temp.find("###")>=0:
@@ -231,18 +231,18 @@ def manageCommandsSort():
pos=-1
if int(pos)<len(myCommandsTemp) and int(pos)>0:
newContent=""
- fh = open(commandsFile, 'r')
+ fh = open(commandsFile+key, 'r')
for line in fh:
if line.find(entry)==0:
pass
else:
newContent+=line
fh.close()
- fh=open(commandsFile, 'w')
+ fh=open(commandsFile+key, 'w')
fh.write(newContent)
fh.close()
newContent=""
- fh = open(commandsFile, 'r')
+ fh = open(commandsFile+key, 'r')
lineNr=1
for line in fh:
if int(pos)==lineNr:
@@ -252,14 +252,33 @@ def manageCommandsSort():
newContent+=line
lineNr+=1
fh.close()
- fh=open(commandsFile, 'w')
+ fh=open(commandsFile+key, 'w')
fh.write(newContent)
fh.close()
- importCommands()
- manageCommandsSort()
+ importCommands(key)
+ manageCommandsSort(key)
else:
- manageCommandsSort()
+ manageCommandsSort(key)
else:
- manageCommands()
+ manageCommands(key)
-commandsMain()
+def parameters_string_to_dict(parameters):
+ ''' Convert parameters encoded in a URL to a dict. '''
+ paramDict = {}
+ if parameters:
+ paramPairs = parameters[1:].split("&")
+ for paramsPair in paramPairs:
+ paramSplits = paramsPair.split('=')
+ if (len(paramSplits)) == 2:
+ paramDict[paramSplits[0]] = paramSplits[1]
+ return paramDict
+
+params=parameters_string_to_dict(sys.argv[2])
+key=params.get('key')
+if type(key)!=type(str()):
+ key=''
+
+if key != '':
+ commandsMain('_'+key)
+else:
+ commandsMain('')
http://xbmc.git.sourceforge.net/git/gitweb.cgi?p=xbmc/scripts;a=commit;h=4b1f9c0841f7653498089753c78be2e64104b3e0
commit 4b1f9c0841f7653498089753c78be2e64104b3e0
Author: amet <[email protected]>
Date: Tue Jun 19 11:03:58 2012 +0400
[script.simpleplaylists] -v1.1.0
- Fixed bug when adding currently playing videos
diff --git a/script.simpleplaylists/addon.xml b/script.simpleplaylists/addon.xml
index 5545992..96de2f9 100644
--- a/script.simpleplaylists/addon.xml
+++ b/script.simpleplaylists/addon.xml
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<addon id="script.simpleplaylists"
name="SimplePlaylists"
- version="1.0.9"
+ version="1.1.0"
provider-name="AddonScriptorDE">
<requires>
<import addon="xbmc.python" version="2.0"/>
diff --git a/script.simpleplaylists/changelog.txt
b/script.simpleplaylists/changelog.txt
index 359a5cd..325bd4b 100644
--- a/script.simpleplaylists/changelog.txt
+++ b/script.simpleplaylists/changelog.txt
@@ -50,3 +50,6 @@
- Added context menu for renaming playlist items
- Added some more db infos
- Fixed some bugs
+
+1.1.0
+- Fixed bug when adding currently playing videos
\ No newline at end of file
diff --git a/script.simpleplaylists/default.py
b/script.simpleplaylists/default.py
index 75ce529..7715b0d 100644
--- a/script.simpleplaylists/default.py
+++ b/script.simpleplaylists/default.py
@@ -253,14 +253,17 @@ def addCurrentUrl():
if url=="" and isAlbum==False:
addModePlaying="true"
if xbmc.Player().isPlayingVideo():
- title = xbmc.Player().getVideoInfoTag().getTitle()
- url = xbmc.Player().getVideoInfoTag().getPath()
+ playlist = xbmc.PlayList(xbmc.PLAYLIST_VIDEO)
+ if playlist.getposition()>=0:
+ title = playlist[playlist.getposition()].getdescription()
+ url = playlist[playlist.getposition()].getfilename()
+ thumb=xbmc.getInfoImage('VideoPlayer.Cover')
elif xbmc.Player().isPlayingAudio():
title = xbmc.Player().getMusicInfoTag().getArtist()+" -
"+xbmc.Player().getMusicInfoTag().getTitle()
url = xbmc.Player().getMusicInfoTag().getURL()
+ thumb=xbmc.getInfoImage('MusicPlayer.Cover')
if url!="" and addModePlaying=="true":
isDir=False
- thumb=xbmc.getInfoImage('VideoPlayer.Cover')
plot = xbmc.getInfoLabel('VideoPlayer.Plot')
genre = xbmc.getInfoLabel('VideoPlayer.Genre')
year = xbmc.getInfoLabel('VideoPlayer.Year')
-----------------------------------------------------------------------
Summary of changes:
script.commands/addon.xml | 8 +-
script.commands/changelog.txt | 4 +-
script.commands/default.py | 125 ++-
script.module.gmusicapi/LICENSE.txt | 24 +
script.module.gmusicapi/README.md | 4 +
script.module.gmusicapi/addon.xml | 21 +
script.module.gmusicapi/changelog.txt | 2 +
script.module.gmusicapi/lib/gmusicapi/__init__.py | 31 +
script.module.gmusicapi/lib/gmusicapi/api.py | 1081 ++++++++++++++++++++
.../lib/gmusicapi/gmtools/__init__.py | 26 +
.../lib/gmusicapi/gmtools/tools.py | 444 ++++++++
.../lib/gmusicapi/metadata_pb2.py | 701 +++++++++++++
script.module.gmusicapi/lib/gmusicapi/protocol.py | 873 ++++++++++++++++
.../lib/gmusicapi/utils/__init__.py | 26 +
.../lib/gmusicapi/utils/apilogging.py | 101 ++
.../lib/gmusicapi/utils/clientlogin.py | 196 ++++
.../lib/gmusicapi/utils/tokenauth.py | 122 +++
.../lib/gmusicapi/utils/utils.py | 155 +++
script.simpleplaylists/addon.xml | 2 +-
script.simpleplaylists/changelog.txt | 3 +
script.simpleplaylists/default.py | 9 +-
21 files changed, 3896 insertions(+), 62 deletions(-)
create mode 100644 script.module.gmusicapi/LICENSE.txt
create mode 100644 script.module.gmusicapi/README.md
create mode 100644 script.module.gmusicapi/addon.xml
create mode 100644 script.module.gmusicapi/changelog.txt
create mode 100644 script.module.gmusicapi/lib/gmusicapi/__init__.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/api.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/gmtools/__init__.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/gmtools/tools.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/metadata_pb2.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/protocol.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/utils/__init__.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/utils/apilogging.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/utils/clientlogin.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/utils/tokenauth.py
create mode 100644 script.module.gmusicapi/lib/gmusicapi/utils/utils.py
hooks/post-receive
--
Scripts
------------------------------------------------------------------------------
Live Security Virtual Conference
Exclusive live event will cover all the ways today's security and
threat landscape has changed and how IT managers can respond. Discussions
will include endpoint security, mobile security and the latest in malware
threats. http://www.accelacomm.com/jaw/sfrnl04242012/114/50122263/
_______________________________________________
Xbmc-addons mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xbmc-addons