Project

General

Profile

Actions

Feature #312

closed

System.HasAddon() boolean condition

Added by dandar3 almost 10 years ago. Updated over 9 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
Other (un-categorized)
Target version:
Start date:
26/07/2014
Due date:
% Done:

100%

Resolution:
fixed

Description

Feature requested on the forums by Byron to so can add "XBMC Subtitles" to a skin, see:
http://www.xbmc4xbox.org.uk/forum/viewtopic.php?f=15&t=2939&p=23273

System.HasAddon() boolean condition
http://wiki.xbmc.org/index.php?title=List_of_boolean_conditions

Please see attached a patch and a test script, please review.

Implemented was aimed at scripts and obviously we don't have an Addons database yet, so it checks for addon (script) directory on disk. It doesn't read and check the addon.xml in all addon folders (thought might be too expensive, especially if used with a skin), so it just deduces the location from the addon id, e.g. for "script.xbmc.subtitles" it checks "special://xbmc/scripts/xbmc subtitles".


Files

test_hasaddon.py (395 Bytes) test_hasaddon.py dandar3, 26/07/2014 05:58 PM
System.HasAddon.patch (3.79 KB) System.HasAddon.patch dandar3, 18/08/2014 08:38 PM
Actions

Also available in: Atom PDF