[vlc-devel] commit: rc: factorisation ( Rémi Duraffort )
git version control
git at videolan.org
Sun Feb 22 11:21:37 CET 2009
vlc | branch: master | Rémi Duraffort <ivoire at videolan.org> | Sun Feb 22 11:18:38 2009 +0100| [3b954882ebc4f0be1b5a3a03e7f160cf6963e479] | committer: Rémi Duraffort
rc: factorisation
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=3b954882ebc4f0be1b5a3a03e7f160cf6963e479
---
modules/control/rc.c | 34 ++++++++++++++++------------------
1 files changed, 16 insertions(+), 18 deletions(-)
diff --git a/modules/control/rc.c b/modules/control/rc.c
index 119ba0b..3f69001 100644
--- a/modules/control/rc.c
+++ b/modules/control/rc.c
@@ -552,25 +552,23 @@ static void Run( intf_thread_t *p_intf )
{
PL_LOCK;
int status = playlist_Status( p_playlist );
- if( (p_intf->p_sys->i_last_state != status) &&
- (status == PLAYLIST_STOPPED) )
+ if( p_intf->p_sys->i_last_state != status )
{
- p_intf->p_sys->i_last_state = PLAYLIST_STOPPED;
- msg_rc( STATUS_CHANGE "( stop state: 5 )" );
- }
- else if(
- (p_intf->p_sys->i_last_state != status) &&
- (status == PLAYLIST_RUNNING) )
- {
- p_intf->p_sys->i_last_state = PLAYLIST_RUNNING;
- msg_rc( STATUS_CHANGE "( play state: 3 )" );
- }
- else if(
- (p_intf->p_sys->i_last_state != status) &&
- (status == PLAYLIST_PAUSED) )
- {
- p_intf->p_sys->i_last_state = PLAYLIST_PAUSED;
- msg_rc( STATUS_CHANGE "( pause state: 4 )" );
+ if( status == PLAYLIST_STOPPED )
+ {
+ p_intf->p_sys->i_last_state = PLAYLIST_STOPPED;
+ msg_rc( STATUS_CHANGE "( stop state: 5 )" );
+ }
+ else if( status == PLAYLIST_RUNNING )
+ {
+ p_intf->p_sys->i_last_state = PLAYLIST_RUNNING;
+ msg_rc( STATUS_CHANGE "( play state: 3 )" );
+ }
+ else if( status == PLAYLIST_PAUSED )
+ {
+ p_intf->p_sys->i_last_state = PLAYLIST_PAUSED;
+ msg_rc( STATUS_CHANGE "( pause state: 4 )" );
+ }
}
PL_UNLOCK;
}
More information about the vlc-devel
mailing list