Changeset d01611b8bf53f270ba24762b2db465ea38b196bb
- Timestamp:
- 14/06/08 16:10:43
(4 months ago)
- Author:
- Rémi Denis-Courmont <rdenis@simphalempin.com>
- git-committer:
- Rémi Denis-Courmont <rdenis@simphalempin.com> 1213452643 +0300
- git-parent:
[378b00a0c611a99bd5449831886817775079276c]
- git-author:
- Rémi Denis-Courmont <rdenis@simphalempin.com> 1213452538 +0300
- Message:
Make the playlist a generic object
-
Files:
-
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
| r2709abb |
rd01611b |
|
| 111 | 111 | { VLC_OBJECT_MODULE, "module" }, |
|---|
| 112 | 112 | { VLC_OBJECT_INTF, "intf" }, |
|---|
| 113 | | { VLC_OBJECT_PLAYLIST, "playlist" }, |
|---|
| 114 | 113 | { VLC_OBJECT_INPUT, "input" }, |
|---|
| 115 | 114 | { VLC_OBJECT_DECODER, "decoder" }, |
|---|
| r378b00a |
rd01611b |
|
| 616 | 616 | * because it is a circular dependency: |
|---|
| 617 | 617 | * ( playlist -> input -> playlist ) */ |
|---|
| 618 | | playlist_t *p_playlist = vlc_object_find( p_input, |
|---|
| 619 | | VLC_OBJECT_PLAYLIST, FIND_PARENT ); |
|---|
| 620 | | if( !p_playlist ) |
|---|
| 621 | | return; |
|---|
| 622 | | var_SetInteger( p_playlist, "item-change", |
|---|
| 623 | | p_input->p->input.p_item->i_id ); |
|---|
| 624 | | vlc_object_release( p_playlist ); |
|---|
| | 618 | playlist_t *p_playlist = pl_Yield( p_input ); |
|---|
| | 619 | if( VLC_OBJECT(p_playlist) == p_input->p_parent ) |
|---|
| | 620 | var_SetInteger( p_playlist, "item-change", |
|---|
| | 621 | p_input->p->input.p_item->i_id ); |
|---|
| | 622 | pl_Release( p_input ); |
|---|
| 625 | 623 | } |
|---|
| 626 | 624 | |
|---|
| r17eeea9 |
rd01611b |
|
| 1691 | 1691 | { |
|---|
| 1692 | 1692 | /* FIXME: we don't want to depend on the playlist */ |
|---|
| 1693 | | playlist_t * p_playlist = vlc_object_find( p_sys->p_input, |
|---|
| 1694 | | VLC_OBJECT_PLAYLIST, FIND_PARENT ); |
|---|
| 1695 | | if( p_playlist ) |
|---|
| | 1693 | playlist_t * p_playlist = pl_Yield( p_sys->p_input ); |
|---|
| | 1694 | if( VLC_OBJECT(p_playlist) == p_sys->p_input ) |
|---|
| 1696 | 1695 | { |
|---|
| 1697 | 1696 | PL_LOCK; |
|---|
| … | … | |
| 1699 | 1698 | vlc_object_signal_unlocked( p_playlist ); |
|---|
| 1700 | 1699 | PL_UNLOCK; |
|---|
| 1701 | | vlc_object_release( p_playlist ); |
|---|
| 1702 | 1700 | } |
|---|
| | 1701 | pl_Release( p_sys->p_input ); |
|---|
| 1703 | 1702 | } |
|---|
| 1704 | 1703 | return VLC_SUCCESS; |
|---|
| r94e3fe1 |
rd01611b |
|
| 67 | 67 | /* Allocate structure */ |
|---|
| 68 | 68 | p_playlist = vlc_custom_create( p_parent, sizeof( *p_playlist ), |
|---|
| 69 | | VLC_OBJECT_PLAYLIST, playlist_name ); |
|---|
| | 69 | VLC_OBJECT_GENERIC, playlist_name ); |
|---|
| 70 | 70 | if( !p_playlist ) |
|---|
| 71 | 71 | { |
|---|