Diffstat (limited to 'noncore/multimedia/opieplayer2/mediaplayerstate.cpp') (more/less context) (ignore whitespace changes)
-rw-r--r-- | noncore/multimedia/opieplayer2/mediaplayerstate.cpp | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/noncore/multimedia/opieplayer2/mediaplayerstate.cpp b/noncore/multimedia/opieplayer2/mediaplayerstate.cpp index 3090b08..778cd1e 100644 --- a/noncore/multimedia/opieplayer2/mediaplayerstate.cpp +++ b/noncore/multimedia/opieplayer2/mediaplayerstate.cpp @@ -57,4 +57,10 @@ void MediaPlayerState::writeConfig( Config& cfg ) const { // public stuff + + +bool MediaPlayerState::streaming() { + return isStreaming; +} + bool MediaPlayerState::fullscreen() { return isFullscreen; @@ -86,4 +92,8 @@ bool MediaPlayerState::playing() { } +bool MediaPlayerState::stop() { + return isStoped; +} + long MediaPlayerState::position() { return curPosition; @@ -99,4 +109,12 @@ char MediaPlayerState::view() { // slots +void MediaPlayerState::setIsStreaming( bool b ) { + if ( isStreaming == b ) { + return; + } + isStreaming = b; +} + + void MediaPlayerState::setFullscreen( bool b ) { if ( isFullscreen == b ) { @@ -153,7 +171,16 @@ void MediaPlayerState::setPlaying( bool b ) { } isPlaying = b; + isStoped = !b; emit playingToggled(b); } +void MediaPlayerState::setStop( bool b ) { + if ( isStoped == b ) { + return; + } + isStoped = b; + emit stopToggled(b); +} + void MediaPlayerState::setPosition( long p ) { if ( curPosition == p ) { @@ -209,6 +236,4 @@ void MediaPlayerState::setAudio() { } - - void MediaPlayerState::toggleFullscreen() { setFullscreen( !isFullscreen ); |