summaryrefslogtreecommitdiffstats
path: root/kicker-applets/mediacontrol/mpdInterface.cpp
diff options
context:
space:
mode:
authorTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 09:58:12 -0600
committerTimothy Pearson <kb9vqf@pearsoncomputing.net>2011-12-16 09:58:12 -0600
commit6b45a7b7b2a804ccb2d522eb9ba6423fedb59b8f (patch)
treea08b27e3f4fde1ed82a5f061a2725998e8012f93 /kicker-applets/mediacontrol/mpdInterface.cpp
parentca82971624269719d487c6f7980d7237f9420036 (diff)
downloadtdeaddons-6b45a7b7b2a804ccb2d522eb9ba6423fedb59b8f.tar.gz
tdeaddons-6b45a7b7b2a804ccb2d522eb9ba6423fedb59b8f.zip
Revert "Rename a number of old tq methods that are no longer tq specific"
This reverts commit ca82971624269719d487c6f7980d7237f9420036.
Diffstat (limited to 'kicker-applets/mediacontrol/mpdInterface.cpp')
-rw-r--r--kicker-applets/mediacontrol/mpdInterface.cpp44
1 files changed, 22 insertions, 22 deletions
diff --git a/kicker-applets/mediacontrol/mpdInterface.cpp b/kicker-applets/mediacontrol/mpdInterface.cpp
index 98ba0cb..ea350d2 100644
--- a/kicker-applets/mediacontrol/mpdInterface.cpp
+++ b/kicker-applets/mediacontrol/mpdInterface.cpp
@@ -118,7 +118,7 @@ void MpdInterface::connected()
{
//kdDebug(90200) << "Connected ok\n";
emit playerStarted();
- emit playingStatusChanged(playingStatus());
+ emit playingStatusChanged(playingtqStatus());
}
else
{
@@ -137,10 +137,10 @@ void MpdInterface::connectionError(int e)
switch (e)
{
case TQSocket::ErrConnectionRefused:
- message=i18n("Connection refused to %1:%2.\nIs mpd running?").arg(hostname).arg(port);
+ message=i18n("Connection refused to %1:%2.\nIs mpd running?").tqarg(hostname).tqarg(port);
break;
case TQSocket::ErrHostNotFound:
- message=i18n("Host '%1' not found.").arg(hostname);
+ message=i18n("Host '%1' not found.").tqarg(hostname);
break;
case TQSocket::ErrSocketRead:
message=i18n("Error reading socket.");
@@ -265,7 +265,7 @@ void MpdInterface::updateSlider()
}
else if (time_re.search(res)>=0)
{
- TQStringList timeinfo=time_re.capturedTexts();
+ TQStringList timeinfo=time_re.tqcapturedTexts();
timeinfo.pop_front();
int elapsed_seconds=timeinfo.first().toInt();
timeinfo.pop_front();
@@ -298,7 +298,7 @@ void MpdInterface::jumpToTime(int sec)
{
if (songid_re.search(res)>=0)
{
- TQStringList songidinfo=songid_re.capturedTexts();
+ TQStringList songidinfo=songid_re.tqcapturedTexts();
songidinfo.pop_front();
songid=songidinfo.first().toInt();
}
@@ -306,7 +306,7 @@ void MpdInterface::jumpToTime(int sec)
if (songid>-1)
{
- if (dispatch(TQString("seekid %1 %2\n").arg(songid).arg(sec).latin1()))
+ if (dispatch(TQString("seekid %1 %2\n").tqarg(songid).tqarg(sec).latin1()))
{
fetchOk(); // unlocks
}
@@ -316,7 +316,7 @@ void MpdInterface::jumpToTime(int sec)
void MpdInterface::playpause()
{
reconnect();
- if (playingStatus()==Stopped ? dispatch("play\n") : dispatch("pause\n"))
+ if (playingtqStatus()==Stopped ? dispatch("play\n") : dispatch("pause\n"))
{
fetchOk();
}
@@ -355,7 +355,7 @@ void MpdInterface::changeVolume(int delta)
{
if (volume_re.search(res)>=0)
{
- TQStringList info=volume_re.capturedTexts();
+ TQStringList info=volume_re.tqcapturedTexts();
info.pop_front();
volume=info.first().toInt();
}
@@ -366,7 +366,7 @@ void MpdInterface::changeVolume(int delta)
volume+=delta;
if (volume<0) volume=0;
if (volume>100) volume=100;
- if (dispatch(TQString("setvol %1\n").arg(volume).latin1()))
+ if (dispatch(TQString("setvol %1\n").tqarg(volume).latin1()))
{
fetchOk();
}
@@ -411,7 +411,7 @@ void MpdInterface::dropEvent(TQDropEvent* event)
TQRegExp id_re("Id: (.+)");
if (file.isEmpty() && file_re.search(res)>=0)
{
- TQStringList info=file_re.capturedTexts();
+ TQStringList info=file_re.tqcapturedTexts();
info.pop_front();
// if the dropped file ends with the same name, record it
if (list.front().path().endsWith(info.first()))
@@ -422,7 +422,7 @@ void MpdInterface::dropEvent(TQDropEvent* event)
else if (!file.isEmpty() && id_re.search(res)>=0)
{
// when we have the file, pick up the id (file scomes first)
- TQStringList info=id_re.capturedTexts();
+ TQStringList info=id_re.tqcapturedTexts();
info.pop_front();
songid=info.first().toInt();
fetchOk(); // skip to the end
@@ -433,7 +433,7 @@ void MpdInterface::dropEvent(TQDropEvent* event)
// found song, so lets play it
if (songid>-1)
{
- if (dispatch((TQString("playid %1\n").arg(songid)).latin1()))
+ if (dispatch((TQString("playid %1\n").tqarg(songid)).latin1()))
{
if (fetchOk()) list.pop_front();
return;
@@ -483,7 +483,7 @@ const TQString MpdInterface::getTrackTitle() const
TQRegExp songid_re("songid: (\\d+)");
if (songid_re.search(res)>=0)
{
- TQStringList songidinfo=songid_re.capturedTexts();
+ TQStringList songidinfo=songid_re.tqcapturedTexts();
songidinfo.pop_front();
songid=songidinfo.first().toInt();
}
@@ -491,7 +491,7 @@ const TQString MpdInterface::getTrackTitle() const
if (!(songid>-1)) return result;
- if (!dispatch(TQString("playlistid %1\n").arg(songid).latin1()))
+ if (!dispatch(TQString("playlistid %1\n").tqarg(songid).latin1()))
return result;
TQString artist;
@@ -508,31 +508,31 @@ const TQString MpdInterface::getTrackTitle() const
TQRegExp file_re("file: (.+)");
if (artist_re.search(res)>=0)
{
- TQStringList info=artist_re.capturedTexts();
+ TQStringList info=artist_re.tqcapturedTexts();
info.pop_front();
artist=info.first();
}
else if (album_re.search(res)>=0)
{
- TQStringList info=album_re.capturedTexts();
+ TQStringList info=album_re.tqcapturedTexts();
info.pop_front();
album=info.first();
}
else if (title_re.search(res)>=0)
{
- TQStringList info=title_re.capturedTexts();
+ TQStringList info=title_re.tqcapturedTexts();
info.pop_front();
title=info.first();
}
else if (track_re.search(res)>=0)
{
- TQStringList info=track_re.capturedTexts();
+ TQStringList info=track_re.tqcapturedTexts();
info.pop_front();
track=info.first();
}
else if (file_re.search(res)>=0)
{
- TQStringList info=file_re.capturedTexts();
+ TQStringList info=file_re.tqcapturedTexts();
info.pop_front();
file=info.first();
}
@@ -559,15 +559,15 @@ const TQString MpdInterface::getTrackTitle() const
else
return album;
}
- return i18n("No tags: %1").arg(file);
+ return i18n("No tags: %1").tqarg(file);
}
-int MpdInterface::playingStatus()
+int MpdInterface::playingtqStatus()
{
//kdDebug(90200) << "looking up playing status\n";
if (!dispatch("status\n")) return Stopped;
- PlayingStatus status=Stopped;
+ PlayingtqStatus status=Stopped;
TQString res;
while(fetchLine(res))
{