Kodi Community Forum
is it possible to install a 3rd party addon from skin? - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Development (https://forum.kodi.tv/forumdisplay.php?fid=32)
+--- Forum: Skinning (https://forum.kodi.tv/forumdisplay.php?fid=12)
+--- Thread: is it possible to install a 3rd party addon from skin? (/showthread.php?tid=369307)



is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-17

is it possible to install a addon from a 3rd party repo from within skinsettings?


RE: is it possible to install a 3rd party addon from skin? - User 405025 - 2022-08-18

(2022-08-17, 17:39)spl147 Wrote: is it possible to install a addon from a 3rd party repo from within skinsettings?

InstallAddon(id) Will install the addon with the given id.
https://kodi.wiki/view/List_of_built-in_functions#Add-on_built-in.27s


if not belonging to the kodi repo,the repository from where the specific addon should be installed must be installed on the system.


RE: is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-18

here is my control

if the repo is not installed, it installs the repo, if the repo is installed nothing happens when clicked

xml:
                <control type="radiobutton" id="323">
                    <label>PVR Artwork Module $INFO[System.AddonVersion(script.module.pvr.artwork),(,)]</label>
                    <textureradioonfocus colordiffuse="ffffffff">buttons/status-on.png</textureradioonfocus>
                    <textureradioonnofocus colordiffuse="ffffffff">buttons/status-on.png</textureradioonnofocus>
                    <textureradioofffocus colordiffuse="fff02222">buttons/status-off.png</textureradioofffocus>
                    <textureradiooffnofocus colordiffuse="fff02222">buttons/status-off.png</textureradiooffnofocus>
                    <onclick condition="!System.HasAddon(repository.kodinerds)">InstallAddon(repository.kodinerds)</onclick>
                    <onclick condition="System.HasAddon(repository.kodinerds)">InstallAddon(script.module.pvr.artwork)</onclick>
                    <onclick condition="System.HasAddon(script.module.pvr.artwork)">Addon.OpenSettings(script.module.pvr.artwork)</onclick>
                    <selected>System.HasAddon(script.module.pvr.artwork)</selected>
                    <include>DefaultSettingButton</include>
                </control>



RE: is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-18

so it seems line 7 installs the repo fine but it is a old version (6.0.0) current is (7.0.1.2), after the repo is installed if i goto addons and try to navigate to the repo it says "could not connect to repository"
looks like the old repo was on github, now they host it on their own site.


RE: is it possible to install a 3rd party addon from skin? - User 405025 - 2022-08-18

(2022-08-18, 15:15)spl147 Wrote: so it seems line 7 installs the repo fine but it is a old version (6.0.0) current is (7.0.1.2), after the repo is installed if i goto addons and try to navigate to the repo it says "could not connect to repository"
looks like the old repo was on github, now they host it on their own site.

Seems you need more declare the visible expression.

I tested,mine this way.
and seems to work, unsure if skin reload is requiered but i think it souldn't.

But your (or any other already installed repo) should provide the repo which should be installed (as it willl not work either)
xml:

<onclick condition="!System.HasAddon(plugin.video.netflix) + !System.HasAddon(repository.castagnait)">InstallAddon(repository.castagnait)</onclick>
<onclick condition="!System.HasAddon(plugin.video.netflix) + System.HasAddon(repository.castagnait)">InstallAddon(plugin.video.netflix)</onclick>
<onclick condition="System.HasAddon(plugin.video.netflix)">Addon.OpenSettings(plugin.video.netflix)</onclick>

(2022-08-18, 15:15)spl147 Wrote: so it seems line 7 installs the repo fine but it is a old version (6.0.0) current is (7.0.1.2), after the repo is installed if i goto addons and try to navigate to the repo it says "could not connect to repository"
looks like the old repo was on github, now they host it on their own site.

you need than, some source with an upo to date linke ( provide by yourself , or create an pr for the 'common' repo which provide )


RE: is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-18

how can i provide a link in the skinsettings to the repo?


RE: is it possible to install a 3rd party addon from skin? - User 405025 - 2022-08-20

(2022-08-18, 19:01)spl147 Wrote: how can i provide a link in the skinsettings to the repo?

just update your repository with the addon which should be updated (repository.*name*) like you seemed to be done before. ( addons.xml / addon.xml )


RE: is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-20

it does not work with repos that are not on github, i tried already


RE: is it possible to install a 3rd party addon from skin? - User 405025 - 2022-08-20

hm. id did a test and it works flawlessly

may take a look and compare.
https://github.com/marduklev/kodi_repo/commit/a8799b0a5759ec68036155e218f85f43f1eee507

if your repo is on git hub i can do a pr if you want.

Edit: worked,but also fix a typo https://github.com/marduklev/kodi_repo/commit/1d16233cdd8818e463c3efb057c3d1530ae53155


RE: is it possible to install a 3rd party addon from skin? - spl147 - 2022-08-21

(2022-08-20, 22:28)mardukL Wrote: hm. id did a test and it works flawlessly

may take a look and compare.
https://github.com/marduklev/kodi_repo/commit/a8799b0a5759ec68036155e218f85f43f1eee507

if your repo is on git hub i can do a pr if you want.

Edit: worked,but also fix a typo https://github.com/marduklev/kodi_repo/commit/1d16233cdd8818e463c3efb057c3d1530ae53155
OK, i got the repo setup and working.

i have this in skinsettings, but when clicked nothing happens, and nothing in the log.

xml:
                <control type="radiobutton" id="301">
                    <label>Kodinerds Addon Repo $INFO[System.AddonVersion(repository.kodinerds),(,)]</label>
                    <textureradioonfocus colordiffuse="ffffffff">buttons/status-on.png</textureradioonfocus>
                    <textureradioonnofocus colordiffuse="ffffffff">buttons/status-on.png</textureradioonnofocus>
                    <textureradioofffocus colordiffuse="fff02222">buttons/status-off.png</textureradioofffocus>
                    <textureradiooffnofocus colordiffuse="fff02222">buttons/status-off.png</textureradiooffnofocus>
                    <onclick condition="!System.HasAddon(repository.kodinerds)">InstallAddon(repository.kodinerds)</onclick>
                    <selected>System.HasAddon(repository.kodinerds)</selected>
                    <include>DefaultSettingButton</include>
                </control>

https://github.com/C4Wiz/Kodi_Repo