rename the following methods:

tqfind find
tqreplace replace
tqcontains contains


git-svn-id: svn://anonsvn.kde.org/home/kde/branches/trinity/applications/kaffeine@1246075 283d02a7-25f6-0310-bc7c-ecb5cbfe19da
v3.5.13-sru
tpearson 13 years ago
parent a488f17322
commit f2418d2c07

@ -43,7 +43,7 @@ DrivesCombo::DrivesCombo(TQWidget* tqparent, const char* name)
while (!stream.eof())
{
line = stream.readLine();
if (line.tqcontains("cdfss"))
if (line.contains("cdfss"))
{
kdDebug() << "DrivesCombo: found disc drive: " << line.section(' ', 0, 0) << endl;
drives.append(line.section(' ', 0, 0));

@ -39,9 +39,9 @@ GoogleImage::GoogleImage(TQString thumbURL, TQString size)
{
// thumbURL is in the following format - and we can regex the imageURL
// images?q=tbn:hKSEWNB8aNcJ:www.styxnet.com/deyoung/styx/stygians/cp_portrait.jpg
m_thumbURL = thumbURL.tqreplace("\"","");
m_imageURL = thumbURL.remove(TQRegExp("^.*q=tbn:[^:]*:")).tqreplace("\"","");
m_size = size.tqreplace("pixels - ", "\n(") + ")";
m_thumbURL = thumbURL.replace("\"","");
m_imageURL = thumbURL.remove(TQRegExp("^.*q=tbn:[^:]*:")).replace("\"","");
m_size = size.replace("pixels - ", "\n(") + ")";
}
@ -120,28 +120,28 @@ void GoogleFetcher::slotLoadImageURLs(GoogleFetcher::ImageSize size)
// Go through each of the top (table) nodes
int pos = text.tqfind("/imgres?imgurl");
int pos = text.find("/imgres?imgurl");
int tpos;
TQString s, c;
while ( pos>-1 ) {
text = text.right( text.length()-pos-14 );
tpos = text.tqfind("&h=");
tpos = text.find("&h=");
text = text.right( text.length()-tpos-3 );
tpos = text.tqfind("&w=");
tpos = text.find("&w=");
c = "pixels - " + text.left( tpos );
text = text.right( text.length()-tpos-3 );
tpos = text.tqfind("&sz=");
tpos = text.find("&sz=");
c = c + "x" + text.left( tpos );
tpos = text.tqfind("src=");
tpos = text.find("src=");
text = text.right( text.length()-tpos-4 );
if ( (tpos=text.tqfind("width="))==-1 )
if ( (tpos=text.find("width="))==-1 )
break;
s = text.left( tpos-1 );
text = text.right( text.length()-tpos );
if ( (tpos=text.tqfind("></a>"))==-1 )
if ( (tpos=text.find("></a>"))==-1 )
break;
m_imageList.append(GoogleImage(s, c));
pos = text.tqfind("/imgres?imgurl");
pos = text.find("/imgres?imgurl");
}
} // try
catch (DOM::DOMException &e)
@ -273,7 +273,7 @@ bool GoogleFetcher::requestNewSearchTerms(bool noResults)
bool GoogleFetcher::hasImageResults( TQString &doc )
{
if ( !doc.tqcontains( "/imgres?imgurl" ) )
if ( !doc.contains( "/imgres?imgurl" ) )
return false;
return true;

@ -545,7 +545,7 @@ void PlayList::slotToggleShuffle()
void PlayList::slotPlaylistLoad()
{
TQString path = KFileDialog::getOpenFileName(":kaffeine_openPlaylist", TQString("*.kaffeine|") + i18n("Kaffeine Playlists") + "\n*.*|" + i18n("All Files"), 0, i18n("Open Playlist"));
if (path.isEmpty() || (!path.tqcontains(".kaffeine", false)))
if (path.isEmpty() || (!path.contains(".kaffeine", false)))
return;
loadPlaylist(path);
@ -904,7 +904,7 @@ void PlayList::setCurrentEntry(TQListViewItem* item, bool playIcon)
}
m_currentEntry = item;
if (m_random)
m_currentRandomListEntry = m_randomList.tqfind(item);
m_currentRandomListEntry = m_randomList.find(item);
m_currentEntryMRL = newItem->toMRL();
roller->setTitle( m_currentEntryMRL );
m_list->setCurrentItem(m_currentEntry);
@ -943,14 +943,14 @@ TQListViewItem* PlayList::insertItem(TQListViewItem* after, const MRL& m)
else
tmp->setPixmap(MIME_COLUMN, KMimeType::mimeType(mrl.mime())->pixmap(KIcon::Small));
if (tmp->length().tqcontains(':'))
if (tmp->length().contains(':'))
m_playTime += timeStringToMs(tmp->length());
if (m_searchSelection)
{
TQString text = m_playlistFilter->text();
if ((!tmp->title().tqcontains(text, false)) && (!tmp->url().tqcontains(text, false))
&& (!tmp->artist().tqcontains(text, false)) && (!tmp->album().tqcontains(text, false)))
if ((!tmp->title().contains(text, false)) && (!tmp->url().contains(text, false))
&& (!tmp->artist().contains(text, false)) && (!tmp->album().contains(text, false)))
{
tmp->setVisible(false);
}
@ -958,7 +958,7 @@ TQListViewItem* PlayList::insertItem(TQListViewItem* after, const MRL& m)
if (tmp->isVisible())
{
if (tmp->length().tqcontains(':'));
if (tmp->length().contains(':'));
m_playTimeVisible += timeStringToMs(tmp->length());
m_countVisible++;
}
@ -1042,7 +1042,7 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
mediaName = url.mid(14);
else
mediaName = url.mid(7);
int slash = mediaName.tqfind("/");
int slash = mediaName.find("/");
TQString filePath(mediaName.mid(slash));
if (filePath == "/")
filePath = "";
@ -1099,7 +1099,7 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
/*********** determine extension and mime type ************/
ext = mrl.kurl().fileName();
ext = ext.remove(0 , ext.tqfindRev('.') +1).lower();
ext = ext.remove(0 , ext.findRev('.') +1).lower();
// kdDebug() << "Extension: " << ext << endl;
//kdDebug() << "PlayList: Try to determine mime of: " << mrl.url() << endl;
@ -1130,24 +1130,24 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
TQString secondLine = stream.readLine();
file.close();
if (secondLine.tqcontains("kaffeine", false))
if (secondLine.contains("kaffeine", false))
{
kdDebug() << "PlayList: Try loading kaffeine playlist\n";
playlist = PlaylistImport::kaffeine(mrl.url(), mrlList);
if (!playlist)
continue;
}
if (secondLine.tqcontains("noatun", false))
if (secondLine.contains("noatun", false))
{
kdDebug() << "PlayList: Try loading noatun playlist\n";
playlist = PlaylistImport::noatun(mrl.url(), mrlList);
}
if (firstLine.tqcontains("asx", false))
if (firstLine.contains("asx", false))
{
kdDebug() << "PlayList: Try loading asx playlist\n";
playlist = PlaylistImport::asx(mrl.url(), mrlList);
}
if ( (firstLine.tqcontains("[playlist]", false)) || (ext == "pls") )
if ( (firstLine.contains("[playlist]", false)) || (ext == "pls") )
{
kdDebug() << "PlayList: Try loading pls playlist\n";
playlist = PlaylistImport::pls(mrl.url(), mrlList);
@ -1228,7 +1228,7 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
TQListViewItemIterator it(m_list);
while (it.current())
{
if (dynamic_cast<PlaylistItem*>(*it)->mime().tqcontains("video"))
if (dynamic_cast<PlaylistItem*>(*it)->mime().contains("video"))
movies << dynamic_cast<PlaylistItem*>(*it)->url();
++it;
}
@ -1263,7 +1263,7 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
* those starting with a different name than the movie,
* prompt the user to select a sub
*/
if (mime->name().tqcontains("video"))
if (mime->name().contains("video"))
{
kdDebug() << "PlayList: Check for subtitle files" << endl;
subtitleURL = TQString();
@ -1331,7 +1331,7 @@ void PlayList::add(const TQStringList& urlList, TQListViewItem* after)
if (!subtitleURL.isNull())
{
kdDebug() << "PlayList: Use subtitle file: " << subtitleURL << " for: " << mrl.url() << endl;
mrl.setCurrentSubtitle(subs.tqfindIndex(subtitleURL));
mrl.setCurrentSubtitle(subs.findIndex(subtitleURL));
}
}
} /* if localFile() */
@ -1518,7 +1518,7 @@ void PlayList::getMetaInfo(MRL& mrl, const TQString& mimeName)
if (keys[n] == "Title")
{
title = metaGroup.item(keys[n]).value().toString().simplifyWhiteSpace();
if ((!title.isEmpty()) && (title.tqcontains(TQRegExp("\\w")) > 2) && (title.left(5).lower() != "track"))
if ((!title.isEmpty()) && (title.contains(TQRegExp("\\w")) > 2) && (title.left(5).lower() != "track"))
{
if ((m_useAlternateEncoding) && (CodecUtf8->heuristicContentMatch(title.ascii(), title.length()) < 0))
{
@ -1596,7 +1596,7 @@ void PlayList::mergeMeta(const MRL& mrl)
}
if (addTime)
{
if (tmp->length().tqcontains(':'));
if (tmp->length().contains(':'));
{
m_playTime += timeStringToMs(tmp->length());
if (tmp->isVisible())
@ -1681,7 +1681,7 @@ void PlayList::setCover( TQString s1, TQString s2, bool forceFetch )
TQImage img;
TQPixmap pix;
TQString fname = s1+"_"+s2;
fname = fname.tqreplace( TQChar( '/' ), "_" );
fname = fname.replace( TQChar( '/' ), "_" );
fname = fname.upper();
fname = s+"covers/"+fname;
if ( !forceFetch && TQFile( fname ).exists() )
@ -1751,7 +1751,7 @@ void PlayList::slotRemoveSelected()
{
// kdDebug() << "Remove " << selected.at(i)->text(TITLE_COLUMN) << "\n";
item = dynamic_cast<PlaylistItem *>(selected.at(i));
if (item->length().tqcontains(':'))
if (item->length().contains(':'))
{
m_playTime -= timeStringToMs(item->length());
m_playTimeVisible -= timeStringToMs(item->length());
@ -1803,8 +1803,8 @@ void PlayList::setPlaylist(const TQString& name, bool clear)
if (clear)
clearList();
int index = 0;
if (m_playlistSelector->listBox()->tqfindItem(name))
index = m_playlistSelector->listBox()->index(m_playlistSelector->listBox()->tqfindItem(name));
if (m_playlistSelector->listBox()->findItem(name))
index = m_playlistSelector->listBox()->index(m_playlistSelector->listBox()->findItem(name));
else
m_playlistSelector->insertItem(name, 0);
m_playlistSelector->setCurrentItem(index);
@ -1855,7 +1855,7 @@ void PlayList::slotNewPlaylistName(const TQString& text)
{
if ((text.isEmpty()) || (text == m_playlistSelector->text(m_currentPlaylist)))
return;
if (m_playlistSelector->listBox()->tqfindItem(text))
if (m_playlistSelector->listBox()->findItem(text))
{
kdDebug() << "PlayList: Name still exists!" << endl;
return;
@ -1905,7 +1905,7 @@ void PlayList::loadPlaylist(const TQString& pl)
saveCurrentPlaylist();
TQString plName = KURL(pl).fileName();
plName = plName.remove(".kaffeine", false);
if (m_playlistSelector->listBox()->tqfindItem(plName))
if (m_playlistSelector->listBox()->findItem(plName))
{
TQString plNewName = NULL;
while (true)
@ -1915,7 +1915,7 @@ void PlayList::loadPlaylist(const TQString& pl)
i18n("Enter different playlist name:"), TQLineEdit::Normal, plName, &ok);
if ((ok) && (!plNewName.isEmpty()))
{
if (m_playlistSelector->listBox()->tqfindItem(plNewName))
if (m_playlistSelector->listBox()->findItem(plNewName))
continue;
else
break;
@ -2093,11 +2093,11 @@ void PlayList::slotFindText(const TQString& text)
while ( it.current() )
{
tmp = dynamic_cast<PlaylistItem *>(it.current());
if (text.isEmpty() || tmp->title().tqcontains(text, false) || tmp->url().tqcontains(text, false)
|| tmp->artist().tqcontains(text, false) || tmp->album().tqcontains(text, false) )
if (text.isEmpty() || tmp->title().contains(text, false) || tmp->url().contains(text, false)
|| tmp->artist().contains(text, false) || tmp->album().contains(text, false) )
{
tmp->setVisible(true);
if (tmp->length().tqcontains(':'))
if (tmp->length().contains(':'))
m_playTimeVisible += timeStringToMs(tmp->length());
m_countVisible++;

@ -146,7 +146,7 @@ void UrlListView::slotShowContextMenu(TQListViewItem* item, const TQPoint& pos,
else
{
m_itemOfContextMenu = dynamic_cast<PlaylistItem *>(item);
if (m_itemOfContextMenu->mime().tqcontains("video"))
if (m_itemOfContextMenu->mime().contains("video"))
enableSubEntry();
else
disableSubEntry();
@ -291,7 +291,7 @@ void UrlListView::slotAddSubtitle()
TQString subtitleURL = KFileDialog::getOpenURL(openURL,
i18n("*.smi *.srt *.sub *.txt *.ssa *.asc|Subtitle Files\n*.*|All Files"),
0, i18n("Select Subtitle File")).path();
if(!(subtitleURL.isEmpty()) && !(m_itemOfContextMenu->subtitles().tqcontains(subtitleURL)) && TQFile::exists(subtitleURL))
if(!(subtitleURL.isEmpty()) && !(m_itemOfContextMenu->subtitles().contains(subtitleURL)) && TQFile::exists(subtitleURL))
{
m_itemOfContextMenu->addSubtitle(subtitleURL);
emit signalPlayItem(m_itemOfContextMenu);

@ -107,7 +107,7 @@ bool CDDB::readLine(TQCString& ret)
while (read_length < 40000)
{
// Look for a \n in buf
int ni = buf.tqfind('\n');
int ni = buf.find('\n');
if (ni >= 0)
{
// Nice, so return this substring (without the \n),
@ -200,14 +200,14 @@ static int get_code (const TQCString &s)
static void parse_query_resp (const TQCString& _r, TQCString& catg, TQCString& d_id, TQCString& title)
{
TQCString r = _r.stripWhiteSpace();
int i = r.tqfind(' ');
int i = r.find(' ');
if (i)
{
catg = r.left(i).stripWhiteSpace();
r.remove(0, i+1);
r = r.stripWhiteSpace();
}
i = r.tqfind(' ');
i = r.find(' ');
if (i)
{
d_id = r.left(i).stripWhiteSpace();
@ -265,7 +265,7 @@ bool CDDB::parse_read_resp(TQTextStream *stream, TQTextStream *write_stream)
else if (r.left(6) == "TTITLE")
{
r.remove(0, 6);
int e = r.tqfind('=');
int e = r.find('=');
if (e)
{
bool ok;
@ -281,7 +281,7 @@ bool CDDB::parse_read_resp(TQTextStream *stream, TQTextStream *write_stream)
/* XXX We should canonicalize the strings ("\n" --> '\n' e.g.) */
int si = m_title.tqfind(" / ");
int si = m_title.find(" / ");
if (si > 0)
{
m_artist = m_title.left(si).stripWhiteSpace();
@ -292,18 +292,18 @@ bool CDDB::parse_read_resp(TQTextStream *stream, TQTextStream *write_stream)
if (m_title.isEmpty())
m_title = i18n("No Title");
/*else
m_title.tqreplace(TQRegExp("/"), "%2f");*/
m_title.replace(TQRegExp("/"), "%2f");*/
if (m_artist.isEmpty())
m_artist = i18n("Unknown");
/*else
m_artist.tqreplace(TQRegExp("/"), "%2f");*/
m_artist.replace(TQRegExp("/"), "%2f");*/
kdDebug(7101) << "CDDB: found Title: `" << m_title << "'" << endl;
for (int i = 0; i < m_tracks; i++)
{
if (m_names[i].isEmpty())
m_names[i] += i18n("Track %1").tqarg(i);
m_names[i].tqreplace(TQRegExp("/"), "%2f");
m_names[i].replace(TQRegExp("/"), "%2f");
kdDebug(7101) << "CDDB: found Track " << i+1 << ": `" << m_names[i]
<< "'" << endl;
}
@ -464,7 +464,7 @@ bool CDDB::queryCD(TQValueList<int>& track_ofs)
}
file.close();
/*TQString newname (file.name());
newname.truncate(newname.tqfindRev('.'));
newname.truncate(newname.findRev('.'));
if (TQDir::current().rename(file.name(), newname)) {
kdDebug(7101) << "CDDB: rename failed" << endl;
file.remove();

@ -176,13 +176,13 @@ bool Paranoia::findCdrom()
TQTextStream t( f );
while ( !t.eof() && !stop ) {
s = t.readLine();
if ( s.tqcontains("drive name:") )
if ( s.contains("drive name:") )
stop = true;
}
if ( !stop )
return false;
pos = s.tqfind(":");
pos = s.find(":");
c = s.right( s.length()-pos-1 );
sscanf( c.latin1(), "%s %s %s %s", dev[0], dev[1], dev[2], dev[3] );
@ -198,15 +198,15 @@ bool Paranoia::procCdrom( TQString name )
{
int pos;
if ( name.tqcontains("sr") ) {
pos = name.tqfind("r");
if ( name.contains("sr") ) {
pos = name.find("r");
name = name.right( name.length()-pos-1 );
name = "/dev/scd"+name;
d = cdda_identify( name.ascii(), CDDA_MESSAGE_PRINTIT, 0 );
if ( cdda_open( d )==0 )
return true;
}
else if ( name.tqcontains("hd") ) {
else if ( name.contains("hd") ) {
name = "/dev/"+name;
d = cdda_identify( name.ascii(), CDDA_MESSAGE_PRINTIT, 0 );
if ( cdda_open( d )==0 )
@ -274,7 +274,7 @@ bool Paranoia::encode( const TQStringList &list, TQWidget *tqparent )
return false;
}
if ( !setPath( baseDir, TQString(encodingList[0]).tqreplace("/","_"), TQString(encodingList[1]).tqreplace("/","_") ) ) {
if ( !setPath( baseDir, TQString(encodingList[0]).replace("/","_"), TQString(encodingList[1]).replace("/","_") ) ) {
return false;
}
isRunning = true;
@ -292,7 +292,7 @@ bool Paranoia::loadEncoder( TQWidget *tqparent )
return false;
}
if ( service->serviceTypes().tqcontains("KaffeineAudioEncoder") ) {
if ( service->serviceTypes().contains("KaffeineAudioEncoder") ) {
currentEncoder = KParts::ComponentFactory::createPartInstanceFromService<KaffeineAudioEncoder>(service, 0, service->name().ascii(), 0, 0, 0, &error);
if (error > 0) {
KMessageBox::error( tqparent, i18n("Loading of encoder '%1' failed.").tqarg(encoderDesktop) );
@ -389,7 +389,7 @@ void Paranoia::run()
for ( i=2; i<(int)encodingList.count(); ++i ) {
n = encodingList[i].left(2).toInt();
s = TQString(encodingList[i]).tqreplace("/","_")+currentEncoder->getExtension();
s = TQString(encodingList[i]).replace("/","_")+currentEncoder->getExtension();
f.setName( baseDir+s );
initTrack( n );
max = 0;

@ -242,7 +242,7 @@ void DVBconfig::startup()
else
as = false;
fprintf(stderr,"/dev/dvb/%s/%s : opened ( %s ) (%dms)\n", s.ascii(), t.ascii(), info.name, t1.msecsTo(TQTime::currentTime()) );
devList.append( new Device( s.tqreplace("adapter","").toInt(), t.tqreplace("frontend","").toInt(), info.type, info.name, as ) );
devList.append( new Device( s.replace("adapter","").toInt(), t.replace("frontend","").toInt(), info.type, info.name, as ) );
}
close( fdFrontend );
}
@ -1099,7 +1099,7 @@ void DvbConfigDialog::setSource( TQComboBox *box, TQString s )
{
int pos, i;
pos = s.tqfind("|");
pos = s.find("|");
if ( pos>=0 )
s = s.right( s.length()-pos-1 );
for ( i=0; i<(int)box->count(); i++ ) {
@ -1189,7 +1189,7 @@ void DvbConfigDialog::accept()
broadcastLe->setFocus();
return;
}
if ( !filenameFormatLe->text().tqcontains("%chan") && !filenameFormatLe->text().tqcontains("%date") && !filenameFormatLe->text().tqcontains("%name") ) {
if ( !filenameFormatLe->text().contains("%chan") && !filenameFormatLe->text().contains("%date") && !filenameFormatLe->text().contains("%name") ) {
KMessageBox::sorry( this, i18n("Invalid filename format.") );
filenameFormatLe->setFocus();
return;

@ -48,7 +48,7 @@ DVBevents::DVBevents( TQString devType, int anum, int tnum, const TQString &char
for ( KTrader::OfferList::Iterator it=offers.begin(); it!=end; ++it ) {
error = 0;
KService::Ptr ptr = (*it);
if ( !ptr->name().tqcontains(devType) )
if ( !ptr->name().contains(devType) )
continue;
plug = KParts::ComponentFactory::createPartInstanceFromService<KaffeineEpgPlugin>(ptr, 0, ptr->name().ascii(), 0, 0, 0, &error );
plugName = ptr->desktopEntryName();
@ -280,7 +280,7 @@ bool DVBevents::tableEIT( unsigned char* buffer )
if ( !nodesc ) {
if ( start==desc->startDateTime )
goto ifend;
currentEvents->take( currentEvents->tqfind( desc ) );
currentEvents->take( currentEvents->find( desc ) );
}
desc->startDateTime = start;
for ( i=0; i<(int)currentEvents->count(); i++ ) {

@ -63,7 +63,7 @@ DVBout::DVBout( ChannelDesc chan, int anum, int tnum, KaffeineDvbPlugin *p )
patpmt = wpatpmt = false;
connect( &stopRecTimer, TQT_SIGNAL(timeout()), this, TQT_SLOT(stopRec()) );
connect( &timerPatPmt, TQT_SIGNAL(timeout()), this, TQT_SLOT(setPatPmt()) );
if ( !pids.tqcontains(8192) )
if ( !pids.contains(8192) )
timerPatPmt.start(500);
}
@ -109,7 +109,7 @@ void DVBout::writePat()
tspat[0x0d] = tspat[0x0e] = 0x00; tspat[0x0f] = 0xe0; tspat[0x10] = 0x10;
// Program Map PID
pmtpid = 0xff;
while ( pids.tqcontains( pmtpid ) ) pmtpid--;
while ( pids.contains( pmtpid ) ) pmtpid--;
tspat[0x11] = 0x03; tspat[0x12] = 0xe8; tspat[0x13] = 0xe0; tspat[0x14] = pmtpid;
// Put CRC in ts[0x15...0x18]
calculateCRC( tspat + 0x05, tspat + 0x15 );
@ -300,7 +300,7 @@ bool DVBout::goLive( const TQString &name, int ringBufSize )
writePat();
writePmt();
if ( !pids.tqcontains(8192) )
if ( !pids.contains(8192) )
patpmt = wpatpmt = true;
wbufSize = ringBufSize*1024*1024/(TS_SIZE*NTS);
wBuf = new unsigned char[TS_SIZE*NTS*wbufSize];
@ -461,7 +461,7 @@ void DVBout::process( unsigned char *buf, int size )
for ( i=0; i<size; i+=TS_SIZE ) {
pid = (((buffer[1] & 0x1f) << 8) | buffer[2]);
if ( pids.tqcontains( pid ) || pids.tqcontains( 8192) ) {
if ( pids.contains( pid ) || pids.contains( 8192) ) {
memcpy( thBuf+thWrite, buffer, TS_SIZE );
thWrite+=TS_SIZE;
if ( thWrite==(TS_SIZE*NTS ) ) {

@ -484,7 +484,7 @@ void DvbPanel::searchChannel( const TQString &text )
channelsCb->visibleItems = 0;
while ( it.current() ) {
if ( text.isEmpty() || it.current()->text( c ).tqcontains( text, false ) ) {
if ( text.isEmpty() || it.current()->text( c ).contains( text, false ) ) {
it.current()->setVisible(true);
++channelsCb->visibleItems;
}
@ -1406,9 +1406,9 @@ void DvbPanel::setRecord()
s = desc->title;
if ( s.isEmpty() ) {
if ( !dvbConfig->filenameFormat.tqcontains("%chan") )
if ( !dvbConfig->filenameFormat.contains("%chan") )
s = curchan.name;
if ( !dvbConfig->filenameFormat.tqcontains("%date") )
if ( !dvbConfig->filenameFormat.contains("%date") )
s+="_"+TQDateTime::tqcurrentDateTime().toString( "yyyyMMdd-hhmmss" );
}
@ -1643,7 +1643,7 @@ void DvbPanel::newTimer( TQString channel, TQString name, TQDateTime begin, TQTi
RecTimer *t;
RecTimer *rt = new RecTimer();
rt->name = name.tqreplace("/","_").tqreplace(">","_").tqreplace("<","_").tqreplace(":","_").tqreplace('"',"_").tqreplace("\\","_").tqreplace("|","_");
rt->name = name.replace("/","_").replace(">","_").replace("<","_").replace(":","_").replace('"',"_").replace("\\","_").replace("|","_");
rt->channel = channel;
rt->begin = begin.addSecs( -(dvbConfig->beginMargin*60) );
rt->duration = duration.addSecs( (dvbConfig->beginMargin+dvbConfig->endMargin)*60 ) ;
@ -1901,7 +1901,7 @@ void DvbPanel::next()
TQListViewItem* nextItem;
TQListViewItem* playingItem = channelsCb->tqfindItem( TQString().sprintf("%05d", dvbConfig->lastChannel), 0 );
TQListViewItem* playingItem = channelsCb->findItem( TQString().sprintf("%05d", dvbConfig->lastChannel), 0 );
if ( !playingItem == 0 ) // yes, it's in the current category
{
@ -1927,7 +1927,7 @@ void DvbPanel::previous()
TQListViewItem* prevItem;
TQListViewItem* playingItem = channelsCb->tqfindItem( TQString().sprintf("%05d", dvbConfig->lastChannel), 0 );
TQListViewItem* playingItem = channelsCb->findItem( TQString().sprintf("%05d", dvbConfig->lastChannel), 0 );
if ( !playingItem == 0 ) // yes, it's in the current category
{
@ -2149,12 +2149,12 @@ bool DvbPanel::getChannelList()
while ( !tt.eof() ) {
s = tt.readLine();
if ( s.startsWith("#") ) {
if ( s.tqcontains("KaxTV") )
if ( s.contains("KaxTV") )
break;
continue;
}
chan = new ChannelDesc();
pos = s.tqfind("|");
pos = s.find("|");
c = s.left( pos );
if ( c=="TV" || c=="TVC" )
chan->type=1;
@ -2163,13 +2163,13 @@ bool DvbPanel::getChannelList()
if ( c=="TVC" || c=="RAC" )
chan->fta=1;
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->name = s.left( pos );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
c = s.left( pos );
s = s.right( s.length()-pos-1 );
tpos = c.tqfind("(");
tpos = c.find("(");
if ( tpos>0 )
chan->vpid = c.left(tpos).toUShort();
else
@ -2183,17 +2183,17 @@ bool DvbPanel::getChannelList()
chan->vType = 2;
if ( !chan->vpid )
chan->vType = 0;
pos = s.tqfind("|");
pos = s.find("|");
c = s.left( pos );
s = s.right( s.length()-pos-1 );
while ( (pos=c.tqfind(","))!=-1 ) {
while ( (pos=c.find(","))!=-1 ) {
t = c.left(pos);
chan->napid++;
if ( t.tqcontains("(ac3)") ) {
if ( t.contains("(ac3)") ) {
chan->apid[chan->napid-1].ac3=1;
t.remove("(ac3)");
}
if( (tpos=t.tqfind("("))!=-1 ) {
if( (tpos=t.find("("))!=-1 ) {
t.remove(")");
chan->apid[chan->napid-1].lang=t.right( t.length()-tpos-1 );
t = t.left( tpos );
@ -2201,16 +2201,16 @@ bool DvbPanel::getChannelList()
chan->apid[chan->napid-1].pid=t.toUShort();
c = c.right( c.length()-pos-1 );
}
pos = s.tqfind("|");
pos = s.find("|");
chan->ttpid = s.left(pos).toUShort();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->sid = s.left(pos).toUShort();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->tp.tsid = s.left(pos).toUShort();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
c = s.left(pos);
if ( c.startsWith("T") ) {
chan->tp.type=FE_OFDM;
@ -2230,17 +2230,17 @@ bool DvbPanel::getChannelList()
chan->tp.source = "Atsc";
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->tp.freq = s.left(pos).toULong();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->tp.sr = s.left(pos).toULong();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
c = s.left( pos );
chan->tp.pol = c[0].latin1();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 0 : chan->tp.coderateH = FEC_NONE; break;
case 12 : chan->tp.coderateH = FEC_1_2; break;
@ -2256,14 +2256,14 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.coderateH = FEC_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 0 : chan->tp.inversion = INVERSION_OFF; break;
case 1 : chan->tp.inversion = INVERSION_ON; break;
case -1 : chan->tp.inversion = INVERSION_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 8 : chan->tp.modulation = QPSK; break;
case 16 : chan->tp.modulation = QAM_16; break;
@ -2279,7 +2279,7 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.modulation = QAM_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 0 : chan->tp.coderateL = FEC_NONE; break;
case 12 : chan->tp.coderateL = FEC_1_2; break;
@ -2295,7 +2295,7 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.coderateL = FEC_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 8 : chan->tp.bandwidth = BANDWIDTH_8_MHZ; break;
case 7 : chan->tp.bandwidth = BANDWIDTH_7_MHZ; break;
@ -2303,14 +2303,14 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.bandwidth = BANDWIDTH_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 2 : chan->tp.transmission = TRANSMISSION_MODE_2K; break;
case 8 : chan->tp.transmission = TRANSMISSION_MODE_8K; break;
case -1 : chan->tp.transmission = TRANSMISSION_MODE_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 32 : chan->tp.guard = GUARD_INTERVAL_1_32; break;
case 16 : chan->tp.guard = GUARD_INTERVAL_1_16; break;
@ -2319,7 +2319,7 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.guard = GUARD_INTERVAL_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 0 : chan->tp.hierarchy = HIERARCHY_NONE; break;
case 1 : chan->tp.hierarchy = HIERARCHY_1; break;
@ -2328,39 +2328,39 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.hierarchy = HIERARCHY_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->num = s.left(pos).toUInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
c = s.left( pos );
s = s.right( s.length()-pos-1 );
while ( (pos=c.tqfind(","))!=-1 ) {
while ( (pos=c.find(","))!=-1 ) {
t = c.left(pos);
tpos=t.tqfind("(");
tpos=t.find("(");
ns = (int)chan->nsubpid;
chan->subpid[ns].pid = t.left(tpos).toUShort();
t = t.right( t.length()-tpos-1 );
tpos=t.tqfind(")");
tpos=t.find(")");
chan->subpid[ns].type = t.left(tpos).toUShort();
t = t.right( t.length()-tpos-2 );
tpos=t.tqfind(")");
tpos=t.find(")");
chan->subpid[ns].page = t.left(tpos).toUShort();
t = t.right( t.length()-tpos-2 );
tpos=t.tqfind(")");
tpos=t.find(")");
chan->subpid[ns].id = t.left(tpos).toUShort();
t = t.right( t.length()-tpos-2 );
tpos=t.tqfind(")");
tpos=t.find(")");
chan->subpid[ns].lang = t.left(tpos);
c = c.right( c.length()-pos-1 );
chan->nsubpid++;
}
pos = s.tqfind("|");
pos = s.find("|");
chan->category = s.left( pos );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->tp.nid = s.left(pos).toUShort();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
switch ( s.left(pos).toInt() ) {
case 20 : chan->tp.rolloff = ROLLOFF_20; break;
case 25 : chan->tp.rolloff = ROLLOFF_25; break;
@ -2368,7 +2368,7 @@ bool DvbPanel::getChannelList()
case -1 : chan->tp.rolloff = ROLLOFF_AUTO;
}
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
chan->tp.S2 = s.left(pos).toInt();
if ( chan->tp.source.isEmpty() ) {
@ -2587,23 +2587,23 @@ bool DvbPanel::getTimerList()
if ( s.startsWith("#") )
continue;
t = new RecTimer();
pos = s.tqfind("|");
pos = s.find("|");
t->name = s.left( pos );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
t->channel = s.left( pos );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
t->begin = TQDateTime::fromString( s.left( pos ), Qt::ISODate );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
t->duration = TQTime::fromString( s.left( pos ) );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
//t->filetype = s.left( pos ).toInt();
t->mode = 0;
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
t->mode = s.left( pos ).toInt();
t->running = 0;
timers.append( t );

@ -660,7 +660,7 @@ bool DVBsi::getSection( int pid, int tid, int timeout, int sid )
}
cursid = getBits(buf+3,0,16);
if ( sid && cursid!=sid && !sidList.tqcontains(cursid) ) {
if ( sid && cursid!=sid && !sidList.contains(cursid) ) {
sidList.append( cursid );
continue;
}

@ -158,7 +158,7 @@ bool DvbStream::canSource( ChannelDesc *chan )
return false;
int i;
for ( i=0; i<dvbDevice->numLnb; i++ ) {
if ( dvbDevice->lnb[i].source.tqcontains(chan->tp.source) )
if ( dvbDevice->lnb[i].source.contains(chan->tp.source) )
return true;
}
return false;
@ -181,7 +181,7 @@ int DvbStream::getSatPos( const TQString &src )
return -1;
for ( i=0; i<dvbDevice->numLnb; i++ )
if ( dvbDevice->lnb[i].source.tqcontains(src) )
if ( dvbDevice->lnb[i].source.contains(src) )
return i;
return -1;
}
@ -376,7 +376,7 @@ bool DvbStream::tuneDvb( ChannelDesc *chan, bool dvr )
switch( fe_info.type ) {
case FE_OFDM : {
TQString s = fe_info.name;
//if ( s.tqcontains("TerraTec/qanu USB2.0 Highspeed DVB-T Receiver") ) // cinergyT2 hack
//if ( s.contains("TerraTec/qanu USB2.0 Highspeed DVB-T Receiver") ) // cinergyT2 hack
// freq+=167000;
if (freq < 1000000)
freq*=1000UL;
@ -721,7 +721,7 @@ void DvbStream::moveRotor( int switchPos, ChannelDesc *chan, int hiband, bool dv
double DvbStream::getSourceAngle( TQString source )
{
double angle=1.0;
int pos = source.tqfindRev("-");
int pos = source.findRev("-");
source.remove(0,pos+1);
source = source.upper();
if ( source.endsWith("W") )
@ -1302,10 +1302,10 @@ bool DvbStream::startTimer( ChannelDesc *chan, TQString path, int maxsize, RecTi
newout = true;
}
if ( t->mode && !name.tqcontains("%date") )
if ( t->mode && !name.contains("%date") )
name+= "-%date";
name = name.tqreplace( "%chan", chan->name ).tqreplace("%date", t->begin.toString( "yyyyMMdd-hhmmss" ) ).tqreplace("%name", t->name );
name = name.tqreplace( "/", "_" ).tqreplace( ">", "_" ).tqreplace("<","_").tqreplace(":","_").tqreplace('"',"_").tqreplace("\\","_").tqreplace("|","_");
name = name.replace( "%chan", chan->name ).replace("%date", t->begin.toString( "yyyyMMdd-hhmmss" ) ).replace("%name", t->name );
name = name.replace( "/", "_" ).replace( ">", "_" ).replace("<","_").replace(":","_").replace('"',"_").replace("\\","_").replace("|","_");
name = path+name;
if ( !o->goRec( name, maxsize, t ) ) {

@ -203,11 +203,11 @@ void KEvents::checkEpgSearch(TQString searchword)
break;
found=false;
if(desc->title.upper().tqfind(searchword.upper())!=-1)
if(desc->title.upper().find(searchword.upper())!=-1)
found=true;
if(!desc->subtitle.isEmpty()) {
if(desc->subtitle.upper().tqfind(searchword.upper())!=-1)
if(desc->subtitle.upper().find(searchword.upper())!=-1)
found=true;
}
@ -216,7 +216,7 @@ void KEvents::checkEpgSearch(TQString searchword)
for ( l=0; l<(int)desc->extEvents.count(); l++ ) {
s = *desc->extEvents.at(l);
if(!s.isEmpty()) {
if(s.upper().tqfind(searchword.upper())!=-1) {
if(s.upper().find(searchword.upper())!=-1) {
found=true;
s="";
break;
@ -228,7 +228,7 @@ void KEvents::checkEpgSearch(TQString searchword)
for ( l=0; l<(int)desc->shortEvents.count(); l++ ) {
s = desc->shortEvents.at(l)->name;
if(!s.isEmpty()) {
if(s.upper().tqfind(searchword.upper())!=-1) {
if(s.upper().find(searchword.upper())!=-1) {
found=true;
s="";
break;
@ -236,7 +236,7 @@ void KEvents::checkEpgSearch(TQString searchword)
}
s = desc->shortEvents.at(l)->text;
if(!s.isEmpty()) {
if(s.upper().tqfind(searchword.upper())!=-1) {
if(s.upper().find(searchword.upper())!=-1) {
found=true;
s="";
break;

@ -185,19 +185,19 @@ void KTimerEditor::accept()
return;
}
if ( nameLe->text().stripWhiteSpace().tqcontains("/") )
if ( nameLe->text().stripWhiteSpace().contains("/") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains(">") )
if ( nameLe->text().stripWhiteSpace().contains(">") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains("<") )
if ( nameLe->text().stripWhiteSpace().contains("<") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains("\\") )
if ( nameLe->text().stripWhiteSpace().contains("\\") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains(":") )
if ( nameLe->text().stripWhiteSpace().contains(":") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains("\"") )
if ( nameLe->text().stripWhiteSpace().contains("\"") )
goto stop;
if ( nameLe->text().stripWhiteSpace().tqcontains("|") )
if ( nameLe->text().stripWhiteSpace().contains("|") )
goto stop;
if ( duration->time()<TQTime(0,1) ) {

@ -418,7 +418,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
s = s.stripWhiteSpace();
trans = new Transponder();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( s.left(pos)=="T" ) {
trans->type=FE_OFDM;
trans->source = "Terrestrial";
@ -441,17 +441,17 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
}
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
trans->freq = s.left(pos).toULong()/1000;
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
if ( trans->type!=FE_ATSC )
pos = s.tqfind(" ");
pos = s.find(" ");
if ( trans->type==FE_QPSK ) {
trans->pol = s.left(pos).lower()[0].latin1();
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
}
if ( trans->type!=FE_OFDM && trans->type!=FE_ATSC ) {
trans->sr = s.left(pos).toULong()/1000;
@ -489,7 +489,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( s.left(pos)=="1/2" )
trans->coderateH = FEC_1_2;
else if ( s.left(pos)=="2/3" )
@ -512,7 +512,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
trans->coderateH = FEC_AUTO;
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( trans->type==FE_OFDM ) {
if ( s.left(pos)=="1/2" )
trans->coderateL = FEC_1_2;
@ -542,7 +542,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
}
if ( trans->type!=FE_QPSK ) {
if ( s.left(pos)=="QPSK" )
@ -563,7 +563,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
if ( trans->type==FE_OFDM ) {
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( s.left(pos)=="8k" )
trans->transmission = TRANSMISSION_MODE_8K;
else if ( s.left(pos)=="2k" )
@ -573,7 +573,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( s.left(pos)=="1/32" )
trans->guard = GUARD_INTERVAL_1_32;
else if ( s.left(pos)=="1/16" )
@ -587,7 +587,7 @@ void ScanDialog::parseTp( TQString s, fe_type_t type, TQString src )
s = s.right( s.length()-pos-1 );
s = s.stripWhiteSpace();
pos = s.tqfind(" ");
pos = s.find(" ");
if ( s.left(pos)=="1" )
trans->hierarchy = HIERARCHY_1;
else if ( s.left(pos)=="2" )
@ -724,7 +724,7 @@ bool ScanDialog::checkChannUpdate( ChannelDesc *chan )
break;
}
}
chandesc->tqreplace(i,new ChannelDesc(*chan));
chandesc->replace(i,new ChannelDesc(*chan));
return false;
}
}

@ -123,7 +123,7 @@ bool Ts2Rtp::addChannels( TQPtrList<ChannelDesc> *channels )
pids.append( d->apid[k].pid );
for ( k=0; k<d->nsubpid && k<MAX_DVBSUB; k++ )
pids.append( d->subpid[k].pid );
while ( pmtpid==17 || pids.tqcontains( pmtpid ) )
while ( pmtpid==17 || pids.contains( pmtpid ) )
--pmtpid;
}
desc->pmtpid = pmtpid--;

@ -180,32 +180,32 @@ void CdWidget::updateList( const TQString &list )
chan.clear();
if ( list=="quit" ) return;
while ( (pos = s.tqfind("|"))!=-1 ) {
while ( (pos = s.find("|"))!=-1 ) {
name = s.left( pos );
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
vpid = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
apid = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
if ( s.left( pos )=="n" ) ac3 = 0;
else ac3 = 1;
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
subpid = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
page = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
id = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
type = s.left( pos ).toInt();
s = s.right( s.length()-pos-1 );
pos = s.tqfind("|");
pos = s.find("|");
lang = s.left( pos );
s = s.right( s.length()-pos-1 );
chan.append( new CdChannel( name, vpid, apid, ac3, subpid, page, id, type, lang ) );

@ -68,7 +68,7 @@ void InstWizard::internalWizard()
info << "<b>" << i18n("Kaffeine-Xine") << "...</b><br>";
KService::Ptr service = KService::serviceByDesktopName("xine_part");
if ((service) && (service->serviceTypes().tqcontains("KaffeinePart")))
if ((service) && (service->serviceTypes().contains("KaffeinePart")))
info << "<font color=\"DarkGreen\">" << i18n("Ok.") << "</font>";
else
info << "<font color=\"DarkRed\">" << i18n("Part not found. Please check your installation!") << "</font>";
@ -91,10 +91,10 @@ void InstWizard::internalWizard()
{
int major, minor, sub;
xine_get_version(&major, &minor, &sub);
if (xineVersion.tqcontains("CVS", false))
if (xineVersion.contains("CVS", false))
info << "<font color=\"DarkBlue\">" << i18n("Developer version.") << "</font>";
if ((major == 1) && (minor == 0) && (sub == 0) && (xineVersion.tqcontains("rc", false)))
if ((major == 1) && (minor == 0) && (sub == 0) && (xineVersion.contains("rc", false)))
{
info << "<font color=\"DarkRed\">" << i18n("Kaffeine requires xine-lib >= %1. Download the latest version here:").tqarg("1.0") << " <a href=\"http://www.xinehq.de\">http://www.xinehq.de</a>.</font>";
}
@ -149,9 +149,9 @@ void InstWizard::internalWizard()
connect(&process, TQT_SIGNAL(receivedStdout(KProcess*,char*,int)), this, TQT_SLOT(slotStdout(KProcess*, char*, int)));
process.start(KProcess::Block, KProcess::Stdout);
if (stdout.tqcontains('1'))
if (stdout.contains('1'))
info << "<font color=\"DarkGreen\">" << i18n("Ok.") << "</font>";
else if (stdout.tqcontains('0'))
else if (stdout.contains('0'))
info << "<font color=\"DarkRed\">" << i18n("DMA mode off! For smooth DVD playback run as root:") + " \"hdparm -d1 /dev/dvd\".</font>";
else
info << "<font color=\"DarkBlue\">" << i18n("Can't check DMA mode. Permission denied or no such device:")
@ -188,7 +188,7 @@ void InstWizard::internalWizard()
info << "<hr><br><b>" << i18n("RESULT") << ":</b> ";
if (infoString.tqcontains("DarkRed"))
if (infoString.contains("DarkRed"))
{
info << i18n("Found some problems, but nevertheless Kaffeine may work.");
}

@ -291,7 +291,7 @@ void Kaffeine::updateArgs()
for (int i = 0; i < args->count(); i++ ) {
TQDir path;
TQString url = TQFile::decodeName(args->arg(i));
if ((url.left(1) != "/") && (!url.tqcontains("://")) && (url.lower() != "dvd") && (url.lower() != "vcd")
if ((url.left(1) != "/") && (!url.contains("://")) && (url.lower() != "dvd") && (url.lower() != "vcd")
&& (url.lower() != "audiocd") && (url.lower() != "cdda") && (url.lower() != "dvb")) {
#if KDE_IS_VERSION(3,5,0)
KURL u = KIO::NetAccess::mostLocalURL(args->url(i), 0);
@ -382,7 +382,7 @@ void Kaffeine::slotLoadPart(const TQString& desktopName)
m_playerContainer = new PlayerContainer(playerWidget);
connect(m_playerContainer, TQT_SIGNAL(signalURLDropEvent(const TQStringList&)), TQT_TQOBJECT(this), TQT_SLOT(slotLoadURLS(const TQStringList&)));
if (service->serviceTypes().tqcontains("KaffeinePart")) {
if (service->serviceTypes().contains("KaffeinePart")) {
kdDebug() << "This is a KaffeinePart..." << endl;
int error = 0;
m_mediaPart = KParts::ComponentFactory::createPartInstanceFromService<KaffeinePart>(service, m_playerContainer, service->name().ascii(), TQT_TQOBJECT(this), 0, m_engineParameters, &error);
@ -477,7 +477,7 @@ void Kaffeine::load(const TQStringList& urllist)
if (!urllist.count())
return;
if (urllist[0].tqcontains(".kaffeine", false))
if (urllist[0].contains(".kaffeine", false))
{
m_playlist->loadPlaylist(urllist[0]);
}
@ -503,7 +503,7 @@ void Kaffeine::slotPlay(const MRL& mrl)
if (m_mediaPart)
{
m_mediaPart->openURL(mrl);
if ( !mrl.mime().tqcontains("audio") )
if ( !mrl.mime().contains("audio") )
TQTimer::singleShot(300, TQT_TQOBJECT(this), TQT_SLOT(slotSwitchToPlayerWindow()));
}
}
@ -1394,7 +1394,7 @@ void Kaffeine::slotOpenURL()
TQString url = KInputDialog::getText(i18n("Open URL"), i18n("Enter a URL:"), "", &ok);
if (ok)
{
if ((!(url.left(1) == "/")) && (!url.tqcontains(":/")))
if ((!(url.left(1) == "/")) && (!url.contains(":/")))
url.prepend("http://"); // assume http protocol
load(url);
}
@ -1425,7 +1425,7 @@ void Kaffeine::slotOpenDirectory()
}
else {
s = path.path();
if ( TQDir(s).entryList().tqcontains("VIDEO_TS") || TQDir(s).entryList().tqcontains("video_ts") )
if ( TQDir(s).entryList().contains("VIDEO_TS") || TQDir(s).entryList().contains("video_ts") )
s = s.prepend("dvd://");
load( s );
}
@ -1473,7 +1473,7 @@ bool Kaffeine::loadTMP(const TQStringList& list)
for (TQStringList::ConstIterator it = list.begin(); it != end; ++it) {
TQString url = (*it).lower();
TQString ext = url;
ext = ext.remove( 0 , ext.tqfindRev('.')+1 ).lower();
ext = ext.remove( 0 , ext.findRev('.')+1 ).lower();
if (url == "dvd") {
cddisc->startDVD( device );
return true;
@ -1490,10 +1490,10 @@ bool Kaffeine::loadTMP(const TQStringList& list)
playDvb();
return true;
}
else if ( sublist.tqcontains(ext)) {
else if ( sublist.contains(ext)) {
MRL mrl = m_playlist->getCurrent();
if (!mrl.isEmpty()) {
if (!mrl.subtitleFiles().tqcontains(url)) {
if (!mrl.subtitleFiles().contains(url)) {
mrl.addSubtitleFile(*it);
mrl.setCurrentSubtitle(mrl.subtitleFiles().size() - 1);
m_mediaPart->openURL(mrl);
@ -1698,12 +1698,12 @@ bool Kaffeine::isVideo()
if (m_mediaPart)
{
if (m_mediaPart->isPlaying())
return m_playlist->getCurrent().mime().tqcontains("video");
return m_playlist->getCurrent().mime().contains("video");
else
return false;
}
else
return m_playlist->getCurrent().mime().tqcontains("video");
return m_playlist->getCurrent().mime().contains("video");
}
TQString Kaffeine::title()

@ -179,7 +179,7 @@ bool GStreamerPart::openURL(const MRL& mrl)
currentDevice = "";
TQString ext = m_mrl.kurl().fileName();
ext = ext.remove( 0 , ext.tqfindRev('.')+1 ).lower();
ext = ext.remove( 0 , ext.findRev('.')+1 ).lower();
if ( m_mrl.mime().isNull() ) {
KMimeType::Ptr mime = KMimeType::findByURL( m_mrl.kurl().path() );
@ -201,19 +201,19 @@ bool GStreamerPart::openURL(const MRL& mrl)
TQString secondLine = stream.readLine();
file.close();
if ( secondLine.tqcontains("kaffeine", false) ) {
if ( secondLine.contains("kaffeine", false) ) {
kdDebug() << "GStreamerPart: Try loading kaffeine playlist\n";
playlist = PlaylistImport::kaffeine( localFile, m_playlist );
}
if ( secondLine.tqcontains("noatun", false) ) {
if ( secondLine.contains("noatun", false) ) {
kdDebug() << "GStreamerPart: Try loading noatun playlist\n";
playlist = PlaylistImport::noatun( localFile, m_playlist);
}
if ( firstLine.tqcontains("asx", false) ) {
if ( firstLine.contains("asx", false) ) {
kdDebug() << "GStreamerPart: Try loading asx playlist\n";
playlist = PlaylistImport::asx( localFile, m_playlist );
}
if ( firstLine.tqcontains("[playlist]", false) ) {
if ( firstLine.contains("[playlist]", false) ) {
kdDebug() << "GStreamerPart: Try loading pls playlist\n";
playlist = PlaylistImport::pls( localFile, m_playlist );
}
@ -235,7 +235,7 @@ bool GStreamerPart::openURL(const MRL& mrl)
TQString s = mrl.url();
if ( s.startsWith("cdda://") ) {
s = s.remove("cdda://");
if ( (pos=s.tqfindRev("/"))>-1 ) {
if ( (pos=s.findRev("/"))>-1 ) {
currentDevice=s.left( pos );
s = s.right( s.length()-pos-1 );
}
@ -541,7 +541,7 @@ void GStreamerPart::processMetaInfo()
MRL mrl = m_playlist[m_current];
if ( (mrl.title().tqcontains("/") || mrl.title().tqcontains(".") || (mrl.title().isEmpty()))
if ( (mrl.title().contains("/") || mrl.title().contains(".") || (mrl.title().isEmpty()))
&& !m_title.stripWhiteSpace().isEmpty() && m_title.length() > 1 )
mrl.setTitle( m_title );
if (mrl.artist().isEmpty() && !m_artist.stripWhiteSpace().isEmpty())
@ -707,7 +707,7 @@ void GStreamerPart::initActions()
connect(m_audioVisual, TQT_SIGNAL(activated(const TQString&)), TQT_TQOBJECT(this), TQT_SLOT(slotSetVisualPlugin(const TQString&)));
m_audioVisualPluginList.prepend("none");
m_audioVisual->setItems(m_audioVisualPluginList);
m_audioVisual->setCurrentItem(m_audioVisual->items().tqfindIndex(m_visualPluginName));
m_audioVisual->setCurrentItem(m_audioVisual->items().findIndex(m_visualPluginName));
new KAction(i18n("&Mute"), "player_mute", Key_U, TQT_TQOBJECT(this), TQT_SLOT(slotMute()), actionCollection(), "audio_mute");
new KAction(i18n("&Auto"), "viewmagfit", Key_F5, TQT_TQOBJECT(m_video), TQT_SLOT(slotAspectRatioAuto()), actionCollection(), "aspect_auto");

@ -223,7 +223,7 @@ bool PlaylistImport::m3u(const TQString& playlist , TQValueList<MRL>& mrls)
continue;
}
}
url.tqreplace ('\\', '/'); /* for windows styled urls */
url.replace ('\\', '/'); /* for windows styled urls */
kUrl = KURL (plurl, url); /* maybe a relative url */
if (kUrl.isValid())
{
@ -296,12 +296,12 @@ bool PlaylistImport::pls(const TQString& playlist, TQValueList<MRL>& mrls)
continue;
}
if (tmp.tqcontains(regExp_File)) {
if (tmp.contains(regExp_File)) {
entryCnt++;
continue;
}
if (tmp.tqcontains(regExp_NumberOfEntries)) {
if (tmp.contains(regExp_NumberOfEntries)) {
numberOfEntries = TQString(tmp.section('=', -1)).stripWhiteSpace().toUInt();
continue;
}
@ -341,7 +341,7 @@ bool PlaylistImport::pls(const TQString& playlist, TQValueList<MRL>& mrls)
inPlaylistSection = true;
continue;
}
if ((*i).tqcontains(regExp_File)) {
if ((*i).contains(regExp_File)) {
// Have a "File#=XYZ" line.
index = extractIndex(*i);
if (index > numberOfEntries || index == 0)
@ -349,7 +349,7 @@ bool PlaylistImport::pls(const TQString& playlist, TQValueList<MRL>& mrls)
files[index-1] = TQString((*i).section('=', 1)).stripWhiteSpace();
continue;
}
if ((*i).tqcontains(regExp_Title)) {
if ((*i).contains(regExp_Title)) {
// Have a "Title#=XYZ" line.
index = extractIndex(*i);
if (index > numberOfEntries || index == 0)
@ -357,7 +357,7 @@ bool PlaylistImport::pls(const TQString& playlist, TQValueList<MRL>& mrls)
titles[index-1] = TQString((*i).section('=', 1)).stripWhiteSpace();
continue;
}
if ((*i).tqcontains(regExp_Length)) {
if ((*i).contains(regExp_Length)) {
// Have a "Length#=XYZ" line.
index = extractIndex(*i);
if (index > numberOfEntries || index == 0)
@ -368,11 +368,11 @@ bool PlaylistImport::pls(const TQString& playlist, TQValueList<MRL>& mrls)
length[index-1] = TQTime().addSecs(time);
continue;
}
if ((*i).tqcontains(regExp_NumberOfEntries)) {
if ((*i).contains(regExp_NumberOfEntries)) {
// Have the "NumberOfEntries=#" line.
continue;
}
if ((*i).tqcontains(regExp_Version)) {
if ((*i).contains(regExp_Version)) {
// Have the "Version=#" line.
tmp = TQString((*i).section('=', 1)).stripWhiteSpace();
// We only support Version=2

@ -533,7 +533,7 @@ void KXineWidget::xineEventListener(void *p, const xine_event_t* xineEvent)
{
case XINE_MSG_NO_ERROR:
{
/* copy strings, and tqreplace '\0' separators by '\n' */
/* copy strings, and replace '\0' separators by '\n' */
char* s = data->messages;
char* d = new char[2000];
@ -647,7 +647,7 @@ void KXineWidget::xineEventListener(void *p, const xine_event_t* xineEvent)
case XINE_MSG_ENCRYPTED_SOURCE:
{
message = i18n("The source seems encrypted, and can't be read. ");
if (vw->m_trackURL.tqcontains("dvd:/"))
if (vw->m_trackURL.contains("dvd:/"))
message = message + i18n("\nYour DVD is probably crypted. According to your country laws, you can or can't use libdvdcss to be able to read this disc. ");
if(data->explanation)
message = message + "(" + ((char *) data + data->parameters) + ")";
@ -685,7 +685,7 @@ void KXineWidget::timerEvent( TQTimerEvent* tevent )
TQTimer::singleShot(0, this, TQT_SLOT(slotPlayTimeShift()));
break;
}
if ( m_trackURL=="DVB" || m_trackURL.tqcontains(".kaxtv") )
if ( m_trackURL=="DVB" || m_trackURL.contains(".kaxtv") )
break;
#ifdef XINE_PARAM_GAPLESS_SWITCH
@ -1204,7 +1204,7 @@ bool KXineWidget::initXine()
i = xine_config_register_enum(m_xineEngine, "audio.driver", 0,
m_audioChoices, m_audioInfo, NULL, 10, &KXineWidget::audioDriverChangedCallback, this);
if (m_audioDriverList.tqcontains(m_preferedAudio))
if (m_audioDriverList.contains(m_preferedAudio))
m_audioDriverName = m_preferedAudio;
else
m_audioDriverName = m_audioChoices[i];
@ -1230,7 +1230,7 @@ bool KXineWidget::initXine()
i = xine_config_register_enum(m_xineEngine, "video.driver", 0,
m_videoChoices, m_videoInfo, NULL, 10, &KXineWidget::videoDriverChangedCallback, this);
if (m_videoDriverList.tqcontains(m_preferedVideo))
if (m_videoDriverList.contains(m_preferedVideo))
m_videoDriverName = m_preferedVideo;
else
m_videoDriverName = m_videoChoices[i];
@ -1601,7 +1601,7 @@ void getOSDLine( xine_osd_t *osd, int w, TQCString &dest, TQCString &source )
int prevPos, pos, tw, th;
bool wrap=false;
pos = source.tqfind(" ");
pos = source.find(" ");
if ( pos==-1 ) {
dest = source;
source = "";
@ -1618,7 +1618,7 @@ void getOSDLine( xine_osd_t *osd, int w, TQCString &dest, TQCString &source )
if ( pos==-1 )
break;
prevPos = pos;
pos = source.tqfind(" ",pos+1);
pos = source.find(" ",pos+1);
dest = source.left( pos );
}
if ( wrap ) {
@ -1738,7 +1738,7 @@ void KXineWidget::dvbShowOSD()
}
if ( !dvbCurrentNext[1].isEmpty() ) {
s = dvbCurrentNext[1];
pos = s.tqfind("-");
pos = s.find("-");
c = s.left( pos+1 );
s = s.right( s.length()-pos-1 );
t = s;
@ -1791,7 +1791,7 @@ void KXineWidget::dvbShowOSD()
continue;
}
s = dvbCurrentNext[ j ];
pos = s.tqfind("-");
pos = s.find("-");
c = s.left( pos+1 );
s = s.right( s.length()-pos-1 );
ct = cs = s.utf8();
@ -1933,7 +1933,7 @@ void KXineWidget::slotPlay()
setCursor(TQCursor(TQt::WaitCursor));
m_trackURL = m_queue.first();
m_queue.remove(m_queue.tqfind(m_trackURL));
m_queue.remove(m_queue.find(m_trackURL));
if (m_trackURL != m_logoFile)
emit signalXinetqStatus(i18n("Opening..."));
@ -1942,7 +1942,7 @@ void KXineWidget::slotPlay()
m_trackSubtitleURL = TQString();
m_trackSaveURL = TQString();
/*for (int i = 1; i <= m_trackURL.tqcontains('#'); i++) {
/*for (int i = 1; i <= m_trackURL.contains('#'); i++) {
ref = m_trackURL.section('#', i, i);
if (ref.section(':', 0, 0) == "subtitle")
m_trackSubtitleURL = ref.section(':', 1);
@ -1953,15 +1953,15 @@ void KXineWidget::slotPlay()
TQString turl;
int pos;
if ( (pos=m_trackURL.tqfind("#subtitle:"))>-1 ) {
if ( (pos=m_trackURL.find("#subtitle:"))>-1 ) {
turl = m_trackURL.left(pos);
m_trackSubtitleURL = m_trackURL.right( m_trackURL.length()-pos );
if ( (pos=m_trackSubtitleURL.tqfind("#save:"))>-1 ) {
if ( (pos=m_trackSubtitleURL.find("#save:"))>-1 ) {
m_trackSaveURL = m_trackSubtitleURL.right( m_trackSubtitleURL.length()-pos );
m_trackSubtitleURL = m_trackSubtitleURL.left(pos);
}
}
else if ( (pos=m_trackURL.tqfind("#save:"))>-1 ) {
else if ( (pos=m_trackURL.find("#save:"))>-1 ) {
turl = m_trackURL.left(pos);
m_trackSaveURL = m_trackURL.right( m_trackURL.length()-pos );
}
@ -1970,11 +1970,11 @@ void KXineWidget::slotPlay()
m_trackSubtitleURL.remove("#subtitle:");
m_trackSaveURL.remove("#save:");
turl = turl.tqreplace( "%", "%25" ).tqreplace( "#", "%23" ).tqreplace( ";", "%3b" ).tqreplace( " ", "%20" );
turl = turl.replace( "%", "%25" ).replace( "#", "%23" ).replace( ";", "%3b" ).replace( " ", "%20" );
if ( !m_trackSubtitleURL.isEmpty() )
turl = turl + "#subtitle:" + m_trackSubtitleURL.tqreplace( "%", "%25" ).tqreplace( "#", "%23" ).tqreplace( ";", "%3b" ).tqreplace( " ", "%20" );
turl = turl + "#subtitle:" + m_trackSubtitleURL.replace( "%", "%25" ).replace( "#", "%23" ).replace( ";", "%3b" ).replace( " ", "%20" );
if ( !m_trackSaveURL.isEmpty() )
turl = turl + "#save:" + m_trackSaveURL.tqreplace( "%", "%25" ).tqreplace( "#", "%23" ).tqreplace( ";", "%3b" ).tqreplace( " ", "%20" );
turl = turl + "#save:" + m_trackSaveURL.replace( "%", "%25" ).replace( "#", "%23" ).replace( ";", "%3b" ).replace( " ", "%20" );
if ( turl.startsWith("/") )
turl.prepend("file://");
@ -2243,7 +2243,7 @@ void KXineWidget::sendXineError()
emit signalXineError(error);
}
else
errorOut("Can't tqfind/play logo file!");
errorOut("Can't find/play logo file!");
}
else
{

@ -93,7 +93,7 @@ bool PositionSlider::eventFilter(TQObject *obj, TQEvent *ev)
TQMouseEvent *e = (TQMouseEvent *)ev;
TQRect r = sliderRect();
if( r.tqcontains( e->pos() ) || e->button() != Qt::LeftButton )
if( r.contains( e->pos() ) || e->button() != Qt::LeftButton )
return false;
int range = maxValue() - minValue();

@ -311,7 +311,7 @@ void PostFilter::setConfig(const TQString &configString)
return;
}
for( int i = 0; i < configStr.tqcontains(',') + 1; i++ )
for( int i = 0; i < configStr.contains(',') + 1; i++ )
{
TQString parameterConfig = configStr.section(',', i, i);
TQString parameterName = parameterConfig.section('=', 0, 0);

@ -169,7 +169,7 @@ bool XinePart::openURL(const MRL& mrl)
bool playlist = false;
TQString ext = m_mrl.kurl().fileName();
ext = ext.remove( 0 , ext.tqfindRev('.')+1 ).lower();
ext = ext.remove( 0 , ext.findRev('.')+1 ).lower();
if (!m_mrl.mime().isNull())
{
@ -194,22 +194,22 @@ bool XinePart::openURL(const MRL& mrl)
TQString secondLine = stream.readLine();
file.close();
if (secondLine.tqcontains("kaffeine", false))
if (secondLine.contains("kaffeine", false))
{
kdDebug() << "KafeinePart: Try loading kaffeine playlist\n";
playlist = PlaylistImport::kaffeine(localFile, m_playlist);
}
if (secondLine.tqcontains("noatun", false))
if (secondLine.contains("noatun", false))
{
kdDebug() << "XinePart: Try loading noatun playlist\n";
playlist = PlaylistImport::noatun(localFile, m_playlist);
}
if (firstLine.tqcontains("asx", false))
if (firstLine.contains("asx", false))
{
kdDebug() << "XinePart: Try loading asx playlist\n";
playlist = PlaylistImport::asx(localFile, m_playlist);
}
if (firstLine.tqcontains("smil", false))
if (firstLine.contains("smil", false))
{
kdDebug() << "XinePart: Try loading smil playlist\n";
if (KMessageBox::warningYesNo(0, i18n("SMIL (Synchronized Multimedia Integration Language) support is rudimentary!\nXinePart can now try to playback contained video sources without any tqlayout. Proceed?"), TQString(), KStdGuiItem::yes(), KStdGuiItem::no(), "smil_warning") == KMessageBox::Yes)
@ -223,7 +223,7 @@ bool XinePart::openURL(const MRL& mrl)
else
return false;
}
if (firstLine.tqcontains("[playlist]", false))
if (firstLine.contains("[playlist]", false))
{
kdDebug() << "XinePart: Try loading pls playlist\n";
playlist = PlaylistImport::pls(localFile, m_playlist);
@ -299,7 +299,7 @@ void XinePart::slotPlay(bool forcePlay)
/*
* is protocol supported by xine or not known by KIO?
*/
if ((TQString(SUPPORTED_PROTOCOLS).tqcontains(mrl.kurl().protocol()))
if ((TQString(SUPPORTED_PROTOCOLS).contains(mrl.kurl().protocol()))
|| (!KProtocolInfo::isKnownProtocol(mrl.kurl())))
{
TQString sub;
@ -617,7 +617,7 @@ void XinePart::slotAddSubtitle(void)
if (!(subtitleURL.isEmpty()))
{
if (!m_playlist[m_current].subtitleFiles().tqcontains(subtitleURL))
if (!m_playlist[m_current].subtitleFiles().contains(subtitleURL))
{
m_playlist[m_current].addSubtitleFile(subtitleURL);
}
@ -711,7 +711,7 @@ void XinePart::slotChannelInfo(const TQStringList& audio, const TQStringList& su
for (TQStringList::ConstIterator it = subFiles.begin(); it != end; ++it)
{
sub = (*it);
sub = sub.remove(0 , sub.tqfindRev('/')+1);
sub = sub.remove(0 , sub.findRev('/')+1);
subs.append(sub);
}
m_subtitles->setItems(subs);
@ -1051,7 +1051,7 @@ void XinePart::slotMessage(const TQString& message)
{
TQString msg = message;
if ( msg.startsWith("@") ) {
if ( m_xine->isPlaying() && m_xine->getURL().tqcontains("#") ) // do not warn for url containing #
if ( m_xine->isPlaying() && m_xine->getURL().contains("#") ) // do not warn for url containing #
return;
msg.remove(0,1);
}
@ -1088,8 +1088,8 @@ void XinePart::slotTrackPlaying()
if (mrl.length().isNull()) /* no meta */
{
if ((!m_xine->getTitle().isEmpty()) && (!m_xine->getTitle().tqcontains('/'))
&& (m_xine->getTitle().tqcontains(TQRegExp("\\w")) > 2) && (m_xine->getTitle().left(5).lower() != "track"))
if ((!m_xine->getTitle().isEmpty()) && (!m_xine->getTitle().contains('/'))
&& (m_xine->getTitle().contains(TQRegExp("\\w")) > 2) && (m_xine->getTitle().left(5).lower() != "track"))
mrl.setTitle(m_xine->getTitle());
if ((mrl.artist().isEmpty()) && (!m_xine->getArtist().isEmpty()))
mrl.setArtist(m_xine->getArtist());
@ -1502,7 +1502,7 @@ void XinePart::loadConfig()
config->setGroup("Visualization");
TQString visual = config->readEntry("Visual Plugin", "goom");
m_audioVisual->setCurrentItem(m_audioVisual->items().tqfindIndex(visual));
m_audioVisual->setCurrentItem(m_audioVisual->items().findIndex(visual));
m_xine->slotSetVisualPlugin(visual);
config->setGroup("Deinterlace");
@ -1833,7 +1833,7 @@ TQString XinePart::supportedExtensions()
ext = ext.remove("txt");
ext = "*." + ext;
ext.append(" smil");
ext = ext.tqreplace( ' ', " *." );
ext = ext.replace( ' ', " *." );
ext = ext + " " + ext.upper();
return ext;
@ -2088,7 +2088,7 @@ void VolumeSlider::wheelEvent(TQWheelEvent* e)
TQMouseEvent *e = (TQMouseEvent *)ev;
TQRect r = sliderRect();
if( r.tqcontains( e->pos() ) || e->button() != LeftButton )
if( r.contains( e->pos() ) || e->button() != LeftButton )
return FALSE;
int range = maxValue() - minValue();

@ -129,7 +129,7 @@ XineConfigEntry::XineConfigEntry(TQWidget* tqparent, TQGridLayout* grid, int row
}
TQString m_keyName(entry->key);
m_keyName.remove( 0, m_keyName.tqfind(".") + 1 );
m_keyName.remove( 0, m_keyName.find(".") + 1 );
TQLabel* description = new TQLabel(m_keyName + "\n" + TQString::fromLocal8Bit(entry->description), tqparent);
description->tqsetAlignment( TQLabel::WordBreak | TQLabel::AlignVCenter );
@ -322,11 +322,11 @@ void XineConfig::createPage(const TQString& cat, bool expert, TQWidget* tqparent
do
{
entCat = TQString(ent->key);
entCat = entCat.left(entCat.tqfind("."));
entCat = entCat.left(entCat.find("."));
if (entCat == cat)
{
if (((!expert) && (TQString(NON_EXPERT_OPTIONS).tqcontains(ent->key))) ||
((expert) && (!TQString(NON_EXPERT_OPTIONS).tqcontains(ent->key))))
if (((!expert) && (TQString(NON_EXPERT_OPTIONS).contains(ent->key))) ||
((expert) && (!TQString(NON_EXPERT_OPTIONS).contains(ent->key))))
{
m_entries.append(new XineConfigEntry(tqparent, grid, row, ent));
delete ent;
@ -351,8 +351,8 @@ const TQStringList XineConfig::getCategories()
do
{
entCat = TQString(ent->key);
entCat = entCat.left(entCat.tqfind("."));
if (cats.tqfindIndex(entCat) == -1)
entCat = entCat.left(entCat.find("."));
if (cats.findIndex(entCat) == -1)
{
// kdDebug() << "XineConfig: new category: " << entCat << endl;
cats.append(entCat);

@ -101,7 +101,7 @@ void SystemTray::mousePressEvent(TQMouseEvent *e)
KSystemTray::mousePressEvent(e);
break;
case Qt::MidButton:
if(!TQT_TQRECT_OBJECT(rect()).tqcontains(e->pos()))
if(!TQT_TQRECT_OBJECT(rect()).contains(e->pos()))
return;
actionCollection()->action("trayplay")->activate();
break;

Loading…
Cancel
Save