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
c2b01bcb
Commit
c2b01bcb
authored
Jul 21, 2003
by
Laurent Aimar
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
* http: added "del" and "empty" control. (for playlist). Corrected
"previous" command. TODO: doc :(
parent
604f15c9
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
40 additions
and
2 deletions
+40
-2
modules/control/http.c
modules/control/http.c
+40
-2
No files found.
modules/control/http.c
View file @
c2b01bcb
...
...
@@ -2,7 +2,7 @@
* http.c : http mini-server ;)
*****************************************************************************
* Copyright (C) 2001 VideoLAN
* $Id: http.c,v 1.1
5 2003/07/14 16:10:20 gbazin
Exp $
* $Id: http.c,v 1.1
6 2003/07/21 23:53:55 fenrir
Exp $
*
* Authors: Gildas Bazin <gbazin@netcourrier.com>
* Laurent Aimar <fenrir@via.ecp.fr>
...
...
@@ -25,6 +25,14 @@
/*****************************************************************************
* Preamble
*****************************************************************************/
/*
* TODO:
*
* - clean up ?
* - doc ! (mouarf ;)
*
*/
#include <stdlib.h>
#include <vlc/vlc.h>
#include <vlc/intf.h>
...
...
@@ -1236,6 +1244,8 @@ enum macroType
MVLC_NEXT
,
MVLC_PREVIOUS
,
MVLC_ADD
,
MVLC_DEL
,
MVLC_EMPTY
,
MVLC_CLOSE
,
MVLC_SHUTDOWN
,
...
...
@@ -1266,8 +1276,12 @@ StrToMacroTypeTab [] =
{
"stop"
,
MVLC_STOP
},
{
"pause"
,
MVLC_PAUSE
},
{
"next"
,
MVLC_NEXT
},
{
"prevous"
,
MVLC_PREVIOUS
},
{
"previous"
,
MVLC_PREVIOUS
},
/* playlist management */
{
"add"
,
MVLC_ADD
},
{
"del"
,
MVLC_DEL
},
{
"empty"
,
MVLC_EMPTY
},
/* admin control */
{
"close"
,
MVLC_CLOSE
},
...
...
@@ -1378,6 +1392,8 @@ static void MacroDo( httpd_file_callback_args_t *p_args,
p_sys
->
p_playlist
->
i_index
-
1
);
msg_Dbg
(
p_intf
,
"requested playlist next"
);
break
;
/* playlist management */
case
MVLC_ADD
:
{
char
mrl
[
512
];
...
...
@@ -1388,6 +1404,28 @@ static void MacroDo( httpd_file_callback_args_t *p_args,
msg_Dbg
(
p_intf
,
"requested playlist add: %s"
,
mrl
);
break
;
}
case
MVLC_DEL
:
{
int
i_item
;
char
item
[
512
];
uri_extract_value
(
p_request
,
"item"
,
item
,
512
);
i_item
=
atoi
(
item
);
playlist_Delete
(
p_sys
->
p_playlist
,
i_item
);
msg_Dbg
(
p_intf
,
"requested playlist del: %d"
,
i_item
);
break
;
}
case
MVLC_EMPTY
:
{
while
(
p_sys
->
p_playlist
->
i_size
>
0
)
{
playlist_Delete
(
p_sys
->
p_playlist
,
0
);
}
msg_Dbg
(
p_intf
,
"requested playlist empty"
);
break
;
}
/* admin function */
case
MVLC_CLOSE
:
{
...
...
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