domains.py 文件源码

python
阅读 30 收藏 0 点赞 0 评论 0

项目:script.reddit.reader 作者: gedisony 项目源码 文件源码
def return_action_and_link_tuple_accdg_to_setting_wether_to_use_addon_for_youtube(self, video_id):
        link_actn=''
        link_=''

        if video_id:
            if use_addon_for_youtube:
                link_actn=self.DI_ACTION_PLAYABLE
                link_="plugin://plugin.video.youtube/play/?video_id=" + video_id
            else:
                link_actn=self.DI_ACTION_YTDL
                #some youtube links take a VERY long time for youtube_dl to parse. we simplify it by getting the video id and using a simpler url
                #BUT if there is a time skip code in the url, we just pass it right through. youtube-dl can handle this part.
                #   time skip code comes in the form of ?t=122  OR #t=1m45s OR ?t=2:43
                link_=self.build_youtube_url_with_video_id(video_id)
            #log('    returning:{0} {1}'.format(link_actn, link_))
            return link_actn, link_
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号