Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-2-2
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Redmine
Redmine
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Operations
Operations
Metrics
Environments
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
videolan
vlc-2-2
Commits
f8b1ac11
Commit
f8b1ac11
authored
Aug 07, 2011
by
Pierre Ynard
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
youtube.lua: more clean-up
parent
9cd79b70
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
11 additions
and
8 deletions
+11
-8
share/lua/playlist/youtube.lua
share/lua/playlist/youtube.lua
+11
-8
No files found.
share/lua/playlist/youtube.lua
View file @
f8b1ac11
...
...
@@ -24,13 +24,17 @@ function get_url_param( url, name )
return
res
end
function
get_arturl
(
path
,
video_id
)
if
string.match
(
vlc
.
path
,
"iurl="
)
then
return
vlc
.
strings
(
get_url_param
(
vlc
.
path
,
"iurl"
)
)
end
if
not
arturl
then
return
"http://img.youtube.com/vi/"
..
video_id
..
"/default.jpg"
function
get_arturl
()
-- FIXME: vlc.strings() is not a function, it should probably be
-- vlc.strings.decode_uri()
--if string.match( vlc.path, "iurl=" ) then
-- return vlc.strings( get_url_param( vlc.path, "iurl" ) )
--end
video_id
=
get_url_param
(
vlc
.
path
,
"v"
)
if
not
video_id
then
return
nil
end
return
"http://img.youtube.com/vi/"
..
video_id
..
"/default.jpg"
end
-- Probe function.
...
...
@@ -106,8 +110,7 @@ function parse()
end
if not arturl then
video_id = get_url_param( vlc.path, "
v
" )
arturl = get_arturl( vlc.path, video_id )
arturl = get_arturl()
end
if not path then
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment