diff options
| author | 2007-01-26 03:54:22 +0000 | |
|---|---|---|
| committer | 2007-01-26 03:54:22 +0000 | |
| commit | 1a8a7e6f145613c34ff0604b95370995fc625ef2 (patch) | |
| tree | 79b63ab083ae2eecfbf98170e9d50731f6bb4d67 /src/modules/mediaplayer/mp_jukinterface.cpp | |
| parent | fix win compilation and update win projects (diff) | |
| download | KVIrc-1a8a7e6f145613c34ff0604b95370995fc625ef2.tar.gz KVIrc-1a8a7e6f145613c34ff0604b95370995fc625ef2.tar.bz2 KVIrc-1a8a7e6f145613c34ff0604b95370995fc625ef2.zip | |
More Qt 4.x port and the torrent module by Alexander Stillich
git-svn-id: https://svn.kvirc.de/svn/trunk/kvirc@255 17fca916-40b9-46aa-a4ea-0a15b648b75c
Diffstat (limited to 'src/modules/mediaplayer/mp_jukinterface.cpp')
| -rw-r--r-- | src/modules/mediaplayer/mp_jukinterface.cpp | 32 |
1 files changed, 16 insertions, 16 deletions
diff --git a/src/modules/mediaplayer/mp_jukinterface.cpp b/src/modules/mediaplayer/mp_jukinterface.cpp index 0b31ebedf..3e89a408f 100644 --- a/src/modules/mediaplayer/mp_jukinterface.cpp +++ b/src/modules/mediaplayer/mp_jukinterface.cpp @@ -50,7 +50,7 @@ MP_IMPLEMENT_DESCRIPTOR( KviJukInterface::KviJukInterface() -: KviMediaPlayerDCOPInterface("amarok") + : KviDCOPHelper(true, "amarok") { } @@ -60,27 +60,27 @@ KviJukInterface::~KviJukInterface() int KviJukInterface::detect(bool bStart){ return detectApp("juk",bStart,90,96); } -bool KviJukInterface::prev(){ return simpleDCOPCall("Player","forward()"); } -bool KviJukInterface::next(){ return simpleDCOPCall("Player","back()"); } -bool KviJukInterface::play(){ return simpleDCOPCall("Player","play()"); } -bool KviJukInterface::stop(){ return simpleDCOPCall("Player","stop()"); } -bool KviJukInterface::pause(){ return simpleDCOPCall("Player","pause()"); } -bool KviJukInterface::quit(){ return simpleDCOPCall("MainApplication-Interface","quit()"); } +bool KviJukInterface::prev(){ return voidRetVoidDCOPCall("Player","forward()"); } +bool KviJukInterface::next(){ return voidRetVoidDCOPCall("Player","back()"); } +bool KviJukInterface::play(){ return voidRetVoidDCOPCall("Player","play()"); } +bool KviJukInterface::stop(){ return voidRetVoidDCOPCall("Player","stop()"); } +bool KviJukInterface::pause(){ return voidRetVoidDCOPCall("Player","pause()"); } +bool KviJukInterface::quit(){ return voidRetVoidDCOPCall("MainApplication-Interface","quit()"); } bool KviJukInterface::setVol(int &iVol) { - return floatDCOPCall("player","setVolume(float)",(float)(iVol)/255.); + return voidRetFloatDCOPCall("player","setVolume(float)",(float)(iVol)/255.); } bool KviJukInterface::jumpTo(int &iPos) { - return intDCOPCall("player","seek(int)",iPos/1000); + return voidRetIntDCOPCall("player","seek(int)",iPos/1000); } bool KviJukInterface::getShuffle() { QString szMode; - if(!stringRetDCOPCall("player","randomPlayMode()",szMode))return false; + if(!stringRetVoidDCOPCall("player","randomPlayMode()",szMode))return false; return (szMode != "NoRandom"); } @@ -93,7 +93,7 @@ bool KviJukInterface::setShuffle(bool &bVal) } else { szMode = "NoRandom"; } - if(!stringDCOPCall("player","setRandomPlayMode(QString)",szMode))return false; + if(!voidRetStringDCOPCall("player","setRandomPlayMode(QString)",szMode))return false; return true; } @@ -102,7 +102,7 @@ bool KviJukInterface::setShuffle(bool &bVal) QString KviJukInterface::_fncname() \ { \ QString ret; \ - if(!stringRetDCOPCall(_iface,_fnc,ret))return false; \ + if(!stringRetVoidDCOPCall(_iface,_fnc,ret))return false; \ return ret; \ } @@ -121,7 +121,7 @@ MP_DCOP_STRING_CALL(album,"player","album()") int KviJukInterface::sampleRate() { int ret; - if(!intRetDCOPCall("player","sampleRate()",ret))return false; + if(!intRetVoidDCOPCall("player","sampleRate()",ret))return false; return ret; } */ @@ -129,21 +129,21 @@ int KviJukInterface::sampleRate() int KviJukInterface::length() { int ret; - if(!intRetDCOPCall("player","totalTime()",ret))return false; + if(!intRetVoidDCOPCall("player","totalTime()",ret))return false; return ret * 1000; } int KviJukInterface::position() { int ret; - if(!intRetDCOPCall("player","currentTime()",ret))return false; + if(!intRetVoidDCOPCall("player","currentTime()",ret))return false; return ret * 1000; } KviMediaPlayerInterface::PlayerStatus KviJukInterface::status() { int ret; - if(!intRetDCOPCall("player","status()",ret))return KviMediaPlayerInterface::Unknown; + if(!intRetVoidDCOPCall("player","status()",ret))return KviMediaPlayerInterface::Unknown; switch(ret) { case 0: |
