import enigma2-plugin-extensions-mediaportal 2020062101 v2020062101
authorChristian Weiske <cweiske@cweiske.de>
Sun, 21 Jun 2020 23:15:26 +0000 (01:15 +0200)
committerChristian Weiske <cweiske@cweiske.de>
Sun, 21 Jun 2020 23:15:26 +0000 (01:15 +0200)
229 files changed:
usr/lib/enigma2/python/Components/Converter/MPServiceInfo.py
usr/lib/enigma2/python/Components/Converter/MPServiceName.py
usr/lib/enigma2/python/Components/Converter/mp_audioinfo.py
usr/lib/enigma2/python/Components/Renderer/mp_AudioIcon.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/additions.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/ccc.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/cczwei.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/chefkoch.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/gaskrank_tv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/hornoxe.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/itunestrailers.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/lachmeister_de.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/lachschon_de.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/liveleak.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/retrotv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/fun/twitch.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/ard.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/arte.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/atv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/brf.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/disneyplus.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/dreisat.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/funk.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/kindertube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/myspass.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/netflix.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/netzkino.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/orf.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/popcorntimes.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/primevideo.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/servustv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/southpark.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/srg.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/tvnow.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/youtube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/youtube_user.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/zdf.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/music/mtvdecharts.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/music/radio.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/music/shoutcast.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/music/tunein.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/newsdoku/autobild.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/newsdoku/dokus4_me.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/newsdoku/focus.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/newsdoku/urknall.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/ahme.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/anyporn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/beeg.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/bongacams.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/cam4.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/camhub.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/camsoda.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/chaturbate.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/cliphunter.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/crocotube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/cumlouder.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/dachix.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/daftsex.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/dirtyship.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/drtuber.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/eporner.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/eroprofile.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/extremetube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/faapy.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/freeones.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/hdzog.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/homemoviestube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/hotmovs.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/hotscope.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/lovehomeporn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/manyvids.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/moviefap.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/nsfw247.py [moved from usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/brazzers.py with 57% similarity]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/nubilefilms.py [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pinflix.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/porn7.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/porndoe.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/porngo.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornhat.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornhdsexy.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornhub.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornicom.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornid.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornone.py [moved from usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/vporn.py with 76% similarity]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornoreino.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornoxo.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornrabbit.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/porntrex.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/porntv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/pornxio.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/realgfporn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/redtube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/sextvx.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/sexu.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/shemalez.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/shesfreaky.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/slutload.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/spankbang.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/spankwire.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/stripchat.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/sunporno.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/teenager365.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/tnaflix.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/tube8.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/tubepornclassic.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/tubewolf.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/txxx.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/upornia.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/vintagetube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/vjav.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/x2search4porn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/x3movs.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/x4tube.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xfreehd.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xhamster.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xnxx.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xpaja.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xvideos.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xxxdan.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/xxxfiles.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/youjizz.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/porn/youporn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/sport/dazn.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/sport/pokerstars.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/locale/de/LC_MESSAGES/MediaPortal.mo
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/locale/de/LC_MESSAGES/MediaPortal.po
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/plugin.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/MPEuronewsUriResolver.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/MPLivestreamcomUriResolver.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/MPYoutubeUriResolver.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/__init__.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/aes_crypt.py [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/choiceboxext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/config.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/configlistext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/coverhelper.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/cvevosignalgoextractor.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/debuglog.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/decrypt.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/fembed.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/flashx.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/flyflv.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/google.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/hosters.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/jetload.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/mailru.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/mangovideo.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/okru.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/onlystream.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vidcloud.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/videowood.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vidfast.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vidup.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vidzi.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vivo.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/vkme.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/hosters/youwatch.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/imports.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/iso3166/__init__.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/keyboardext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/menuhelper.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/messageboxext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/mp_globals.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/mpscreen.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/mtvdelink.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/nexx.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/numericaltextinputext.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/packer.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/pininputext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/pixmapext.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/realdebrid.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/showAsThumb.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/simple_lru_cache.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/simplelist.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/simpleplayer.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/streams.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/tmdb.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/tw_util.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/twagenthelper.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/twisted_hang.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/update.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/youtubelink.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/youtubeplayer.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/yt_url.py
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/resources/ytdl.py [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Grid.xml [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_InputHelpDialog.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_List.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_PinInput.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Playlist.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Plugin.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_PluginSetup.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Setup.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Sort.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_TMDb.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Thumbs.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Update.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_VirtualKeyBoard.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Wall.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_Wall2.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_WallVTi.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_skin.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_widget_rating.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_widget_search.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/MP_widget_youtube.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/images/page.png
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_1080/clean_fhd/images/page_select.png
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Grid.xml [new file with mode: 0644]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_InputHelpDialog.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_List.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_PinInput.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Playlist.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Plugin.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_PluginSetup.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Setup.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Sort.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_TMDb.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Thumbs.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Update.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_VirtualKeyBoard.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Wall.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_Wall2.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_WallVTi.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_skin.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_widget_rating.xml [deleted file]
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_widget_search.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/MP_widget_youtube.xml
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/images/page.png
usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/skins_720/clean_hd/images/page_select.png

index 0088e6f..0da4766 100644 (file)
@@ -5,7 +5,7 @@ from os import path
 from Plugins.Extensions.MediaPortal.resources import mp_globals
 from Plugins.Extensions.MediaPortal.resources.imports import TimerCall
 
-if mp_globals.isDreamOS and mp_globals.model in ["one","two"]:
+if mp_globals.model in ["one", "two"]:
        from enigma import CT_MPEG2, CT_H264, CT_MPEG1, CT_MPEG4_PART2, CT_VC1, CT_VC1_SIMPLE_MAIN, CT_H265, CT_DIVX311, CT_DIVX4, CT_SPARK, CT_VP6, CT_VP8, CT_VP9, CT_H263, CT_MJPEG, CT_REAL, CT_AVS, CT_UNKNOWN
 
 class MPServiceInfo(Converter, object):
@@ -15,24 +15,18 @@ class MPServiceInfo(Converter, object):
 
        def __init__(self, type):
                Converter.__init__(self, type)
-               if mp_globals.isDreamOS and mp_globals.model in ["one","two"]:
+               if mp_globals.model in ["one", "two"]:
                        self.type, self.interesting_events = {
                                        "VideoInfo": (self.VIDEO_INFO, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo,)),
                                        "VideoInfoCodec": (self.VIDEO_INFOCODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo, iPlayableService.evVideoTypeReady,)),
                                        "VideoCodec": (self.VIDEO_CODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo, iPlayableService.evVideoTypeReady,)),
                                }[type]
-               elif mp_globals.isDreamOS:
+               else:
                        self.type, self.interesting_events = {
                                        "VideoInfo": (self.VIDEO_INFO, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo,)),
                                        "VideoInfoCodec": (self.VIDEO_INFOCODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo,)),
                                        "VideoCodec": (self.VIDEO_CODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evVideoProgressiveChanged, iPlayableService.evVideoFramerateChanged, iPlayableService.evUpdatedInfo,)),
                                }[type]
-               else:
-                       self.type, self.interesting_events = {
-                                       "VideoInfo": (self.VIDEO_INFO, (iPlayableService.evVideoSizeChanged, iPlayableService.evUpdatedInfo,)),
-                                       "VideoInfoCodec": (self.VIDEO_INFOCODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evUpdatedInfo,)),
-                                       "VideoCodec": (self.VIDEO_CODEC, (iPlayableService.evVideoSizeChanged, iPlayableService.evUpdatedInfo,)),
-                               }[type]
                self.need_wa = iPlayableService.evVideoSizeChanged in self.interesting_events
 
        def reuse(self):
@@ -46,23 +40,19 @@ class MPServiceInfo(Converter, object):
                        return False
 
                if self.type == self.VIDEO_INFO:
-                       if mp_globals.isDreamOS:
-                               frame_rate = info.getInfo(iServiceInformation.sFrameRate)
-                               if mp_globals.isDreamOS and mp_globals.model in ["one","two"]:
-                                       xres = info.getInfo(iServiceInformation.sVideoWidth)
-                                       yres = info.getInfo(iServiceInformation.sVideoHeight)
-                                       if frame_rate > 0 and xres > 0 and yres > 0:
-                                               return True
-                                       else:
-                                               return False
+                       frame_rate = info.getInfo(iServiceInformation.sFrameRate)
+                       if mp_globals.model in ["one", "two"]:
+                               xres = info.getInfo(iServiceInformation.sVideoWidth)
+                               yres = info.getInfo(iServiceInformation.sVideoHeight)
+                               if frame_rate > 0 and xres > 0 and yres > 0:
+                                       return True
                                else:
-                                       if frame_rate > 0:
-                                               return True
-                                       else:
-                                               return False
+                                       return False
                        else:
-                               return True
-
+                               if frame_rate > 0:
+                                       return True
+                               else:
+                                       return False
                return False
 
        boolean = property(getBoolean)
@@ -79,7 +69,7 @@ class MPServiceInfo(Converter, object):
                        if path.exists("/proc/stb/vmpeg/0/xres"):
                                f = open("/proc/stb/vmpeg/0/xres", "r")
                                try:
-                                       xres = int(f.read(),16)
+                                       xres = int(f.read(), 16)
                                except:
                                        pass
                                f.close()
@@ -97,7 +87,7 @@ class MPServiceInfo(Converter, object):
                        if path.exists("/proc/stb/vmpeg/0/yres"):
                                f = open("/proc/stb/vmpeg/0/yres", "r")
                                try:
-                                       yres = int(f.read(),16)
+                                       yres = int(f.read(), 16)
                                except:
                                        pass
                                f.close()
@@ -111,35 +101,28 @@ class MPServiceInfo(Converter, object):
                        if not yres:
                                yres = info.getInfo(iServiceInformation.sVideoHeight)
 
-                       if mp_globals.isDreamOS:
-                               progressive = info.getInfo(iServiceInformation.sProgressive)
-                               frame_rate = info.getInfo(iServiceInformation.sFrameRate)
-                               if not progressive:
-                                       frame_rate *= 2
-                               frame_rate = (frame_rate+500)/1000
-                               if frame_rate > 0 and xres > 0 and yres > 0:
-                                       xres = str(xres)
-                                       yres = str(yres)
-                                       x = "x"
-                                       frame_rate = str(frame_rate)
-                                       p = 'p' if progressive else 'i'
-                               else:
-                                       xres = ""
-                                       yres = ""
-                                       x = ""
-                                       frame_rate = ""
-                                       p = ""
-                       else:
+                       progressive = info.getInfo(iServiceInformation.sProgressive)
+                       frame_rate = info.getInfo(iServiceInformation.sFrameRate)
+                       if not progressive:
+                               frame_rate *= 2
+                       frame_rate = (frame_rate+500) / 1000
+                       if frame_rate > 0 and xres > 0 and yres > 0:
                                xres = str(xres)
                                yres = str(yres)
                                x = "x"
+                               frame_rate = str(frame_rate)
+                               p = 'p' if progressive else 'i'
+                       else:
+                               xres = ""
+                               yres = ""
+                               x = ""
                                frame_rate = ""
                                p = ""
                        if self.type == self.VIDEO_INFO:
                                return "%s%s%s%s%s" % (xres, x, yres, p, frame_rate)
                if self.type in [self.VIDEO_INFOCODEC, self.VIDEO_CODEC]:
                        codec = None
