summaryrefslogtreecommitdiffstats
path: root/src/freshklam.cpp
diff options
context:
space:
mode:
authorMavridis Philippe <mavridisf@gmail.com>2021-01-13 19:30:17 +0200
committerMavridis Philippe <mavridisf@gmail.com>2021-01-13 19:30:17 +0200
commit357ddeb8afd82d69ef871c146f4fc8f2c67fb17e (patch)
treedc3ef0e6fedd64f5fb177c114f72e1515a07cd1b /src/freshklam.cpp
parentc6cbd71bc169ac0e927e52325dbbbcb506abbc73 (diff)
downloadklamav-357ddeb8afd82d69ef871c146f4fc8f2c67fb17e.tar.gz
klamav-357ddeb8afd82d69ef871c146f4fc8f2c67fb17e.zip
Conversion Qt3->TQt
Signed-off-by: Mavridis Philippe <mavridisf@gmail.com>
Diffstat (limited to 'src/freshklam.cpp')
-rw-r--r--src/freshklam.cpp178
1 files changed, 89 insertions, 89 deletions
diff --git a/src/freshklam.cpp b/src/freshklam.cpp
index e356939..77bfe27 100644
--- a/src/freshklam.cpp
+++ b/src/freshklam.cpp
@@ -18,12 +18,12 @@
#include <kaction.h>
-#include <qcheckbox.h>
+#include <tqcheckbox.h>
#include <kbuttonbox.h>
#include <kurlrequester.h>
#include <kurlcompletion.h>
#include <kcombobox.h>
-#include <qlayout.h>
+#include <tqlayout.h>
#include <kmessagebox.h>
#include <klineedit.h>
#include <ktempfile.h>
@@ -37,7 +37,7 @@
#include <dcopclient.h>
#include <kuser.h>
-#include <qtimer.h>
+#include <tqtimer.h>
#include <clamav.h>
#include "version.h"
@@ -74,10 +74,10 @@ const char *check_desc[] = {
};
-QString readymessage = i18n("KlamAV ") + KLAMAV_VERSION + i18n(" - Ready");
+TQString readymessage = i18n("KlamAV ") + KLAMAV_VERSION + i18n(" - Ready");
-Freshklam::Freshklam(QWidget *parent, const char *name)
- : QWidget(parent, name)
+Freshklam::Freshklam(TQWidget *parent, const char *name)
+ : TQWidget(parent, name)
{
// MetaDB* updater = new MetaDB();
@@ -98,27 +98,27 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
lastDownloadPaths = config->readListEntry("lastDownloadPaths");
getCurrentVersionOfClamAV( );
- if ((lastDownloadPaths.isEmpty()) || (!(KIO::NetAccess::exists(QString((*lastDownloadPaths.begin())),TRUE,NULL)))){
+ if ((lastDownloadPaths.isEmpty()) || (!(KIO::NetAccess::exists(TQString((*lastDownloadPaths.begin())),TRUE,NULL)))){
createDBDir();
}
- QString proxyIPText = config->readEntry("ProxyIP");
- QString proxyPortText = config->readEntry("ProxyPort");
- QString proxyUserText = config->readEntry("ProxyUser");
- QString proxyPassText = config->readEntry("ProxyPass");
+ TQString proxyIPText = config->readEntry("ProxyIP");
+ TQString proxyPortText = config->readEntry("ProxyPort");
+ TQString proxyUserText = config->readEntry("ProxyUser");
+ TQString proxyPassText = config->readEntry("ProxyPass");
//Data Directory Widget
- QVBoxLayout *vbox = new QVBoxLayout(this, KDialog::marginHint(),
+ TQVBoxLayout *vbox = new TQVBoxLayout(this, KDialog::marginHint(),
KDialog::spacingHint(), "vbox");
//Proxy Widget
- QGroupBox *software_group = new QGroupBox(i18n("Software Updates"), this);
+ TQGroupBox *software_group = new TQGroupBox(i18n("Software Updates"), this);
vbox->addWidget(software_group);
- QGridLayout *software_layout = new QGridLayout( software_group, 5, 2, KDialog::spacingHint(),
+ TQGridLayout *software_layout = new TQGridLayout( software_group, 5, 2, KDialog::spacingHint(),
KDialog::spacingHint(), "software_layout");
software_layout->addRowSpacing(0, software_group->fontMetrics().height());
software_layout->setColStretch(0, 1);
@@ -126,28 +126,28 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
//Dazuko
- QWidget *dazuko_hlp = new QWidget( software_group );
+ TQWidget *dazuko_hlp = new TQWidget( software_group );
software_layout->addMultiCellWidget(dazuko_hlp, 1,2, 0,2);
- QGridLayout *dazuko_dir_layout = new QGridLayout(dazuko_hlp,2,2, KDialog::spacingHint() );
+ TQGridLayout *dazuko_dir_layout = new TQGridLayout(dazuko_hlp,2,2, KDialog::spacingHint() );
- clamav_box = new QCheckBox(i18n("Update ClamAV Automatically"), dazuko_hlp);
+ clamav_box = new TQCheckBox(i18n("Update ClamAV Automatically"), dazuko_hlp);
clamav_box->setMinimumWidth(clamav_box->sizeHint().width());
dazuko_dir_layout->addWidget(clamav_box,0,0);
- klamav_box = new QCheckBox(i18n("Update KlamAV Automatically"), dazuko_hlp);
+ klamav_box = new TQCheckBox(i18n("Update KlamAV Automatically"), dazuko_hlp);
klamav_box->setMinimumWidth(klamav_box->sizeHint().width());
dazuko_dir_layout->addWidget(klamav_box,0,1);
- clamav_options = new QPushButton (i18n( "Upgrade ClamAV Now" ), dazuko_hlp);
+ clamav_options = new TQPushButton (i18n( "Upgrade ClamAV Now" ), dazuko_hlp);
dazuko_dir_layout->addWidget(clamav_options,1,0);
clamav_options->setFixedSize(clamav_options->sizeHint());
connect( clamav_options, SIGNAL( clicked() ), this,
SLOT( checkForNewClamAVNow() ) );
- klamav_options = new QPushButton (i18n( "Upgrade KlamAV Now" ), dazuko_hlp);
+ klamav_options = new TQPushButton (i18n( "Upgrade KlamAV Now" ), dazuko_hlp);
dazuko_dir_layout->addWidget(klamav_options,1,1);
klamav_options->setFixedSize(klamav_options->sizeHint());
connect( klamav_options, SIGNAL( clicked() ), this,
@@ -160,11 +160,11 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
klamav_options->setEnabled(false);
#endif
//Virus Database Directory
- QGroupBox *group = new QGroupBox(i18n("Virus Database Directory"), this);
+ TQGroupBox *group = new TQGroupBox(i18n("Virus Database Directory"), this);
vbox->addWidget(group);
- QGridLayout *layout = new QGridLayout( group, 9, 2, KDialog::spacingHint(),
+ TQGridLayout *layout = new TQGridLayout( group, 9, 2, KDialog::spacingHint(),
KDialog::spacingHint(), "layout");
layout->addRowSpacing(0, group->fontMetrics().height());
@@ -172,44 +172,44 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
layout->setColStretch(1, 1);
- QWidget *hlp = new QWidget( group );
+ TQWidget *hlp = new TQWidget( group );
layout->addMultiCellWidget(hlp, 1,1, 0,1);
- QHBoxLayout *dir_layout = new QHBoxLayout(hlp,KDialog::spacingHint() );
+ TQHBoxLayout *dir_layout = new TQHBoxLayout(hlp,KDialog::spacingHint() );
dir_combo = new KURLRequester( new KComboBox(true, this), hlp, "dir combo" );
dir_combo->completionObject()->setMode(KURLCompletion::DirCompletion);
dir_combo->comboBox()->insertStringList(lastDownloadPaths);
dir_combo->setMode( KFile::Directory|KFile::LocalOnly );
- QLabel *dir_label = new QLabel(i18n("Directory:"), hlp);
+ TQLabel *dir_label = new TQLabel(i18n("Directory:"), hlp);
dir_label->setFixedSize(dir_label->sizeHint());
dir_layout->addWidget(dir_label);
dir_layout->addWidget(dir_combo);
//Proxy Widget
- QGroupBox *proxy_group = new QGroupBox(i18n("Proxy for Database Updates"), this);
+ TQGroupBox *proxy_group = new TQGroupBox(i18n("Proxy for Database Updates"), this);
vbox->addWidget(proxy_group);
- QGridLayout *proxy_layout = new QGridLayout( proxy_group, 2, 5, KDialog::spacingHint(),
+ TQGridLayout *proxy_layout = new TQGridLayout( proxy_group, 2, 5, KDialog::spacingHint(),
KDialog::spacingHint(), "proxy_layout");
proxy_layout->addRowSpacing(0, proxy_group->fontMetrics().height());
proxy_layout->setColStretch(0, 1);
proxy_layout->setColStretch(1, 1);
//IP Address & Port
- QWidget *proxy_hlp = new QWidget( proxy_group );
+ TQWidget *proxy_hlp = new TQWidget( proxy_group );
proxy_layout->addMultiCellWidget(proxy_hlp, 1,2, 0,2);
- QGridLayout *proxy_dir_layout = new QGridLayout(proxy_hlp, 2,4,KDialog::spacingHint() );
+ TQGridLayout *proxy_dir_layout = new TQGridLayout(proxy_hlp, 2,4,KDialog::spacingHint() );
- QLabel *proxy_dir_label = new QLabel(i18n("IP Address:"), proxy_hlp);
+ TQLabel *proxy_dir_label = new TQLabel(i18n("IP Address:"), proxy_hlp);
//proxy_dir_label->setFixedSize(proxy_dir_label->sizeHint());
proxy_dir_layout->addWidget(proxy_dir_label,0,0);
proxyIP = new KLineEdit(proxy_hlp);
proxy_dir_layout->addWidget(proxyIP,0,1);
proxyIP->setText(proxyIPText);
- QLabel *proxy_port_label = new QLabel(i18n("Port:"), proxy_hlp);
+ TQLabel *proxy_port_label = new TQLabel(i18n("Port:"), proxy_hlp);
//proxy_port_label->setFixedSize(proxy_port_label->sizeHint());
proxy_dir_layout->addWidget(proxy_port_label,0,3);
proxyPort = new KLineEdit(proxy_hlp);
@@ -217,14 +217,14 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
proxyPort->setText(proxyPortText);
- QLabel *proxy_user_label = new QLabel(i18n("User:"), proxy_hlp);
+ TQLabel *proxy_user_label = new TQLabel(i18n("User:"), proxy_hlp);
//proxy_user_label->setFixedSize(proxy_user_label->sizeHint());
proxy_dir_layout->addWidget(proxy_user_label,1,0);
proxyUser = new KLineEdit(proxy_hlp);
proxy_dir_layout->addWidget(proxyUser,1,1);
proxyUser->setText(proxyUserText);
- QLabel *proxy_pass_label = new QLabel(i18n("Password:"), proxy_hlp);
+ TQLabel *proxy_pass_label = new TQLabel(i18n("Password:"), proxy_hlp);
//proxy_pass_label->setFixedSize(proxy_pass_label->sizeHint());
proxy_dir_layout->addWidget(proxy_pass_label,1,3);
proxyPass = new KLineEdit(proxy_hlp);
@@ -234,11 +234,11 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
//Daemon Widget
- QGroupBox *daemon_group = new QGroupBox(i18n("Database AutoUpdate Settings"), this);
+ TQGroupBox *daemon_group = new TQGroupBox(i18n("Database AutoUpdate Settings"), this);
vbox->addWidget(daemon_group);
- QGridLayout *daemon_layout = new QGridLayout( daemon_group, 5, 4, KDialog::spacingHint(),
+ TQGridLayout *daemon_layout = new TQGridLayout( daemon_group, 5, 4, KDialog::spacingHint(),
KDialog::spacingHint(), "daemon_layout");
daemon_layout->addRowSpacing(0, daemon_group->fontMetrics().height());
daemon_layout->addRowSpacing(1, daemon_group->fontMetrics().height());
@@ -246,18 +246,18 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
//daemon_layout->setColStretch(1, 1);
- QWidget *daemonhlp = new QWidget( daemon_group );
+ TQWidget *daemonhlp = new TQWidget( daemon_group );
daemon_layout->addMultiCellWidget(daemonhlp, 1,1, 0,1);
- QHBoxLayout *daemon_check_layout = new QHBoxLayout(daemonhlp, KDialog::spacingHint() );
- daemon_box = new QCheckBox(i18n("Update Virus Database Automatically"), daemonhlp);
+ TQHBoxLayout *daemon_check_layout = new TQHBoxLayout(daemonhlp, KDialog::spacingHint() );
+ daemon_box = new TQCheckBox(i18n("Update Virus Database Automatically"), daemonhlp);
daemon_box->setMinimumWidth(daemon_box->sizeHint().width());
daemon_check_layout->addSpacing(10);
daemon_check_layout->addWidget(daemon_box);
- check_combo = new QComboBox(false, daemonhlp);
+ check_combo = new TQComboBox(false, daemonhlp);
check_combo->insertStrList(check_desc);
if (!(config->readEntry("NoOfUpdates").isEmpty()))
check_combo->setCurrentText(config->readEntry("NoOfUpdates"));
@@ -267,13 +267,13 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
- QLabel *combo_label = new QLabel(i18n("Times a Day"), daemonhlp);
+ TQLabel *combo_label = new TQLabel(i18n("Times a Day"), daemonhlp);
//combo_label->setFixedSize(combo_label->sizeHint());
daemon_check_layout->addWidget(combo_label);
- KButtonBox *actionbox = new KButtonBox(this, Qt::Horizontal);
+ KButtonBox *actionbox = new KButtonBox(this, TQt::Horizontal);
vbox->addWidget(actionbox, 2, 0);
actionbox->addStretch();
search_button = actionbox->addButton(i18n("&Update Now"));
@@ -283,11 +283,11 @@ Freshklam::Freshklam(QWidget *parent, const char *name)
actionbox->addStretch();
actionbox->layout();
- QFrame *status_frame = new QFrame(this);
- status_frame->setFrameStyle(QFrame::Panel | QFrame::Sunken);
- QBoxLayout *status_layout = new QHBoxLayout(status_frame, 2);
+ TQFrame *status_frame = new TQFrame(this);
+ status_frame->setFrameStyle(TQFrame::Panel | TQFrame::Sunken);
+ TQBoxLayout *status_layout = new TQHBoxLayout(status_frame, 2);
- status_label = new QLabel(readymessage, status_frame);
+ status_label = new TQLabel(readymessage, status_frame);
status_layout->addWidget(status_label, 10);
status_layout->activate();
@@ -318,14 +318,14 @@ void Freshklam::processOutput()
{
int pos;
int pos2;
- QString item2;
+ TQString item2;
while (( (pos = buf.find('\n')) != -1) || ( (pos = buf.find(']')) != -1))
{
- QString item = buf.left(pos);
- QDate today = QDate::currentDate();
- QTime now = QTime::currentTime();
- QString suffix = QString("%1 %2")
+ TQString item = buf.left(pos);
+ TQDate today = TQDate::currentDate();
+ TQTime now = TQTime::currentTime();
+ TQString suffix = TQString("%1 %2")
.arg(today.toString("ddd MMMM d yyyy"))
.arg(now.toString("hh:mm:ss ap : "));
@@ -361,7 +361,7 @@ void Freshklam::processOutput()
kmain->_tray->setPixmap(KSystemTray::loadIcon("klamav_update_required"));
pos2 = item2.find('\n',pos);
- QString version = item2.mid((pos+20),pos2 - (pos+20)).stripWhiteSpace();
+ TQString version = item2.mid((pos+20),pos2 - (pos+20)).stripWhiteSpace();
if ((clamav_box->isChecked())){
@@ -374,7 +374,7 @@ void Freshklam::processOutput()
updater->downloadComponent("clamav",version,"tar.gz");
}
}else if (!(clamav_box->isChecked()))
- KNotifyClient::event(kmain->_tray->winId(),"ClamAVOutDated", QString("Your copy of ClamAV is out of date! Please Upgrade to ClamAV %1!").arg(version));
+ KNotifyClient::event(kmain->_tray->winId(),"ClamAVOutDated", TQString("Your copy of ClamAV is out of date! Please Upgrade to ClamAV %1!").arg(version));
}
@@ -387,7 +387,7 @@ void Freshklam::slotSearch()
search_button->setEnabled(false);
cancel_button->setEnabled(true);
- QString filepattern = dir_combo->url();
+ TQString filepattern = dir_combo->url();
CollectionDB::instance()->insertEvent("Updates","Commencing DB Update", filepattern);
@@ -395,9 +395,9 @@ void Freshklam::slotSearch()
childproc = new KShellProcess();
- QString command = "freshclam --stdout ";
+ TQString command = "freshclam --stdout ";
- QString user = KUser().loginName();
+ TQString user = KUser().loginName();
command += " --user=" + user + " ";
if (!(filepattern.isEmpty())){
@@ -424,7 +424,7 @@ void Freshklam::slotSearch()
if (!(KApplication::kApplication()->isRestored())){
if (kmain->klamd->isKlamdAlive()){
- QString klamdconf = kmain->klamd->getKlamdConfFile();
+ TQString klamdconf = kmain->klamd->getKlamdConfFile();
////kdDebug() << klamdconf << endl;
command += " --daemon-notify=";
command += klamdconf;
@@ -488,8 +488,8 @@ void Freshklam::finish()
void Freshklam::updateMetaDB()
{
- QDate latestDate = QDate::fromString(CollectionDB::instance()->latestMetaDBDate(),Qt::ISODate);
- QDate today = QDate::currentDate();
+ TQDate latestDate = TQDate::fromString(CollectionDB::instance()->latestMetaDBDate(),TQt::ISODate);
+ TQDate today = TQDate::currentDate();
kdDebug() << latestDate << " " << today << endl;
if (latestDate.daysTo(today) > 31){
@@ -618,29 +618,29 @@ void Freshklam::updateMailClient()
KConfig* mailconfig = new KConfig("kmailrc");
mailconfig->setGroup("General");
- QVariant nooffilters = mailconfig->readEntry("filters");
+ TQVariant nooffilters = mailconfig->readEntry("filters");
int result;
int numfilters = nooffilters.toInt();
nooffilters = numfilters;
for (int j=0; j != numfilters; j++ ){
- QVariant numb = j;
- QString filtername=QString("Filter #%1").arg(numb.toString());
+ TQVariant numb = j;
+ TQString filtername=TQString("Filter #%1").arg(numb.toString());
mailconfig->setGroup(filtername);
- QString binary = mailconfig->readEntry("action-args-0");
+ TQString binary = mailconfig->readEntry("action-args-0");
if (binary.find("klammail") != -1){
- QString pathonly = binary.section(" ",2,2);
+ TQString pathonly = binary.section(" ",2,2);
if (pathonly == dir_combo->url())
break;
if (binary.find(" " + dir_combo->url() + " ") == -1){
- QString path = getenv("HOME");
- result = KMessageBox::warningContinueCancelList(this, i18n( "Since you have changed the database location, KlamAV needs to change the parameters used for mail scanning in KMail. The change is displayed below. If you have KMail open you will need to close it now so that the change can take effect. If you want to make the change manually just click 'Cancel'. "),QString("New filter command: klammail -d %1").arg(dir_combo->url()),i18n( "Update KMail Filters" ),i18n( "Update" ));
+ TQString path = getenv("HOME");
+ result = KMessageBox::warningContinueCancelList(this, i18n( "Since you have changed the database location, KlamAV needs to change the parameters used for mail scanning in KMail. The change is displayed below. If you have KMail open you will need to close it now so that the change can take effect. If you want to make the change manually just click 'Cancel'. "),TQString("New filter command: klammail -d %1").arg(dir_combo->url()),i18n( "Update KMail Filters" ),i18n( "Update" ));
switch (result) {
case 2 : KMessageBox::information (this,"KMail has not been updated with the new database location."); break;
case 5 :
- mailconfig->writeEntry("action-args-0",QString("klammail -d %1").arg(dir_combo->url()));
+ mailconfig->writeEntry("action-args-0",TQString("klammail -d %1").arg(dir_combo->url()));
mailconfig->sync();
break;
@@ -657,7 +657,7 @@ void Freshklam::updateMailClient()
void Freshklam::receivedOutput(KProcess */*proc*/, char *buffer, int buflen)
{
//kdDebug() << buffer << endl;
- buf += QCString(buffer, buflen+1);
+ buf += TQCString(buffer, buflen+1);
processOutput();
}
@@ -672,7 +672,7 @@ void Freshklam::slotClear()
}
-void Freshklam::setDirName(QString dir){
+void Freshklam::setDirName(TQString dir){
// dir_combo->setEditText(dir);
dir_combo->setURL(dir);
}
@@ -692,20 +692,20 @@ void Freshklam::writeConf()
//tf->setAutoDelete(TRUE);
tempFileName = tf.name();
- QTextStream &ts = *(tf.textStream());
+ TQTextStream &ts = *(tf.textStream());
ts << "DatabaseMirror database.clamav.net" << "\n";
ts << "DNSDatabaseInfo current.cvd.clamav.net" << "\n";
ts << "Foreground True" << "\n";
if ( (proxyIP->hasAcceptableInput()) && (!(proxyIP->text().isEmpty()))) {
- ts << QString("HTTPProxyServer %1").arg(proxyIP->text()) << "\n";
+ ts << TQString("HTTPProxyServer %1").arg(proxyIP->text()) << "\n";
if ( proxyPort->hasAcceptableInput() ) {
- ts << QString("HTTPProxyPort %1").arg(proxyPort->text()) << "\n";
+ ts << TQString("HTTPProxyPort %1").arg(proxyPort->text()) << "\n";
}
if ( proxyUser->hasAcceptableInput() && ! proxyUser->text().isEmpty() ) {
- ts << QString("HTTPProxyUsername %1").arg(proxyUser->text()) << "\n";
+ ts << TQString("HTTPProxyUsername %1").arg(proxyUser->text()) << "\n";
if ( proxyPass->hasAcceptableInput() ) {
- ts << QString("HTTPProxyPassword %1").arg(proxyPass->text()) << "\n";
+ ts << TQString("HTTPProxyPassword %1").arg(proxyPass->text()) << "\n";
}
}
}
@@ -777,11 +777,11 @@ void Freshklam::handleChecks(){
bool Freshklam::killPID(){
- QFile inf(pidFileName);
+ TQFile inf(pidFileName);
if (!inf.open(IO_ReadOnly))
return false;
- QTextStream is(&inf);
- QString line;
+ TQTextStream is(&inf);
+ TQString line;
while (!is.eof())
line = is.readLine();
inf.close();
@@ -822,18 +822,18 @@ void Freshklam::enableInputs(){
proxyPass->setEnabled(true);
}
-QString Freshklam::getCurrentDBDir(){
+TQString Freshklam::getCurrentDBDir(){
unsigned int ret= 0;
unsigned int no = 0;
struct cl_engine *engine = NULL;
- QStringList lastDownloadPaths;
- QString dbdir;
- QString db;
+ TQStringList lastDownloadPaths;
+ TQString dbdir;
+ TQString db;
config = KGlobal::config();
config->setGroup("Freshklam");
lastDownloadPaths = config->readListEntry("lastDownloadPaths");
- for (QStringList::Iterator ita = lastDownloadPaths.begin(); ita == lastDownloadPaths.begin() ; ita++){
+ for (TQStringList::Iterator ita = lastDownloadPaths.begin(); ita == lastDownloadPaths.begin() ; ita++){
dbdir = *ita;
}
@@ -866,18 +866,18 @@ QString Freshklam::getCurrentDBDir(){
void Freshklam::createDBDir(){
- QString path = getenv("HOME");
+ TQString path = getenv("HOME");
bool ok = true;
// directory exist?
path += "/.klamav";
- QDir klamavdir(path);
+ TQDir klamavdir(path);
if (!klamavdir.exists() && !klamavdir.mkdir(path))
ok = false;
path += "/database";
if (ok)
{
- QDir klamavqdir(path);
+ TQDir klamavqdir(path);
if (!klamavqdir.exists() && !klamavqdir.mkdir(path))
ok = false;
else
@@ -885,7 +885,7 @@ void Freshklam::createDBDir(){
}
if (ok){
- lastDownloadPaths.prepend( QString("%1").arg(path));
+ lastDownloadPaths.prepend( TQString("%1").arg(path));
config = KGlobal::config();
config->setGroup("Freshklam");
config->writeEntry("lastDownloadPaths", lastDownloadPaths);
@@ -894,7 +894,7 @@ void Freshklam::createDBDir(){
}
- KMessageBox::information (this,QString(ok ? i18n( "Your Virus Database location has been set up as '%1'. You can change this to something else if you want to." ) : i18n( "I cannot create the directory '%1' for you. Something is wrong with your HOME or klamav directory. You have to adjust your Virus Database directory by your self." )).arg(path));
+ KMessageBox::information (this,TQString(ok ? i18n( "Your Virus Database location has been set up as '%1'. You can change this to something else if you want to." ) : i18n( "I cannot create the directory '%1' for you. Something is wrong with your HOME or klamav directory. You have to adjust your Virus Database directory by your self." )).arg(path));
if (ok){
int result = KMessageBox::warningContinueCancel(this, i18n( "Would you like to download the latest Virus Database to your new database location now? (You can do this later manually if you want.)"),i18n( "Download Virus Database" ),i18n( "Download" ));
@@ -982,7 +982,7 @@ Freshklam::getCurrentVersionOfClamAV( )
{
////kdDebug() << "version clamav" << endl;
- QString suCommand=QString("clamscan -V");
+ TQString suCommand=TQString("clamscan -V");
versionproc = new KProcIO();
versionproc->setUseShell(TRUE);
@@ -1007,7 +1007,7 @@ void Freshklam::versionExited()
void Freshklam::readVersionLine(KProcIO *)
{
- QString lineout = "";
+ TQString lineout = "";
int pos;
if ((pos = (versionproc->readln(lineout))) != -1) {
@@ -1015,7 +1015,7 @@ void Freshklam::readVersionLine(KProcIO *)
lineout = lineout.stripWhiteSpace();
int StartPoint = (lineout.find("ClamAV") + 6);
int EndPoint = lineout.find("/");
- QString currentClamAVVersion = lineout.mid(StartPoint,(EndPoint - StartPoint));
+ TQString currentClamAVVersion = lineout.mid(StartPoint,(EndPoint - StartPoint));
currentClamAVVersion = currentClamAVVersion.stripWhiteSpace();
KlamavConfig::setClamAVVersion(currentClamAVVersion);
KlamavConfig::writeConfig();