Why Gemfury? Push, build, and install  RubyGems npm packages Python packages Maven artifacts PHP packages Go Modules Debian packages RPM packages NuGet packages

Repository URL to install this package:

Details    
Size: Mime:
ó
Ch-_c@sÐddlmZddlmZmZddlmZmZddl	m
Zddlm
Z
ddlZddlZddlmZd„Zd	fd
„ƒYZdefd„ƒYZd
efd„ƒYZdS(iÿÿÿÿ(tTranslateTXT(t	CHostBasetCBaseHostClass(tprintDBGtprintExc(tloads(tcommonN(t	timedeltacCsdS(Nshttps://vimeo.com/((((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgettytulstSuggestionsProvidercBs#eZd„Zd„Zd„ZRS(cCs7tƒ|_i|jjƒdd6dd6|j_dS(Ns
User-AgenttXMLHttpRequestsX-Requested-With(RtcmtgetDefaultHeadertHEADER(tself((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt__init__scCs
tdƒS(NsVimeo Suggestions(t_(R((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgetNamesc	Cs|jddƒd}dtj|ƒ}|jj|ƒ\}}|r}g}x)t|ƒdD]}|j|dƒq^W|SdS(Nt-iis(https://vimeo.com/search/autocomplete?q=toptionsttext(tsplitturllibtquoteRtgetPaget
json_loadstappendtNone(	RRtlocaletlangturltststdatatretListtitem((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgetSuggestions s(t__name__t
__module__RRR#(((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyR	s		tVimeoComcBsžeZd„Zidd„Zd„Zd„Zd„Zd„Zd„Z	d„Z
d„Zd	„Zd
„Z
d„Zd„Zd
ddd„Zd„ZRS(cCs5tj|idd6dd6ƒd|_d|_d|_i|jd6d	d
6dd6d
d6|jƒd6|jƒd6|_t|jƒ|_|jj	idd6d
d6dd6dd6|jƒd d6ƒi|jd6t
d6t
d6t
d6|jd6|_i|_
idd6dd6d d!6d"d#6d$d%6|_dS(&Ns	vimeo.comthistorysvimeo.com.cookietcookiesHMozilla/5.0 (Windows NT 6.1; WOW64; rv:40.0) Gecko/20100101 Firefox/40.0shttps://vimeo.com/sJhttps://avemariaradio.net/wp-content/uploads/2017/03/vimeo_logo_header.jpgs
User-Agentt1tDNTs	text/htmltAccepts
gzip, deflatesAccept-EncodingtReferertOriginR
sX-Requested-Withs0application/x-www-form-urlencoded; charset=UTF-8sContent-Types(application/vnd.vimeo.*+json;version=3.3iÿÿÿÿtheadert
use_cookietload_cookietsave_cookiet
cookiefiletvideostclipttondemandtpeoplestpeopletgroupstgrouptchannelstchannel(RRt
USER_AGENTtMAIN_URLtDEFAULT_ICON_URLt
getMainUrltHTTP_HEADERtdicttAJAX_HEADERtupdatetTruetCOOKIE_FILEt
defaultParamstapittypeMaps(R((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyR-s			B=2	cCs4|ikrt|jƒ}n|jj|||ƒS(N(RBRGRR(RtbaseUrlt	addParamst	post_data((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyR:scCs€tdƒidd6tdƒd6|jdƒd6idd6td	ƒd6td
6idd6tdƒd6g}|j||ƒdS(
NsVimeoCom.listMainMenut
categoriestcategoryt
Categoriesttitles/categoriesRtsearchtSearchtsearch_itemtsearch_historysSearch history(RRt
getFullUrlREtlistsTab(RtcItemtMAIN_CAT_TAB((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytlistMainMenu>s

'cCs3tjdƒj|ƒ}xo|D]g}|d}|d}|dkr^|dkr^d|}n|dkr|dkr||j|<qqW|jjj|tjdƒtjdƒƒd}|jjj|d	ƒd}d|kró||jd
<n|jjj|dƒd}d|kr/d||jd<ndS(Ns8vimeo\.config\.api\.([^\s^=]+?)\s*=\s*['"]([^'^"]+?)['"]iiRR5shttps://%s/svimeo\.config\s*?=s};s$['"]jwt['"]\s*:\s*['"]([^'^"]+?)['"]tjwts$['"]url['"]\s*:\s*['"]([^'^"]+?)['"](tretcompiletfindallRHRtphtgetDataBeetwenReMarkerstgetSearchGroups(RR tapiObjR"tkeytvalRZR((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt_fillApiDataGs



1cCs3td|ƒ|j|dƒ\}}|s1dS|jjj|ddƒ}xà|D]Ø}|jjj|dƒd}|jjj|d	ƒd}|jd
ƒ}|jd
ƒr¼|d}n
|d}|j|ƒ}	it	d
6dd6|d6|d6|	d6|j
|ƒd6|j|ƒd6}
|j|
ƒqSWdS(NsVimeoCom.listLang [%s]Rs<divt>scategory categorys</as\ssrc=['"]([^'^"]+?)['"]is\shref=['"]([^'^"]+?)['"]t/iþÿÿÿiÿÿÿÿtgood_for_favRNtnametf_catRPticon(s<divRescategory category(s</aRe(
RRRR^tgetAllItemsBeetwenNodesR`RtendswithtcleanHtmlStrtFalseRUtgetFullIconUrltaddDir(RRWtnextCategoryRR R"RjRtcatRPtparams((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytlistCategoriesWs


IcCs;td|ƒ|jjddƒdkr\|j|dƒ\}}|sLdS|j|ƒn|j|ddƒ\}}|sƒdS|j|ƒ|jjddƒd|jddƒ}t|jƒ}|j|d<d|jjd	dƒ|dd
<|j||ƒ\}}|sdSyt|ƒ}xñ|ddd
ddd…D]Ð}|ddkrcqGn|ddkryqGn|j	|dƒ}|d}	t
|dƒ}
|dd|jj|	dƒ}t|ƒ}|jit
d6|d6|d6|d6|	d6|
d6ƒ|j|ƒqGWWntk
r6tƒnXdS(NsVimeoCom.listTypes [%s]RR5s/videossVsearch?_video_override=true&filter_type=clip&c=b&filter_category=%s&fields=facets.typeRiR.sjwt %sRZt
AuthorizationtfacetsttypeRiÿÿÿÿttotaliRhR6RRfRgRNRPtf_typetdesc(RRHtgetRRdRBRGRCRRmtstrRIRDRnRpt	ExceptionR(RRWRqRR RRsR"RPRwRz((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt	listTypeshsB
)
!&
!7
cCsítd|ƒ|j|dƒ\}}|s1dS|j|ƒ|jjddƒd|jddƒ|jddƒf}t|jƒ}|j|d<d|jjd	dƒ|dd
<|j||ƒ\}}|sØdSt|ƒ}|jit	d6|d6t
d
ƒd6ƒ|j|ƒyµt|ƒ}x¢|dddD]Ž}|j
|dƒ}|d}	t|dƒ}
|dd|	}t|ƒ}|jit	d6|d6|d6|	d6|
d6ƒ|j|ƒq;WWntk
rètƒnXdS(NsVimeoCom.listSubCategories [%s]RR5sqsearch?_video_override=true&filter_type=%s&page=1&per_page=1&c=b&facets=true&filter_category=%s&fields=search_webRyRiR.sjwt %sRZRuRgRNtAnyRPRvtsubcategoryRRRhRxs
?subcategory=t
f_subcategoryRz(RRRdRHR{RBRGRCRDRnRRpRRmR|R}R(RRWRqRR RRsR"RPRwRz((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytlistSubCategoriesŒs6
;
!(

0
cCs+td|ƒ|j|dƒ\}}|s1dS|j|ƒ|jjj|d|jddƒƒd}|jjj|ddƒ}y‡td	d
j	|ƒƒ}xg|D]_}|j
|dƒ}t|ƒ}|jit
d6|d
6|d6|dd6ƒ|j|ƒq¨WWntk
r&tƒnXdS(NsVimeoCom.listSort [%s]Rs2"%s"\:\{"identifier"[^;]+?"sorts"\:\{([^;]+?\})\},RyR5it{t}s[%s]t,tlabelRgRNRPt
identifiertf_sort(RRRdRR^R`R{tgetAllItemsBeetwenMarkersRtjoinRmRBRDRnRpR}R(RRWRqRR R"RPRs((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytlistSort¬s 
,
-
cCs;td|ƒd}|jddƒ}|j|dƒ\}}|sIdS|j|ƒ|jjddƒd|jddƒ||f}id	d
6dd6d
d6dd6}|jdƒdkrÌ|d7}n|jddƒdkr|dtj|dƒ7}n|jddƒdkr?|d|j|d|dƒ7}n|jddƒdkrl|d|d7}n|d|jddƒ7}t|j	ƒ}|j
|d<d|jjddƒ|dd<|j||ƒ\}}|sådSy7t|ƒ}t|ƒx¶|d D]ª}	|	d!}
|	|
}	|j|	d"ƒ}|j
|	d#ƒ}|j|	d$d%d&d#ƒ}d'|
krÆ|	d(d)d*d+}
|	d(d)d,d+}d-|
d.|g}d/j|ƒ}nqd0|
kr$|	d(d)d*d+}
|	d(d)d,d+}d-|
d1|g}d/j|ƒ}nd2|
kr‚|	d(d)d*d+}
|	d(d)d3d+}d-|
d.|g}d/j|ƒ}nµd|
kr7|	d(d)d4d+}|	d(d)d5d+}ttd6|	d7ƒƒ}|jd8ƒrï|d9}n|d:|d;|g}d/j|ƒ}|j|	d<d"ƒd=|}nt|ƒ}|jddƒ|jitd>6|
d?6|d@6|d6|dA6|dB6ƒ|
dkr¦|j|ƒq	|j|ƒq	W|d+|d|dCkrt|ƒ}|jitd>6tdDƒd@6|dd6ƒ|j|ƒnWntk
r6tƒnXdS(ENsVimeoCom.listItems [%s]itpageiRR5s^search?_video_override=true&filter_type=%s&page=%s&per_page=%s&sizes=250x115&fields=search_webRysduration&direction=asctshortestsduration&direction=desctlongestsalphabetical&direction=desctalphabetical_descsalphabetical&direction=asctalphabetical_ascR4s&filter_price=freetf_querys	&query=%sRˆs&sort=%sRis&filter_category=%ss&c=%stf_ctbR.sjwt %sRZRuR RwRhtlinktpicturestsizesiÿÿÿÿR<tmetadatatconnectionsR3Rxtuserss	%s videoss%s followerss | R:s
%s membersR8t	followerstlikestcommentstsecondstdurations0:is%s likess%s commentstusers[/br]RgRNRPRjRztper_pages	Next page(RtpopRRdRHR{RRRBRGRCRRmRURoRŠR|Rt
startswithRRDREtaddVideoRpRnRR}R(RRWtITEMS_PER_PAGERŒRR RtsortMapRsR"RwRPRjtvideosCountstusersCountsRztlikesCountstcommentsCountsRž((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt	listItems¿sŒ
2"
%
!



7,
c	Cstd|ƒ|j|ddƒ\}}|s5dS|jjj|ddƒd}|jjj|d	d
ƒ}x‹|D]ƒ}|j|ƒ}|jjj|dƒd}t|ƒ}|j	d
dƒ|jitd6|d6|d6|d6ƒ|j
|ƒqvWdS(NsVimeoCom.listSort2 [%s]Rs/videos/format:details<divResjs-sorts</divis<as</a>s/sort\:([^/]+?)/iRŒRgRNRPRˆ(s<divResjs-sort(s</divRe(RRRR^tgetDataBeetwenNodesR‰RmR`RBR¡RRDRnRp(	RRWRqRR R"RPtsortRs((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt	listSort2s
)c	Csltd|ƒ|jddƒ}|dd}|dkrK|d|7}n|jddƒdkrx|d	|d7}n|d
7}|j|ƒ\}}|s¡dS|jjj|d)d*ƒd}d|d|krÝt}nt}|jjj	|d+d,ƒ}x|D]}|jjj
|dƒd}|jjj
|dƒd}|jdƒd}|j|jjj|d-d.ƒdƒ}	|j|jjj|d/d0ƒdƒ}
|
g}|jjj|d1d2ƒd}|jjj
|ddƒ}xz|D]r}
d|
kr|
}
n,|jjj
|
d ƒd}d!||
f}
|j|
ƒ}
|
dkrð|j|
ƒqðqðWd"j|ƒ}|d#|j|jjj|d3d4ƒdƒ7}t|ƒ}|jddƒ|jitd%6|	d6|j|ƒd6|j|ƒd&6|d'6ƒ|j|ƒqW|dkrht|ƒ}|jitd%6td(ƒd6|dd6ƒ|j|ƒndS(5NsVimeoCom.listItems2 [%s]RŒiRs/videoss/page:%sRˆR5s/sort:%ss/format:details<divRet
paginations</divs	/page:%s/s<lis	id="clip_s</lis\ssrc=['"]([^'^"]+?)['"]is\shref=['"]([^'^"]+?)['"]Rfiÿÿÿÿs<pRPs</pRžtmetas<spans</span>s<times\stitle=['"]([^'^"]+?)['"]s%s: %ss | s[/br]tdescriptionRgRjRzs	Next page(s<divReR®(s</divRe(s<liRes	id="clip_(s</liRe(s<pRestitle(s</pRe(s<divResduration(s</divRe(s<pReR¯(s</pRe(s<pReR°(s</pRe(RR¡R{RRR^R«RERnRkR`RRmR‰RRŠRBRRDRURoR£RRp(RRWRŒRRR tnextPageR"RjRPRžRzttmpttR†Rs((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt
listItems2sV
	
((	
	0B,cCs€td|||fƒ|jdtj|ƒƒ}t|ƒ}|ji|d6dd6|d6dd6|d	6ƒ|j|ƒdS(
NsEVimeoCom.listSearchResult cItem[%s], searchPattern[%s] searchType[%s]s/search?q=%sRt
list_itemsRNRytsR’R‘(RRURRRBRDRª(RRWt
searchPatternt
searchTypeRRs((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytlistSearchResultFs
0cCs"td|ƒ|jj|dƒS(NsVimeoCom.getLinksForVideo [%s]R(RtuptgetVideoLinkExt(RRW((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgetLinksForVideoNsiR5c	Cs3tdƒtj|||||ƒ|jjddƒ}|jjddƒ}|jjddƒ}td||fƒi|_g|_|dkr«|jidd6ƒnq|dkrÍ|j	|jdƒnO|dkrï|j
|jd	ƒn-|d	kr|j|jd
ƒn|d
kr3|j|jdƒné|dkrR|j
|jƒnÊ|dkrt|j|jdƒn¨|dkr“|j|jƒn‰|dkrßt|jƒ}|jitd6dd6ƒ|j|||ƒn=|dkr|jidd6dd6dtdƒƒntƒtj|||ƒdS(NshandleService startRhR5RNtmodes+handleService: |||| name[%s], category[%s] RMt
list_typest
list_sub_catst	list_sortRµR8R:R<tlist_items2RQtsearch_next_pageRSRTR'RzsType: (speoplesgroupschannel(ssearchRÂ(RRt
handleServicetcurrItemR{t
cacheLinkstcurrListRRYRtR~R‚R‹RªR­R´RBRDRnR¹tlistsHistoryRRtendHandleService(	RtindextrefreshR·R¸RhRNR½RW((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyRÃRs@
		*cCstdƒtƒS(NsVimeo.getSuggestionsProvider(RR	(RRÉ((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgetSuggestionsProvider}s
N(R$R%RRRRYRdRtR~R‚R‹RªR­R´R¹R¼RÃRË(((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyR&+s	
					$	 		H		/		+tIPTVHostcBseZd„Zd„ZRS(cCsDtj|tƒtgƒidd6dd6dd6dd6d	d
6dS(NR3R4R5R6R7R8R9R:R;R<(RRR&RE(R((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyRƒscCsng}|jtdƒdfƒ|jtdƒdfƒ|jtdƒdfƒ|jtdƒdfƒ|S(	NtVideosR4tPeopleR8tChannelsR<tGroupsR:(RR(RtsearchTypesOptions((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pytgetSearchTypes‡s(R$R%RRÒ(((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyŔs	(t7Plugins.Extensions.IPTVPlayer.components.iptvplayerinitRRt.Plugins.Extensions.IPTVPlayer.components.ihostRRt-Plugins.Extensions.IPTVPlayer.tools.iptvtoolsRRt*Plugins.Extensions.IPTVPlayer.libs.e2ijsonRRt*Plugins.Extensions.IPTVPlayer.libs.pCommonRR[RtdatetimeRRR	R&RÌ(((sH/usr/lib/enigma2/python/Plugins/Extensions/IPTVPlayer/hosts/hostvimeo.pyt<module>s	ÿW