diff options
author | Gregory Nutt <gnutt@nuttx.org> | 2014-07-17 10:57:32 -0600 |
---|---|---|
committer | Gregory Nutt <gnutt@nuttx.org> | 2014-07-17 10:57:32 -0600 |
commit | d6d1e4f05703fd2e5dd62d0ec951308029020fa9 (patch) | |
tree | 42a44c927c3e8d01847f7f3fb729ef08232ad01c /NxWidgets/nxwm/src | |
parent | 3733936b6f7992263e3eebefd24a85a4f0a96452 (diff) | |
download | nuttx-d6d1e4f05703fd2e5dd62d0ec951308029020fa9.tar.gz nuttx-d6d1e4f05703fd2e5dd62d0ec951308029020fa9.tar.bz2 nuttx-d6d1e4f05703fd2e5dd62d0ec951308029020fa9.zip |
NxWM::CMediaPlayer: State variable was left in a bad state and caused some problems down the road
Diffstat (limited to 'NxWidgets/nxwm/src')
-rw-r--r-- | NxWidgets/nxwm/src/cmediaplayer.cxx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/NxWidgets/nxwm/src/cmediaplayer.cxx b/NxWidgets/nxwm/src/cmediaplayer.cxx index ffe0692d1..caaeffed3 100644 --- a/NxWidgets/nxwm/src/cmediaplayer.cxx +++ b/NxWidgets/nxwm/src/cmediaplayer.cxx @@ -1073,7 +1073,7 @@ void CMediaPlayer::checkFileSelection(void) // Remain in the stopped state if we fail to open the file m_fileIndex = -1; - gdbg("openMediaFile failed\m"); + gdbg("openMediaFile failed\n"); } else { @@ -1098,7 +1098,7 @@ void CMediaPlayer::checkFileSelection(void) // Go to the STOPPED state on a failure to open the media file // The play button will be disable because m_fileIndex == -1. - gdbg("openMediaFile failed\m"); + gdbg("openMediaFile failed\n"); m_fileIndex = -1; setMediaPlayerState(MPLAYER_STOPPED); } @@ -1227,6 +1227,10 @@ void CMediaPlayer::handleReleaseEvent(const NXWidgets::CWidgetEventArgs &e) setMediaPlayerState(m_prevState); } + + // No longer any action pending the PLAY image release + + m_pending = PENDING_NONE; } // Check if the Pause image was released @@ -1251,6 +1255,10 @@ void CMediaPlayer::handleReleaseEvent(const NXWidgets::CWidgetEventArgs &e) setMediaPlayerState(m_prevState); } + + // No longer any action pending the PAUSE image release + + m_pending = PENDING_NONE; } } |