Changeset 4b295c7cb26de39368086af8dc901df6bd29d135
- Timestamp:
- 23/12/07 23:23:25
(10 months ago)
- Author:
- Antoine Cellerier <dionoea@videolan.org>
- git-committer:
- Antoine Cellerier <dionoea@videolan.org> 1198448605 +0000
- git-parent:
[0212c5155653272d0125e3b788a2ed4db09876de]
- git-author:
- Antoine Cellerier <dionoea@videolan.org> 1198448605 +0000
- Message:
Allow specifying options specific to each url in the shout service discovery.
Make it possible to inherit the m3u-extvlcopt option in the m3u parser.
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| rf3903fc |
r4b295c7 |
|
| 110 | 110 | int i_options = 0; |
|---|
| 111 | 111 | vlc_bool_t b_cleanup = VLC_FALSE; |
|---|
| 112 | | vlc_bool_t b_enable_extvlcopt = config_GetInt( p_demux, "m3u-extvlcopt" ); |
|---|
| | 112 | vlc_bool_t b_enable_extvlcopt = var_CreateGetInteger( p_demux, |
|---|
| | 113 | "m3u-extvlcopt" ); |
|---|
| 113 | 114 | input_item_t *p_input; |
|---|
| 114 | 115 | |
|---|
| … | … | |
| 221 | 222 | } |
|---|
| 222 | 223 | HANDLE_PLAY_AND_RELEASE; |
|---|
| | 224 | var_Destroy( p_demux, "m3u-extvlcopt" ); |
|---|
| 223 | 225 | return 0; /* Needed for correct operation of go back */ |
|---|
| 224 | 226 | } |
|---|
| r0212c51 |
r4b295c7 |
|
| 44 | 44 | const char *psz_url; |
|---|
| 45 | 45 | const char *psz_name; |
|---|
| | 46 | const char *ppsz_options[2]; |
|---|
| 46 | 47 | } p_items[] = { |
|---|
| 47 | 48 | { "http/shout-winamp://www.shoutcast.com/sbin/newxml.phtml", |
|---|
| 48 | | N_("Shoutcast Radio") }, |
|---|
| | 49 | N_("Shoutcast Radio"), { NULL } }, |
|---|
| 49 | 50 | { "http/shout-winamp://www.shoutcast.com/sbin/newtvlister.phtml?alltv=1", |
|---|
| 50 | | N_("Shoutcast TV") }, |
|---|
| | 51 | N_("Shoutcast TV"), { NULL } }, |
|---|
| 51 | 52 | { "http://mafreebox.freebox.fr/freeboxtv/playlist.m3u", |
|---|
| 52 | | N_("Freebox TV") }, |
|---|
| | 53 | N_("Freebox TV"), { "m3u-extvlcopt=1", NULL } }, |
|---|
| 53 | 54 | }; |
|---|
| 54 | 55 | |
|---|
| … | … | |
| 129 | 130 | { |
|---|
| 130 | 131 | enum type_e i_type = (enum type_e)p_sd->p_sys; |
|---|
| | 132 | int i; |
|---|
| 131 | 133 | input_item_t *p_input = input_ItemNewExt( p_sd, |
|---|
| 132 | 134 | p_items[i_type].psz_url, _(p_items[i_type].psz_name), |
|---|
| 133 | 135 | 0, NULL, -1 ); |
|---|
| | 136 | for( i = 0; p_items[i_type].ppsz_options[i] != NULL; i++ ) |
|---|
| | 137 | input_ItemAddOption( p_input, p_items[i_type].ppsz_options[i] ); |
|---|
| 134 | 138 | input_ItemAddOption( p_input, "no-playlist-autostart" ); |
|---|
| | 139 | |
|---|
| 135 | 140 | |
|---|
| 136 | 141 | vlc_gc_incref( p_input ); |
|---|