Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc-gpu
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-gpu
Commits
22a9f08b
Commit
22a9f08b
authored
Feb 05, 2010
by
Jakob Leben
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
lua: vlclua_playlist_add_internal() should post an input item tree
parent
b48252ea
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
1 deletion
+8
-1
modules/misc/lua/vlc.c
modules/misc/lua/vlc.c
+8
-1
No files found.
modules/misc/lua/vlc.c
View file @
22a9f08b
...
@@ -392,12 +392,14 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
...
@@ -392,12 +392,14 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
input_item_t
*
p_parent
,
bool
b_play
)
input_item_t
*
p_parent
,
bool
b_play
)
{
{
int
i_count
=
0
;
int
i_count
=
0
;
input_item_node_t
*
p_parent_node
=
NULL
;
assert
(
p_parent
||
p_playlist
);
assert
(
p_parent
||
p_playlist
);
/* playlist */
/* playlist */
if
(
lua_istable
(
L
,
-
1
)
)
if
(
lua_istable
(
L
,
-
1
)
)
{
{
if
(
p_parent
)
p_parent_node
=
input_item_node_Create
(
p_parent
);
lua_pushnil
(
L
);
lua_pushnil
(
L
);
/* playlist nil */
/* playlist nil */
while
(
lua_next
(
L
,
-
2
)
)
while
(
lua_next
(
L
,
-
2
)
)
...
@@ -472,7 +474,7 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
...
@@ -472,7 +474,7 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
/* Append item to playlist */
/* Append item to playlist */
if
(
p_parent
)
/* Add to node */
if
(
p_parent
)
/* Add to node */
{
{
input_item_
PostSubItem
(
p_parent
,
p_input
);
input_item_
node_AppendItem
(
p_parent_node
,
p_input
);
}
}
else
/* Play or Enqueue (preparse) */
else
/* Play or Enqueue (preparse) */
/* FIXME: playlist_AddInput() can fail */
/* FIXME: playlist_AddInput() can fail */
...
@@ -504,6 +506,11 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
...
@@ -504,6 +506,11 @@ int __vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
/* playlist key */
/* playlist key */
}
}
/* playlist */
/* playlist */
if
(
p_parent
)
{
if
(
i_count
)
input_item_node_PostAndDelete
(
p_parent_node
);
else
input_item_node_Delete
(
p_parent_node
);
}
}
}
else
else
{
{
...
...
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