summaryrefslogtreecommitdiffstats
path: root/src/modules/mediaplayer/mp_interface.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/modules/mediaplayer/mp_interface.cpp')
-rw-r--r--src/modules/mediaplayer/mp_interface.cpp78
1 files changed, 39 insertions, 39 deletions
diff --git a/src/modules/mediaplayer/mp_interface.cpp b/src/modules/mediaplayer/mp_interface.cpp
index 0894de05..0c0a97a0 100644
--- a/src/modules/mediaplayer/mp_interface.cpp
+++ b/src/modules/mediaplayer/mp_interface.cpp
@@ -26,12 +26,12 @@
#include "mp_mp3.h"
#include "kvi_options.h"
#include "kvi_locale.h"
-#include <qtextcodec.h>
+#include <tqtextcodec.h>
-static QTextCodec * mediaplayer_get_codec()
+static TQTextCodec * mediaplayer_get_codec()
{
- QTextCodec * c= QTextCodec::codecForName(KVI_OPTION_STRING(KviOption_stringWinampTextEncoding));
- if(!c)c = QTextCodec::codecForLocale();
+ TQTextCodec * c= TQTextCodec::codecForName(KVI_OPTION_STRING(KviOption_stringWinampTextEncoding));
+ if(!c)c = TQTextCodec::codecForLocale();
return c;
}
@@ -78,82 +78,82 @@ bool KviMediaPlayerInterface::minimize()
return false;
}
-QString KviMediaPlayerInterface::getLocalFile()
+TQString KviMediaPlayerInterface::getLocalFile()
{
- QString ret = mrl();
+ TQString ret = mrl();
if(ret.isEmpty())return ret;
- if(ret.startsWith("file://",false))
+ if(ret.tqstartsWith("file://",false))
{
ret.remove(0,7);
return ret;
}
- return QString::null;
+ return TQString();
}
-QString KviMediaPlayerInterface::amipEval(const QString &cmd)
+TQString KviMediaPlayerInterface::amipEval(const TQString &cmd)
{
- return QString::null;
+ return TQString();
}
#define SCAN_MP3_FILE \
- QString f = getLocalFile(); \
- if(f.isEmpty())return QString::null; \
+ TQString f = getLocalFile(); \
+ if(f.isEmpty())return TQString(); \
mp3info mp3; \
- if(!scan_mp3_file(f,&mp3))return QString::null; \
- QTextCodec *pCodec; \
+ if(!scan_mp3_file(f,&mp3))return TQString(); \
+ TQTextCodec *pCodec; \
pCodec=mediaplayer_get_codec();
#define SCAN_MP3_FILE_RET_INT \
- QString f = getLocalFile(); \
+ TQString f = getLocalFile(); \
if(f.isEmpty())return -1; \
mp3info mp3; \
if(!scan_mp3_file(f,&mp3))return -1;
-QString KviMediaPlayerInterface::artist()
+TQString KviMediaPlayerInterface::artist()
{
SCAN_MP3_FILE
- return pCodec->toUnicode(KviQCString(mp3.id3.artist));
+ return pCodec->toUnicode(KviTQCString(mp3.id3.artist));
}
-QString KviMediaPlayerInterface::title()
+TQString KviMediaPlayerInterface::title()
{
SCAN_MP3_FILE
- return pCodec->toUnicode(KviQCString(mp3.id3.title));
+ return pCodec->toUnicode(KviTQCString(mp3.id3.title));
}
-QString KviMediaPlayerInterface::genre()
+TQString KviMediaPlayerInterface::genre()
{
SCAN_MP3_FILE
- return pCodec->toUnicode(KviQCString(get_typegenre(mp3.id3.genre[0])));
+ return pCodec->toUnicode(KviTQCString(get_typegenre(mp3.id3.genre[0])));
}
-QString KviMediaPlayerInterface::comment()
+TQString KviMediaPlayerInterface::comment()
{
SCAN_MP3_FILE
- return pCodec->toUnicode(KviQCString(mp3.id3.comment));
+ return pCodec->toUnicode(KviTQCString(mp3.id3.comment));
}
-QString KviMediaPlayerInterface::year()
+TQString KviMediaPlayerInterface::year()
{
SCAN_MP3_FILE
- return QString(mp3.id3.year);
+ return TQString(mp3.id3.year);
}
-QString KviMediaPlayerInterface::album()
+TQString KviMediaPlayerInterface::album()
{
SCAN_MP3_FILE
- return pCodec->toUnicode(KviQCString(mp3.id3.album));
+ return pCodec->toUnicode(KviTQCString(mp3.id3.album));
}
-bool KviMediaPlayerInterface::playMrl(const QString &mrl)
+bool KviMediaPlayerInterface::playMrl(const TQString &mrl)
{
notImplemented();
return false;
}
-bool KviMediaPlayerInterface::amipExec(const QString &cmd)
+bool KviMediaPlayerInterface::amipExec(const TQString &cmd)
{
notImplemented();
return false;
@@ -183,7 +183,7 @@ bool KviMediaPlayerInterface::jumpTo(int &iPos)
return false;
}
-KviMediaPlayerInterface::PlayerStatus KviMediaPlayerInterface::status()
+KviMediaPlayerInterface::PlayertqStatus KviMediaPlayerInterface::status()
{
notImplemented();
return KviMediaPlayerInterface::Unknown;
@@ -262,16 +262,16 @@ bool KviMediaPlayerInterface::setShuffle(bool &bVal)
return false;
}
-QString KviMediaPlayerInterface::mediaType()
+TQString KviMediaPlayerInterface::mediaType()
{
- QString ret = mrl();
- if(ret.endsWith(".mp3",false))ret = "MPEG Layer 3";
- else if(ret.endsWith(".ogg",false))ret = "OGG Vorbis";
- else if(ret.endsWith(".avi",false))ret = "Audio Video Interleave";
- else if(ret.endsWith(".mpeg",false))ret = "MPEG Video";
- else if(ret.endsWith(".mpg",false))ret = "MPEG Video";
- else if(ret.startsWith("http://",false))ret = "HTTP Audio Stream";
- else ret = QString::null;
+ TQString ret = mrl();
+ if(ret.tqendsWith(".mp3",false))ret = "MPEG Layer 3";
+ else if(ret.tqendsWith(".ogg",false))ret = "OGG Vorbis";
+ else if(ret.tqendsWith(".avi",false))ret = "Audio Video Interleave";
+ else if(ret.tqendsWith(".mpeg",false))ret = "MPEG Video";
+ else if(ret.tqendsWith(".mpg",false))ret = "MPEG Video";
+ else if(ret.tqstartsWith("http://",false))ret = "HTTP Audio Stream";
+ else ret = TQString();
return ret;
}