2014-11-07, 10:50
Hi,
Long time Metropolis user, it is the best xbmc skin by a country mile.
I am trying to work out how to modify the skins context menu to include the Trakt Custom Actions (https://github.com/trakt/script.trakt/wiki) but I am very new to modifying skins and I don't seem to be getting very far.
From reading in the forums it looks as though the best way to implement these actions to the skin is to include them in the context menu through DialogContextMenu.xml. ezechiel1917 has provided an example for the Transparency skin but it doesn't seem to work when used within the metropolis DialogContextMenu.xml file and I don't know enough about the structure and format of the xml file to work out how to modify it to work within metropolis.
If someone could point me in the right direction then it would be really appreciated.
Thanks heaps.
Long time Metropolis user, it is the best xbmc skin by a country mile.
I am trying to work out how to modify the skins context menu to include the Trakt Custom Actions (https://github.com/trakt/script.trakt/wiki) but I am very new to modifying skins and I don't seem to be getting very far.
From reading in the forums it looks as though the best way to implement these actions to the skin is to include them in the context menu through DialogContextMenu.xml. ezechiel1917 has provided an example for the Transparency skin but it doesn't seem to work when used within the metropolis DialogContextMenu.xml file and I don't know enough about the structure and format of the xml file to work out how to modify it to work within metropolis.
Code:
<control type="button" id="1247">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Rate on trakt.tv</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=rate)</onclick>
<visible>!IsEmpty(ListItem.TVShowTitle) + !IsEmpty(ListItem.DBID) + !StringCompare(ListItem.Label,All seasons) + !SubString(ListItem.Label,Season ,,left) + !StringCompare(ListItem.Label,Specials) | [SubString(Container.FolderPath,videodb://Movies/) | SubString(Container.FolderPath,library://Video/Movies/Titles.xml) | SubString(Container.FolderPath,videodb://RecentlyAddedMovies) | SubString(Container.FolderPath,special://profile/playlists/video/Movies)]</visible>
</control>
<control type="button" id="1248">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Add to trakt.tv Watchlist</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=addtolist,list=Watchlist)</onclick>
<visible>!IsEmpty(ListItem.DBID) + !IsEmpty(ListItem.Duration) + [SubString(Container.FolderPath,library://Video/Movies/Titles.xml) | [!IsEmpty(ListItem.DBID) + SubString(Container.FolderPath,videodb://movies/ + !SubString(Container.FolderPath,videodb://movies/tags/)] | SubString(Container.FolderPath,videodb://RecentlyAddedMovies)] | [SubString(Container.FolderPath,special://profile/playlists/video/Movies) + !SubString(Container.FolderPath,special://profile/playlists/video/Movies Watchlist)]]</visible>
</control>
<control type="button" id="1249">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Remove from trakt.tv Watchlist</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=removefromlist,list=Watchlist)</onclick>
<visible>!IsEmpty(ListItem.DBID) + !IsEmpty(ListItem.Duration) + [SubString(Container.FolderPath,library://Video/Movies/Titles.xml) | SubString(Container.FolderPath,videodb://movies/) | SubString(Container.FolderPath,videodb://RecentlyAddedMovies)] | SubString(Container.FolderPath,special://profile/playlists/video/Movies)]</visible>
</control>
<control type="button" id="1251">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Add/Remove trakt.tv lists</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=itemlists)</onclick>
<visible>!IsEmpty(ListItem.TVShowTitle) + !IsEmpty(ListItem.DBID) + !StringCompare(ListItem.Label,All seasons) + !SubString(ListItem.Label,Season ,,left) + !StringCompare(ListItem.Label,Specials) | [SubString(Container.FolderPath,videodb://Movies/) | SubString(Container.FolderPath,library://Video/Movies/Titles.xml) | SubString(Container.FolderPath,videodb://RecentlyAddedMovies) | SubString(Container.FolderPath,special://profile/playlists/video/Movies)]</visible>
</control>
<control type="button" id="1252">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Manage trakt.tv lists</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=managelists)</onclick>
</control>
<control type="button" id="1253">
<posx>0</posx>
<posy>0</posy>
<width>300</width>
<height>35</height>
<label>Update trakt.tv tags</label>
<font>font-20</font>
<align>center</align>
<textcolor>white</textcolor>
<focusedcolor>lightblue</focusedcolor>
<texturefocus border="7">list-focus.png</texturefocus>
<texturenofocus border="7">list-nofocus.png</texturenofocus>
<onclick>RunScript(script.trakt,action=updatetags)</onclick>
</control>
If someone could point me in the right direction then it would be really appreciated.
Thanks heaps.