Your 2nd Add-On: Online Videos!
#61
To be able to select view modes for your media listing you need to set media type of your media items: https://github.com/romanvm/plugin.video....in.py#L119

Also, switching view modes (although it is strongly discouraged) needs to be done after endOfDirectory call.
Raspberry PI 2 + LibreELEC 8 (Kodi 17)
Samsung Galaxy Tab A 10.1 + Kodi 17 for Android
Reply
#62
xbmcplugin.setContent(_handle, 'videos')
Yes!
that was the line i missed, with this (but without
xbmc.executebuiltin('Container.SetViewMode(57)')
) the sideblade menu unlocked

I've misunderstood this function, i was believing that was only for the page which should display the final videos, and i was displaying just picture of the show (a folder in my mind) which when you click on it open another folder (season)

Thank a lot for your help! Smile
Reply
#63
Hello, 
Thanks to this tutorial I made an addon of online videos with subtitles.
Unfortunately when I tried to play the videos with a remote : the subtitles disappear.
I just add those two lines inside the main.py file :
subtitles = domain+video['sub']+'.srt'
list_item.setSubtitles([subtitles])
It's working with the usual playing mode, maybe I should add more things to recognize the subtitles by the remote too.
Thanks for your help
Reply
#64
Is there a way to create video "SubCategories"
The structure of the original add-on is

1) 'Animals'
-> 'Crab'
-> 'Alligator'
-> 'Turtle'

2) 'Cars'
-> 'Postal Truck'
-> 'Traffic'
-> 'Traffic Arrows'

etc.

I'm looking for something like this:
1) 'Animals'
-> 1A) 'Wild Animals'
---> 'Lion'
---> 'Tiger'
---> 'Zebra'

-> 1B) 'Domestic Animals'
---> 'Chicken'
---> 'Cat'
---> 'Dog'

-> 1C) 'Sea Animals'
---> 'Dolphin'
---> 'Goldfish'
---> 'Tuna'

Is possible to create something like this, modifying the main code?
Please advice. Thank you.
Reply
#65
@fsatark
Yes, you can have nested "virtual folders" as well to whatever depth you want. They are defined as the top-level "virtual folder" ListItems.
Raspberry PI 2 + LibreELEC 8 (Kodi 17)
Samsung Galaxy Tab A 10.1 + Kodi 17 for Android
Reply
#66
@Roman_V_M

Thank you for your answer. Unfortunately I'm not educated enough to decode your answer and create the solution I need by my self.
I also search around for a while but I can't find an example to analyze and follow.
Is it possible to provide code as example?
Thanks in advance
Reply
 
Thread Rating:
  • 2 Vote(s) - 5 Average



Logout Mark Read Team Forum Stats Members Help
Your 2nd Add-On: Online Videos!52