-                       if mp_globals.isDreamOS and mp_globals.model in ["one","two"]:
+                       if mp_globals.model in ["one", "two"]:
                                codec = info.getInfo(iServiceInformation.sVideoType)
                                codec = { CT_MPEG2 : "MPEG2", CT_H264 : "H.264/AVC", CT_MPEG1 : "MPEG1", CT_MPEG4_PART2 : "MPEG4",
                                        CT_VC1 : "VC1", CT_VC1_SIMPLE_MAIN : "WMV3", CT_H265 : "H.265/HEVC", CT_DIVX311 : "DIVX3",
@@ -156,14 +139,14 @@ class MPServiceInfo(Converter, object):
                                                pass
                                        f.close()
                        if self.type == self.VIDEO_INFOCODEC:
-                               if xres in ["","0"]:
+                               if xres in ["", "0"]:
                                        return ""
-                               elif mp_globals.isDreamOS and codec:
+                               elif codec:
                                        return "%s%s%s%s%s [%s]" % (xres, x, yres, p, frame_rate, codec)
                                else:
                                        return "%s%s%s%s%s" % (xres, x, yres, p, frame_rate)
                        if self.type == self.VIDEO_CODEC:
-                               if mp_globals.isDreamOS and codec:
+                               if codec:
                                        return codec
                                else:
                                        return ""
@@ -179,10 +162,7 @@ class MPServiceInfo(Converter, object):
                        return -1
 
                if self.type == self.VIDEO_INFO:
-                       if mp_globals.isDreamOS:
-                               return -1 if info.getInfo(iServiceInformation.sVideoHeight) < 0 or info.getInfo(iServiceInformation.sFrameRate) < 0 or info.getInfo(iServiceInformation.sProgressive) < 0 else -2
-                       else:
-                               return -1 if info.getInfo(iServiceInformation.sVideoHeight) < 0 else -2
+                       return -1 if info.getInfo(iServiceInformation.sVideoHeight) < 0 or info.getInfo(iServiceInformation.sFrameRate) < 0 or info.getInfo(iServiceInformation.sProgressive) < 0 else -2
                return -1
 
        value = property(getValue)
index b774582..393c3a1 100644 (file)
@@ -39,7 +39,7 @@ class MPServiceName(Poll, Converter, object):
                        ref = service
                if info is None:
                        return ""
-               if self.type in [self.NAME,self.NAMELCD]:
+               if self.type in [self.NAME, self.NAMELCD]:
                        name = ref and info.getName(ref)
                        if name is None:
                                name = info.getName()
index 8739baa..5f7e2d9 100644 (file)
@@ -8,26 +8,26 @@ from Plugins.Extensions.MediaPortal.resources import mp_globals
 try:
        from enigma import iAudioType_ENUMS as iAt
        AUDIO_FORMATS = {
-                  iAt.atDTSHD:  ("DTS-HD",_("DTS-HD"),1),
-                  iAt.atDTS:    ("DTS",   _("DTS"),   2),
-                  iAt.atAACHE:  ("AACHE", _("HE-AAC"),3),
-                  iAt.atAAC:    ("AAC",   _("AAC"),   4),
-                  iAt.atDDP:    ("DDP",   _("AC3+"),  5),
-                  iAt.atAC3:    ("AC3",   _("AC3"),   6),
-                  iAt.atMPEG:   ("MPEG",  _("MPEG"),  7),
-                  iAt.atMP3:    ("MP3",   _("MP3"),   8),
-                  iAt.atLPCM:   ("LPCM",  _("LPCM"),  9),
-                  iAt.atPCM:    ("PCM",   _("PCM"),  10),
-                  iAt.atWMA:    ("WMA",   _("WMA"),  11),
-                  iAt.atFLAC:   ("FLAC",  _("FLAC"), -1),
-                  iAt.atOGG:    ("OGG",   _("OGG"),  -1),
-                  iAt.atUnknown:("unknown",_("<unknown>"), -1)
+                  iAt.atDTSHD:  ("DTS-HD", _("DTS-HD"), 1),
+                  iAt.atDTS:    ("DTS",    _("DTS"),    2),
+                  iAt.atAACHE:  ("AACHE",  _("HE-AAC"), 3),
+                  iAt.atAAC:    ("AAC",    _("AAC"),    4),
+                  iAt.atDDP:    ("DDP",    _("AC3+"),   5),
+                  iAt.atAC3:    ("AC3",    _("AC3"),    6),
+                  iAt.atMPEG:   ("MPEG",   _("MPEG"),   7),
+                  iAt.atMP3:    ("MP3",    _("MP3"),    8),
+                  iAt.atLPCM:   ("LPCM",   _("LPCM"),   9),
+                  iAt.atPCM:    ("PCM",    _("PCM"),   10),
+                  iAt.atWMA:    ("WMA",    _("WMA"),   11),
+                  iAt.atFLAC:   ("FLAC",   _("FLAC"),  -1),
+                  iAt.atOGG:    ("OGG",    _("OGG"),   -1),
+                  iAt.atUnknown:("unknown", _("<unknown>"), -1)
        }
 except:
        pass
 
 try:
-       AUDIO_FORMATS.update({iAt.atTRUEHD:("TRUEHD",_("TRUEHD"), -1),})
+       AUDIO_FORMATS.update({iAt.atTRUEHD: ("TRUEHD", _("TRUEHD"), -1),})
 except:
        pass
 
@@ -43,7 +43,7 @@ class mp_audioinfo(Poll, Converter, object):
                self.poll_enabled = True
                self.lang_strings = ("ger", "german", "deu")
                self.codecs = {
-                       "01_dolbydigitalplus" : ("digital+", "digitalplus", "ac3+", "e-ac-3"),
+                       "01_dolbydigitalplus": ("digital+", "digitalplus", "ac3+", "e-ac-3"),
                        "02_dolbydigital": ("ac3", "ac-3", "dolbydigital"),
                        "03_mp3": ("mp3",),
                        "04_wma": ("wma",),
@@ -57,9 +57,9 @@ class mp_audioinfo(Poll, Converter, object):
                        "12_mpeg": ("mpeg",),
                        "13_dolbytruehd": ("truehd",),
                        }
-               self.codec_info = { "dolbydigitalplus" : ("51", "20", "71"),
-                       "dolbydigital" : ("51", "20", "10", "71"),
-                       "wma" : ("8", "9"),
+               self.codec_info = { "dolbydigitalplus": ("51", "20", "71"),
+                       "dolbydigital": ("51", "20", "10", "71"),
+                       "wma": ("8", "9"),
                        }
                self.type, self.interesting_events = {
                        "AudioIcon": (self.GET_AUDIO_ICON, (iPlayableService.evUpdatedInfo,)),
@@ -102,7 +102,7 @@ class mp_audioinfo(Poll, Converter, object):
                                        elif "Opus" in description:
                                                description_str = "OPUS"
                                        elif "googlevideo.com" in mp_globals.nav_suburi:
-                                               itags = ["itag=251&","itag=250&","itag=249&"]
+                                               itags = ["itag=251&", "itag=250&", "itag=249&"]
                                                for itag in itags:
                                                        if itag in mp_globals.nav_suburi:
                                                                description_str = "OPUS"
@@ -128,7 +128,7 @@ class mp_audioinfo(Poll, Converter, object):
                return description_str
 
        def get_short(self, audioName):
-               for return_codec, codecs in sorted(self.codecs.iteritems()):
+               for return_codec, codecs in sorted(self.codecs.items()):
                        for codec in codecs:
                                if codec in audioName:
                                        codec = return_codec.split('_')[1]
index f2133c1..7d262cf 100644 (file)
@@ -22,7 +22,7 @@ class mp_AudioIcon(Renderer):
                                else:
                                        self.path = value + "/"
                        else:
-                               attribs.append((attrib,value))
+                               attribs.append((attrib, value))
                        if attrib == "size":
                                value = value.split(',')
                                if len(value) == 2:
index d8b9bbe..2826773 100644 (file)
@@ -29,6 +29,7 @@
                <!--mediatheken section-->
                <plugin type="mod" modfile="mediatheken.netflix" confopt="shownetflix" default="True" confcat="mediatheken" gz="0" name="Netflix" icon="netflix" filter="Mediathek" screen="netflixScreen" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.primevideo" confopt="showprimevideo" default="True" confcat="mediatheken" gz="0" name="Prime Video" icon="primevideo" filter="Mediathek" screen="AmazonScreen" param1="" param2=""/>
+               <plugin type="mod" modfile="mediatheken.disneyplus" confopt="showdisneyplus" default="True" confcat="mediatheken" gz="0" name="Disney+" icon="disneyplus" filter="Mediathek" screen="disneyplusScreen" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.dreisat" confopt="showDreisat" default="True" confcat="mediatheken" gz="0" name="3sat Mediathek" icon="3sat" filter="Mediathek" screen="dreisatGenreScreen" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.ard" confopt="showARD" default="True" confcat="mediatheken" gz="0" name="ARD Mediathek" icon="ard" filter="Mediathek" screen="ARDGenreScreen" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.arte" confopt="showArte" default="True" confcat="mediatheken" gz="0" name="arte Mediathek" icon="arte" filter="Mediathek" screen="arteFirstScreen" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.youtube_user" confopt="showyoutubeuser" default="True" confcat="mediatheken" gz="0" name="YouTube Channels" icon="userchannels" filter="Mediathek" screen="show_USER_Genre" param1="" param2=""/>
                <plugin type="mod" modfile="mediatheken.zdf" confopt="showZDF" default="True" confcat="mediatheken" gz="0" name="ZDF Mediathek" icon="zdf" filter="Mediathek" screen="ZDFGenreScreen" param1="" param2=""/>
                <!--porn section-->
-               <plugin type="mod" modfile="porn.chaturbate" confopt="showchaturbate" default="False" confcat="porn" gz="0" name="Chaturbate" icon="chaturbate" filter="Porn" screen="chaturbateGenreScreen" param1="" param2="" />
-               <plugin type="mod" modfile="porn.cam4" confopt="showcam4" default="False" confcat="porn" gz="0" name="Cam4" icon="cam4" filter="Porn" screen="cam4GenreScreen" param1="" param2="" />
-               <plugin type="mod" modfile="porn.bongacams" confopt="showbongacams" default="False" confcat="porn" gz="0" name="BongaCams" icon="bongacams" filter="Porn" screen="bongacamsGenreScreen" param1="" param2="" />
-               <!--<plugin type="mod" modfile="porn.camsoda" confopt="showcamsoda" default="False" confcat="porn" gz="0" name="CamSoda" icon="camsoda" filter="Porn" screen="camsodaGenreScreen" param1="" param2="" />-->
+               <plugin type="mod" modfile="porn.chaturbate" confopt="showchaturbate" default="False" confcat="porn" gz="0" name="Chaturbate" icon="chaturbate" filter="Porn" screen="chaturbateGenreScreen" param1="" param2=""/>
+               <plugin type="mod" modfile="porn.cam4" confopt="showcam4" default="False" confcat="porn" gz="0" name="Cam4" icon="cam4" filter="Porn" screen="cam4GenreScreen" param1="" param2=""/>
+               <plugin type="mod" modfile="porn.bongacams" confopt="showbongacams" default="False" confcat="porn" gz="0" name="BongaCams" icon="bongacams" filter="Porn" screen="bongacamsGenreScreen" param1="" param2=""/>
+               <plugin type="mod" modfile="porn.camsoda" confopt="showcamsoda" default="False" confcat="porn" gz="0" name="CamSoda" icon="camsoda" filter="Porn" screen="camsodaGenreScreen" param1="" param2=""/>
+               <plugin type="mod" modfile="porn.stripchat" confopt="showstripchat" default="False" confcat="porn" gz="0" name="Stripchat" icon="stripchat" filter="Porn" screen="stripchatGenreScreen" param1="" param2=""/>
                <plugin type="mod" modfile="porn.x2search4porn" confopt="show2search4porn" default="True" confcat="porn" gz="0" name="2Search4Porn" icon="2search4porn" filter="Porn" screen="toSearchForPorn" param1="" param2=""/>
-               <plugin type="mod" modfile="porn.brazzers" confopt="showbrazzerscom" default="False" confcat="porn" gz="0" name="Brazzers.com" icon="brazzers" filter="Porn" screen="brazzersGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="brazzersFilmScreen" searchparam=""/>
-               <plugin type="mod" modfile="porn.nubilefilms" confopt="shownubilefilms" default="False" confcat="porn" gz="0" name="Nubilefilms.com" icon="nubilefilms" filter="Porn" screen="nubilefilmsGenreScreen" param1="" param2="" search="0" delim="" searchurl="" searchscreen="" searchparam=""/>
+               <plugin type="mod" modfile="porn.manyvids" confopt="showmanyvids" default="False" confcat="porn" gz="0" name="ManyVids" icon="manyvids" filter="Porn" screen="manyvidsGenreScreen" param1="" param2=""/>
                <plugin type="mod" modfile="porn.cumlouder" confopt="showcumlouder" default="False" confcat="porn" gz="0" name="Cumlouder" icon="cumlouder" filter="Porn" screen="cumlouderGenreScreen" param1="" param2="" search="1" delim="%20" searchurl="%s" searchscreen="cumlouderFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.pornhub" confopt="showpornhub" default="False" confcat="porn" gz="0" name="Pornhub" icon="pornhub" filter="Porn" screen="pornhubGenreScreen" param1="pornhub" param2="" search="1" delim="+" searchurl="%s" searchscreen="pornhubFilmScreen" searchparam=", mode=&quot;pornhub&quot;"/>
                <plugin type="mod" modfile="porn.pornhub" confopt="showpornhubpremium" default="False" confcat="porn" gz="0" name="PornhubPremium" icon="pornhubpremium" filter="Porn" screen="pornhubGenreScreen" param1="pornhubpremium" param2="" search="1" delim="+" searchurl="%s" searchscreen="pornhubFilmScreen" searchparam=", mode=&quot;pornhubpremium&quot;"/>
                <plugin type="mod" modfile="porn.xhamster" confopt="showxhamster" default="False" confcat="porn" gz="0" name="xHamster" icon="xhamster" filter="Porn" screen="xhamsterGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="xhamsterFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.porndoe" confopt="showporndoe" default="False" confcat="porn" gz="0" name="Porndoe" icon="porndoe" filter="Porn" screen="porndoeGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="porndoeFilmScreen" searchparam=", False"/>
                <plugin type="mod" modfile="porn.porngo" confopt="showporngo" default="False" confcat="porn" gz="0" name="PornGO" icon="porngo" filter="Porn" screen="porngoGenreScreen" param1="" param2="" search="1" delim="-" searchurl="%s" searchscreen="porngoFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.xxxfiles" confopt="showxxxfiles" default="False" confcat="porn" gz="0" name="XXXFiles" icon="xxxfiles" filter="Porn" screen="xxxfilesGenreScreen" param1="" param2="" search="1" delim="-" searchurl="%s" searchscreen="xxxfilesFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.daftsex" confopt="showdaftsex" default="False" confcat="porn" gz="0" name="DaftSex" icon="daftsex" filter="Porn" screen="daftsexGenreScreen" param1="" param2="" search="1" delim="%20" searchurl="%s" searchscreen="daftsexFilmScreen" searchparam=""/>/>
+               <plugin type="mod" modfile="porn.sextvx" confopt="showsextvx" default="False" confcat="porn" gz="1" name="Sextvx" icon="sextvx" filter="Porn" screen="sextvxGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="sextvxFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.porntrex" confopt="showporntrex" default="False" confcat="porn" gz="1" name="Porntrex" icon="porntrex" filter="Porn" screen="porntrexGenreScreen" param1="porntrex" param2="" search="1" delim="-" searchurl="%s" searchscreen="porntrexFilmScreen" searchparam=", &quot;Porntrex.com&quot;, &quot;https://www.porntrex.com&quot;"/>
                <plugin type="mod" modfile="porn.porntrex" confopt="showcamwhoresbay" default="False" confcat="porn" gz="1" name="Camwhoresbay" icon="camwhoresbay" filter="Porn" screen="porntrexGenreScreen" param1="camwhoresbay" param2="" search="1" delim="-" searchurl="%s" searchscreen="porntrexFilmScreen" searchparam=", &quot;Camwhoresbay.com&quot;, &quot;http://www.camwhoresbay.com&quot;"/>
                <plugin type="mod" modfile="porn.porntrex" confopt="showjavwhores" default="False" confcat="porn" gz="1" name="JavBangers" icon="javbangers" filter="Porn" screen="porntrexGenreScreen" param1="javbangers" param2="" search="1" delim="-" searchurl="%s" searchscreen="porntrexFilmScreen" searchparam=", &quot;JavBangers.com&quot;, &quot;https://www.javbangers.com&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showpornhdsexy" default="False" confcat="porn" gz="0" name="PornHD.sexy" icon="pornhdsexy" filter="Porn" screen="pornhdsexyGenreScreen" param1="pornhdsexy" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;PornHD.sexy&quot;, &quot;http://www.pornhd.sexy&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showporn4ktv" default="False" confcat="porn" gz="0" name="Porn4kTV" icon="porn4ktv" filter="Porn" screen="pornhdsexyGenreScreen" param1="porn4ktv" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;Porn4kTV.com&quot;, &quot;http://www.porn4ktv.com&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showxvideoshdonline" default="False" confcat="porn" gz="0" name="XVideosHD" icon="xvideoshdonline" filter="Porn" screen="pornhdsexyGenreScreen" param1="xvideoshdonline" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;XVideosHD.online&quot;, &quot;http://www.xvideoshd.online&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showxhentaitv" default="False" confcat="porn" gz="0" name="XHentai" icon="xhentaitv" filter="Porn" screen="pornhdsexyGenreScreen" param1="xhentaitv" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;XHentai.tv&quot;, &quot;http://www.xhentai.tv&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showsexjav" default="False" confcat="porn" gz="0" name="SexJAV" icon="sexjav" filter="Porn" screen="pornhdsexyGenreScreen" param1="sexjav" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;SexJAV.org&quot;, &quot;http://www.sexjav.org&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showsexvn" default="False" confcat="porn" gz="0" name="SexVN" icon="sexvn" filter="Porn" screen="pornhdsexyGenreScreen" param1="sexvn" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;SexVN.org&quot;, &quot;http://en.sexvn.org&quot;"/>
+               <plugin type="mod" modfile="porn.pornhdsexy" confopt="showtabootube" default="False" confcat="porn" gz="0" name="TabooTube" icon="tabootube" filter="Porn" screen="pornhdsexyGenreScreen" param1="tabootube" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornhdsexyFilmScreen" searchparam=", &quot;TabooTube.xxx&quot;, &quot;https://tabootube.xxx&quot;"/>
                <plugin type="mod" modfile="porn.pornxio" confopt="showpornxio" default="False" confcat="porn" gz="0" name="PornXio" icon="pornxio" filter="Porn" screen="pornxioGenreScreen" param1="pornxio" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornxioFilmScreen" searchparam=", &quot;PornXio.com&quot;, &quot;https://pornxio.com&quot;"/>
                <plugin type="mod" modfile="porn.pornxio" confopt="showhandjobhub" default="False" confcat="porn" gz="0" name="HandjobHub" icon="handjobhub" filter="Porn" screen="pornxioGenreScreen" param1="handjobhub" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornxioFilmScreen" searchparam=", &quot;HandjobHub.com&quot;, &quot;https://handjobhub.com&quot;"/>
                <plugin type="mod" modfile="porn.pornxio" confopt="showhypnotube" default="False" confcat="porn" gz="0" name="hypnotube" icon="hypnotube" filter="Porn" screen="pornxioGenreScreen" param1="hypnotube" param2="" search="1" delim="-" searchurl="%s" searchscreen="pornxioFilmScreen" searchparam=", &quot;hypnotube.com&quot;, &quot;https://hypnotube.com&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="showslutload" default="False" confcat="porn" gz="0" name="Slutload" icon="slutload" filter="Porn" screen="slutloadGenreScreen" param1="slutload" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Slutload.com&quot;, &quot;https://www.slutload.com&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="show0dayporn" default="False" confcat="porn" gz="0" name="0DayPorn" icon="0dayporn" filter="Porn" screen="slutloadGenreScreen" param1="0dayporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;0DayPorn.com&quot;, &quot;https://0dayporn.com&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="showdatoporn" default="False" confcat="porn" gz="0" name="DatoPorn" icon="datoporn" filter="Porn" screen="slutloadGenreScreen" param1="datoporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;DatoPorn.com&quot;, &quot;https://dato.porn&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showporn00" default="False" confcat="porn" gz="0" name="Porn00" icon="porn00" filter="Porn" screen="slutloadGenreScreen" param1="porn00" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Porn00.org&quot;, &quot;https://www.porn00.org&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showsmutr" default="False" confcat="porn" gz="0" name="Smutr" icon="smutr" filter="Porn" screen="slutloadGenreScreen" param1="smutr" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Smutr.com&quot;, &quot;https://smutr.com&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showfapnado" default="False" confcat="porn" gz="0" name="FapNado" icon="fapnado" filter="Porn" screen="slutloadGenreScreen" param1="fapnado" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;FapNado.com&quot;, &quot;https://www.fapnado.com&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showfineporn" default="False" confcat="porn" gz="0" name="FinePorn" icon="fineporn" filter="Porn" screen="slutloadGenreScreen" param1="fineporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;FinePorn.xxx&quot;, &quot;https://fineporn.xxx&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showloveporn" default="False" confcat="porn" gz="0" name="LovePorn" icon="lovepornxxx" filter="Porn" screen="slutloadGenreScreen" param1="loveporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;LovePorn.xxx&quot;, &quot;https://loveporn.xxx&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showtopporn" default="False" confcat="porn" gz="0" name="TopPorn" icon="topporn" filter="Porn" screen="slutloadGenreScreen" param1="topporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;TopPorn.xxx&quot;, &quot;https://topporn.xxx&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showtabooporn" default="False" confcat="porn" gz="0" name="TabooPorn" icon="tabooporn" filter="Porn" screen="slutloadGenreScreen" param1="tabooporn" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;TabooPorn.tv&quot;, &quot;https://www.tabooporn.tv&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showporno700" default="False" confcat="porn" gz="0" name="Porno700" icon="porno700" filter="Porn" screen="slutloadGenreScreen" param1="porno700" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Porno700.com&quot;, &quot;https://porno700.com&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showporno900" default="False" confcat="porn" gz="0" name="Porno900" icon="porno900" filter="Porn" screen="slutloadGenreScreen" param1="porno900" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Porno900.com&quot;, &quot;https://porno900.com&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="showiwatchmygf" default="False" confcat="porn" gz="0" name="IWatchMyGF" icon="iwatchmygf" filter="Porn" screen="slutloadGenreScreen" param1="iwatchmygf" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;IWatchMyGF.com&quot;, &quot;https://www.iwatchmygf.com&quot;"/>
+               <plugin type="mod" modfile="porn.slutload" confopt="show18abused" default="False" confcat="porn" gz="0" name="18Abused" icon="18abused" filter="Porn" screen="slutloadGenreScreen" param1="18abused" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;18Abused.com&quot;, &quot;https://18abused.com&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="showmadthumbs" default="False" confcat="porn" gz="0" name="MadThumbs" icon="madthumbs" filter="Porn" screen="slutloadGenreScreen" param1="madthumbs" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;MadThumbs.com&quot;, &quot;http://www.madthumbs.com&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="showfapster" default="False" confcat="porn" gz="0" name="Fapster" icon="fapster" filter="Porn" screen="slutloadGenreScreen" param1="fapster" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;Fapster.xxx&quot;, &quot;https://fapster.xxx&quot;"/>
                <plugin type="mod" modfile="porn.slutload" confopt="showvqtube" default="False" confcat="porn" gz="0" name="VQTube" icon="vqtube" filter="Porn" screen="slutloadGenreScreen" param1="vqtube" param2="" search="1" delim="-" searchurl="%s" searchscreen="slutloadFilmScreen" searchparam=", &quot;VQTube.com&quot;, &quot;https://vqtube.com&quot;"/>
                <plugin type="mod" modfile="porn.shesfreaky" confopt="showshesfreaky" default="False" confcat="porn" gz="0" name="ShesFreaky" icon="shesfreaky" filter="Porn" screen="shesfreakyGenreScreen" param1="" param2="" search="1" delim="-" searchurl="%s" searchscreen="shesfreakyFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.spankwire" confopt="showspankwire" default="False" confcat="porn" gz="0" name="Spankwire" icon="spankwire" filter="Porn" screen="spankwireGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="spankwireFilmScreen" searchparam=", ''"/>
                <plugin type="mod" modfile="porn.extremetube" confopt="showextremetube" default="False" confcat="porn" gz="0" name="ExtremeTube" icon="extremetube" filter="Porn" screen="extremetubeGenreScreen" param1="" param2="" search="1" delim="+" searchurl="http://www.extremetube.com/videos?search=%s" searchscreen="extremetubeFilmScreen" searchparam=""/>
-               <plugin type="mod" modfile="porn.freeones" confopt="showfreeones" default="False" confcat="porn" gz="0" name="FreeOnes" icon="freeones" filter="Porn" screen="freeonesGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="freeonesFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.freeones" confopt="showfreeones" default="False" confcat="porn" gz="0" name="FreeOnes" icon="freeones" filter="Porn" screen="freeonesGenreScreen" param1="" param2="" search="1" delim="%20" searchurl="%s" searchscreen="freeonesFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.x3movs" confopt="show3movs" default="False" confcat="porn" gz="0" name="3Movs" icon="3movs" filter="Porn" screen="x3movsGenreScreen" param1="" param2="" search="1" delim="-" searchurl="%s" searchscreen="x3movsFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.porntv" confopt="showporntv" default="False" confcat="porn" gz="0" name="PornTV" icon="porntv" filter="Porn" screen="porntvGenreScreen" param1="porntv" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;PornTV.com&quot;, &quot;https://www.porntv.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showyoungpornvideos" default="False" confcat="porn" gz="0" name="YoungPornVideos" icon="youngpornvideos" filter="Porn" screen="porntvGenreScreen" param1="youngpornvideos" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;YoungPornVideos.com&quot;, &quot;https://www.youngpornvideos.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showghettotube" default="False" confcat="porn" gz="0" name="GhettoTube" icon="ghettotube" filter="Porn" screen="porntvGenreScreen" param1="ghettotube" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;GhettoTube.com&quot;, &quot;https://www.ghettotube.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showmovieshark" default="False" confcat="porn" gz="0" name="MovieShark" icon="movieshark" filter="Porn" screen="porntvGenreScreen" param1="movieshark" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;MovieShark.com&quot;, &quot;https://www.movieshark.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showyoungporno" default="False" confcat="porn" gz="0" name="YoungPorno" icon="youngporno" filter="Porn" screen="porntvGenreScreen" param1="youngporno" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;YoungPorno.com&quot;, &quot;https://www.youngporno.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showporntitan" default="False" confcat="porn" gz="0" name="PornTitan" icon="porntitan" filter="Porn" screen="porntvGenreScreen" param1="porntitan" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;PornTitan.com&quot;, &quot;https://www.porntitan.com&quot;"/>
-               <plugin type="mod" modfile="porn.porntv" confopt="showxjizz" default="False" confcat="porn" gz="0" name="XJizz" icon="xjizz" filter="Porn" screen="porntvGenreScreen" param1="xjizz" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;XJizz.com&quot;, &quot;https://www.xjizz.com&quot;"/>
                <plugin type="mod" modfile="porn.porntv" confopt="showmovietitan" default="False" confcat="porn" gz="0" name="MovieTitan" icon="movietitan" filter="Porn" screen="porntvGenreScreen" param1="movietitan" param2="" search="1" delim="+" searchurl="%s" searchscreen="porntvFilmScreen" searchparam=", &quot;MovieTitan.com&quot;, &quot;https://www.movietitan.com&quot;"/>
                <plugin type="mod" modfile="porn.beeg" confopt="showbeeg" default="False" confcat="porn" gz="0" name="beeg" icon="beeg" filter="Porn" screen="beegGenreScreen" param1="" param2="" search="0" delim="" searchurl="" searchscreen="" searchparam=""/>
-               <plugin type="mod" modfile="porn.vporn" confopt="showvporn" default="False" confcat="porn" gz="0" name="VPORN" icon="vporn" filter="Porn" screen="vpornGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="vpornFilmScreen" searchparam=", &quot;&quot;, &quot;&quot;"/>
+               <plugin type="mod" modfile="porn.pornone" confopt="showpornone" default="False" confcat="porn" gz="0" name="PORNONE" icon="pornone" filter="Porn" screen="pornoneGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="pornoneFilmScreen" searchparam=", &quot;&quot;, &quot;&quot;"/>
                <plugin type="mod" modfile="porn.cliphunter" confopt="showcliphunter" default="False" confcat="porn" gz="0" name="cliphunter" icon="cliphunter" filter="Porn" screen="cliphunterGenreScreen" param1="" param2="" search="1" delim="%20" searchurl="%s" searchscreen="cliphunterFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.realgfporn" confopt="showrealgfporn" default="False" confcat="porn" gz="0" name="RealGFPorn" icon="realgfporn" filter="Porn" screen="realgfpornGenreScreen" param1="" param2="" search="1" delim="-" searchurl="https://www.realgfporn.com/search/%s/page" searchscreen="realgfpornFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.hotscope" confopt="showhotscope" default="False" confcat="porn" gz="0" name="Hotscope" icon="hotscope" filter="Porn" screen="hotscopeGenreScreen" param1="" param2="" search="1" delim="%20" searchurl="%s" searchscreen="hotscopeFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.dirtyship" confopt="showdirtyship" default="False" confcat="porn" gz="0" name="Dirtyship" icon="dirtyship" filter="Porn" screen="dirtyshipGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="dirtyshipFilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.nsfw247" confopt="shownsfw247" default="False" confcat="porn" gz="0" name="NSFW247" icon="nsfw247" filter="Porn" screen="nsfw247GenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="nsfw247FilmScreen" searchparam=""/>
+               <plugin type="mod" modfile="porn.teenager365" confopt="showteenager365" default="False" confcat="porn" gz="0" name="Teenager365" icon="teenager365" filter="Porn" screen="teenager365GenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="teenager365FilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.eroprofile" confopt="showeroprofile" default="False" confcat="porn" gz="0" name="EroProfile" icon="eroprofile" filter="Porn" screen="eroprofileGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="eroprofileFilmScreen" searchparam=", &quot;&quot;"/>
                <plugin type="mod" modfile="porn.homemoviestube" confopt="showhomemoviestube" default="False" confcat="porn" gz="0" name="HomeMoviesTube" icon="homemoviestube" filter="Porn" screen="homemoviestubeGenreScreen" param1="" param2="" search="1" delim="-" searchurl="%s" searchscreen="homemoviestubeFilmScreen" searchparam=""/>
                <plugin type="mod" modfile="porn.lovehomeporn" confopt="showlovehomeporn" default="False" confcat="porn" gz="0" name="LoveHomePorn" icon="lovehomeporn" filter="Porn" screen="lovehomepornGenreScreen" param1="" param2="" search="1" delim="+" searchurl="%s" searchscreen="lovehomepornFilmScreen" searchparam=""/>
index d4c68a2..3e51ed2 100644 (file)
@@ -1,4 +1,6 @@
 # -*- coding: utf-8 -*-
+from builtins import map
+from builtins import object
 import os.path as os_path
 
 from Plugins.Extensions.MediaPortal.plugin import _
@@ -34,7 +36,7 @@ class CccOverviewScreen(MPScreen):
                self.onLayoutFinish.append(self.loadConferences)
 
        def loadConferences(self):
-               getPage('https://api.media.ccc.de/public/conferences', agent=std_headers, headers={'Content-Type': 'application/json'}).addCallback(self.parseConferences).addErrback(self.dataError)
+               twAgentGetPage('https://api.media.ccc.de/public/conferences', agent=std_headers, headers={'Content-Type': 'application/json'}).addCallback(self.parseConferences).addErrback(self.dataError)
 
        def parseConferences(self, data):
                watcheduids = self.watchdb.getWatched(3)
@@ -43,7 +45,7 @@ class CccOverviewScreen(MPScreen):
                alls   = []
                try:
                        conferences = json.loads(data)
-                       if conferences.has_key('conferences'):
+                       if 'conferences' in conferences:
                                for conference in conferences['conferences']:
                                        title = conference.get('title').encode('utf-8')
                                        url = conference.get('url').encode('utf-8')
@@ -63,7 +65,7 @@ class CccOverviewScreen(MPScreen):
 
                self.filmliste = recent + alls
 
-               self.ml.setList(map(self._defaultlistleftmarked, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleftmarked, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -119,12 +121,12 @@ class CccConferenceScreen(MPScreen):
 
        def loadEvents(self):
                self.filmliste = []
-               getPage(self.url, agent=std_headers, headers={'Content-Type': 'application/json'}).addCallback(self.parseEvents).addErrback(self.dataError)
+               twAgentGetPage(self.url, agent=std_headers, headers={'Content-Type': 'application/json'}).addCallback(self.parseEvents).addErrback(self.dataError)
 
        def parseEvents(self, data):
                try:
                        events = json.loads(data)
-                       if events.has_key('events'):
+                       if 'events' in events:
                                for event in events['events']:
                                        title = event.get('title').encode('utf-8')
                                        url = event.get('url').encode('utf-8')
@@ -142,11 +144,11 @@ class CccConferenceScreen(MPScreen):
                        pass
 
                if len(self.filmliste) == 0:
-                       self.filmliste.append((_('No events found!'), '',''))
+                       self.filmliste.append((_('No events found!'), '', ''))
 
                self.filmliste.sort(key=lambda t : t[0].lower())
 
-               self.ml.setList(map(self._defaultlistleftmarked, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleftmarked, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -169,7 +171,7 @@ class CccConferenceScreen(MPScreen):
                url = self['liste'].getCurrent()[0][1]
                if url == '':
                        return
-               getPage(url, headers={'Content-Type': 'application/json', }).addCallback(self.parseAndPlayEvent).addErrback(self.dataError)
+               twAgentGetPage(url, headers={'Content-Type': 'application/json', }).addCallback(self.parseAndPlayEvent).addErrback(self.dataError)
 
        def parseAndPlayEvent(self, data):
                url = None
@@ -182,7 +184,7 @@ class CccConferenceScreen(MPScreen):
                        title     = event.get('title').encode('utf-8')
                        guid      = event.get('guid').encode('utf-8')
 
-                       if event.has_key('recordings'):
+                       if 'recordings' in event:
                                for recording in event['recordings']:
                                        mimetype = recording.get('mime_type').encode('utf-8')
                                        url = recording.get('recording_url').encode('utf-8')
@@ -211,7 +213,7 @@ class CccConferenceScreen(MPScreen):
                self.session.open(SimplePlayer, [(title, url, image_url)], showPlaylist=False, ltype='ccc')
                self.loadEvents()
 
-class CccWatchDb:
+class CccWatchDb(object):
 
        def __init__(self, group):
                self.__dbfile = config_mp.mediaportal.watchlistpath.value + "mp_" + group
index 941927e..50d1b3f 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.youtubeplayer import YoutubePlayer
@@ -62,7 +63,7 @@ class cczwei(MPScreen):
 
        def loadPage(self):
                url = "http://cc2.tv/daten/20161213181538.php"
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                parse = re.search('class="block"><h4>Videosendungen(.*)', data, re.S)
@@ -75,10 +76,10 @@ class cczwei(MPScreen):
                                else:
                                        url = re.search('.*?href="(.*?)"', urldata, re.S)
                                        url = url.group(1)
-                               title = title.replace('\r\n<br>',', ').replace('   ','').replace('Youtube, HD 1080p','').replace('<br>',', ').strip().strip(', ').strip(',')
-                               title = "Folge %s - %s" % (folge, stripAllTags(title.replace(', , , ','').replace(', , ','').replace('mehr</a>','')))
+                               title = title.replace('\r\n<br>', ', ').replace('   ', '').replace('Youtube, HD 1080p', '').replace('<br>', ', ').strip().strip(', ').strip(',')
+                               title = "Folge %s - %s" % (folge, stripAllTags(title.replace(', , , ', '').replace(', , ', '').replace('mehr</a>', '')))
                                self.streamList.append((decodeHtml(title), url.strip()))
-                       self.ml.setList(map(self._defaultlistleft, self.streamList))
+                       self.ml.setList(list(map(self._defaultlistleft, self.streamList)))
                        self.keyLocked = False
 
        def keyOK(self):
@@ -87,4 +88,4 @@ class cczwei(MPScreen):
                        return
                url = self['liste'].getCurrent()[0][1]
                Title = self['liste'].getCurrent()[0][0]
-               self.session.open(YoutubePlayer,[(Title, url, None)],playAll= False,showPlaylist=False,showCover=False)
\ No newline at end of file
+               self.session.open(YoutubePlayer, [(Title, url, None)], playAll= False, showPlaylist=False, showCover=False)
\ No newline at end of file
index f8043fd..c9c205c 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -68,7 +69,7 @@ class chefkochGenreScreen(MPScreen):
 
        def loadPage(self):
                u = "%s/video" % baseurl
-               getPage(u).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(u).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                raw = re.findall('class="navigation">(.*?)</ul>', data, re.S)
@@ -77,8 +78,8 @@ class chefkochGenreScreen(MPScreen):
                        for (url, title) in parse:
                                title = decodeHtml(title).strip()
                                if title != "Club of Cooks":
-                                       self.genreliste.append((title,url))
-                       self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+                                       self.genreliste.append((title, url))
+                       self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                        self.ml.moveToIndex(0)
                        self.keyLocked = False
                self['name'].setText('')
@@ -92,7 +93,7 @@ class chefkochGenreScreen(MPScreen):
 
 class chefvids(MPScreen):
 
-       def __init__(self, session,name,url):
+       def __init__(self, session, name, url):
                self.url = url
                self.name = name
                MPScreen.__init__(self, session, skin='MP_Plugin', default_cover=default_cover)
@@ -118,15 +119,15 @@ class chefvids(MPScreen):
                self.onLayoutFinish.append(self.loadPage)
 
        def loadPage(self):
-               getPage(self.url).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(self.url).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                self.filmliste = []
                parse = re.findall('class="teaser-box.*?href="/video/artikel/(.*?)".*?img\ssrc="(.*?)".*?<h2>(.*?)</h2>', data, re.S)
                if parse:
-                       for (url,pic,title) in parse:
-                               self.filmliste.append((decodeHtml(title).strip(),url,pic))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                       for (url, pic, title) in parse:
+                               self.filmliste.append((decodeHtml(title).strip(), url, pic))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                        self.ml.moveToIndex(0)
                        self.keyLocked = False
                        self.showInfos()
@@ -138,14 +139,14 @@ class chefvids(MPScreen):
                pic = self['liste'].getCurrent()[0][2]
                self['name'].setText(title)
                CoverHelper(self['coverArt']).getCover(pic)
-               getPage(link).addCallback(self.showInfos2).addErrback(self.dataError)
+               twAgentGetPage(link).addCallback(self.showInfos2).addErrback(self.dataError)
 
        def showInfos2(self, data):
                self.desc = re.findall('itemprop="description" content="(.*?)"', data, re.S)
                self.runtime = re.findall('L.*?nge: <strong>(.*?)</strong>', data, re.S)
                self.vid = re.findall('contentUrl" content="(.*?)"(?:\s/)>', data, re.S)
                if self.desc and self.runtime and self.vid:
-                       d = "Länge: %s\n%s" % (self.runtime[0],(decodeHtml(self.desc[0])))
+                       d = "Länge: %s\n%s" % (self.runtime[0], (decodeHtml(self.desc[0])))
                else:
                        d = ""
                self['handlung'].setText(d)
@@ -154,6 +155,6 @@ class chefvids(MPScreen):
                if self.keyLocked:
                        return
                if self.vid:
-                       self.vid = self.vid[0].replace('https','http')
+                       self.vid = self.vid[0]
                        name = self['liste'].getCurrent()[0][0]
                        self.session.open(SimplePlayer, [(name, str(self.vid))], cover=False, showPlaylist=False, ltype='chefkoch', useResume=False)
\ No newline at end of file
index bf4707b..e5f1dcf 100644 (file)
@@ -1,7 +1,10 @@
 # -*- coding: utf-8 -*-
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
-import Queue
+import queue
 import threading
 from Plugins.Extensions.MediaPortal.resources.menuhelper import MenuHelper
 from Plugins.Extensions.MediaPortal.resources.twagenthelper import twAgentGetPage
@@ -12,7 +15,7 @@ class show_GKTV_Genre(MenuHelper):
 
        def __init__(self, session):
 
-               MenuHelper.__init__(self, session, 2, [[],[],[]], "http://www.gaskrank.tv", "/tv", self._defaultlistcenter, default_cover=default_cover)
+               MenuHelper.__init__(self, session, 2, [[], [], []], "http://www.gaskrank.tv", "/tv", self._defaultlistcenter, default_cover=default_cover)
 
                self['title'] = Label("Gaskrank.tv")
                self['ContentTitle'] = Label("Genres")
@@ -24,10 +27,10 @@ class show_GKTV_Genre(MenuHelper):
 
        def mh_parseData(self, data):
                entrys = entrys2 = []
-               entrys.append(('/motorrad-videos','Die neuesten Filme'))
-               entrys.append(('/top-videos','Am meisten gesehen'))
-               entrys.append(('/user-voted','Am besten bewertet'))
-               entrys.append(('/charts','Charts'))
+               entrys.append(('/motorrad-videos', 'Die neuesten Filme'))
+               entrys.append(('/top-videos', 'Am meisten gesehen'))
+               entrys.append(('/user-voted', 'Am besten bewertet'))
+               entrys.append(('/charts', 'Charts'))
 
                a = data.find('<h3>Video Kategorien</h3>')
                if a >= 0:
@@ -87,9 +90,9 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
 
                self['Page'] = Label(_("Page:"))
 
-               self.filmQ = Queue.Queue(0)
-               self.hanQ = Queue.Queue(0)
-               self.picQ = Queue.Queue(0)
+               self.filmQ = queue.Queue(0)
+               self.hanQ = queue.Queue(0)
+               self.picQ = queue.Queue(0)
                self.updateP = 0
                self.eventL = threading.Event()
                self.eventP = threading.Event()
@@ -107,7 +110,7 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
                self.onLayoutFinish.append(self.loadPage)
 
        def setGenreStrTitle(self):
-               genreName = "%s%s" % (self.genreTitle,self.genreName)
+               genreName = "%s%s" % (self.genreTitle, self.genreName)
                self['ContentTitle'].setText(genreName)
 
        def loadPage(self):
@@ -116,7 +119,7 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
                else:
                        url = self.genreLink
                if self.page:
-                       self['page'].setText("%d / %d" % (self.page,self.pages))
+                       self['page'].setText("%d / %d" % (self.page, self.pages))
                self.filmQ.put(url)
                if not self.eventL.is_set():
                        self.eventL.set()
@@ -130,9 +133,9 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
 
        def dataError(self, error):
                self.eventL.clear()
-               printl(error,self,"E")
-               self.dokusListe.append((_("No videos found!"),"","",""))
-               self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+               printl(error, self, "E")
+               self.dokusListe.append((_("No videos found!"), "", "", ""))
+               self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
 
        def loadPageData(self, data):
                self.dokusListe = []
@@ -145,18 +148,18 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
                                except:
                                        pages = 1
                                if pages > self.pages:
-                                       self.pages = min(pages,999)
+                                       self.pages = min(pages, 999)
                        if not self.page:
                                self.page = 1
-                       self['page'].setText("%d / %d" % (self.page,self.pages))
-                       for     (img,url,name) in dokus:
+                       self['page'].setText("%d / %d" % (self.page, self.pages))
+                       for     (img, url, name) in dokus:
                                self.dokusListe.append((decodeHtml(name), self.baseUrl+url, img))
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        self.th_ThumbsQuery(self.dokusListe, 0, 1, 2, None, None, self.page, self.pages, mode=1)
                        self.loadPicQueued()
                else:
-                       self.dokusListe.append((_("No videos found!"),"","",""))
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.dokusListe.append((_("No videos found!"), "", "", ""))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        if self.filmQ.empty():
                                self.eventL.clear()
                        else:
@@ -242,7 +245,7 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
        def keyPageUp(self):
                self.keyPageUpFast(1)
 
-       def keyPageUpFast(self,step):
+       def keyPageUpFast(self, step):
                if self.keyLocked:
                        return
                oldpage = self.page
@@ -253,7 +256,7 @@ class GKTV_FilmListeScreen(MPScreen, ThumbsHelper):
                if oldpage != self.page:
                        self.loadPage()
 
-       def keyPageDownFast(self,step):
+       def keyPageDownFast(self, step):
                if self.keyLocked:
                        return
                oldpage = self.page
index 01cc06a..f48b99d 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.youtubeplayer import YoutubePlayer
@@ -81,7 +82,7 @@ class hornoxeScreen(MPScreen, ThumbsHelper):
                twAgentGetPage(url).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
-               self.getLastPage(data, "class='wp-pagenavi'>(.*?)</div>", '.*/page/(\d+)')
+               self.getLastPage(data, "class='wp-pagenavi'(.*?)</div>", '.*/page/(\d+)')
                Videos = re.findall('lass="storytitle"><a\shref="((?!http://www.hornoxe.com/den-picdump-von-morgen).*?)".*?img\ssrc="(.*?)".*?alt="(.*?)".*?</a>(.*?)</p', data, re.S)
                if Videos:
                        self.filmliste = []
@@ -90,7 +91,7 @@ class hornoxeScreen(MPScreen, ThumbsHelper):
                                self.filmliste.append((decodeHtml(Title), Url, Image, decodeHtml(Descr)))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_('No videos found!'), None, None, ''))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, self.page, 999, mode=1)
@@ -119,4 +120,4 @@ class hornoxeScreen(MPScreen, ThumbsHelper):
                else:
                        videoPage = re.findall('www.youtube.com/(v|embed)/(.*?)"', data, re.S)
                        if videoPage:
-                               self.session.open(YoutubePlayer,[(Title, videoPage[0][1], None)],playAll= False,showPlaylist=False,showCover=False)
\ No newline at end of file
+                               self.session.open(YoutubePlayer, [(Title, videoPage[0][1], None)], playAll= False, showPlaylist=False, showCover=False)
\ No newline at end of file
index 9ab837c..676d48f 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -78,12 +81,12 @@ class itunestrailersGenreScreen(MPScreen):
                self.genreliste.append(("Calendar", "https://trailers.apple.com/appletv/us/calendar.xml"))
                self.genreliste.append(("Genres", "https://trailers.apple.com/appletv/us/browse.xml"))
                self.genreliste.append(("--- Search ---", "callSuchen"))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.keyLocked = False
 
        def SuchenCallback(self, callback = None):
                if callback is not None and len(callback):
-                       self.suchString = urllib.quote(callback).replace(' ', '+')
+                       self.suchString = urllib.parse.quote(callback).replace(' ', '+')
                        Link = 'https://trailers.apple.com/trailers/global/atv/search.php?q=%s' % self.suchString
                        Name = self['liste'].getCurrent()[0][0]
                        self.session.open(itunestrailersFilmScreen, Link, Name, "Search")
@@ -146,7 +149,7 @@ class itunestrailersSubGenreScreen(MPScreen):
 
        def loadPage(self):
                self.genreliste = []
-               getPage(self.Link).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(self.Link).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                if self.Name == "Genres":
@@ -159,7 +162,7 @@ class itunestrailersSubGenreScreen(MPScreen):
                        if raw:
                                for Label in raw:
                                        self.genreliste.append((Label, self.Link, self.Name))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -203,7 +206,7 @@ class itunestrailersFilmScreen(MPScreen):
                self.keyLocked = True
                self.filmliste = []
                url = self.Link
-               getPage(url).addCallback(self.loadData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.loadData).addErrback(self.dataError)
 
        def loadData(self, data):
                if self.Cat == "Search":
@@ -215,8 +218,10 @@ class itunestrailersFilmScreen(MPScreen):
                        Movies = re.findall('loadTrailerDetailPage\(\'(.*?)\'\);.*?<title>(.*?)</title>.*?<image>(.*?)</image>', parse.group(1), re.S)
                if Movies:
                        for (Url, Title, Image) in Movies:
-                               self.filmliste.append((decodeHtml(Title).replace('&amp;','&'), Url, Image))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                               self.filmliste.append((decodeHtml(Title).replace('&amp;', '&'), Url, Image))
+               if len(self.filmliste) == 0:
+                       self.filmliste.append((_('No movies found!'), None, None))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -226,7 +231,8 @@ class itunestrailersFilmScreen(MPScreen):
                coverUrl = self['liste'].getCurrent()[0][2]
                self['name'].setText(title)
                CoverHelper(self['coverArt']).getCover(coverUrl)
-               getPage(url).addCallback(self.getDescription).addErrback(self.dataError)
+               if url:
+                       twAgentGetPage(url).addCallback(self.getDescription).addErrback(self.dataError)
 
        def getDescription(self, data):
                description = re.search('<summary>(.*?)</summary>', data, re.S)
@@ -239,7 +245,8 @@ class itunestrailersFilmScreen(MPScreen):
                Title = self['liste'].getCurrent()[0][0]
                Link = self['liste'].getCurrent()[0][1]
                Cover = self['liste'].getCurrent()[0][2]
-               self.session.open(itunestrailersSubFilmScreen, Link, Title, Cover)
+               if Link:
+                       self.session.open(itunestrailersSubFilmScreen, Link, Title, Cover)
 
 class itunestrailersSubFilmScreen(MPScreen):
 
@@ -274,16 +281,16 @@ class itunestrailersSubFilmScreen(MPScreen):
                self.keyLocked = True
                self.filmliste = []
                url = self.Link
-               getPage(url).addCallback(self.loadData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.loadData).addErrback(self.dataError)
 
        def loadData(self, data):
                if re.search('id="more"', data):
                        url = re.search('id="more".onSelect="atv.loadURL\(\'(.*?)\'\)', data, re.S|re.I)
-                       getPage(url.group(1)).addCallback(self.loadData2).addErrback(self.dataError)
+                       twAgentGetPage(url.group(1)).addCallback(self.loadData2).addErrback(self.dataError)
                else:
                        url = re.search('id="play".onSelect="atv.loadURL\(\'(.*?)\'\)', data, re.S|re.I)
                        self.filmliste.append(("Trailer", url.group(1), self.Cover))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                        self.keyLocked = False
                        self.showInfos()
 
@@ -292,8 +299,8 @@ class itunestrailersSubFilmScreen(MPScreen):
                if Movies:
                        for (Url, Title, Image) in Movies:
                                if Title != "Related":
-                                       self.filmliste.append((decodeHtml(Title).replace('&amp;','&'), Url, Image))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                                       self.filmliste.append((decodeHtml(Title).replace('&amp;', '&'), Url, Image))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -303,7 +310,7 @@ class itunestrailersSubFilmScreen(MPScreen):
                coverUrl = self['liste'].getCurrent()[0][2]
                self['name'].setText(title)
                CoverHelper(self['coverArt']).getCover(coverUrl)
-               getPage(url).addCallback(self.getDescription).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.getDescription).addErrback(self.dataError)
 
        def getDescription(self, data):
                description = re.search('<description>(.*?)</description>', data, re.S)
@@ -314,19 +321,19 @@ class itunestrailersSubFilmScreen(MPScreen):
                if self.keyLocked:
                        return
                Link = self['liste'].getCurrent()[0][1]
-               getPage(Link).addCallback(self.getVideo).addErrback(self.dataError)
+               twAgentGetPage(Link).addCallback(self.getVideo).addErrback(self.dataError)
 
        def getVideo(self, data):
                video = re.search('<mediaURL>(.*?)</mediaURL>', data, re.S)
                Link = video.group(1)
                if config_mp.mediaportal.itunestrailersquality.value == "720p":
-                       Link = Link.replace('a720p.m4v','h720p.mov')
+                       Link = Link.replace('a720p.m4v', 'h720p.mov')
                elif config_mp.mediaportal.itunestrailersquality.value == "1080p":
-                       Link = Link.replace('a720p.m4v','h1080p.mov')
-                       Link = Link.replace('h720p.mov','h1080p.mov')
+                       Link = Link.replace('a720p.m4v', 'h1080p.mov')
+                       Link = Link.replace('h720p.mov', 'h1080p.mov')
                elif config_mp.mediaportal.itunestrailersquality.value == "480p":
-                       Link = Link.replace('a720p.m4v','h480p.mov')
-                       Link = Link.replace('h720p.mov','h480p.mov')
+                       Link = Link.replace('a720p.m4v', 'h480p.mov')
+                       Link = Link.replace('h720p.mov', 'h480p.mov')
                Title = self['liste'].getCurrent()[0][0]
                mp_globals.player_agent = "QuickTime/7.6.2 (qtver=7.6.2;os=Windows NT 5.1Service Pack 3)"
                self.session.open(SimplePlayer, [(self.Name + " - " + Title, Link, self.Cover)], showPlaylist=False, ltype='itunestrailers', cover=True)
\ No newline at end of file
index 87d905b..f4e83a7 100644 (file)
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
-import Queue
+import queue
 import threading
 from Plugins.Extensions.MediaPortal.resources.youtubelink import YoutubeLink
 from Plugins.Extensions.MediaPortal.resources.menuhelper import MenuHelper
@@ -115,9 +118,9 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
 
                self['Page'] = Label(_("Page:"))
 
-               self.filmQ = Queue.Queue(0)
-               self.hanQ = Queue.Queue(0)
-               self.picQ = Queue.Queue(0)
+               self.filmQ = queue.Queue(0)
+               self.hanQ = queue.Queue(0)
+               self.picQ = queue.Queue(0)
                self.updateP = 0
                self.eventL = threading.Event()
                self.eventP = threading.Event()
@@ -134,13 +137,13 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
                self.onLayoutFinish.append(self.loadPage)
 
        def setGenreStrTitle(self):
-               genreName = "%s%s" % (self.genreTitle,self.genreName)
+               genreName = "%s%s" % (self.genreTitle, self.genreName)
                self['ContentTitle'].setText(genreName)
 
        def loadPage(self):
-               url = self.genreLink % max(1,self.page)
+               url = self.genreLink % max(1, self.page)
                if self.page:
-                       self['page'].setText("%d / %d" % (self.page,self.pages))
+                       self['page'].setText("%d / %d" % (self.page, self.pages))
                self.filmQ.put(url)
                if not self.eventL.is_set():
                        self.eventL.set()
@@ -154,9 +157,9 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
 
        def dataError(self, error):
                self.eventL.clear()
-               printl(error,self,"E")
-               self.dokusListe.append(("Keine Videoclips gefunden!","","",""))
-               self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+               printl(error, self, "E")
+               self.dokusListe.append(("Keine Videoclips gefunden!", "", "", ""))
+               self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
 
        def loadPageData(self, data):
                self.dokusListe = []
@@ -187,14 +190,14 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
                        else:
                                self.pages = 1
 
-                       self['page'].setText("%d / %d" % (self.page,self.pages))
+                       self['page'].setText("%d / %d" % (self.page, self.pages))
 
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        self.th_ThumbsQuery(self.dokusListe, 0, 1, 2, None, None, self.page, self.pages, mode=1)
                        self.loadPicQueued()
                else:
-                       self.dokusListe.append(("Keine Videoclips gefunden!","","",""))
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.dokusListe.append(("Keine Videoclips gefunden!", "", "", ""))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        if self.filmQ.empty():
                                self.eventL.clear()
                        else:
@@ -280,7 +283,7 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
        def keyPageUp(self):
                self.keyPageUpFast(1)
 
-       def keyPageUpFast(self,step):
+       def keyPageUpFast(self, step):
                if self.keyLocked:
                        return
                oldpage = self.page
@@ -291,7 +294,7 @@ class LMDE_FilmListeScreen(MPScreen, ThumbsHelper):
                if oldpage != self.page:
                        self.loadPage()
 
-       def keyPageDownFast(self,step):
+       def keyPageDownFast(self, step):
                if self.keyLocked:
                        return
                oldpage = self.page
index 1fbf17d..768b002 100644 (file)
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
+from builtins import range
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.keyboardext import VirtualKeyBoardExt
-import Queue
+import queue
 import threading
 from Plugins.Extensions.MediaPortal.resources.youtubelink import YoutubeLink
 from Plugins.Extensions.MediaPortal.resources.menuhelper import MenuHelper
@@ -89,7 +93,7 @@ class show_LSDE_Genre(MenuHelper):
        def SuchenCallback(self, callback = None):
                if callback is not None and len(callback):
                        self.suchString = callback
-                       qr = urllib.quote(self.suchString).replace(' ','+')
+                       qr = urllib.parse.quote(self.suchString).replace(' ', '+')
                        genreurl = self.mh_baseUrl+(self.mh_genreUrl[self.mh_menuLevel] % qr)+'set_gallery_type=video'
                        self.session.open(LSDE_FilmListeScreen, genreurl, self.mh_genreTitle)
 
@@ -133,9 +137,9 @@ class LSDE_FilmListeScreen(MPScreen, ThumbsHelper):
 
                self['Page'] = Label(_("Page:"))
 
-               self.filmQ = Queue.Queue(0)
-               self.hanQ = Queue.Queue(0)
-               self.picQ = Queue.Queue(0)
+               self.filmQ = queue.Queue(0)
+               self.hanQ = queue.Queue(0)
+               self.picQ = queue.Queue(0)
                self.updateP = 0
                self.eventL = threading.Event()
                self.eventP = threading.Event()
@@ -152,14 +156,14 @@ class LSDE_FilmListeScreen(MPScreen, ThumbsHelper):
                self.onLayoutFinish.append(self.loadPage)
 
        def setGenreStrTitle(self):
-               genreName = "%s%s" % (self.genreTitle,self.genreName)
+               genreName = "%s%s" % (self.genreTitle, self.genreName)
                self['ContentTitle'].setText(genreName)
 
        def loadPage(self):
-               url = "%s&page=%d" % (self.genreLink, max(self.page,1))
+               url = "%s&page=%d" % (self.genreLink, max(self.page, 1))
 
                if self.page:
-                       self['page'].setText("%d / %d" % (self.page,self.lastpage))
+                       self['page'].setText("%d / %d" % (self.page, self.lastpage))
 
                self.filmQ.put(url)
                if not self.eventL.is_set():
@@ -177,7 +181,7 @@ class LSDE_FilmListeScreen(MPScreen, ThumbsHelper):
                self.dokusListe = []
                content = content[content.find('<ul id="itemlist">'):content.find('<p class="advert-notice">')]
                spl=content.split('<li>')
-               for i in range(1,len(spl),1):
+               for i in range(1, len(spl), 1):
                        entry=spl[i]
                        match=re.compile('<a href="(.+?)"', re.S).findall(entry)
                        if match:
@@ -200,7 +204,7 @@ class LSDE_FilmListeScreen(MPScreen, ThumbsHelper):
                        title=decodeHtml(title).strip()
                        if rating!=-1:
                                title=title+(" (%.1f / 10)" % float(rating))
-                       self.dokusListe.append((title, "http://www.lachschon.de"+url, thumb.replace('-medium',''), None))
+                       self.dokusListe.append((title, "http://www.lachschon.de"+url, thumb.replace('-medium', ''), None))
                if self.dokusListe:
                        if not self.lastpage:
                                try:
@@ -213,15 +217,15 @@ class LSDE_FilmListeScreen(MPScreen, ThumbsHelper):
                                        self.lastpage = lastpage
                        if not self.page:
                                self.page = 1
-                       self['page'].setText("%d / %d" % (self.page,self.lastpage))
+                       self['page'].setText("%d / %d" % (self.page, self.lastpage))
 
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        self['liste'].moveToIndex(0)
-                       self.th_ThumbsQuery(self.dokusListe,0,1,2,None,None, self.page, self.lastpage, mode=1)
+                       self.th_ThumbsQuery(self.dokusListe, 0, 1, 2, None, None, self.page, self.lastpage, mode=1)
                        self.loadPicQueued()
                else:
-                       self.dokusListe.append((_("No videos found!"),"","",""))
-                       self.ml.setList(map(self._defaultlistleft, self.dokusListe))
+                       self.dokusListe.append((_("No videos found!"), "", "", ""))
+                       self.ml.setList(list(map(self._defaultlistleft, self.dokusListe)))
                        self['liste'].moveToIndex(0)
                        if self.filmQ.empty():
                                self.eventL.clear()
index 346c32c..5fbbe24 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.youtubeplayer import YoutubePlayer
@@ -62,22 +65,16 @@ class LiveLeakScreen(MPScreen):
 
        def layoutFinished(self):
                self.genreliste.append(("--- Search ---", ""))
-               self.genreliste.append(("Featured", "browse?featured=1&page="))
-               self.genreliste.append(("Recent Items", "browse?page="))
-               self.genreliste.append(("Must See", "browse?in_bookmark_folder_id=2&container_id=module_container_1&hs=1&page="))
-               self.genreliste.append(("German", "browse?q=german&hs=1&page="))
-               self.genreliste.append(("News & Politics", "browse?tag_string=news%2C+politics%2C+trump&container_id=module_container_1&hs=1&page="))
-               self.genreliste.append(("Law Enforcement", "browse?tag_string=police%2C+law+enforcement%2C+cops%2C+bodycam&container_id=module_container_1&hs=1&page="))
-               self.genreliste.append(("Weather", "browse?tag_string=weather%2Cstorm%2Cthunder%2Cwind%2Churricane%2Ctornado%2Crainbow%2Chail%2Csnow%2Cice&container_id=module_container_1&hs=1&page="))
-               self.genreliste.append(("Entertainment", "browse?tag_string=entertainment&container_id=module_container_1&hs=1&page="))
-               self.genreliste.append(("WTF", "browse?tag_string=wtf&container_id=module_container_1&hs=1&page="))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.genreliste.append(("Recent Items", "list?page="))
+               self.genreliste.append(("Must See", "list?channel=must+see&page="))
+               self.genreliste.append(("News", "list?channel=news&page="))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
 
        def SuchenCallback(self, callback = None):
                if callback is not None and len(callback):
                        Name = "--- Search ---"
                        self.suchString = callback
-                       Link = 'browse?q=%s&hs=1&page=' % urllib.quote(self.suchString).replace(' ', '+')
+                       Link = 'browse?q=%s&hs=1&page=' % urllib.parse.quote(self.suchString).replace(' ', '+')
                        self.session.open(LiveLeakClips, Link, Name)
 
        def keyOK(self):
@@ -129,19 +126,19 @@ class LiveLeakClips(MPScreen, ThumbsHelper):
                self.feedliste = []
                self['name'].setText(_('Please wait...'))
                url = "https://www.liveleak.com/%s%s&safe_mode=off" % (self.Link, str(self.page))
-               getPage(url).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                self.getLastPage(data, 'class="pagination"(.*?)</ul>')
-               vids = re.findall('items_pic.*?img\ssrc="(.*?)"\salt="(.*?)".*?href="(.*?)".*?h3>(.*?)<div.*?Leaked:(.*?)in:.*?Views:\s(\d+)', data, re.S)
+               vids = re.findall('items_pic.*?img\ssrc="(.*?)"\salt="(.*?)".*?href="(.*?)".*?h3>(.*?)<div.*?(?:Added:|Leaked:)(.*?)(?:in:|\|).*?Views:\s(\d+)', data, re.S)
                if vids:
                        for (image, title, url, descr, date, views) in vids:
                                if image.startswith('//'):
                                        image = "https:" + image
-                               self.feedliste.append((decodeHtml(title).strip(), url , image , decodeHtml(stripAllTags(descr)).strip(), date.strip(), views.strip()))
+                               self.feedliste.append((decodeHtml(title).strip(), url, image, decodeHtml(stripAllTags(descr)).strip(), date.strip(), views.strip()))
                if len(self.feedliste) == 0:
                        self.feedliste.append((_('No videos found!'), None, None, '', '', ''))
-               self.ml.setList(map(self._defaultlistleft, self.feedliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.feedliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.th_ThumbsQuery(self.feedliste, 0, 1, 2, None, None, self.page, self.lastpage, mode=1)
@@ -152,7 +149,7 @@ class LiveLeakClips(MPScreen, ThumbsHelper):
                Title = self['liste'].getCurrent()[0][0]
                Image = self['liste'].getCurrent()[0][2]
                self['name'].setText(Title)
-               getPage(url).addCallback(self.showInfos2).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.showInfos2).addErrback(self.dataError)
                CoverHelper(self['coverArt']).getCover(Image)
 
        def showInfos2(self, data):
@@ -160,13 +157,13 @@ class LiveLeakClips(MPScreen, ThumbsHelper):
                views = self['liste'].getCurrent()[0][5]
                descr = re.findall('step_outer">(.*?)<div', data, re.S)
                if descr:
-                       self['handlung'].setText("Leaked: %s\nViews: %s\n\n%s" % (date, views, decodeHtml(stripAllTags(descr[0])).strip()))
+                       self['handlung'].setText("Added: %s\nViews: %s\n\n%s" % (date, views, decodeHtml(stripAllTags(descr[0])).strip()))
 
        def keyOK(self):
                if self.keyLocked:
                        return
                url = self['liste'].getCurrent()[0][1]
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                title = self['liste'].getCurrent()[0][0]
@@ -176,6 +173,6 @@ class LiveLeakClips(MPScreen, ThumbsHelper):
                else:
                        videoPage = re.findall('//www.youtube.com/(v|embed)/(.*?)\?.*?"', data, re.S)
                        if videoPage:
-                               self.session.open(YoutubePlayer,[(title, videoPage[0][1], None)],playAll= False,showPlaylist=False,showCover=False)
+                               self.session.open(YoutubePlayer, [(title, videoPage[0][1], None)], playAll= False, showPlaylist=False, showCover=False)
                        else:
                                self.session.open(MessageBoxExt, _("No videos found!"), MessageBoxExt.TYPE_INFO, timeout=3)
\ No newline at end of file
index 6696b23..a1e5619 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -86,11 +87,11 @@ class retrotvFilmListeScreen(MPScreen, ThumbsHelper):
                movies = re.findall('title="(Folge.*?)".*?href="(.*?)"><img\ssrc=".*?".*?<img\ssrc=".*?videos%2F(.*?)".*?td_description', data, re.S)
                if movies:
                        self.filmliste = []
-                       for (title,url,image) in movies:
+                       for (title, url, image) in movies:
                                image = 'https://www.retro-tv.de/gfx/videos/' + image
                                url = 'https://www.retro-tv.de/' + url
-                               self.filmliste.append((decodeHtml(title),url,image))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                               self.filmliste.append((decodeHtml(title), url, image))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                        self.ml.moveToIndex(0)
                        self.keyLocked = False
                        self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, self.page, self.lastpage, mode=1)
index 72565fc..72293a3 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.choiceboxext import ChoiceBoxExt
@@ -75,7 +78,7 @@ class twitchMainScreen(MPScreen):
                self.genreliste.append(("--- Search for Games ---", "searchgames"))
                self.genreliste.append(("--- Search for Streams ---", "searchstreams"))
                self.genreliste.append(("--- Search for Channels ---", "searchchannels"))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
 
@@ -93,7 +96,7 @@ class twitchMainScreen(MPScreen):
                if callback is not None and len(callback):
                        Name = self['liste'].getCurrent()[0][0]
                        ID = self['liste'].getCurrent()[0][1]
-                       self.suchString = urllib.quote(callback).replace(' ', '%20')
+                       self.suchString = urllib.parse.quote(callback).replace(' ', '%20')
                        self.session.open(twitchGames, self.suchString, Name, ID)
 
 class twitchGames(MPScreen):
@@ -175,12 +178,12 @@ class twitchGames(MPScreen):
                        twAgentGetPage(url, agent=agent, headers=headers).addCallback(self.parseData).addErrback(self.dataError)
                else:
                        if not fileExists(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"):
-                               open(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites","w").close()
+                               open(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites", "w").close()
                        if fileExists(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"):
                                path = config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"
                        if fileExists(path):
                                user_id = ""
-                               read = open(path,"r")
+                               read = open(path, "r")
                                for rawData in read.readlines():
                                        data = re.findall('"(.*?)" "(.*?)" "(.*?)"', rawData, re.S)
                                        if data:
@@ -219,11 +222,11 @@ class twitchGames(MPScreen):
                        except:
                                pass
                        if not fileExists(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"):
-                               open(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites","w").close()
+                               open(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites", "w").close()
                        if fileExists(config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"):
                                path = config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"
                        if fileExists(path):
-                               read = open(path,"r")
+                               read = open(path, "r")
                                for rawData in read.readlines():
                                        data = re.findall('"(.*?)" "(.*?)" "(.*?)"', rawData, re.S)
                                        if data:
@@ -236,23 +239,23 @@ class twitchGames(MPScreen):
                                read.close()
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No entries found!'), None, default_cover))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self._defaultlistleftmarked, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleftmarked, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "searchgames":
                        try:
                                for node in jsondata["games"]:
                                        title = str(node["name"])
-                                       image = str(node["box"]["template"]).replace('{width}x{height}','600x800')
+                                       image = str(node["box"]["template"]).replace('{width}x{height}', '600x800')
                                        self.gameList.append((title, '', image))
                        except:
                                pass
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No games found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                                self.keyLocked = False
                elif (self.ID == "streams" or self.ID == "searchstreams"):
                        for node in jsondata["streams"]:
@@ -261,13 +264,13 @@ class twitchGames(MPScreen):
                                language = str(node["channel"]["language"])
                                title = str(node["channel"]["display_name"])
                                name = str(node["channel"]["name"])
-                               image = str(node["preview"]["template"]).replace('{width}x{height}','800x450')
+                               image = str(node["preview"]["template"]).replace('{width}x{height}', '800x450')
                                self.gameList.append((game + " - " + title, language, image, name, game, title, id))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No streams found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self.twitchListEntry, self.gameList))
+                               self.ml.setList(list(map(self.twitchListEntry, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "featuredstreams":
                        for node in jsondata["featured"]:
@@ -276,24 +279,24 @@ class twitchGames(MPScreen):
                                language = str(node["stream"]["channel"]["language"])
                                title = str(node["stream"]["channel"]["display_name"])
                                name = str(node["stream"]["channel"]["name"])
-                               image = str(node["stream"]["preview"]["template"]).replace('{width}x{height}','800x450')
+                               image = str(node["stream"]["preview"]["template"]).replace('{width}x{height}', '800x450')
                                self.gameList.append((game + " - " + title, language, image, name, game, title, id))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No streams found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self.twitchListEntry, self.gameList))
+                               self.ml.setList(list(map(self.twitchListEntry, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "topgames":
                        for node in jsondata["top"]:
                                title = str(node["game"]["name"])
-                               image = str(node["game"]["box"]["template"]).replace('{width}x{height}','600x800')
+                               image = str(node["game"]["box"]["template"]).replace('{width}x{height}', '600x800')
                                self.gameList.append((title, '', image))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No games found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "videos":
                        for node in jsondata["vods"]:
@@ -302,16 +305,16 @@ class twitchGames(MPScreen):
                                vidtitle = str(node["title"])
                                game = str(node["game"])
                                try:
-                                       image = str(node["thumbnails"]["template"][0]["url"]).replace('{width}x{height}','800x450')
+                                       image = str(node["thumbnails"]["template"][0]["url"]).replace('{width}x{height}', '800x450')
                                except:
                                        image = None
                                id = str(node["_id"])
                                self.gameList.append((game + " - " + title + " - " + vidtitle, language, image, id, game, title + " - " + vidtitle))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No videos found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self.twitchListEntry, self.gameList))
+                               self.ml.setList(list(map(self.twitchListEntry, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "channelvideos":
                        for node in jsondata["videos"]:
@@ -320,16 +323,16 @@ class twitchGames(MPScreen):
                                vidtitle = str(node["title"])
                                game = str(node["game"])
                                try:
-                                       image = str(node["thumbnails"]["template"][0]["url"]).replace('{width}x{height}','800x450')
+                                       image = str(node["thumbnails"]["template"][0]["url"]).replace('{width}x{height}', '800x450')
                                except:
                                        image = None
                                id = str(node["_id"])
                                self.gameList.append((game + " - " + title + " - " + vidtitle, language, image, id, game, title + " - " + vidtitle))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No videos found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self.twitchListEntry, self.gameList))
+                               self.ml.setList(list(map(self.twitchListEntry, self.gameList)))
                                self.keyLocked = False
                elif self.ID == "searchchannels":
                        for node in jsondata["channels"]:
@@ -342,9 +345,9 @@ class twitchGames(MPScreen):
                                self.gameList.append((title, language, image, name, game, title, id))
                        if len(self.gameList) == 0:
                                self.gameList.append((_('No channels found!'), None, None))
-                               self.ml.setList(map(self._defaultlistleft, self.gameList))
+                               self.ml.setList(list(map(self._defaultlistleft, self.gameList)))
                        else:
-                               self.ml.setList(map(self.twitchListEntry, self.gameList))
+                               self.ml.setList(list(map(self.twitchListEntry, self.gameList)))
                                self.keyLocked = False
                self.ml.moveToIndex(0)
                self.showInfos()
@@ -412,7 +415,7 @@ class twitchGames(MPScreen):
                        Id = self['liste'].getCurrent()[0][6]
                        fn = config_mp.mediaportal.watchlistpath.value+"mp_twitch_favorites"
                        if not fileExists(fn):
-                               open(fn,"w").close()
+                               open(fn, "w").close()
                        try:
                                writePlaylist = open(fn, "a")
                                writePlaylist.write('"%s" "%s" "%s"\n' % (Title, Name, Id))
@@ -447,7 +450,7 @@ class twitchGames(MPScreen):
                else:
                        url = "http://usher.twitch.tv/api/channel/hls/{channel}.m3u8?player=twitchweb&token={token}&sig={sig}&allow_source=true"
                url = url.replace("{sig}", str(token["sig"]))
-               url = url.replace("{token}", urllib.quote(str(token["token"])))
+               url = url.replace("{token}", urllib.parse.quote(str(token["token"])))
                if (self.ID == "videos" or self.ID == "channelvideos"):
                        url = url.replace("{channel}", str(self.vodid[1:]))
                else:
@@ -468,12 +471,12 @@ class twitchGames(MPScreen):
                        if videoPrio == 2:
                                bw = max
                        elif videoPrio == 1:
-                               bw = max/2
+                               bw = max / 2
                        else:
-                               bw = max/3
+                               bw = max / 3
                        for each in match_sec_m3u8:
-                               bandwith,url = each
-                               self.bandwith_list.append((int(bandwith),url))
+                               bandwith, url = each
+                               self.bandwith_list.append((int(bandwith), url))
                        _x, best = min((abs(int(x[0]) - bw), x) for x in self.bandwith_list)
                        url = best[1]
                        mp_globals.player_agent = agent
index b8aed70..6911224 100644 (file)
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
+from builtins import range
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.keyboardext import VirtualKeyBoardExt
@@ -75,11 +79,11 @@ class ARDGenreScreen(MPScreen):
                self.genreliste.append(("Sendung verpasst!? - TV", "3"))
                self.genreliste.append(("Kategorien - TV", "4"))
                self.genreliste.append(("Tagesschau - TV", "11"))
-               self.genreliste.append((400 * "—","99"))
+               self.genreliste.append((400 * "—", "99"))
                self.genreliste.append(("Suche - Radio", "6"))
                self.genreliste.append(("Sendungen A bis Z - Radio", "7"))
                self.genreliste.append(("Kategorien - Radio", "8"))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
 
        def keyOK(self):
                self.gN = self['liste'].getCurrent()[0][0]
@@ -89,23 +93,23 @@ class ARDGenreScreen(MPScreen):
                elif self.gF == "1" or self.gF == "6":
                        self.session.openWithCallback(self.searchCallback, VirtualKeyBoardExt, title = (_("Enter search criteria")), text = self.suchString, is_dialog=True)
                else:
-                       self.session.open(ARDPreSelect,self.gN,self.gF)
+                       self.session.open(ARDPreSelect, self.gN, self.gF)
 
        def searchCallback(self, callback):
                self.gF = self['liste'].getCurrent()[0][1]
                if callback is not None and len(callback):
                        self.suchString = callback
-                       searchStr = urllib.quote(callback)
+                       searchStr = urllib.parse.quote(callback)
                        genreName = "Suche - " + self.suchString
                        if self.gF == "1":
                                url = BASE_URL+"/suche?searchText="+searchStr+"&source=tv&sort="
                        elif self.gF == "6":
                                url = BASE_URL+"/suche?searchText="+searchStr+"&source=radio&sort="
-                       self.session.open(ARDStreamScreen,url,genreName,self.gF)
+                       self.session.open(ARDStreamScreen, url, genreName, self.gF)
 
 class ARDPreSelect(MPScreen):
 
-       def __init__(self,session,genreName,genreFlag):
+       def __init__(self, session, genreName, genreFlag):
                self.gN = genreName
                self.gF = genreFlag
                MPScreen.__init__(self, session, skin='MP_Plugin', default_cover=default_cover)
@@ -132,7 +136,7 @@ class ARDPreSelect(MPScreen):
        def loadPage(self):
                if self.gF == "2" or self.gF == "7":
                        self.genreliste = []
-                       for c in xrange(26): # ABC, Radio & TV
+                       for c in range(26): # ABC, Radio & TV
                                self.genreliste.append((chr(ord('A') + c), None))
                        self.genreliste.insert(0, ('0-9', None))
                elif self.gF == "4" or self.gF == "8":
@@ -144,7 +148,7 @@ class ARDPreSelect(MPScreen):
                                self.genreliste.append(("Meistabgerufene Videos", "4"))
                                self.genreliste.append(("Ausgewählte Filme", "5"))
                                self.genreliste.append(("Ausgewählte Dokus", "6"))
-                               self.genreliste.append((400 * "—","99"))
+                               self.genreliste.append((400 * "—", "99"))
                                self.genreliste.append(("Kinder & Familie", "7"))
                                self.genreliste.append(('"Must see" - was die Redaktion schaut', "8"))
                                self.genreliste.append(("Kurzes für Zwischendurch", "9"))
@@ -161,7 +165,7 @@ class ARDPreSelect(MPScreen):
                        if self.gF == "8": # Extra-Kategorien, nur Radio
                                self.genreliste.append(("Neueste Clips", "1"))
                                self.genreliste.append(("Meistabgerufene Clips", "2"))
-                               self.genreliste.append((400 * "—","99"))
+                               self.genreliste.append((400 * "—", "99"))
                                self.genreliste.append(("Tipps der Redaktion", "3"))
                                self.genreliste.append(("Hörspiel", "4"))
                                self.genreliste.append(("Kabarett & Comedy", "5"))
@@ -172,7 +176,7 @@ class ARDPreSelect(MPScreen):
                        for q in range (0, 7):
                                s2 = (datetime.date.today()+datetime.timedelta(days=-q)).strftime("%A %d. %B %Y")
                                s3 = str(q)
-                               self.genreliste.append((s2,s3))
+                               self.genreliste.append((s2, s3))
                elif self.gF == "11":
                        self.genreliste = []
                        self.genreliste.append(("Tagesschau", "1"))
@@ -181,7 +185,7 @@ class ARDPreSelect(MPScreen):
                        self.genreliste.append(("Tagesschau24", "4"))
 
                self.keyLocked = False
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.showInfos()
 
        def keyOK(self):
@@ -192,7 +196,7 @@ class ARDPreSelect(MPScreen):
                if extra == "99":
                        return
                elif self.gF == "3":
-                       self.session.open(ARDPreSelectSender,auswahl,self.gF,extra)
+                       self.session.open(ARDPreSelectSender, auswahl, self.gF, extra)
                elif self.gF == "4":    # Kategorien TV
                        if extra == '1': # TOP von Seite 1 - TV
                                streamLink = "%s/tv" % BASE_URL
@@ -232,7 +236,7 @@ class ARDPreSelect(MPScreen):
                                streamLink = "%s/tv/Alle-Filme/mehr?documentId=31610076" % BASE_URL
                        elif extra == '19': # Alle Dokus & Reportagen
                                streamLink = "%s/tv/Alle-Dokus-und-Reportagen/mehr?documentId=29897594" % BASE_URL
-                       self.session.open(ARDStreamScreen,streamLink,auswahl,self.gF)
+                       self.session.open(ARDStreamScreen, streamLink, auswahl, self.gF)
                elif self.gF == "8": # Kategorien Radio
                        if extra == '1': # Neueste Clips
                                streamLink = "%s/radio/Neueste-Audios/mehr?documentId=21282450" % BASE_URL
@@ -250,7 +254,7 @@ class ARDPreSelect(MPScreen):
                                streamLink = "%s/radio/Wissen/mehr?documentId=34836128" % BASE_URL
                        elif extra == '8': # Gespräch
                                streamLink = "%s/radio/Gespräch/mehr?documentId=35293220" % BASE_URL
-                       self.session.open(ARDStreamScreen,streamLink,auswahl,self.gF)
+                       self.session.open(ARDStreamScreen, streamLink, auswahl, self.gF)
                elif self.gF == "11": # Tagesschau
                        if extra == '1': # Tagesschau
                                streamLink = "%s/tv/Tagesschau/Sendung?documentId=4326&bcastId=4326" % BASE_URL
@@ -260,18 +264,18 @@ class ARDPreSelect(MPScreen):
                                streamLink = "%s/tv/Tagesthemen/Sendung?documentId=3914&bcastId=3914" % BASE_URL
                        elif extra == '4': # Tagesschau24
                                streamLink = "%s/tv/tagesschau24/Sendung?documentId=6753968&bcastId=6753968" % BASE_URL
-                       self.session.open(ARDStreamScreen,streamLink,auswahl,self.gF)
+                       self.session.open(ARDStreamScreen, streamLink, auswahl, self.gF)
                else:
                        if self.gF == "2" or self.gF == "7": # ABC (TV oder Radio)
                                self.gN = auswahl
                        else:
                                self.gN = auswahl
                                auswahl = extra
-                       self.session.open(ARDPostSelect,auswahl,self.gN,self.gF)
+                       self.session.open(ARDPostSelect, auswahl, self.gN, self.gF)
 
 class ARDPreSelectSender(MPScreen):
 
-       def __init__(self,session,genreName,genreFlag,sender):
+       def __init__(self, session, genreName, genreFlag, sender):
                self.gN = genreName
                self.gF = genreFlag
                self.sender = sender
@@ -317,18 +321,18 @@ class ARDPreSelectSender(MPScreen):
                self.genreliste.append(("ARD alpha", "5868"))
                self.genreliste.append(("ONE", "673348"))
                self.genreliste.append(("KiKA", "5886"))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.showInfos()
 
        def keyOK(self):
                auswahl = self['liste'].getCurrent()[0][0]
                extra = self['liste'].getCurrent()[0][1]
-               url = "%s/tv/sendungVerpasst?tag=%s&kanal=%s" % (BASE_URL,self.sender,extra)    # "self.sender" kein Tippfehler!
-               self.session.open(ARDStreamScreen,url,auswahl,self.gF)
+               url = "%s/tv/sendungVerpasst?tag=%s&kanal=%s" % (BASE_URL, self.sender, extra)  # "self.sender" kein Tippfehler!
+               self.session.open(ARDStreamScreen, url, auswahl, self.gF)
 
 class ARDPostSelect(MPScreen, ThumbsHelper):
 
-       def __init__(self,session,auswahl,genreName,genreFlag):
+       def __init__(self, session, auswahl, genreName, genreFlag):
                self.auswahl = auswahl
                self.gN = genreName
                self.gF = genreFlag
@@ -358,24 +362,24 @@ class ARDPostSelect(MPScreen, ThumbsHelper):
 
        def loadPage(self):
                if self.gF == "2":      # ABC - TV
-                       url = "%s/tv/sendungen-a-z?buchstabe=%s&mcontent=page.1" % (BASE_URL,self.auswahl)
+                       url = "%s/tv/sendungen-a-z?buchstabe=%s&mcontent=page.1" % (BASE_URL, self.auswahl)
                if self.gF == "7":      # ABC - Radio
-                       url = "%s/radio/sendungen-a-z?buchstabe=%s&mcontent=page.1" % (BASE_URL,self.auswahl)
+                       url = "%s/radio/sendungen-a-z?buchstabe=%s&mcontent=page.1" % (BASE_URL, self.auswahl)
                twAgentGetPage(url, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                self.genreliste = []
                self.sendungen = re.findall('<div class="box" .*?textWrapper.*?<a\shref="(.*?)".*?headline">(.*?)<', data, re.S)
                if self.sendungen:
-                       for (url,title) in self.sendungen:
-                               url = BASE_URL+url.replace("&amp;","&")
+                       for (url, title) in self.sendungen:
+                               url = BASE_URL+url.replace("&amp;", "&")
                                if "|" in title:
-                                       title = title.replace("|","-")
-                               self.genreliste.append((decodeHtml(title),url))
+                                       title = title.replace("|", "-")
+                               self.genreliste.append((decodeHtml(title), url))
                        self.keyLocked = False
                else:
-                       self.genreliste.append((isWeg,None))
-               self.ml.setList(map(self._defaultlistleft, self.genreliste))
+                       self.genreliste.append((isWeg, None))
+               self.ml.setList(list(map(self._defaultlistleft, self.genreliste)))
                self.th_ThumbsQuery(self.genreliste, 0, 1, None, None, '<meta name="gsaimg512" content="(.*?)"', 1, 1, mode=1)
                if self['liste'].getCurrent()[0][0] != isWeg:
                        self.showInfos()
@@ -398,7 +402,7 @@ class ARDPostSelect(MPScreen, ThumbsHelper):
                gefunden = re.findall('<meta name="description" content="(.*?)"/.*?<meta name="author" content="(.*?)".*?<meta name="gsaimg512" content="(.*?)"/>.*?<div class="box">.*?textWrapper.*?dachzeile">(.*?)[<|\s]', data, re.S)
                if gefunden:
                        itxt = ''
-                       for (itxt,sender,streamPic,ausgaben) in gefunden:
+                       for (itxt, sender, streamPic, ausgaben) in gefunden:
                                itxttmp = itxt.split("|")
                                itxt = itxttmp[-2]
                                itxt = decodeHtml(itxt)
@@ -412,7 +416,7 @@ class ARDPostSelect(MPScreen, ThumbsHelper):
                                        media = "Radio"
                                else:
                                        media = "?"
-                               handlung = "Media: %s\nSender: %s\nClips: %s" % (media,sender,ausgaben)
+                               handlung = "Media: %s\nSender: %s\nClips: %s" % (media, sender, ausgaben)
                streamHandlung = handlung+"\n\n"+itxt
                self['handlung'].setText(streamHandlung)
                if streamPic:
@@ -426,11 +430,11 @@ class ARDPostSelect(MPScreen, ThumbsHelper):
                streamLink = self['liste'].getCurrent()[0][1]
                if streamLink == None:
                        return
-               self.session.open(ARDStreamScreen,streamLink,self.gN,self.gF)
+               self.session.open(ARDStreamScreen, streamLink, self.gN, self.gF)
 
 class ARDStreamScreen(MPScreen, ThumbsHelper):
 
-       def __init__(self, session,streamLink,genreName,genreFlag):
+       def __init__(self, session, streamLink, genreName, genreFlag):
                self.streamLink = streamLink
                self.gN = genreName
                self.gF = genreFlag
@@ -467,7 +471,7 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                self.suchTrigger = "score"
                self.blueTrigger = 0
                self.blueURL = ""
-               self.blueMemory = [0,0,0]
+               self.blueMemory = [0, 0, 0]
                self.blueIdx = 0
                self.folgen = ""
                self.filmliste = []
@@ -481,32 +485,32 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                        if self.gF == "1" or self.gF =="6":     # Suche
                                url = self.streamLink+self.suchTrigger+"&mresults=page."+str(self.page) # Kein "%s" hier verwenden!! Gewandelte Umlaute aus searchCallBack enthalten "%"!
                        elif self.gF == "4" or self.gF == "8":  # Kategorien
-                               url = "%s&mcontent=page.%s" % (self.streamLink,self.page)
+                               url = "%s&mcontent=page.%s" % (self.streamLink, self.page)
                        elif self.gF == "3":
                                url = self.streamLink
                        else:
-                               url = "%s&mcontents=page.%s" % (self.streamLink,self.page)
+                               url = "%s&mcontents=page.%s" % (self.streamLink, self.page)
 
                        if self.gN == "TOP von Seite 1 - TV":
                                url = self.streamLink
                        elif self.gN == '"Must see" - was die Redaktion schaut':
-                               url = "%s?m37862988=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m37862988=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Unterhaltung & Comedy':
-                               url = "%s?m39803570=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39803570=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Wissen' and "/tv/" in self.streamLink:
-                               url = "%s?m39348662=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39348662=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Politik':
-                               url = "%s?m39593042=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39593042=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Kultur':
-                               url = "%s?m39594746=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39594746=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Reise':
-                               url = "%s?m39618186=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39618186=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Ratgeber':
-                               url = "%s?m39712440=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m39712440=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Sport':
-                               url = "%s?m30348620=page.%s" % (self.streamLink,self.page)
+                               url = "%s?m30348620=page.%s" % (self.streamLink, self.page)
                        elif self.gN == 'Sportreportagen':
-                               url = "%s&m27307124=page.%s" % (self.streamLink,self.page)
+                               url = "%s&m27307124=page.%s" % (self.streamLink, self.page)
                else:   # Zweiter Durchlauf, wenn "Mehr.." gedrückt wurde (StreamLink wird zur StreamLink-Liste)
                        self['F4'].setText("Zurück")
                        self.blueMemory[0] = self.page
@@ -525,11 +529,11 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                                                max = re.findall('Loader-source.*?<a.*?>\s+(.*?)\s+</a>', data, re.S)[-2]       # Der vorletzte Treffer ist die letzte Seite
                                        except IndexError:      #       Gab kein [-2]
                                                max = "x"
-                                       max = filter(lambda x: x.isdigit(), max)        #       Ziffer enthalten?
-                                       if max == "":   # Keine Ziffer gefunden
+                                       max = [x for x in max if x.isdigit()]   #       Ziffer enthalten?
+                                       if not max:     # Keine Ziffer gefunden
                                                self.lastpage = 1
                                        else:
-                                               self.lastpage = int(max)
+                                               self.lastpage = int(max[-1])
                                else: # Kein "Loader-source"; ergo: Gibt nur eine Seite
                                        self.lastpage = 1
                else:   #       "Mehr..."
@@ -556,20 +560,20 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                                data = re.search('.*class="controls sliding"(.*?)$', data, re.S).group(1)
                        self.folgen = re.findall('<div class="teaser" data-ctrl-.*?textWrapper.*?href="(.*?)" class="textLink">.*?headline">(.*?)</', data, re.S)
                if self.folgen:
-                       for (url,title) in self.folgen:
+                       for (url, title) in self.folgen:
                                if not "Livestream" in url and not "http:" in url and "bcastId" in url:
-                                       url = BASE_URL+url.replace("&amp;","&")
+                                       url = BASE_URL+url.replace("&amp;", "&")
                                        sub = re.search('documentId=(.*?)($|&)', url, re.S)
                                        if sub:
                                                iD = sub.group(1)
-                                               self.filmliste.append((decodeHtml(title),url,iD))
-                                               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                                               self.filmliste.append((decodeHtml(title), url, iD))
+                                               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                                                self.ml.moveToIndex(self.blueIdx)
                        self.keyLocked = False
                else:
                        self.filmliste.append((isWeg, None, None, None))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
-               self.th_ThumbsQuery(self.filmliste, 0, 1, None, None, '<meta name="gsaimg512" content="(.*?)"', self.page,self.lastpage, mode=1)
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
+               self.th_ThumbsQuery(self.filmliste, 0, 1, None, None, '<meta name="gsaimg512" content="(.*?)"', self.page, self.lastpage, mode=1)
                if self['liste'].getCurrent()[0][0] != isWeg:
                        self.showInfos()
 
@@ -596,7 +600,7 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                                ergebnis = re.findall('<meta name="description" content="(.*?)"/>.*?author" content="(.*?)"/.*?<meta name="gsaimg512" content="(.*?)"/>.*?dcterms.title" content="(.*?)"/>.*?dcterms.date" content="(.*?)"/>.*?<p class="subtitle">(.*?)</', data, re.S)
                if ergebnis:
                        itxt = ''
-                       for (itxt,sender,streamPic,sendung,uhr,meta) in ergebnis:
+                       for (itxt, sender, streamPic, sendung, uhr, meta) in ergebnis:
                                self.sendung = sendung
                                title = self['liste'].getCurrent()[0][0]
                                if title in itxt:
@@ -615,7 +619,7 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                                airtime = meta[0]
                                dur = meta[1]
                        url = self['liste'].getCurrent()[0][1]
-                       handlung = "Sender: %s\nDatum: %s%s\nLaufzeit: %s" % (sender,airtime,uhr,dur)
+                       handlung = "Sender: %s\nDatum: %s%s\nLaufzeit: %s" % (sender, airtime, uhr, dur)
                self['name'].setText(decodeHtml(self.sendung))
                streamHandlung = handlung+"\n\n"+itxt
                self['handlung'].setText(streamHandlung)
@@ -682,35 +686,32 @@ class ARDStreamScreen(MPScreen, ThumbsHelper):
                        stream_data = json_data["_mediaArray"][1]
                else:
                        stream_data = json_data["_mediaArray"][0]
-               if type(stream_data["_mediaStreamArray"][-1]["_stream"]) == list:
+               if isinstance(stream_data["_mediaStreamArray"][-1]["_stream"], list):
                        stream = str(stream_data["_mediaStreamArray"][-1]["_stream"][-1])
                else:
                        stream = str(stream_data["_mediaStreamArray"][-1]["_stream"])
 
                if "960-" in stream: # Das Erste
                        try:
-                               import requests
-                               request = requests.head(stream.replace('960-','1280-'))
+                               request = requests.head(stream.replace('960-', '1280-'))
                                if request.status_code == 200:
-                                       stream = stream.replace('960-','1280-')
+                                       stream = stream.replace('960-', '1280-')
                        except:
                                pass
 
                if ".xl.mp4" in stream: # SWR
                        try:
-                               import requests
-                               request = requests.head(stream.replace('.xl.mp4','.xxl.mp4'))
+                               request = requests.head(stream.replace('.xl.mp4', '.xxl.mp4'))
                                if request.status_code == 200:
-                                       stream = stream.replace('.xl.mp4','.xxl.mp4')
+                                       stream = stream.replace('.xl.mp4', '.xxl.mp4')
                        except:
                                pass
 
                if "_sd.mp4" in stream: # DW
                        try:
-                               import requests
-                               request = requests.head(stream.replace('_sd.mp4','_hd.mp4'))
+                               request = requests.head(stream.replace('_sd.mp4', '_hd.mp4'))
                                if request.status_code == 200:
-                                       stream = stream.replace('_sd.mp4','_hd.mp4')
+                                       stream = stream.replace('_sd.mp4', '_hd.mp4')
                        except:
                                pass
 
index 3ef1e90..d829de2 100644 (file)
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
+from builtins import range
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 default_cover = "file://%s/arte.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
@@ -69,7 +73,7 @@ class arteFirstScreen(MPScreen):
                self.filmliste.append(("Sendungen A-Z", "http://www.arte.tv/hbbtvv2/services/web/index.php/OPA/v3/magazines/de"))
                self.filmliste.append(("Themen", "by_channel"))
                self.filmliste.append(("Datum", "by_date"))
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -88,7 +92,7 @@ class arteFirstScreen(MPScreen):
                if callback is not None and len(callback):
                        Name = "Suche"
                        self.suchString = callback
-                       Link = urllib.quote(self.suchString).replace(' ', '%20')
+                       Link = urllib.parse.quote(self.suchString).replace(' ', '%20')
                        self.session.open(arteSecondScreen, Link, Name)
 
 class arteSubGenreScreen(MPScreen):
@@ -118,12 +122,12 @@ class arteSubGenreScreen(MPScreen):
        def loadPage(self):
                if self.Name == "Datum":
                        today = datetime.date.today()
-                       for daynr in range(-21,22):
+                       for daynr in range(-21, 22):
                                day1 = today -datetime.timedelta(days=daynr)
                                dateselect =  day1.strftime('%Y-%m-%d')
                                link = 'http://www.arte.tv/hbbtvv2/services/web/index.php/OPA/v3/programs/%s/de' % dateselect
                                self.filmliste.append((dateselect, link))
-                       self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+                       self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                        self.ml.moveToIndex(21)
                elif self.Name == "Themen":
                        # http://www.arte.tv/hbbtvv2/services/web/index.php/EMAC/teasers/categories/v2/de
@@ -136,7 +140,7 @@ class arteSubGenreScreen(MPScreen):
                        self.filmliste.append(('Wissenschaft', link % 'SCI'))
                        self.filmliste.append(('Entdeckung der Welt', link % 'DEC'))
                        self.filmliste.append(('Geschichte', link % 'HIS'))
-                       self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+                       self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -155,16 +159,16 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                ThumbsHelper.__init__(self)
 
                self["actions"] = ActionMap(["MP_Actions"], {
-                       "0"             : self.closeAll,
-                       "ok"    : self.keyOK,
+                       "0": self.closeAll,
+                       "ok": self.keyOK,
                        "cancel": self.keyCancel,
-                       "5" : self.keyShowThumb,
-                       "up" : self.keyUp,
-                       "down" : self.keyDown,
-                       "right" : self.keyRight,
-                       "left" : self.keyLeft,
-                       "nextBouquet" : self.keyPageUp,
-                       "prevBouquet" : self.keyPageDown,
+                       "5": self.keyShowThumb,
+                       "up": self.keyUp,
+                       "down": self.keyDown,
+                       "right": self.keyRight,
+                       "left": self.keyLeft,
+                       "nextBouquet": self.keyPageUp,
+                       "prevBouquet": self.keyPageDown,
                }, -1)
 
                self['title'] = Label("arte Mediathek")
@@ -185,17 +189,17 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                if self.Name == "Suche":
                        url = "https://www.arte.tv/guide/api/api/zones/de/listing_SEARCH/?limit=100&query=%s&page=%s" % (url, str(self.page))
                else:
-                       url = url.replace('%%PAGE%%',str(self.page))
+                       url = url.replace('%%PAGE%%', str(self.page))
                        if "/teasers/category/" in url:
                                id = url.split('/')[-2]
                                url2 = "http://www.arte.tv/hbbtvv2/services/web/index.php/EMAC/teasers/category/v2/%s/de" % id
-                               getPage(url2, agent=std_headers, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Referer': self.Link}).addCallback(self.parseData).addErrback(self.dataError)
-               getPage(url, agent=std_headers, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Referer': self.Link}).addCallback(self.parseData).addErrback(self.dataError)
+                               twAgentGetPage(url2, agent=std_headers, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Referer': self.Link}).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url, agent=std_headers, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Referer': self.Link}).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                json_data = json.loads(data)
                if "teasers" in self.Link:
-                       if json_data.has_key('category'):
+                       if 'category' in json_data:
                                for node in json_data["category"]:
                                        if str(node["type"]) == "category":
                                                title = "Thema: " + str(node["title"])
@@ -203,8 +207,8 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                url = 'http://www.arte.tv/hbbtvv2/services/web/index.php/OPA/v3/videos/subcategory/%s/page/1/limit/100/de' % code
                                                self.filmliste.append((decodeHtml(title), url, default_cover, "", "subcat"))
                                self.filmliste.sort()
-                       if json_data.has_key('teasers'):
-                               if json_data["teasers"].has_key('highlights') and len(json_data["teasers"]["highlights"]) > 0:
+                       if 'teasers' in json_data:
+                               if 'highlights' in json_data["teasers"] and len(json_data["teasers"]["highlights"]) > 0:
                                        for node in json_data["teasers"]["highlights"]:
                                                kind = str(node['kind'])
                                                if kind in ["SHOW", "BONUS"]:
@@ -223,7 +227,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                        descr = ""
                                                self.filmliste.append((decodeHtml(title), url, image, descr, kind))
                                        self.filmliste.sort()
-                               if json_data["teasers"].has_key('collections') and len(json_data["teasers"]["collections"]) > 0:
+                               if 'collections' in json_data["teasers"] and len(json_data["teasers"]["collections"]) > 0:
                                        for node in json_data["teasers"]["collections"]:
                                                kind = str(node['kind'])
                                                programid = str(node['programId'])
@@ -239,7 +243,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                        descr = ""
                                                self.filmliste.append((decodeHtml(title), programid, image, descr, kind))
                                        self.filmliste.sort()
-                               if json_data["teasers"].has_key('playlists') and len(json_data["teasers"]["playlists"]) > 0:
+                               if 'playlists' in json_data["teasers"] and len(json_data["teasers"]["playlists"]) > 0:
                                        for node in json_data["teasers"]["playlists"]:
                                                kind = str(node['kind'])
                                                programid = str(node['programId'])
@@ -255,7 +259,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                        descr = ""
                                                self.filmliste.append((decodeHtml(title), programid, image, descr, kind))
                                        self.filmliste.sort()
-                               if json_data["teasers"].has_key('magazines') and len(json_data["teasers"]["magazines"]) > 0:
+                               if 'magazines' in json_data["teasers"] and len(json_data["teasers"]["magazines"]) > 0:
                                        for node in json_data["teasers"]["magazines"]:
                                                title = "Sendung: " + str(node["label"]["de"])
                                                url = str(node["url"])
@@ -263,7 +267,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                self.filmliste.append((decodeHtml(title), url, image, "", "sendung"))
                                        self.filmliste.sort()
                else:
-                       if json_data.has_key('programs'):
+                       if 'programs' in json_data:
                                for node in json_data["programs"]:
                                        if node['video']:
                                                if node['video']['kind'] in ["CLIP", "MANUAL_CLIP", "TRAILER"]:
@@ -295,8 +299,8 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                                image = str(node['video']['imageUrl'])
                                                url = "https://api.arte.tv/api/player/v1/config/de/%s" % str(node['video']['programId'])
                                                self.filmliste.append((decodeHtml(title), url, image, handlung, ""))
-                       elif json_data.has_key('videos'):
-                               if json_data.has_key('meta'):
+                       elif 'videos' in json_data:
+                               if 'meta' in json_data:
                                        self.lastpage = json_data["meta"]["pages"]
                                        if self.lastpage > 1:
                                                self['Page'].setText(_("Page:"))
@@ -329,7 +333,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                        image = str(node['imageUrl'])
                                        url = "https://api.arte.tv/api/player/v1/config/de/%s" % str(node['programId'])
                                        self.filmliste.append((decodeHtml(title), url, image, handlung, ""))
-                       elif json_data.has_key('magazines'):
+                       elif 'magazines' in json_data:
                                for node in json_data["magazines"]:
                                        if node['subtitle']:
                                                title = "%s - %s" % (str(node['title']), str(node['subtitle']))
@@ -343,8 +347,8 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                        kind = str(node['kind'])
                                        url = str(node['programId'])
                                        self.filmliste.append((decodeHtml(title), url, image, descr, kind))
-                       elif json_data.has_key('data'):
-                               if json_data.has_key('nextPage'):
+                       elif 'data' in json_data:
+                               if 'nextPage' in json_data:
                                        if json_data["nextPage"]:
                                                self.lastpage = self.page + 1
                                        if self.lastpage > 1:
@@ -365,8 +369,8 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                                        self.filmliste.append((decodeHtml(title), url, str(node['images']['landscape']['resolutions'][-1]['url']), handlung, ""))
 
                        if len(self.filmliste) == 0:
-                               self.filmliste.append((_("No videos found!"), '','','','',''))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                               self.filmliste.append((_("No videos found!"), '', '', '', '', ''))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, self.page, self.lastpage, mode=1)
@@ -387,7 +391,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
                link = self['liste'].getCurrent()[0][1]
                kind = self['liste'].getCurrent()[0][4]
                if link.startswith('http') and kind != "subcat":
-                       getPage(link, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest'}).addCallback(self.getStream).addErrback(self.dataError)
+                       twAgentGetPage(link, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest'}).addCallback(self.getStream).addErrback(self.dataError)
                else:
                        id = self['liste'].getCurrent()[0][1]
                        if kind == "subcat":
@@ -400,7 +404,7 @@ class arteSecondScreen(MPScreen, ThumbsHelper):
 
        def getStream(self, data):
                json_data  = json.loads(data)
-               if json_data["videoJsonPlayer"].has_key('VSR'):
+               if 'VSR' in json_data["videoJsonPlayer"]:
                        try:
                                url = str(json_data["videoJsonPlayer"]["VSR"]["HTTPS_SQ_1"]["url"])
                        except:
index 3ad0bc9..e7fb473 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 default_cover = "file://%s/atv.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
@@ -68,7 +71,7 @@ class atvGenreScreen(MPScreen, ThumbsHelper):
        def loadPage(self):
                self.filmliste = []
                url = "http://atv.at/mediathek"
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                parse = re.search('class="mod_programs">(.*?)/mod_programs', data, re.S)
@@ -76,9 +79,9 @@ class atvGenreScreen(MPScreen, ThumbsHelper):
                        raw = re.findall('href="(.*?)">.*?img\ssrc=".*?path=(.*?\.jpg).*?"\salt="(.*?)"', parse.group(), re.S)
                        if raw:
                                for (Url, ImageId, Title) in raw:
-                                       Image = "https://static.atv.cdn.tvnext.tv/static/assets/cms/%s" % urllib.unquote(ImageId)
+                                       Image = "https://static.atv.cdn.tvnext.tv/static/assets/cms/%s" % urllib.parse.unquote(ImageId)
                                        self.filmliste.append((decodeHtml(Title), Url, Image))
-                               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+                               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                                self.keyLocked = False
                                self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, 1, 1, mode=1)
                                self.showInfos()
@@ -127,7 +130,7 @@ class atvListScreen(MPScreen, ThumbsHelper):
 
        def loadPage(self):
                self.keyLocked = True
-               getPage(self.Link).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(self.Link).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                self['name'].setText(_("Please wait..."))
@@ -140,18 +143,18 @@ class atvListScreen(MPScreen, ThumbsHelper):
                        raw = re.findall('<li class="teaser">.*?href="(.*?)".*?img\ssrc=".*?path=(.*?\.jpg).*?class="title">(.*?)<', parse.group(), re.S)
                        if raw:
                                for (Url, ImageId, Title) in raw:
-                                       Image = "https://static.atv.cdn.tvnext.tv/static/assets/cms/%s" % urllib.unquote(ImageId)
+                                       Image = "https://static.atv.cdn.tvnext.tv/static/assets/cms/%s" % urllib.parse.unquote(ImageId)
                                        self.filmliste.append((decodeHtml(Title), Url, Image))
                nextpage = re.search('data-jsb="url=(.*?)" style=.*?Weitere Folgen', data, re.S)
                if nextpage:
-                       self.Link = urllib.unquote_plus(nextpage.group(1))
+                       self.Link = urllib.parse.unquote_plus(nextpage.group(1))
                        self.loadPage()
                if len(self.filmliste) == 0:
-                       self.filmliste.append((_("No videos found!"), "",""))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                       self.filmliste.append((_("No videos found!"), "", ""))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
-               self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None ,1 ,1, mode=1)
+               self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, 1, 1, mode=1)
                self.showInfos()
 
        def showInfos(self):
@@ -166,7 +169,7 @@ class atvListScreen(MPScreen, ThumbsHelper):
                        return
                Link = self['liste'].getCurrent()[0][1]
                self.keyLocked = True
-               getPage(Link).addCallback(self.getStreamLink).addErrback(self.dataError)
+               twAgentGetPage(Link).addCallback(self.getStreamLink).addErrback(self.dataError)
                self['name'].setText(_("Please wait..."))
 
        def getStreamLink(self, data):
@@ -181,7 +184,7 @@ class atvListScreen(MPScreen, ThumbsHelper):
                                        raw = re.findall('quot;(http[s]?:\\\/\\\/(?:blocked.|)(?:multiscreen.atv.cdn.tvnext.tv|atv.at)\\\/\d+\\\/\d+\\\/(?:HD|SD)\\\/(?:\d+)(?:\\\/index)(?:_\d|).m3u8)', part.group(1), re.S)
                        if raw:
                                for Link in raw:
-                                       Link = Link.replace('\/','/').replace('blocked.','').replace('blocked-','')
+                                       Link = Link.replace('\/', '/').replace('blocked.', '').replace('blocked-', '')
                                        Streampart = "Teil %s" % str(len(Linkliste)+1)
                                        Linkliste.append((Streampart, Link))
                self.keyLocked = False
@@ -199,11 +202,11 @@ class atvPartScreen(MPScreen):
                MPScreen.__init__(self, session, skin='MP_Plugin', default_cover=default_cover)
 
                self["actions"] = ActionMap(["MP_Actions"], {
-                       "0"             : self.closeAll,
-                       "ok"    : self.keyOK,
+                       "0": self.closeAll,
+                       "ok": self.keyOK,
                        "cancel": self.keyCancel,
-                       "up" : self.keyUp,
-                       "down" : self.keyDown,
+                       "up": self.keyUp,
+                       "down": self.keyDown,
                }, -1)
 
                self['title'] = Label("ATV Mediathek")
@@ -217,7 +220,7 @@ class atvPartScreen(MPScreen):
                self.onLayoutFinish.append(self.parseData)
 
        def parseData(self):
-               self.ml.setList(map(self._defaultlistcenter, self.Linkliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.Linkliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self['name'] = Label("%s" % self.Name)
index f18f243..ea32678 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -69,7 +72,7 @@ class brfGenreScreen(MPScreen):
                self.filmliste.append(("Blickpunkt", 'https://m.brf.be/blickpunkt/page/'))
                self.filmliste.append(("Beiträge", 'https://m.brf.be/beitraege/page/'))
                self.filmliste.append(("Reportagen", 'https://m.brf.be/reportagen/page/'))
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.showInfos()
 
        def keyOK(self):
@@ -86,7 +89,7 @@ class brfGenreScreen(MPScreen):
                if callback is not None and len(callback):
                        self.suchString = callback
                        Name = "Suche"
-                       Link = urllib.quote(callback).replace(' ', '+')
+                       Link = urllib.parse.quote(callback).replace(' ', '+')
                        self.session.open(brfListScreen, Link, Name)
 
 class brfListScreen(MPScreen, ThumbsHelper):
@@ -130,7 +133,7 @@ class brfListScreen(MPScreen, ThumbsHelper):
                        url = "https://m.brf.be/page/%s?s=%s" % (str(self.page), self.Link)
                else:
                        url = self.Link + str(self.page)
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                if ">Weitere laden</a>" in data:
@@ -143,7 +146,7 @@ class brfListScreen(MPScreen, ThumbsHelper):
                                self.filmliste.append((decodeHtml(Title), Url, Image, Date))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_("No videos found!"), None, default_cover, ""))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, self.page+1, self.lastpage, mode=1, pagefix=-1)
@@ -162,12 +165,12 @@ class brfListScreen(MPScreen, ThumbsHelper):
                        return
                url = self['liste'].getCurrent()[0][1]
                if url:
-                       getPage(url).addCallback(self.getDataStream).addErrback(self.dataError)
+                       twAgentGetPage(url).addCallback(self.getDataStream).addErrback(self.dataError)
 
        def getDataStream(self, data):
                videopage = re.findall('jQuery.get\("(.*?)"\)', data, re.S)
                if videopage:
-                       getPage(videopage[0]).addCallback(self.getStream).addErrback(self.dataError)
+                       twAgentGetPage(videopage[0]).addCallback(self.getStream).addErrback(self.dataError)
 
        def getStream(self, data):
                stream = re.findall('<source src="(.*?)"', data, re.S)
diff --git a/usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/disneyplus.py b/usr/lib/enigma2/python/Plugins/Extensions/MediaPortal/additions/mediatheken/disneyplus.py
new file mode 100644 (file)
index 0000000..5bc73b2
--- /dev/null
@@ -0,0 +1,117 @@
+# -*- coding: utf-8 -*-
+#######################################################################################################
+#
+#    MediaPortal for Dreambox OS
+#
+#    Coded by MediaPortal Team (c) 2013-2020
+#
+#  This plugin is open source but it is NOT free software.
+#
+#  This plugin may only be distributed to and executed on hardware which
+#  is licensed by Dream Property GmbH. This includes commercial distribution.
+#  In other words:
+#  It's NOT allowed to distribute any parts of this plugin or its source code in ANY way
+#  to hardware which is NOT licensed by Dream Property GmbH.
+#  It's NOT allowed to execute this plugin and its source code or even parts of it in ANY way
+#  on hardware which is NOT licensed by Dream Property GmbH.
+#
+#  This applies to the source code as a whole as well as to parts of it, unless explicitely
+#  stated otherwise.
+#
+#  If you want to use or modify the code or parts of it, permission from the authors is necessary.
+#  You have to keep OUR license and inform us about any modification, but it may NOT be distributed
+#  other than under the conditions noted above.
+#
+#  As an exception regarding modifcations, you are NOT permitted to remove
+#  any copy protections implemented in this plugin or change them for means of disabling
+#  or working around the copy protections, unless the change has been explicitly permitted
+#  by the original authors. Also decompiling and modification of the closed source
+#  parts is NOT permitted.
+#
+#  Advertising with this plugin is NOT allowed.
+#
+#  For other uses, permission from the authors is necessary.
+#
+#######################################################################################################
+
+from builtins import map
+from Plugins.Extensions.MediaPortal.plugin import _
+from Plugins.Extensions.MediaPortal.resources.imports import *
+
+try:
+    from Plugins.GP4.geminibrowser.gbrowserWidget import gMoviePlayer
+    GeminiPlayerFound = True
+except:
+    GeminiPlayerFound = False
+
+default_cover = "file://%s/disneyplus.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
+
+class disneyplusScreen(MPScreen):
+
+       def __init__(self, session):
+               MPScreen.__init__(self, session, skin='MP_Plugin', default_cover=default_cover)
+
+               self["actions"] = ActionMap(["MP_Actions"], {
+                       "0"             : self.closeAll,
+                       "ok"    : self.keyOK,
+                       "cancel": self.keyCancel
+               }, -1)
+
+               self['title'] = Label("Disney+")
+
+               self.filmliste = []
+               self.ml = MenuList([], enableWrapAround=True, content=eListboxPythonMultiContent)
+               self['liste'] = self.ml
+               self.StartTimer = eTimer()
+               self.keyLocked = True
+
+               self.onLayoutFinish.append(self.start)
+
+       def start(self):
+               self.filmliste.append(("",))
+               if mp_globals.model in ["one", "two"]:
+                       try:
+                               self.player_org = config.vod.disney.player.value
+                       except:
+                               pass
+                       self.StartTimer_conn = self.StartTimer.timeout.connect(self.keyOK)
+                       self.StartTimer.start(1000, False)
+                       self.filmliste.append((_("Please wait while Disney+ is started..."),))
+                       self.keyLocked = False
+               else:
+                       self.filmliste.append((_("This plugin is only available for Dreambox One and Two!"),))
+                       self['handlung'].setText('')
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
+               self.ml.moveToIndex(0)
+               self.ml.selectionEnabled(False)
+
+       def keyOK(self):
+               if self.keyLocked:
+                       return
+               self.StartTimer.stop()
+               try:
+                       from Plugins.Extensions.VOD.plugin import Plugins
+                       config.vod.disney.player = ConfigSelection(default='SIMPLE_PL', choices=[('SIMPLE_PL', 'MediaPortal')])
+                       config.vod.disney.player.save()
+                       configfile.save()
+                       from Plugins.Extensions.DisneyplusVod.disneymain import DisneyMain
+                       from Plugins.Extensions.MediaPortal.plugin import _stylemanager
+                       _stylemanager(0)
+                       self.session.openWithCallback(self.disneyplusClose, DisneyMain)
+               except:
+                       self.session.openWithCallback(self.disneyplusClose, MessageBoxExt, _("Launching Disney+ failed!"), MessageBoxExt.TYPE_ERROR, timeout=5)
+
+       def disneyplusClose(self, answer=''):
+               from Plugins.Extensions.MediaPortal.plugin import _stylemanager
+               _stylemanager(1)
+               menu = [('DREAMOS_PL', 'Dreamos'), ('SIMPLE_PL', 'Mediaportal')]
+               if GeminiPlayerFound:
+                       menu.append(('GEMINI_PL', 'Gemini'))
+               config.vod.disney.player = ConfigSelection(default='DREAMOS_PL', choices=menu)
+               try:
+                       config.vod.disney.player.value = self.player_org
+                       config.vod.disney.player.save()
+                       configfile.save()
+               except:
+                       pass
+               self.keyCancel()
\ No newline at end of file
index 7a316ee..2ffd5a4 100644 (file)
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
+from builtins import range
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
-import requests
 
 baseurl = "https://www.3sat.de"
 apiurl = "https://api.3sat.de"
@@ -80,7 +83,7 @@ class dreisatGenreScreen(MPScreen):
                self.filmliste.append(("Film", '/film', default_cover))
                self.filmliste.append(("Dokumentation", '/dokumentation', default_cover))
                self.filmliste.append(("Kabarett", '/kabarett', default_cover))
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -105,7 +108,7 @@ class dreisatGenreScreen(MPScreen):
                if callback is not None and len(callback):
                        Name = "Suche"
                        self.suchString = callback
-                       Link = urllib.quote(self.suchString).replace(' ', '+')
+                       Link = urllib.parse.quote(self.suchString).replace(' ', '+')
                        self.session.open(dreisatListScreen, Link, Name)
 
 class dreisatGenreSubScreen(MPScreen):
@@ -164,7 +167,7 @@ class dreisatGenreSubScreen(MPScreen):
                                for (Image, Url, Title, Handlung) in raw:
                                        Url = baseurl + Url
                                        self.filmliste.append((decodeHtml(Title), Url, Image, Handlung))
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -215,12 +218,12 @@ class dreisatDateScreen(MPScreen):
 
        def loadPage(self):
                today = datetime.date.today()
-               for daynr in range(-21,15):
+               for daynr in range(-21, 15):
                        day1 = today - datetime.timedelta(days=daynr)
                        dateselect = day1.strftime('%Y-%m-%d')
                        link = '%s/programm?airtimeDate=%s' % (baseurl, dateselect)
                        self.filmliste.append((dateselect, link, ''))
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.ml.moveToIndex(21)
                self.keyLocked = False
 
@@ -270,7 +273,7 @@ class dreisatAZScreen(MPScreen):
                                self.filmliste.append((decodeHtml(Title), Url, Image, Handlung))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_("No contents / results found!"), None, default_cover))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -343,7 +346,7 @@ class dreisatListScreen(MPScreen):
                        if raw:
                                for (Image, Airtime, Title, Runtime, Handlung, Url) in raw:
                                        Title = Airtime + " - " + decodeHtml(Title)
-                                       Handlung = "Laufzeit: " + Runtime + "\n\n" + decodeHtml(Handlung).replace('<b>','').replace('</b>','').strip()
+                                       Handlung = "Laufzeit: " + Runtime + "\n\n" + decodeHtml(Handlung).replace('<b>', '').replace('</b>', '').strip()
                                        self.filmliste.append((Title, Url, Image, Handlung))
                else:
                        raw = re.findall('class="m--content-module.*?title":\s"(.*?)",.*?"duration":\s"(.*?)".*?"embed_content":\s"(.*?)",.*?teaser-image="\[(.*?),(.*?)class="teaser-info', decodeHtml(data), re.S)
@@ -356,13 +359,13 @@ class dreisatListScreen(MPScreen):
                                                Url = Embed + ".html"
                                        handlung = re.findall('paragraph-large\s{0,2}">(.*?)</p>', Meta, re.S)
                                        Handlung = "Laufzeit: " + Runtime + "\n\n" + decodeHtml(handlung[0]).strip()
-                                       self.filmliste.append((decodeHtml(Title).replace('\/','/'), Url, Image, Handlung))
+                                       self.filmliste.append((decodeHtml(Title).replace('\/', '/'), Url, Image, Handlung))
                        raw = re.findall('class="video-carousel-item">.*?"title":\s"(.*?)",.*?duration":\s"(.*?)",.*?"embed_content":\s"(.*?)",.*?teaser-image-overwrite=[\"|\']\{"\d+x\d+":"(.*?)",', decodeHtml(data), re.S)
                        if raw:
                                for (Title, Runtime, Url, Image) in raw:
                                        Url = Url + ".html"
                                        Runtime = "Laufzeit: " + Runtime
-                                       self.filmliste.append((decodeHtml(Title).strip().replace('\\"','"').replace('\/','/'), Url, Image.replace('\/','/'), Runtime))
+                                       self.filmliste.append((decodeHtml(Title).strip().replace('\\"', '"').replace('\/', '/'), Url, Image.replace('\/', '/'), Runtime))
                        raw = re.findall('<article class="m--teaser-small.*?data-src="(.*?)".*?href="(.*?)".*?<h3(.*?)</article>', data, re.S)
                        if raw:
                                for (Image, Url, Meta) in raw:
@@ -377,10 +380,10 @@ class dreisatListScreen(MPScreen):
                                        for (Id, Title, Handlung) in raw:
                                                Url = topurl.group(1) + "/" + Id + ".html"
                                                Image = None
-                                               self.filmliste.append((decodeHtml(Title).strip().replace('\\"','"').replace('\/','/'), Url, Image, decodeHtml(Handlung).strip().replace('\\"','"'), Id))
+                                               self.filmliste.append((decodeHtml(Title).strip().replace('\\"', '"').replace('\/', '/'), Url, Image, decodeHtml(Handlung).strip().replace('\\"', '"'), Id))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_("No videos found!"), None, default_cover, ""))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.showInfos()
@@ -427,19 +430,19 @@ class dreisatListScreen(MPScreen):
                        Link = baseurl + streamLink
                        twAgentGetPage(Link, agent=agent).addCallback(self.getToken).addErrback(self.dataError)
 
-       def getToken(self,data):
+       def getToken(self, data):
                token = re.findall('data-zdfplayer-jsb.*?apiToken":\s"(.*?)",', data, re.S)
                if token:
                        self.token = token[0]
                        streamLink = self['liste'].getCurrent()[0][1]
-                       Link = apiurl + "/content/documents/zdf" +  streamLink.replace('.html','.json') + "?profile=player2"
+                       Link = apiurl + "/content/documents/zdf" +  streamLink.replace('.html', '.json') + "?profile=player2"
                        twAgentGetPage(Link, agent=agent, headers={'Api-Auth':'Bearer %s' % self.token, 'Accept':'application/vnd.de.zdf.v1.0+json'}).addCallback(self.getTemplateJson).addErrback(self.dataError)
                else:
                        self.keyLocked = False
                        streamName = self['liste'].getCurrent()[0][0]
                        self['name'].setText(streamName)
 
-       def getTemplateJson(self,data):
+       def getTemplateJson(self, data):
                a = json.loads(data)
                try:
                        url = apiurl + str(a['location'])
@@ -447,14 +450,14 @@ class dreisatListScreen(MPScreen):
                except:
                        b = a['mainVideoContent']['http://zdf.de/rels/target']['http://zdf.de/rels/streams/ptmd-template']
                        if b:
-                               b = b.replace('{playerId}','ngplayer_2_3')
+                               b = b.replace('{playerId}', 'ngplayer_2_3')
                                b = apiurl +b
                                twAgentGetPage(str(b), agent=agent, headers={'Api-Auth':'Bearer %s' % self.token, 'Accept':'application/vnd.de.zdf.v1.0+json'}).addCallback(self.getContentJson).addErrback(self.dataError)
 
-       def getContentJson(self,data):
+       def getContentJson(self, data):
                a = json.loads(data)
                b = []
-               for x in range (0,5,1):
+               for x in range (0, 5, 1):
                        try:
                                b.append((a['priorityList'][1]['formitaeten'][0]['qualities'][x]['audio']['tracks'][0]['uri']))
                        except:
@@ -462,13 +465,13 @@ class dreisatListScreen(MPScreen):
                self.keyLocked = False
                streamName = self['liste'].getCurrent()[0][0]
                c = b[0]
-               c = c.replace("1496k","3296k")
-               c = c.replace("p13v13","p15v13")
-               c = c.replace("p13v14","p15v14")
-               url = str(c).replace("https","http")
+               c = c.replace("1496k", "3296k")
+               c = c.replace("p13v13", "p15v13")
+               c = c.replace("p13v14", "p15v14")
+               url = str(c)
                if '.f4m' in url:
                        b = []
-                       for x in range (0,5,1):
+                       for x in range (0, 5, 1):
                                try:
                                        b.append((a['priorityList'][0]['formitaeten'][0]['qualities'][x]['audio']['tracks'][0]['uri']))
                                except:
index 3e5a408..ea029d7 100644 (file)
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 default_cover = "file://%s/funk.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
 
 headers = {
-       'Authorization':'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnROYW1lIjoid2ViYXBwLXYzMSIsInNjb3BlIjoic3RhdGljLWNvbnRlbnQtYXBpLGN1cmF0aW9uLWFwaSxuZXh4LWNvbnRlbnQtYXBpLXYzMSx3ZWJhcHAtYXBpIn0.mbuG9wS9Yf5q6PqgR4fiaRFIagiHk9JhwoKES7ksVX4',
-       'Accept-Encoding':'deflate',
+       'Authorization': 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJjbGllbnROYW1lIjoid2ViYXBwLXYzMSIsInNjb3BlIjoic3RhdGljLWNvbnRlbnQtYXBpLGN1cmF0aW9uLWFwaSxuZXh4LWNvbnRlbnQtYXBpLXYzMSx3ZWJhcHAtYXBpIn0.mbuG9wS9Yf5q6PqgR4fiaRFIagiHk9JhwoKES7ksVX4',
+       'Accept-Encoding': 'deflate',
 }
 
 BASE_URL = 'https://www.funk.net/api/v4.0'
@@ -81,28 +82,28 @@ class funkGenreScreen(MPScreen):
                self.filmliste = []
                self.keyLocked = True
                url = BASE_URL + "/channels/?size=100&page=%s" % str(self.page-1)
-               getPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
+               twAgentGetPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
 
        def genreData(self, data):
                json_data = json.loads(data)
-               if json_data.has_key('page'):
+               if 'page' in json_data:
                        if int(json_data["page"]["totalPages"])>1:
                                self.lastpage = int(json_data["page"]["totalPages"])
                                self['Page'].setText(_("Page:"))
                                self['page'].setText(str(self.page) + ' / ' + str(self.lastpage))
                for item in json_data["_embedded"]["channelDTOList"]:
-                       if item.has_key('imageUrlOrigin') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
+                       if 'imageUrlOrigin' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
                                image = str(item["imageUrlOrigin"])
-                       elif item.has_key('imageUrlLandscape') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
+                       elif 'imageUrlLandscape' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
                                image = str(item["imageUrlLandscape"])
-                       elif item.has_key('imageUrlPortrait') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
+                       elif 'imageUrlPortrait' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
                                image = str(item["imageUrlPortrait"])
-                       elif item.has_key('imageUrlSquare') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
+                       elif 'imageUrlSquare' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
                                image = str(item["imageUrlSquare"])
                        else:
                                image = None
                        title = decodeHtml(str(item["title"]))
-                       if item.has_key('description'):
+                       if 'description' in item:
                                descr = decodeHtml(str(item["description"]))
                        else:
                                descr = ""
@@ -110,7 +111,7 @@ class funkGenreScreen(MPScreen):
                        if title not in ("Doctor Who", "Uncle", "Threesome", "Orange is the new Black", "The Job Lot"):
                                self.filmliste.append((title, image, url, descr))
                self.filmliste.sort(key=lambda t : t[0].lower())
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.showInfos()
@@ -168,28 +169,28 @@ class funkSeasonsScreen(MPScreen):
                self.filmliste = []
                self.keyLocked = True
                url = self.url + "&page=%s" % str(self.page-1)
-               getPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
+               twAgentGetPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
 
        def genreData(self, data):
                json_data = json.loads(data)
-               if json_data.has_key('page'):
+               if 'page' in json_data:
                        if int(json_data["page"]["totalPages"])>1:
                                self.lastpage = int(json_data["page"]["totalPages"])
                                self['Page'].setText(_("Page:"))
                                self['page'].setText(str(self.page) + ' / ' + str(self.lastpage))
-               if not json_data.has_key('_embedded'):
-                       if json_data["parent"].has_key('imageUrlOrigin') and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlOrigin"]:
+               if '_embedded' not in json_data:
+                       if 'imageUrlOrigin' in json_data["parent"] and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlOrigin"]:
                                image = str(json_data["parent"]["imageUrlOrigin"])
-                       elif json_data["parent"].has_key('imageUrlLandscape') and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlLandscape"]:
+                       elif 'imageUrlLandscape' in json_data["parent"] and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlLandscape"]:
                                image = str(json_data["parent"]["imageUrlLandscape"])
-                       elif json_data["parent"].has_key('imageUrlPortrait') and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlPortrait"]:
+                       elif 'imageUrlPortrait' in json_data["parent"] and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlPortrait"]:
                                image = str(json_data["parent"]["imageUrlPortrait"])
-                       elif json_data["parent"].has_key('imageUrlSquare') and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlSquare"]:
+                       elif 'imageUrlSquare' in json_data["parent"] and not "8415ad90686d2c75aca239372903a45e" in json_data["parent"]["imageUrlSquare"]:
                                image = str(json_data["parent"]["imageUrlSquare"])
                        else:
                                image = None
                        title = decodeHtml(str(json_data["parent"]["title"]))
-                       if json_data["parent"].has_key('description'):
+                       if 'description' in json_data["parent"]:
                                descr = decodeHtml(str(json_data["parent"]["description"]))
                        else:
                                descr = ""
@@ -197,24 +198,24 @@ class funkSeasonsScreen(MPScreen):
                        self.filmliste.append((title, image, url, descr))
                else:
                        for item in json_data["_embedded"]["playlistDTOList"]:
-                               if item.has_key('imageUrlOrigin') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
+                               if 'imageUrlOrigin' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
                                        image = str(item["imageUrlOrigin"])
-                               elif item.has_key('imageUrlLandscape') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
+                               elif 'imageUrlLandscape' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
                                        image = str(item["imageUrlLandscape"])
-                               elif item.has_key('imageUrlPortrait') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
+                               elif 'imageUrlPortrait' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
                                        image = str(item["imageUrlPortrait"])
-                               elif item.has_key('imageUrlSquare') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
+                               elif 'imageUrlSquare' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
                                        image = str(item["imageUrlSquare"])
                                else:
                                        image = None
                                title = decodeHtml(str(item["title"]))
-                               if item.has_key('description'):
+                               if 'description' in item:
                                        descr = decodeHtml(str(item["description"]))
                                else:
                                        descr = ""
                                url = BASE_URL + "/videos/byPlaylistAlias/" + str(item["alias"]) + "?filterFsk=false&size=100&sort=episodeNr,ASC"
                                self.filmliste.append((title, image, url, descr))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.showInfos()
@@ -270,43 +271,43 @@ class funkEpisodesScreen(MPScreen):
                self.filmliste = []
                self.keyLocked = True
                url = self.url + "&page=%s" % str(self.page-1)
-               getPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
+               twAgentGetPage(url, headers=headers).addCallback(self.genreData).addErrback(self.dataError)
 
        def genreData(self, data):
                json_data = json.loads(data)
-               if json_data.has_key('page'):
+               if 'page' in json_data:
                        if int(json_data["page"]["totalPages"])>1:
                                self.lastpage = int(json_data["page"]["totalPages"])
                                self['Page'].setText(_("Page:"))
                                self['page'].setText(str(self.page) + ' / ' + str(self.lastpage))
                try:
                        for item in json_data["_embedded"]["videoDTOList"]:
-                               if item.has_key('imageUrlOrigin') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
+                               if 'imageUrlOrigin' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlOrigin"]:
                                        image = str(item["imageUrlOrigin"])
-                               elif item.has_key('imageUrlLandscape') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
+                               elif 'imageUrlLandscape' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlLandscape"]:
                                        image = str(item["imageUrlLandscape"])
-                               elif item.has_key('imageUrlPortrait') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
+                               elif 'imageUrlPortrait' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlPortrait"]:
                                        image = str(item["imageUrlPortrait"])
-                               elif item.has_key('imageUrlSquare') and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
+                               elif 'imageUrlSquare' in item and not "8415ad90686d2c75aca239372903a45e" in item["imageUrlSquare"]:
                                        image = str(item["imageUrlSquare"])
                                else:
                                        image = None
                                title = decodeHtml(str(item["title"]))
-                               if item.has_key('description'):
+                               if 'description' in item:
                                        descr = decodeHtml(str(item["description"]))
                                else:
                                        descr = ""
-                               if item.has_key('duration'):
+                               if 'duration' in item:
                                        duration = int(item["duration"])
                                        m, s = divmod(duration, 60)
                                        duration = "Laufzeit: %02d:%02d\n" % (m, s)
                                else:
                                        duration = ""
-                               if item.has_key('episodeNr'):
+                               if 'episodeNr' in item:
                                        episode = int(item["episodeNr"])
                                else:
                                        episode = ""
-                               if item.has_key('seasonNr'):
+                               if 'seasonNr' in item:
                                        season = int(item["seasonNr"])
                                else:
                                        season = ""
@@ -317,21 +318,21 @@ class funkEpisodesScreen(MPScreen):
                                                epi = ""
                                else:
                                        epi = ""
-                               if item.has_key('entityId'):
+                               if 'entityId' in item:
                                        id = str(item["entityId"])
                                else:
                                        id = None
-                               if item.has_key('downloadUrl'):
+                               if 'downloadUrl' in item:
                                        downld = str(item["downloadUrl"])
                                else:
                                        downld = None
 
                                self.filmliste.append((title, image, id, descr, epi, duration, downld))
                except Exception as e:
-                       printl(e,self,"E")
+                       printl(e, self, "E")
                if len(self.filmliste) == 0:
                        self.filmliste.append((_('No episodes found!'), None, None, "", "", "", None))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.showInfos()
index 932ed35..2f5f121 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 from Plugins.Extensions.MediaPortal.resources.youtubeplayer import YoutubePlayer
@@ -73,7 +74,7 @@ class kindertubeMain(MPScreen):
                self.streamList.append(("Musik", BASE_URL+'/musik-für-kinder.html'))
                self.streamList.append(("Alle Filme", BASE_URL+'/alle-filme-und-serien.html'))
                self.streamList.append(("Serien von früher", BASE_URL+'/alte-kinderserien.html'))
-               self.ml.setList(map(self._defaultlistcenter, self.streamList))
+               self.ml.setList(list(map(self._defaultlistcenter, self.streamList)))
                self.showInfos()
 
        def keyOK(self):
@@ -112,9 +113,9 @@ class kindertubeParsing(MPScreen, ThumbsHelper):
 
        def loadPage(self):
                self.streamList.append((_('Please wait...'), None))
-               self.ml.setList(map(self._defaultlistcenter, self.streamList))
+               self.ml.setList(list(map(self._defaultlistcenter, self.streamList)))
                self.streamList = []
-               getPage(self.url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(self.url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                pls = re.findall('<a href="(.*?)" class="col.*?"><div class="thumb"><img src="(image.*?)" alt="" class="img-thumbnail"></div><span class="title">(.*?)\n</span></a>', data)
@@ -130,7 +131,7 @@ class kindertubeParsing(MPScreen, ThumbsHelper):
                else:
                        self.keyLocked = False
 
-               self.ml.setList(map(self._defaultlistleft, self.streamList))
+               self.ml.setList(list(map(self._defaultlistleft, self.streamList)))
                self.ml.moveToIndex(0)
                self.th_ThumbsQuery(self.streamList, 0, 1, 2, None, None, 1, 1)
                self.showInfos()
@@ -180,8 +181,8 @@ class kindertubeEpisoden(MPScreen, ThumbsHelper):
        def loadPage(self):
                CoverHelper(self['coverArt']).getCover(self.cover)
                self.streamList.append((_('Please wait...'), None))
-               self.ml.setList(map(self._defaultlistcenter, self.streamList))
-               getPage(self.url).addCallback(self.parseData).addErrback(self.dataError)
+               self.ml.setList(list(map(self._defaultlistcenter, self.streamList)))
+               twAgentGetPage(self.url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                self.streamList = []
@@ -196,7 +197,7 @@ class kindertubeEpisoden(MPScreen, ThumbsHelper):
                        self.keyLocked = True
                else:
                        self.keyLocked = False
-               self.ml.setList(map(self._defaultlistleft, self.streamList))
+               self.ml.setList(list(map(self._defaultlistleft, self.streamList)))
                self.ml.moveToIndex(0)
                self.th_ThumbsQuery(self.streamList, 0, 1, 2, None, None, 1, 1)
                self.showInfos()
index 8e0227d..96a2f77 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 agent = 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/59.0.3071.115 Safari/537.36'
@@ -68,9 +69,9 @@ class myspassGenreScreen(MPScreen):
                self.genreliste = []
                self.count = 2
                url = "http://www.myspass.de/ganze-folgen/"
-               getPage(url, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(url, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
                url2 = "http://www.myspass.de/sendungen-a-bis-z/"
-               getPage(url2, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(url2, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                self.count -= 1
@@ -86,7 +87,7 @@ class myspassGenreScreen(MPScreen):
                        self.genreliste.sort(key=lambda t : t[0].lower())
                        if len(self.genreliste) == 0:
                                self.genreliste.append((_("No shows found!"), None, None))
-                       self.ml.setList(map(self._defaultlistleft, self.genreliste))
+                       self.ml.setList(list(map(self._defaultlistleft, self.genreliste)))
                        self.keyLocked = False
                        self.showInfos()
 
@@ -128,7 +129,7 @@ class myspassStaffelListeScreen(MPScreen):
                self.onLayoutFinish.append(self.loadPage)
 
        def loadPage(self):
-               getPage(self.myspassUrl, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(self.myspassUrl, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                parse = re.search('has-season-selector"(.*)class="videoPanel__dropdown-placeholder', data, re.S)
@@ -150,7 +151,7 @@ class myspassStaffelListeScreen(MPScreen):
                                self.staffelliste.sort(key=lambda t : (t[4], t[0].lower()))
                if len(self.staffelliste) == 0:
                        self.staffelliste.append((_('No seasons found!'), None, None, None, None))
-               self.ml.setList(map(self._defaultlistleft, self.staffelliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.staffelliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -194,7 +195,7 @@ class myspassFolgenListeScreen(MPScreen):
 
        def loadPage(self):
                url = "http://www.myspass.de/frontend/php/ajax.php?query=bob&seasonId=%s&formatId=%s&category=%s" % (self.seasonid, self.formatid, self.type)
-               getPage(url, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(url, agent=agent).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                myspassdata = json.loads(data)
@@ -207,7 +208,7 @@ class myspassFolgenListeScreen(MPScreen):
                                runtime = re.search(".*\|(.*?)$", str(meta), re.S).group(1).strip()
                                title = episode + " - " + decodeHtml(stripAllTags(str(title)))
                                self.folgenliste.append((title, link, image, str(desc), runtime))
-                       self.ml.setList(map(self._defaultlistleft, self.folgenliste))
+                       self.ml.setList(list(map(self._defaultlistleft, self.folgenliste)))
                        self.keyLocked = False
                        self.showInfos()
 
@@ -225,7 +226,7 @@ class myspassFolgenListeScreen(MPScreen):
                        return
                self.myname = self['liste'].getCurrent()[0][0]
                self.mylink = self['liste'].getCurrent()[0][1]
-               getPage(self.mylink, agent=agent).addCallback(self.get_link).addErrback(self.dataError)
+               twAgentGetPage(self.mylink, agent=agent).addCallback(self.get_link).addErrback(self.dataError)
 
        def get_link(self, data):
                json_data = json.loads(data)
index c8804be..d54f9ef 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -68,7 +69,7 @@ class netflixScreen(MPScreen):
 
        def start(self):
                self.filmliste.append(("",))
-               if mp_globals.model in ["one","two"]:
+               if mp_globals.model in ["one", "two"]:
                        try:
                                self.player_org = config.vod.netflix.player.value
                        except:
@@ -80,7 +81,7 @@ class netflixScreen(MPScreen):
                else:
                        self.filmliste.append((_("This plugin is only available for Dreambox One and Two!"),))
                        self['handlung'].setText('')
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.ml.moveToIndex(0)
                self.ml.selectionEnabled(False)
 
index 05c49ee..de15e9b 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 default_cover = "file://%s/netzkino.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
@@ -91,7 +94,7 @@ class netzKinoGenreScreen(MPScreen):
                self.genreliste.append(('Kinderkino', 'kinderkino'))
                self.genreliste.append(('Prickelkino', 'prickelkino'))
                self.genreliste.append(('Kino ab 18', 'kinoab18'))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
 
        def keyOK(self):
                Name = self['liste'].getCurrent()[0][0]
@@ -105,7 +108,7 @@ class netzKinoGenreScreen(MPScreen):
                if callback is not None and len(callback):
                        Name = "Suche"
                        self.suchString = callback
-                       Link = urllib.quote(self.suchString).replace(' ', '%20')
+                       Link = urllib.parse.quote(self.suchString).replace(' ', '%20')
                        self.session.open(netzKinoFilmeScreen, Link, Name)
 
 class netzKinoFilmeScreen(MPScreen, ThumbsHelper):
@@ -148,15 +151,15 @@ class netzKinoFilmeScreen(MPScreen, ThumbsHelper):
                        url = "http://api.netzkino.de.simplecache.net/capi-2.0a/categories/%s.json?d=www&l=de-DE&v=v1.2.0" % self.genreID
                        if self.Name == "HD-Kino":
                                url = url.split('?')[0]
-               getPage(url, agent=agent, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Origin': 'http://www.netzkino.de/', 'Referer': 'http://www.netzkino.de/'}).addCallback(self.genreData).addErrback(self.dataError)
+               twAgentGetPage(url, agent=agent, headers={'Content-Type': 'application/json', 'X-Requested-With': 'XMLHttpRequest', 'Origin': 'http://www.netzkino.de/', 'Referer': 'http://www.netzkino.de/'}).addCallback(self.genreData).addErrback(self.dataError)
 
        def genreData(self, data):
                json_data = json.loads(data)
                for node in json_data["posts"]:
-                       if node["custom_fields"].has_key('Streaming'):
+                       if 'Streaming' in node["custom_fields"]:
                                Title = str(node["title"])
                                Inhalt = stripAllTags(str(node["content"]))
-                               if node.has_key('thumbnail'):
+                               if 'thumbnail' in node:
                                        Image = str(node["thumbnail"])
                                else:
                                        Image = str(node["custom_fields"]["Artikelbild"][0])
@@ -164,20 +167,20 @@ class netzKinoFilmeScreen(MPScreen, ThumbsHelper):
                                IMDb = str(node["custom_fields"]["IMDb-Bewertung"][0])
                                FSK = str(node["custom_fields"]["FSK"][0])
                                Jahr = str(node["custom_fields"]["Jahr"][0])
-                               if node["custom_fields"].has_key('Regisseur'):
+                               if 'Regisseur' in node["custom_fields"]:
                                        Regie = str(node["custom_fields"]["Regisseur"][0])
                                else:
                                        Regie = "---"
-                               if node["custom_fields"].has_key('Stars'):
+                               if 'Stars' in node["custom_fields"]:
                                        Stars = str(node["custom_fields"]["Stars"][0])
                                else:
                                        Stars = "---"
                                Descr = "Jahr: "+Jahr+"\nIMDb-Rating: "+IMDb+"\nFSK: "+FSK+"\nRegie: "+Regie+"\nStars: "+Stars+"\n\n"+Inhalt
                                Url = "http://pmd.netzkino-seite.netzkino.de/%s.mp4" % Stream
-                               self.filmliste.append((Title,Image,Url,Descr))
+                               self.filmliste.append((Title, Image, Url, Descr))
                if len(self.filmliste) == 0:
-                       self.filmliste.append((_("No videos found!"),default_cover,None,""))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                       self.filmliste.append((_("No videos found!"), default_cover, None, ""))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 2, 1, None, None, 1, 1)
                self.showInfos()
index e40e607..a5b25fb 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 default_cover = "file://%s/orf.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
@@ -81,7 +82,7 @@ class ORFGenreScreen(MPScreen):
                self.genreliste.append(('Kinder', 'https://tvthek.orf.at/profiles/genre/Kinder/2703801'))
                self.genreliste.append(('Comedy & Satire', 'https://tvthek.orf.at/profiles/genre/Comedy-Satire/2703835'))
                self.genreliste.append(('Diskussion', 'https://tvthek.orf.at/profiles/genre/Diskussion/2703831'))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -122,7 +123,7 @@ class ORFSubGenreScreen(MPScreen):
        def loadPage(self):
                self['name'].setText(_('Please wait...'))
                self.keyLocked = True
-               getPage(self.Link).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(self.Link).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                sendungen = re.findall('<article.*?title="(.*?)".*?href="(.*?)".*?img\sdata-src="(.*?)"', data, re.S)
@@ -134,7 +135,7 @@ class ORFSubGenreScreen(MPScreen):
                        self.genreliste.sort(key=lambda t : t[0].lower())
                if len(self.genreliste) == 0:
                        self.genreliste.append(('Keine Sendungen gefunden!', None, None, None))
-               self.ml.setList(map(self._defaultlistleft, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.genreliste)))
                self.keyLocked = False
                self.showInfos()
 
@@ -179,7 +180,7 @@ class ORFFilmeListeScreen(MPScreen):
        def loadPage(self):
                self['name'].setText(_('Please wait...'))
                url = self.Link
-               getPage(url).addCallback(self.loadPageData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                if "other_episodes" in self.Link:
@@ -193,11 +194,11 @@ class ORFFilmeListeScreen(MPScreen):
                                for (date, time) in folgen:
                                        self.filmliste.append((decodeHtml(date + ', ' + time), self.Link))
                                more = re.findall('class="related-videos">.*?&quot;(.*?)&quot;', data, re.S)
-                               self.Link = "https://tvthek.orf.at" + more[0].replace('&amp;','&').replace('\/','/')
+                               self.Link = "https://tvthek.orf.at" + more[0].replace('&amp;', '&').replace('\/', '/')
                                self.loadPage()
                        else:
                                self.filmliste.append(('Momentan ist keine Sendung in der TVthek vorhanden.', None))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self['name'].setText('')
 
@@ -237,24 +238,24 @@ class ORFStreamListeScreen(MPScreen):
 
        def loadPage(self):
                self['name'].setText(_('Please wait...'))
-               getPage(self.Link).addCallback(self.gotPageData).addErrback(self.dataError)
+               twAgentGetPage(self.Link).addCallback(self.gotPageData).addErrback(self.dataError)
 
        def gotPageData(self, data):
                parse = re.search('jsb_VideoPlaylist" data-jsb="(.*?)"></div>', data, re.S)
-               folgen = re.findall('episode_id.*?title":"(.*?)","description":(.*?),".*?preview_image_url":"(.*?)","sources":(\[.*?\])', parse.group(1).replace('&quot;','"').replace('\/','/'), re.S)
+               folgen = re.findall('episode_id.*?title":"(.*?)","description":(.*?),".*?preview_image_url":"(.*?)","sources":(\[.*?\])', parse.group(1).replace('&quot;', '"').replace('\/', '/'), re.S)
                if folgen:
                        self.streamliste = []
                        for (title, desc, image, urls) in folgen[:-1]:
                                url = re.search('"quality":"Q8C","quality_string":"Sehr hoch(?: \(HD\)|)","src":"(http[s]?://apasfiis.sf.apa.at/ipad/.*?)"', urls, re.S)
                                if not url:
                                        url = re.search('"quality":"Q6A","quality_string":"Hoch","src":"(http[s]?://apasfiis.sf.apa.at/ipad/.*?)"', urls, re.S)
-                               title = title.replace('\\"','"')
+                               title = title.replace('\\"', '"')
                                if desc == "null":
                                        desc = ""
                                else:
                                        desc = desc.strip('"')
-                               self.streamliste.append((decodeHtml(title),url.group(1).replace('\/','/').replace('https','http'),image.replace('\/','/'),desc))
-                       self.ml.setList(map(self._defaultlistleft, self.streamliste))
+                               self.streamliste.append((decodeHtml(title), url.group(1).replace('\/', '/'), image.replace('\/', '/'), desc))
+                       self.ml.setList(list(map(self._defaultlistleft, self.streamliste)))
                        self.keyLocked = False
                        self.showInfos()
 
index 91f80c5..1b9907a 100644 (file)
@@ -34,6 +34,8 @@
 #
 #######################################################################################################
 
+from builtins import map
+from builtins import range
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 import base64
@@ -108,7 +110,7 @@ class popcorntimesGenreScreen(MPScreen):
                self.genreliste.append(('Natur-Dokumentation', '/genre/natur-doku'))
                self.genreliste.append(('Sport-Dokumentationen', '/genre/sport-dokus'))
                self.genreliste.append(('Tier-Dokumentationen', '/genre/tier-doku'))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
 
        def keyOK(self):
                Name = self['liste'].getCurrent()[0][0]
@@ -189,7 +191,7 @@ class popcorntimesFilmeScreen(MPScreen, ThumbsHelper):
                                                self.filmliste.append((decodeHtml(title), image, url, desc, meta))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_("No videos found!"), default_cover, None, '', ''))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 2, 1, None, None, 1, 1)
                self.showInfos()
index a053c1f..8dbb55f 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -68,7 +69,7 @@ class AmazonScreen(MPScreen):
 
        def start(self):
                self.filmliste.append(("",))
-               if mp_globals.model in ["one","two"]:
+               if mp_globals.model in ["one", "two"]:
                        try:
                                self.player_org = config.vod.dazn.player.value
                        except:
@@ -80,7 +81,7 @@ class AmazonScreen(MPScreen):
                else:
                        self.filmliste.append((_("This plugin is only available for Dreambox One and Two!"),))
                        self['handlung'].setText('')
-               self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                self.ml.moveToIndex(0)
                self.ml.selectionEnabled(False)
 
index 10b11e9..c26cc8c 100644 (file)
@@ -34,6 +34,7 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -78,11 +79,11 @@ class sTVGenreScreen(MPScreen):
        def loadPageData(self, data):
                shows = re.findall('class="component__card.*?href="(.*?)".*?class="card__image-container">.*?img\ssrc="(.*?\.(?:jpg|png)).*?".*?heading--two">(.*?)</', data, re.S)
                if shows:
-                       for (url,image,title) in shows:
+                       for (url, image, title) in shows:
                                image = image + "?resize=600,413&crop_strategy=smart"
-                               url = url.replace(baseurl,'')
+                               url = url.replace(baseurl, '')
                                self.genreliste.append((decodeHtml(title), url, image))
-                       self.ml.setList(map(self._defaultlistleft, self.genreliste))
+                       self.ml.setList(list(map(self._defaultlistleft, self.genreliste)))
                        self.keyLocked = False
                        self.showInfos()
 
@@ -99,34 +100,34 @@ class sTVGenreScreen(MPScreen):
                self.genreliste.append(("Unterhaltung", "/rubrik/unterhaltung/", default_cover))
                self.genreliste.append(("Volkskultur", "/rubrik/volkskultur/", default_cover))
                self.genreliste.append(("Wissen", "/rubrik/wissen/", default_cover))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
 
        def keyOK(self):
                name = self['liste'].getCurrent()[0][0]
                url = self['liste'].getCurrent()[0][1]
                url = baseurl + url
                if name == "Sendungen A-Z":
-                       self.session.open(sTVGenreScreen,url)
+                       self.session.open(sTVGenreScreen, url)
                else:
-                       self.session.open(sTVids,name,url)
+                       self.session.open(sTVids, name, url)
 
 class sTVids(MPScreen):
 
-       def __init__(self, session,name,url):
+       def __init__(self, session, name, url):
                self.Link = url
                self.Name = name
                MPScreen.__init__(self, session, skin='MP_Plugin', default_cover=default_cover)
 
                self["actions"] = ActionMap(["MP_Actions"], {
-                       "ok"    : self.keyOK,
-                       "0" : self.closeAll,
+                       "ok": self.keyOK,
+                       "0": self.closeAll,
                        "cancel": self.keyCancel,
-                       "up" : self.keyUp,
-                       "down" : self.keyDown,
-                       "right" : self.keyRight,
-                       "left" : self.keyLeft,
-                       "nextBouquet" : self.keyPageUp,
-                       "prevBouquet" : self.keyPageDown,
+                       "up": self.keyUp,
+                       "down": self.keyDown,
+                       "right": self.keyRight,
+                       "left": self.keyLeft,
+                       "nextBouquet": self.keyPageUp,
+                       "prevBouquet": self.keyPageDown,
                }, -1)
 
                self.keyLocked = True
@@ -148,19 +149,19 @@ class sTVids(MPScreen):
                self.filmliste = []
                self.keyLocked = True
                url = self.Link + "page/" + str(self.page) + "/?video_type=full-episodes"
-               print url
                twAgentGetPage(url, agent=stvAgent).addCallback(self.loadPageData).addErrback(self.dataError)
 
        def loadPageData(self, data):
                self.getLastPage(data, 'class="pagination">(.*?)</ul>')
-               shows = re.findall('class="component__card media_asset.*?href="(https://www.servustv.com/videos/(.*?)/)".*?class="card__image-container">.*?img\ssrc="(.*?\.(?:jpg|png)).*?".*?card__label">(.*?)</div.*?heading--two">(.*?)</.*?card__date\s{0,1}">(.*?)</div', data, re.S)
+               parse = re.search('class="grid-container"(.*?)class="site-footer"', data, re.S)
+               shows = re.findall('class="component__card media_asset.*?href="(https://www.servustv.com/videos/(.*?)/)".*?class="card__image-container">.*?img\ssrc="(.*?\.(?:jpg|png)).*?".*?card__label">(.*?)</div.*?heading--two">(.*?)</.*?card__date\s{0,1}">(.*?)</div', parse.group(1), re.S)
                if shows:
-                       for (url,id,image,title,subtitle,date) in shows:
+                       for (url, id, image, title, subtitle, date) in shows:
                                id = id.upper()
                                image = image + "?resize=600,413&crop_strategy=smart"
                                title = title.strip() + " - " + subtitle.strip()
-                               self.filmliste.append((decodeHtml(title),id,image,url,date.strip()))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                               self.filmliste.append((decodeHtml(title), id, image, url, stripAllTags(date).strip()))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                        self.ml.moveToIndex(0)
                        self.keyLocked = False
                        self.showInfos()
@@ -201,13 +202,13 @@ class sTVids(MPScreen):
                if videoPrio == 2:
                        bw = max
                elif videoPrio == 1:
-                       bw = max/2
+                       bw = max / 2
                else:
-                       bw = max/3
+                       bw = max / 3
                self.bandwith_list = []
                for each in match_sec_m3u8:
-                       bandwith,url = each
-                       self.bandwith_list.append((int(bandwith),url))
+                       bandwith, url = each
+                       self.bandwith_list.append((int(bandwith), url))
                _x, best = min((abs(int(x[0]) - bw), x) for x in self.bandwith_list)
                url = basepath + best[1]
                Name = self['liste'].getCurrent()[0][0]
index 7a20499..0594657 100644 (file)
@@ -34,6 +34,9 @@
 #
 #######################################################################################################
 
+from future import standard_library
+standard_library.install_aliases()
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
 
@@ -74,7 +77,7 @@ class SouthparkGenreScreen(MPScreen):
        def loadPage(self):
                self.filmliste = []
                url = "http://www.southpark.de/alle-episoden"
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                jsonurl = re.findall('data-url="(/feeds/carousel/.*?){', data, re.S)
@@ -83,7 +86,7 @@ class SouthparkGenreScreen(MPScreen):
                        for (ID, Title) in raw:
                                Url = "http://www.southpark.de" + jsonurl[0] + "/30/1/json/!airdate/" + ID
                                self.filmliste.append((Title, Url))
-                       self.ml.setList(map(self._defaultlistcenter, self.filmliste))
+                       self.ml.setList(list(map(self._defaultlistcenter, self.filmliste)))
                        self.keyLocked = False
 
        def keyOK(self):
@@ -152,7 +155,7 @@ class SouthparkListScreen(MPScreen, ThumbsHelper):
                self.keyLocked = True
                self.filmliste = []
                url = self.Link
-               getPage(url).addCallback(self.parseData).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.parseData).addErrback(self.dataError)
 
        def parseData(self, data):
                json_data = json.loads(data)
@@ -171,7 +174,7 @@ class SouthparkListScreen(MPScreen, ThumbsHelper):
                                self.filmliste.append((title, itemid, image, description, episode, avail))
                if len(self.filmliste) == 0:
                        self.filmliste.append((_("No episodes found!"), None, '', '', '', ''))
-               self.ml.setList(map(self._defaultlistleft, self.filmliste))
+               self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                self.ml.moveToIndex(0)
                self.keyLocked = False
                self.th_ThumbsQuery(self.filmliste, 0, 1, 2, None, None, 1, 1, mode=1)
@@ -235,7 +238,7 @@ class SouthparkAktScreen(MPScreen):
                self.keyLocked = True
                self.filmliste = []
                url = "http://www.southpark.de/feeds/video-player/mrss/mgid:arc:episode:southpark.de:" + self.Link
-               getPage(url).addCallback(self.getxmls).addErrback(self.dataError)
+               twAgentGetPage(url).addCallback(self.getxmls).addErrback(self.dataError)
 
        def getxmls(self, data):
                if self.locale == "de":
@@ -255,7 +258,7 @@ class SouthparkAktScreen(MPScreen):
                                        url = "http://media-utils.mtvnservices.com/services/MediaGenerator/mgid:arc:video:southparkstudios.com:%s?context=Array&format=xml&acceptMethods=%s%s" % (id, quality, self.lang)
                                        Titel = self.Name + " - Teil " + str(x)
                                        self.filmliste.append((Titel, url, self.Link))
-                       self.ml.setList(map(self._defaultlistleft, self.filmliste))
+                       self.ml.setList(list(map(self._defaultlistleft, self.filmliste)))
                        self.ml.moveToIndex(0)
                self.keyLocked = False
                self.showInfos()
@@ -273,7 +276,7 @@ class SouthparkAktScreen(MPScreen):
                        return
                self.keyLocked = True
                self.link = self['liste'].getCurrent()[0][1]
-               getPage(self.link, agent=agent).addCallback(self.StartStream).addErrback(self.dataError)
+               twAgentGetPage(self.link, agent=agent).addCallback(self.StartStream).addErrback(self.dataError)
 
        def StartStream(self, data):
                title = self['liste'].getCurrent()[0][0]
@@ -281,7 +284,7 @@ class SouthparkAktScreen(MPScreen):
                if http_data:
                        idx = self['liste'].getSelectedIndex()
                        mp_globals.player_agent = agent
-                       self.session.open(SouthparkPlayer, self.filmliste, int(idx) , True, False)
+                       self.session.open(SouthparkPlayer, self.filmliste, int(idx), True, False)
                else:
                        message = self.session.open(MessageBoxExt, _("Sorry, this video is not found or no longer available due to date or rights restrictions."), MessageBoxExt.TYPE_INFO, timeout=5)
                self.keyLocked = False
@@ -296,14 +299,14 @@ class SouthparkPlayer(SimplePlayer):
                self.pageurl = self.playList[self.playIdx][2]
                url = self.playList[self.playIdx][1]
                if fallback:
-                       url = url.replace('hls','phttp')
-               getPage(url, agent=agent).addCallback(self.gotVideo).addErrback(self.dataError)
+                       url = url.replace('hls', 'phttp')
+               twAgentGetPage(url, agent=agent).addCallback(self.gotVideo).addErrback(self.dataError)
 
        def gotVideo(self, data):
                http_data = re.findall('<rendition.*?".*?<src>(.*?)</src>.*?</rendition>', data, re.S|re.I)
                if http_data:
-                       videourl = http_data[-1].replace('&amp;','&')
-                       videourl = urllib.unquote(videourl)
+                       videourl = http_data[-1].replace('&amp;', '&')
+                       videourl = urllib.parse.unquote(videourl)
                        if config_mp.mediaportal.southparkquality.value == "HD" and ".m3u8" in videourl and not "akamaihd.net" in videourl:
                                if ",stream_" in videourl:
                                        splitstring = ',stream_'
index d91abe9..22c72a2 100644 (file)
@@ -34,9 +34,9 @@
 #
 #######################################################################################################
 
+from builtins import map
 from Plugins.Extensions.MediaPortal.plugin import _
 from Plugins.Extensions.MediaPortal.resources.imports import *
-from Plugins.Extensions.MediaPortal.resources.twagenthelper import twAgentGetPage
 
 default_cover = "file://%s/srg.png" % (config_mp.mediaportal.iconcachepath.value + "logos")
 
@@ -71,7 +71,7 @@ class SRGGenreScreen(MPScreen):
                self.genreliste.append(('RTS', ''))
                self.genreliste.append(('RTR', ''))
                self.genreliste.append(('RSI', ''))
-               self.ml.setList(map(self._defaultlistcenter, self.genreliste))
+               self.ml.setList(list(map(self._defaultlistcenter, self.genreliste)))
                self.keyLocked = False
 
        def keyOK(self):
@@ -122,7 +122,7 @@ class SRGListScreen(MPScreen, ThumbsHelper):
                                id = node["id"].encode('utf-8')
                                try:
                                        image = node['Image']['ImageRepresentations']['ImageRepresentation'][0]['url'].encode('utf-8')
-                                       image = image.replace('/16x9','')
+                                       image = image.replace('/16x9', '')
                                e