summaryrefslogtreecommitdiffstats
path: root/kpackage
diff options
context:
space:
mode:
Diffstat (limited to 'kpackage')
-rw-r--r--kpackage/debAptInterface.cpp16
-rw-r--r--kpackage/debInterface.cpp22
-rw-r--r--kpackage/fbsdInterface.cpp6
-rw-r--r--kpackage/findf.cpp12
-rw-r--r--kpackage/kissInterface.cpp10
-rw-r--r--kpackage/kpPty.cpp10
-rw-r--r--kpackage/kpTerm.cpp4
-rw-r--r--kpackage/kpackage.cpp12
-rw-r--r--kpackage/kpackage.h6
-rw-r--r--kpackage/kplview.cpp8
-rw-r--r--kpackage/managementWidget.cpp6
-rw-r--r--kpackage/options.cpp2
-rw-r--r--kpackage/packageDisplay.cpp4
-rw-r--r--kpackage/packageInfo.cpp18
-rw-r--r--kpackage/packageProperties.cpp20
-rw-r--r--kpackage/pkgOptions.cpp4
-rw-r--r--kpackage/rpmInterface.cpp30
-rw-r--r--kpackage/search.cpp2
-rw-r--r--kpackage/slackInterface.cpp12
19 files changed, 102 insertions, 102 deletions
diff --git a/kpackage/debAptInterface.cpp b/kpackage/debAptInterface.cpp
index d453726..ce28d21 100644
--- a/kpackage/debAptInterface.cpp
+++ b/kpackage/debAptInterface.cpp
@@ -318,7 +318,7 @@ TQStringList DEBAPT::listInstalls(const TQStringList &packs, bool install, bool
TQString packAll;
for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it ) {
// kdDebug() << "M=" << *it << "\n";
- if ((*it).tqfind(match) >= 0 || extras) {
+ if ((*it).find(match) >= 0 || extras) {
if (extras) {
if ((*it)[0] == ' ') {
packAll += *it;
@@ -351,14 +351,14 @@ TQStringList DEBAPT::FindFile(const TQString &name, bool searchAll)
TQStringList filelist = kpty->run(s);
for ( TQStringList::Iterator it = filelist.begin(); it != filelist.end(); ++it ) {
- int p = (*it).tqfind(": ");
+ int p = (*it).find(": ");
if( p !=-1 )
- (*it).tqreplace(p, 2, "\t");
+ (*it).replace(p, 2, "\t");
}
if (filelist.count() == 1) {
TQStringList::Iterator it = filelist.begin();
- if ((*it).tqfind("not found") >= 0) {
+ if ((*it).find("not found") >= 0) {
filelist.remove(it);
}
}
@@ -514,10 +514,10 @@ void DEBAPT::writeApt(const TQStringList &list) {
TQString cmd = "sh -c \"/bin/echo -e '";
for ( TQStringList::ConstIterator it = list.begin(); it != list.end(); ++it ) {
TQString s = *it;
- s.tqreplace("\""," ");
- s.tqreplace("'"," ");
- s.tqreplace("!"," ");
- s.tqreplace("`"," ");
+ s.replace("\""," ");
+ s.replace("'"," ");
+ s.replace("!"," ");
+ s.replace("`"," ");
cmd += s;
cmd += "\n";
}
diff --git a/kpackage/debInterface.cpp b/kpackage/debInterface.cpp
index 8ad5226..d0bdd69 100644
--- a/kpackage/debInterface.cpp
+++ b/kpackage/debInterface.cpp
@@ -123,11 +123,11 @@ bool DEB::parseName(const TQString &name, TQString *n, TQString *v)
{
int d1, d2, s1;
- s1 = name.tqfindRev('.');
+ s1 = name.findRev('.');
if (s1 > 0) {
- d2 = name.tqfindRev('-',s1-1);
+ d2 = name.findRev('-',s1-1);
if (d2 > 0) {
- d1 = name.tqfindRev('_',d2-1);
+ d1 = name.findRev('_',d2-1);
if (d1 < 0)
d1 = d2;
*n = name.left(d1);
@@ -248,7 +248,7 @@ packageInfo *DEB::getIRPackageInfo( const TQString &name)
TQStringList list = kpty->run(s);
for ( TQStringList::Iterator it = list.begin(); it != list.end(); ++it ) {
// kdDebug() << "U=" << *it << "\n";
- if ((*it).tqfind("Package:") >= 0) {
+ if ((*it).find("Package:") >= 0) {
kdDebug() << "found\n";
while (it != list.begin()) {
list.remove(list.begin());
@@ -280,7 +280,7 @@ packageInfo *DEB::getUPackageInfo( const TQString &name)
TQStringList list = kpty->run(s);
for ( TQStringList::Iterator it = list.begin(); it != list.end(); ++it ) {
// kdDebug() << "U=" << *it << "\n";
- if ((*it).tqfind("Package:") >= 0) {
+ if ((*it).find("Package:") >= 0) {
// kdDebug() << "found\n";
while (it != list.begin()) {
list.remove(list.begin());
@@ -316,7 +316,7 @@ packageInfo *DEB::collectInfo(TQStringList &ln, pkgInterface *pkgInt)
for ( TQStringList::Iterator it = ln.begin(); it != ln.end(); ++it ) {
loop:
- int col = (*it).tqfind(':');
+ int col = (*it).find(':');
key = ((*it).left(col)).lower();
if (key[0] == ' ') {
key.remove(0,1);
@@ -354,7 +354,7 @@ packageInfo *DEB::collectInfo(TQStringList &ln, pkgInterface *pkgInt)
} else if (key == "section") {
a.insert("group", val);
} else if (key == "status") {
- if ((val.tqfind("not-installed") >= 0) || (val.tqfind("config-files") >= 0)) {
+ if ((val.find("not-installed") >= 0) || (val.find("config-files") >= 0)) {
return 0;
}
if (val != "install ok installed" &&
@@ -492,7 +492,7 @@ TQStringList DEB::getUFileList(const TQString &fn)
it != filelist.end(); ++it ) {
// kdDebug() << "F=" << *it << "\n";
if (pt < 0) {
- pt = (*it).tqfindRev(' ');
+ pt = (*it).findRev(' ');
}
(*it) = (*it).mid(pt + 1);
}
@@ -509,14 +509,14 @@ TQStringList DEB::FindFile(const TQString &name, bool)
TQStringList filelist = kpty->run(s);
for ( TQStringList::Iterator it = filelist.begin(); it != filelist.end(); ++it ) {
- int p = (*it).tqfind(": ");
+ int p = (*it).find(": ");
if( p !=-1 )
- (*it).tqreplace(p, 2, "\t");
+ (*it).replace(p, 2, "\t");
}
if (filelist.count() == 1) {
TQStringList::Iterator it = filelist.begin();
- if ((*it).tqfind("not found") >= 0) {
+ if ((*it).find("not found") >= 0) {
filelist.remove(it);
}
}
diff --git a/kpackage/fbsdInterface.cpp b/kpackage/fbsdInterface.cpp
index cab1b8a..7ad7dbf 100644
--- a/kpackage/fbsdInterface.cpp
+++ b/kpackage/fbsdInterface.cpp
@@ -145,7 +145,7 @@ packageInfo *fbsdInterface::getPackageInfo(char mode, const TQString &pname, con
cmd += name;
TQStringList list = kpty->run(cmd);
- int last_dir = name.tqfind('/');
+ int last_dir = name.find('/');
if (last_dir != -1) {
a["filename"] = name.mid(last_dir+1);
a["base"] = name.left(last_dir + 1);
@@ -335,7 +335,7 @@ TQStringList fbsdInterface::FindFile(const TQString &, bool) {
bool fbsdInterface::parseName(const TQString &name, TQString *n, TQString *v) {
int m1;
- m1 = name.tqfindRev('-');
+ m1 = name.findRev('-');
if (m1 <= 0) return false;
*n = name.left(m1);
*v = name.right(name.length() - m1 - 1);
@@ -482,7 +482,7 @@ int fbsdInterface::pathInfo(TQMap<TQString, TQString> &a)
parseItem(it, name, value, INFO_SEPARATOR, list); // Information
parseItem(it, name, value, INFO_SEPARATOR, list); // Path
- int pos = value.tqfindRev('/');
+ int pos = value.findRev('/');
value.truncate(pos);
a["group"] = value;
} else {
diff --git a/kpackage/findf.cpp b/kpackage/findf.cpp
index 651b50f..84b0d7c 100644
--- a/kpackage/findf.cpp
+++ b/kpackage/findf.cpp
@@ -47,7 +47,7 @@ FindF::FindF(TQWidget *tqparent)
: KDialogBase(tqparent, "find_file", false,
i18n("Find File"),
User1 | Close, User1, true,
- KGuiItem(i18n("&Find"),"filetqfind"))
+ KGuiItem(i18n("&Find"),"filefind"))
{
tick = UserIcon("ptick");
@@ -81,7 +81,7 @@ FindF::FindF(TQWidget *tqparent)
tab->setAllColumnsShowFocus(TRUE);
tab->setSorting(1);
- if (kpackage->management->dirInstPackages->tqfind("apt-file/deb")) {
+ if (kpackage->management->dirInstPackages->find("apt-file/deb")) {
searchAll = new TQCheckBox(i18n("Also search uninstalled packages"), frame1, "searchAll");
} else {
searchAll = new TQCheckBox(i18n("Also search uninstalled packages (apt-file needs to be installed)"), frame1, "searchAll");
@@ -150,11 +150,11 @@ void FindF::doFind(const TQString &str)
cnt++;
for ( TQStringList::Iterator it = filelist.begin(); it != filelist.end(); ++it ) {
- if ((*it).tqfind("diversion by") >= 0) {
+ if ((*it).find("diversion by") >= 0) {
new TQListViewItem(tab, "", *it);
}
- int t1 = (*it).tqfind('\t');
+ int t1 = (*it).find('\t');
TQString s1 = (*it).left(t1);
TQString s2 = (*it).right((*it).length()-t1);
s2 = s2.stripWhiteSpace();
@@ -162,7 +162,7 @@ void FindF::doFind(const TQString &str)
TQListViewItem *ql = new TQListViewItem(tab, "", kpinterface[i]->name, kpinterface[i]->head, s1, s2);
TQString tx = s1 + kpinterface[i]->typeID;
- if (kpackage->management->dirInstPackages->tqfind(tx)) {
+ if (kpackage->management->dirInstPackages->find(tx)) {
ql->setPixmap(0,tick);
}
}
@@ -193,7 +193,7 @@ void FindF::search(TQListViewItem *item)
s = s.stripWhiteSpace();
kdDebug() << "searchF=" << s << "\n";
- p = s.tqfind(',');
+ p = s.find(',');
if (p > 0) {
s.truncate(p);
}
diff --git a/kpackage/kissInterface.cpp b/kpackage/kissInterface.cpp
index 31a9efc..4ed7c74 100644
--- a/kpackage/kissInterface.cpp
+++ b/kpackage/kissInterface.cpp
@@ -103,7 +103,7 @@ bool KISS::isType(char *buf, const TQString &)
{
if (hasProgram) {
TQString tmp = buf;
- if (tmp.tqfind("perl",0,false) >= 0)
+ if (tmp.find("perl",0,false) >= 0)
return true;
else
return false;
@@ -116,11 +116,11 @@ bool KISS::parseName(const TQString& name, TQString *n, TQString *v)
{
int d1, d2, s1;
- s1 = name.tqfindRev('.');
+ s1 = name.findRev('.');
if (s1 > 0) {
- d2 = name.tqfindRev('-',s1-1);
+ d2 = name.findRev('-',s1-1);
if (d2 > 0) {
- d1 = name.tqfindRev('_',d2-1);
+ d1 = name.findRev('_',d2-1);
if (d1 < 0)
d1 = d2;
*n = name.left(d1);
@@ -149,7 +149,7 @@ void KISS::listInstalledPackages(TQPtrList<packageInfo> *pki)
vb = "" ;
int sc, sp = 0;
- while ((sc = reader.buf.tqfind("\n\n",sp)) >= 0) {
+ while ((sc = reader.buf.find("\n\n",sp)) >= 0) {
if (sc+1 == (signed int)reader.buf.length())
break;
p = collectInfo(reader.buf.mid(sp,sc-sp).ascii());
diff --git a/kpackage/kpPty.cpp b/kpackage/kpPty.cpp
index bd6062a..23eb15f 100644
--- a/kpackage/kpPty.cpp
+++ b/kpackage/kpPty.cpp
@@ -257,7 +257,7 @@ void kpPty::breakUpCmd(const TQString &cmd)
if ((*it)[0] == '\'') { // Start of quoted string
s = *it;
if ((*it)[lastPt] == '\'') { // Also End of quoted string
- s.tqreplace("'","");
+ s.replace("'","");
(*pty) << s;
quote = FALSE;
} else {
@@ -266,7 +266,7 @@ void kpPty::breakUpCmd(const TQString &cmd)
}
} else if ((*it)[lastPt] == '\'') { // End of quoted string
s += *it;
- s.tqreplace("'","");
+ s.replace("'","");
(*pty) << s;
quote = FALSE;
} else if (quote) {
@@ -345,7 +345,7 @@ void kpPty::finish(int ret)
if (!retList.empty()) {
int p;
l = retList.fromLast();
- if ((p = (*l).tqfind("RESULT=")) >= 0) {
+ if ((p = (*l).find("RESULT=")) >= 0) {
ret = (*l).mid(p+7).toInt(0,10);
retList.remove(l); // Remove return code
} else {
@@ -356,7 +356,7 @@ void kpPty::finish(int ret)
if (!retList.empty()) {
l = retList.begin();
if ( l != retList.end()) {
- if ((*l).tqfind("RESULT=") >= 0) {
+ if ((*l).find("RESULT=") >= 0) {
retList.remove(l); // Remove command at start
}
}
@@ -396,7 +396,7 @@ void kpPty::readLines()
stext.truncate(stext.length()-1);
}
- i = stext.tqfindRev('\r');
+ i = stext.findRev('\r');
if (i > -1) {
stext = stext.mid(i+1);
}
diff --git a/kpackage/kpTerm.cpp b/kpackage/kpTerm.cpp
index c91f1a2..b085296 100644
--- a/kpackage/kpTerm.cpp
+++ b/kpackage/kpTerm.cpp
@@ -111,13 +111,13 @@ void kpTerm::textIn(const TQString &stext, bool bNewLine)
TQRegExp chrs("[\\010\\012\\015]");
TQString del = "\010";
// kdDebug() << "Tin=[" << stext << "]\n";
- if (stext.tqfind(chrs) < 0) {
+ if (stext.find(chrs) < 0) {
insert( stext );
} else {
int p;
int op = 0;
- while ((p = stext.tqfind(chrs,op)) >= 0) {
+ while ((p = stext.find(chrs,op)) >= 0) {
if (p != op) {
insert( stext.mid(op, p-op));
}
diff --git a/kpackage/kpackage.cpp b/kpackage/kpackage.cpp
index 670b4b6..d8d7e64 100644
--- a/kpackage/kpackage.cpp
+++ b/kpackage/kpackage.cpp
@@ -100,11 +100,11 @@ void KPKG::setupMenu()
actionCollection());
recent->loadEntries( config );
- pack_tqfind = new KAction( i18n("Find &Package..."), "tqfind",
+ pack_find = new KAction( i18n("Find &Package..."), "find",
KStdAccel::shortcut(KStdAccel::Find), TQT_TQOBJECT(kpackage),
- TQT_SLOT(tqfind()), actionCollection(), "pack_tqfind");
+ TQT_SLOT(find()), actionCollection(), "pack_find");
- pack_findf = new KAction( i18n("Find &File..."), "filetqfind",
+ pack_findf = new KAction( i18n("Find &File..."), "filefind",
0, TQT_TQOBJECT(kpackage),
TQT_SLOT(findf()), actionCollection(), "pack_findf");
@@ -196,7 +196,7 @@ void KPKG::setupMenu()
void KPKG::disableMenu()
{
pack_open->setEnabled(false);
- pack_tqfind->setEnabled(false);
+ pack_find->setEnabled(false);
pack_findf->setEnabled(false);
kpack_reload->setEnabled(false);
recent->setEnabled(false);
@@ -205,7 +205,7 @@ void KPKG::disableMenu()
void KPKG::enableMenu()
{
pack_open->setEnabled(true);
- pack_tqfind->setEnabled(true);
+ pack_find->setEnabled(true);
pack_findf->setEnabled(true);
kpack_reload->setEnabled(true);
recent->setEnabled(true);
@@ -682,7 +682,7 @@ void KPACKAGE::fileOpenUrl(){
}
}
-void KPACKAGE::tqfind(){
+void KPACKAGE::find(){
if (srchdialog)
srchdialog->show();
else
diff --git a/kpackage/kpackage.h b/kpackage/kpackage.h
index dcb55fa..b14b167 100644
--- a/kpackage/kpackage.h
+++ b/kpackage/kpackage.h
@@ -159,7 +159,7 @@ public slots:
void fileOpenUrl();
// menu item FIle->OpenUrl
- void tqfind();
+ void find();
// search for package
void findf();
@@ -230,7 +230,7 @@ class KPKG : public KMainWindow
Tfileopen = 3,
Tftout = 4,
Tftin = 5,
- Ttqfind = 6,
+ Tfind = 6,
Tfindf = 7,
Treload = 8
};
@@ -278,7 +278,7 @@ private:
TQStrList recent_files;
KAction *pack_open;
- KAction *pack_tqfind;
+ KAction *pack_find;
KAction *pack_findf;
KAction *kpack_reload;
KAction *pack_prev;
diff --git a/kpackage/kplview.cpp b/kpackage/kplview.cpp
index cf9014e..69d68d3 100644
--- a/kpackage/kplview.cpp
+++ b/kpackage/kplview.cpp
@@ -430,7 +430,7 @@ bool KpTreeList::searchChild(KpTreeListItem *it)
TQString s = it->text(0);
// kdDebug() << "s='" << s << "'='" << searchStr << "\n";
if ((it->childCount() == 0) && (it->info->display(treeType)) &&
- (searchSubstr ? s.tqcontains(searchStr,FALSE) : s == searchStr)) {
+ (searchSubstr ? s.contains(searchStr,FALSE) : s == searchStr)) {
searchResult = it;
return TRUE;
}
@@ -510,7 +510,7 @@ void KpTreeList::previous()
void KpTreeList::stackRemove(KpTreeListItem *pack)
{
- int n = stack.tqfind(pack);
+ int n = stack.find(pack);
if (n >= 0) {
if (n == 0) {
kpkg->disablePrevious();
@@ -650,11 +650,11 @@ int KpTreeListItem::compare( TQListViewItem *i, int col, bool ascending ) const
TQString k, j;
j = key( col, ascending );
- j = j.tqreplace(' ','0');
+ j = j.replace(' ','0');
j = j.rightJustify(6,'0');
k = i->key( col, ascending );
- k = k.tqreplace(' ','0');
+ k = k.replace(' ','0');
k = k.rightJustify(6,'0');
// kdDebug() << k <<"=" << j << "\n";
diff --git a/kpackage/managementWidget.cpp b/kpackage/managementWidget.cpp
index 2d30f5b..16e0ad7 100644
--- a/kpackage/managementWidget.cpp
+++ b/kpackage/managementWidget.cpp
@@ -623,7 +623,7 @@ KpTreeListItem *managementWidget::updatePackage(packageInfo *pki, bool install)
if (install) {
if (pnew) {
if (pnew->packageState != packageInfo::BAD_INSTALL) {
- ptree = dirInstPackages->tqfind(pkgId); // remove installed entry
+ ptree = dirInstPackages->find(pkgId); // remove installed entry
dirInstPackages->remove(pkgId);
if (ptree) {
if (ptree->getItem()) {
@@ -632,7 +632,7 @@ KpTreeListItem *managementWidget::updatePackage(packageInfo *pki, bool install)
}
}
- ptree = dirUninstPackages->tqfind(pkgId); // remove uninstalled entry
+ ptree = dirUninstPackages->find(pkgId); // remove uninstalled entry
if (ptree) {
ptree->packageState = packageInfo::HIDDEN;
if (ptree->getItem()) {
@@ -665,7 +665,7 @@ KpTreeListItem *managementWidget::updatePackage(packageInfo *pki, bool install)
} else {
kdDebug() << "DEL=" << name << endl;
}
- packageInfo *pb = dirUninstPackages->tqfind(pkgId);
+ packageInfo *pb = dirUninstPackages->find(pkgId);
if (pb) { // available package matching the one just uninstalled
pb->packageState = packageInfo::NEW;
q = pb->place(treeList,TRUE);
diff --git a/kpackage/options.cpp b/kpackage/options.cpp
index 16cf61f..895c75f 100644
--- a/kpackage/options.cpp
+++ b/kpackage/options.cpp
@@ -395,7 +395,7 @@ void Opts::readSettings(const TQString &initHost)
// kdDebug() << "readSettings: " << initHost << "\n";
hostList = config->readListEntry("Host_list");
- if (!initHost.isEmpty() && !hostList.tqcontains(initHost)) {
+ if (!initHost.isEmpty() && !hostList.contains(initHost)) {
hostList.prepend(initHost);
config->writeEntry("Host_list", hostList);
}
diff --git a/kpackage/packageDisplay.cpp b/kpackage/packageDisplay.cpp
index 0465d14..826a705 100644
--- a/kpackage/packageDisplay.cpp
+++ b/kpackage/packageDisplay.cpp
@@ -186,7 +186,7 @@ void packageDisplayWidget::changePackage(packageInfo *p)
if (package && package != p) {
- if (!package->getItem() && !kpackage->management->allPackages->tqfind(package)) {
+ if (!package->getItem() && !kpackage->management->allPackages->find(package)) {
delete package;
package = 0;
}
@@ -203,7 +203,7 @@ void packageDisplayWidget::changePackage(packageInfo *p)
if (np) {
TQMap<TQString, TQString>::Iterator it; // update info entries in p
for ( it = np->info.begin(); it != np->info.end(); ++it ) {
- package->info.tqreplace(it.key(),it.data());
+ package->info.replace(it.key(),it.data());
}
package->interface = np->interface;
delete np;
diff --git a/kpackage/packageInfo.cpp b/kpackage/packageInfo.cpp
index e9d1e14..aab5be2 100644
--- a/kpackage/packageInfo.cpp
+++ b/kpackage/packageInfo.cpp
@@ -209,7 +209,7 @@ int packageInfo::getDigElement(const TQString &str, int *pos)
int val = 0;
if ((s[0] >= '0') && (s[0] <= '9')) {
- nf = s.tqfind(ndig);
+ nf = s.find(ndig);
if (nf >= 0) {
val = s.left(nf).toInt();
} else {
@@ -242,7 +242,7 @@ TQString packageInfo::getNdigElement(const TQString &string, int *pos)
TQRegExp idig("[0-9]");
if ((s[0] < '0') || (s[0] > '9') ) {
- nf = s.tqfind(idig);
+ nf = s.find(idig);
if (nf < 0)
nf = s.length();
str = s.left(nf);
@@ -305,7 +305,7 @@ int packageInfo::pnewer(const TQString &s, const TQString &sp)
static bool split(TQString orig, char seperator, TQString &first, TQString &second)
{
- int pos = orig.tqfind(seperator);
+ int pos = orig.find(seperator);
if (pos > 0) {
first = orig.mid(0,pos);
second = orig.mid(pos+1);
@@ -426,7 +426,7 @@ KpTreeListItem *packageInfo::place(KpTreeList *tree, bool insertI)
cnt++;
}
- tmp = *info.tqfind("name");
+ tmp = *info.find("name");
if(item)
delete item;
@@ -509,7 +509,7 @@ bool packageInfo::smerge( const TQString &exp) {
TQDict<packageInfo> *dirInfoPackages = kpackage->management->dirInfoPackages;
TQString pname = getProperty("name") + exp;
- packageInfo *pi = dirInfoPackages->tqfind(pname);
+ packageInfo *pi = dirInfoPackages->find(pname);
if (pi) {
TQMap<TQString,TQString>::Iterator it;
@@ -554,7 +554,7 @@ bool packageInfo::pkgInsert(TQPtrList<packageInfo> *pki, const TQString &exp,
bool shouldUpdate = TRUE;
bool hidden = FALSE;
- packageInfo *pi = dirInstPackages->tqfind(pname);
+ packageInfo *pi = dirInstPackages->find(pname);
if (pi) { // installed version exists
if ((pi->packageState != BAD_INSTALL)
&& (pi->packageState != NOLIST)) {
@@ -564,14 +564,14 @@ bool packageInfo::pkgInsert(TQPtrList<packageInfo> *pki, const TQString &exp,
}
}
- packageInfo *pu = dirUninstPackages->tqfind(pname);
+ packageInfo *pu = dirUninstPackages->find(pname);
if (pu) { // available version exists
if ((pu->packageState != BAD_INSTALL)
&& (pu->packageState != NOLIST)) {
if (newer(pu) >= 0) {
shouldUpdate = FALSE;
} else if (!installed) { // If older available package exists, remove it
- dirUninstPackages->remove(*(pu->info.tqfind("name")));
+ dirUninstPackages->remove(*(pu->info.find("name")));
pki->remove(pu);
}
}
@@ -606,7 +606,7 @@ bool packageInfo::pkgInsert(TQPtrList<packageInfo> *pki, const TQString &exp,
TQString group = getProperty("group");
if (group == "NEW") {
if (pi->hasProperty("group")) {
- info.tqreplace("group",
+ info.replace("group",
pi->getProperty("group") );
}
}
diff --git a/kpackage/packageProperties.cpp b/kpackage/packageProperties.cpp
index c613a23..2062a79 100644
--- a/kpackage/packageProperties.cpp
+++ b/kpackage/packageProperties.cpp
@@ -126,7 +126,7 @@ void packagePropertiesWidget::changePackage(packageInfo *p)
// append other properties to end
TQMap<TQString, TQString>::Iterator it;
for ( it = p->info.begin(); it != p->info.end(); ++it ) {
- if (!trl.tqfind(it.key())) {
+ if (!trl.find(it.key())) {
if (!it.data().isEmpty())
cList.append(it.key());
}
@@ -154,11 +154,11 @@ void packagePropertiesWidget::changePackage(packageInfo *p)
stmp += "</td><td>";
TQString f = p->getProperty(*s);
if (*s == "maintainer" || *s == "packager") {
- f.tqreplace(TQRegExp("<"),"&lt;");
- f.tqreplace(TQRegExp(">"),"&gt;");
+ f.replace(TQRegExp("<"),"&lt;");
+ f.replace(TQRegExp(">"),"&gt;");
}
if (*s == "filename") {
- int p = f.tqfindRev("/");
+ int p = f.findRev("/");
if (p >= 0) {
f.insert(p+1,"\n");
};
@@ -211,7 +211,7 @@ void packagePropertiesWidget::dor(const TQString &f) {
}
void packagePropertiesWidget::delement(const TQString &f) {
- int n = f.tqfind("(");
+ int n = f.find("(");
if (n < 0) {
n = f.length();
}
@@ -222,9 +222,9 @@ void packagePropertiesWidget::delement(const TQString &f) {
TQString us = uf + package->interface->typeID;
bool inst = false, uninst = false;
- if (kpackage->management->dirInstPackages->tqfind(us)) {
+ if (kpackage->management->dirInstPackages->find(us)) {
inst = true;
- } else if (kpackage->management->dirUninstPackages->tqfind(us)) {
+ } else if (kpackage->management->dirUninstPackages->find(us)) {
uninst = true;
}
@@ -242,7 +242,7 @@ void packagePropertiesWidget::delement(const TQString &f) {
if (uninst)
stmp += "</i>";
if (n < (signed)f.length())
- stmp += f.mid(n).tqreplace(TQRegExp("<"),"&lt;");
+ stmp += f.mid(n).replace(TQRegExp("<"),"&lt;");
}
void packagePropertiesWidget::setSource(const TQString &name) {
@@ -262,12 +262,12 @@ void packagePropertiesWidget::setSource(const TQString &name) {
}
TQString ind = s + package->interface->typeID;
- packageInfo *p = kpackage->management->dirInstPackages->tqfind(ind);
+ packageInfo *p = kpackage->management->dirInstPackages->find(ind);
if (p) {
kpackage->management->treeList->changePack(p->getItem(), package->getItem() != 0);
} else {
kdDebug() << "nfound=" << ind << endl;
- p = kpackage->management->dirUninstPackages->tqfind(ind);
+ p = kpackage->management->dirUninstPackages->find(ind);
if (p) {
kpackage->management->treeList->changePack(p->getItem(), package->getItem() != 0);
} else {
diff --git a/kpackage/pkgOptions.cpp b/kpackage/pkgOptions.cpp
index c1be713..1ed42e1 100644
--- a/kpackage/pkgOptions.cpp
+++ b/kpackage/pkgOptions.cpp
@@ -188,9 +188,9 @@ bool pkgOptions::setup(TQPtrList<packageInfo> *pl, const TQString &)
plist.append(*it);
TQString dirIndex = *it + pkgInt->typeID;
if (installer) {
- pk = kpackage->management->dirUninstPackages->tqfind(dirIndex);
+ pk = kpackage->management->dirUninstPackages->find(dirIndex);
} else {
- pk = kpackage->management->dirInstPackages->tqfind(dirIndex);
+ pk = kpackage->management->dirInstPackages->find(dirIndex);
}
if (pk) {
// kdDebug() << "FF=" << dirIndex << "\n";
diff --git a/kpackage/rpmInterface.cpp b/kpackage/rpmInterface.cpp
index b9d6e5c..9b0401f 100644
--- a/kpackage/rpmInterface.cpp
+++ b/kpackage/rpmInterface.cpp
@@ -118,13 +118,13 @@ bool RPM::parseName(const TQString &name, TQString *n, TQString *v)
{
int d1, d2, s1, s2;
- s2 = name.tqfindRev('.');
+ s2 = name.findRev('.');
if (s2 > 0) {
- s1 = name.tqfindRev('.',s2-1);
+ s1 = name.findRev('.',s2-1);
if (s1 > 0) {
- d2 = name.tqfindRev('-',s1-1);
+ d2 = name.findRev('-',s1-1);
if (d2 > 0) {
- d1 = name.tqfindRev('-',d2-1);
+ d1 = name.findRev('-',d2-1);
if (d1 < 0)
d1 = d2;
*n = name.left(d1);
@@ -231,8 +231,8 @@ packageInfo* RPM::collectInfo(TQStringList &ln) {
} else if (name == "buildtime") {
a.insert("build-time", value);
} else if (name == "requires") {
- value = value.tqreplace(TQRegExp("\\(\\)"),"");
- value = value.tqreplace(TQRegExp("\\( \\)"),"");
+ value = value.replace(TQRegExp("\\(\\)"),"");
+ value = value.replace(TQRegExp("\\( \\)"),"");
value = value.stripWhiteSpace();
if (value.endsWith(",")) {
value.truncate(value.length()-1);
@@ -242,18 +242,18 @@ packageInfo* RPM::collectInfo(TQStringList &ln) {
int s = 0, n;
TQString t;
- if (!(*a.tqfind("name")).isEmpty()) {
- while ((n = value.tqfind(",",s)) > 0) {
+ if (!(*a.find("name")).isEmpty()) {
+ while ((n = value.find(",",s)) > 0) {
t = value.mid(s,n-s);
t = t.stripWhiteSpace();
if (!t.isEmpty())
- provides.insert(t,new TQString(*a.tqfind("name")));
+ provides.insert(t,new TQString(*a.find("name")));
s = n+1;
}
t = value.mid(s);
t = t.stripWhiteSpace();
if (!t.isEmpty())
- provides.insert(t,new TQString(*a.tqfind("name")));
+ provides.insert(t,new TQString(*a.find("name")));
value = value.stripWhiteSpace();
if (value.endsWith(",")) {
@@ -464,7 +464,7 @@ void RPM::collectDepends(packageInfo *p, const TQString &name, int src)
if (list.count() > 0) {
TQStringList::Iterator it = list.begin();
- int pt = (*it).tqfind(":");
+ int pt = (*it).find(":");
if (pt > 0) {
TQString s = (*it).mid(pt+1);
if (!s.isEmpty()) {
@@ -602,10 +602,10 @@ TQStringList RPM::FindFile(const TQString &name, bool) {
list.clear();
} else {
for ( TQStringList::Iterator it = list.begin(); it != list.end(); ++it ) {
- int p = (*it).tqfind(" ");
- int nm = (*it).tqfind(name,p);
+ int p = (*it).find(" ");
+ int nm = (*it).find(name,p);
if (nm >= 0) {
- (*it).tqreplace(p, 1, "\t");
+ (*it).replace(p, 1, "\t");
retlist.append(*it);
}
}
@@ -617,7 +617,7 @@ TQStringList RPM::FindFile(const TQString &name, bool) {
//////////////////////////////////////////////////////////////////////////////
TQString RPM::quotePath( const TQString &path) {
TQString s = path;
- s = s.tqreplace(" ","\\ ");
+ s = s.replace(" ","\\ ");
return ( "'" + s + "'" );
}
diff --git a/kpackage/search.cpp b/kpackage/search.cpp
index 8477473..a3e60ee 100644
--- a/kpackage/search.cpp
+++ b/kpackage/search.cpp
@@ -39,7 +39,7 @@ Search::Search(TQWidget *tqparent, const char * name)
: KDialogBase(tqparent, name, false,
i18n("Find Package"),
User1 | Close, User1, true,
- KGuiItem( i18n("&Find"), "tqfind"))
+ KGuiItem( i18n("&Find"), "find"))
{
TQFrame *page = makeMainWidget();
diff --git a/kpackage/slackInterface.cpp b/kpackage/slackInterface.cpp
index 49e7c64..ae51d7b 100644
--- a/kpackage/slackInterface.cpp
+++ b/kpackage/slackInterface.cpp
@@ -148,7 +148,7 @@ bool SLACK::isType(char *buf, const TQString &)
bool SLACK::parseName(const TQString &name, TQString *n, TQString *v)
{
int s1;
- s1 = name.tqfindRev('.');
+ s1 = name.findRev('.');
if (s1 > 0) {
*n = name.left(s1);
v = new TQString("");
@@ -432,15 +432,15 @@ packageInfo *SLACK::collectInfo(const char *_inp, int insState)
} else if (!strcmp("package location",str)) {
TQString sl = xstr;
if (insState != INSTALLED) {
- int sls = sl.tqfindRev("/");
+ int sls = sl.findRev("/");
if (sls >= 0) {
TQRegExp num("[0-9][0-9]*");
- int slf = sl.tqfind(num,sls);
+ int slf = sl.find(num,sls);
if (slf >= 0) {
sls++;
TQString gt = sl.mid(sls,slf-sls);
- if (trl->tqfind(gt)) {
- gt = *trl->tqfind(gt);
+ if (trl->find(gt)) {
+ gt = *trl->find(gt);
}
a.insert("group",gt);
}
@@ -643,7 +643,7 @@ TQStringList SLACK::FindFile(const TQString &name, bool)
}
}
while (fgets(linebuf,sizeof(linebuf),file)) {
- if (TQString(TQString::fromLocal8Bit(linebuf)).tqfind(name) != -1) {
+ if (TQString(TQString::fromLocal8Bit(linebuf)).find(name) != -1) {
st = "/";
st += linebuf;
st.truncate(st.length() -1);