XBMC Picture Library Built On a New Library Abstraction Framework
#6
this is how I think of the library addons. I added a library extension-point, and the .xsd schema lets your addon.xml file look like this

Code:
<extension point="xbmc.library" name="Picture Library">
    <database name="MyPictures" version="1"/>
</extension>

I added a new abstract database alongside videos, music, et al. It's about 12 lines of code ATM. because it overrides CDatabase, you can bump the version in addon.xml and XBMC will automatically create a new database (MyPictures2), copy the data over, and hand the new data over to a python program including the previous version number (basically so python programs can have a UpdateOldVersion())

I also added <libraryaddonsdatabase> to as.xml, so that XBMC can use SQLite or MySQL -- all completely transparent to the python program

Image

currently, you can disable libraries in the skin. I find this to be an egregious offence of separation of presentation and content. Now that libraries have a way to be managed, you should be able to hide an item from your home menu by disabling it in the addon manager. Likewise, enabling the addon again should show it in the home menu.

Image

still in the concept stage, of course, but I think it'd make a good GSoC project and when the summer ends it'll finally let add-on authors make new libraries without reinventing the wheel every time
Reply


Messages In This Thread
RE: XBMC Picture Library Built On a New Library Abstraction Framework - by garbear - 2012-04-06, 14:31
Logout Mark Read Team Forum Stats Members Help
XBMC Picture Library Built On a New Library Abstraction Framework0