Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
V
vlc
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
Commits
085f6772
Commit
085f6772
authored
Jan 06, 2014
by
Rémi Denis-Courmont
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
src: helper for command line item handling
parent
11405d4d
Changes
3
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
17 additions
and
5 deletions
+17
-5
src/interface/interface.c
src/interface/interface.c
+12
-0
src/libvlc.c
src/libvlc.c
+3
-5
src/libvlc.h
src/libvlc.h
+2
-0
No files found.
src/interface/interface.c
View file @
085f6772
...
...
@@ -162,6 +162,18 @@ playlist_t *(pl_Get)(vlc_object_t *obj)
return
pl
;
}
/**
* Inserts an item in the playlist used by interfaces.
* @note This function may <b>not</b> be called at the same time as
* intf_DestroyAll().
*/
void
intf_InsertItem
(
libvlc_int_t
*
libvlc
,
const
char
*
mrl
,
unsigned
optc
,
const
char
*
const
*
optv
,
unsigned
flags
)
{
playlist_AddExt
(
intf_GetPlaylist
(
libvlc
),
mrl
,
NULL
,
PLAYLIST_INSERT
,
0
,
-
1
,
optc
,
optv
,
flags
,
true
,
pl_Unlocked
);
}
/**
* Stops and destroys all interfaces
* @param p_libvlc the LibVLC instance
...
...
src/libvlc.c
View file @
085f6772
...
...
@@ -504,8 +504,7 @@ dbus_out:
psz_val
=
var_InheritString
(
p_libvlc
,
"open"
);
if
(
psz_val
!=
NULL
)
{
playlist_AddExt
(
pl_Get
(
p_libvlc
),
psz_val
,
NULL
,
PLAYLIST_INSERT
,
0
,
-
1
,
0
,
NULL
,
0
,
true
,
pl_Unlocked
);
intf_InsertItem
(
p_libvlc
,
psz_val
,
0
,
NULL
,
0
);
free
(
psz_val
);
}
...
...
@@ -650,10 +649,9 @@ static void GetFilenames( libvlc_int_t *p_vlc, unsigned n,
continue
;
}
playlist_AddExt
(
pl_Get
(
p_vlc
),
(
mrl
!=
NULL
)
?
mrl
:
args
[
n
],
NULL
,
PLAYLIST_INSERT
,
0
,
-
1
,
i_options
,
intf_InsertItem
(
p_vlc
,
(
mrl
!=
NULL
)
?
mrl
:
args
[
n
],
i_options
,
(
i_options
?
&
args
[
n
+
1
]
:
NULL
),
VLC_INPUT_OPTION_TRUSTED
,
true
,
pl_Unlocked
);
VLC_INPUT_OPTION_TRUSTED
);
free
(
mrl
);
}
}
...
...
src/libvlc.h
View file @
085f6772
...
...
@@ -178,6 +178,8 @@ static inline libvlc_priv_t *libvlc_priv (libvlc_int_t *libvlc)
return
(
libvlc_priv_t
*
)
libvlc
;
}
void
intf_InsertItem
(
libvlc_int_t
*
,
const
char
*
mrl
,
unsigned
optc
,
const
char
*
const
*
optv
,
unsigned
flags
);
void
intf_DestroyAll
(
libvlc_int_t
*
);
#define libvlc_stats( o ) (libvlc_priv((VLC_OBJECT(o))->p_libvlc)->b_stats)
...
...
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