File 09-disable-autoscan.patch of Package klamav

diff -Nur -x '*.orig' -x '*~' klamav-0.45/src/configdialog.cpp klamav-0.45.new/src/configdialog.cpp
--- klamav-0.45/src/configdialog.cpp	2009-02-17 15:51:40.000000000 -0500
+++ klamav-0.45.new/src/configdialog.cpp	2009-02-18 15:11:45.000000000 -0500
@@ -61,7 +61,7 @@
     addPage( m_archivelimits, i18n( "Archive Limits" ), "ark", i18n( "Configure Archive Limits" ) );
     addPage( m_archivetypes,   i18n( "Archive Types" ), "tgz", i18n( "Configure Archive Types" ) );
     addPage( m_specialfiletypes, i18n( "File Types" ), "folder", i18n( "Configure File Types" ) );
-    addPage( m_autoscanoptions, i18n( "Auto-Scan" ), "filefind", i18n( "Configure Auto-Scan" ) );
+    //addPage( m_autoscanoptions, i18n( "Auto-Scan" ), "filefind", i18n( "Configure Auto-Scan" ) );
     addPage( m_logoptions, i18n( "Event Logging" ), "kate", i18n( "Configure Events to Log" ) );
 
     QObjectList *list = queryList( "QLabel", "infoPixmap" );
diff -Nur -x '*.orig' -x '*~' klamav-0.45/src/klamav.cpp klamav-0.45.new/src/klamav.cpp
--- klamav-0.45/src/klamav.cpp	2009-02-18 15:11:44.000000000 -0500
+++ klamav-0.45.new/src/klamav.cpp	2009-02-18 15:18:36.000000000 -0500
@@ -52,24 +52,24 @@
 	connect(_tray,SIGNAL(quitSelected()),SLOT(shuttingDown()));
 	
 	KPopupMenu *conf_menu = _tray->contextMenu();
-    EnableKlamd = new KAction(i18n("&Enable Auto-Scan"), "klamav_on_acc_enabled", 0,this, SLOT(contextEnable()),actionCollection(),"klamd_enable");
-    DisableKlamd = new KAction(i18n("&Disable Auto-Scan"),"klamav_on_acc_disabled", 0,this, SLOT(contextDisable()),actionCollection(),"klamd_disable");
+    //EnableKlamd = new KAction(i18n("&Enable Auto-Scan"), "klamav_on_acc_enabled", 0,this, SLOT(contextEnable()),actionCollection(),"klamd_enable");
+    //DisableKlamd = new KAction(i18n("&Disable Auto-Scan"),"klamav_on_acc_disabled", 0,this, SLOT(contextDisable()),actionCollection(),"klamd_disable");
         
 	EnableFreshklam = new KAction(i18n("&Enable Auto-Updates"), "klamav", 0,this, SLOT(contextEnableFK()),actionCollection(),"fk_enable");
     DisableFreshklam = new KAction(i18n("&Disable Auto-Updates"),"klamavbw", 0,this, SLOT(contextDisableFK()),actionCollection(),"fk_disable");
 
 	EnableFreshklam->plug(conf_menu);
 	DisableFreshklam->plug(conf_menu);
-	EnableKlamd->plug(conf_menu);
-	DisableKlamd->plug(conf_menu);
+	//EnableKlamd->plug(conf_menu);
+	//DisableKlamd->plug(conf_menu);
 	
 	QToolTip::add( _tray, i18n( "KlamAV - Virus Protection for KDE" ) );
 	_tray->show();
 	
 	DisableFreshklam->setEnabled(FALSE);
 	EnableFreshklam->setEnabled(TRUE);
-	DisableKlamd->setEnabled(FALSE);
-	EnableKlamd->setEnabled(TRUE);
+	//DisableKlamd->setEnabled(FALSE);
+	//EnableKlamd->setEnabled(TRUE);
 
         KConfig* config = KGlobal::config();
         config->setGroup("Freshklam");
@@ -88,11 +88,11 @@
 	klamscan = new Klamscan(this);
 	tab->addTab(klamscan, i18n("&Scan"));
 
-	klamd = new Klamd(this);
-	tab->addTab(klamd, i18n("&Auto-Scan"));
+	//klamd = new Klamd(this);
+	//tab->addTab(klamd, i18n("&Auto-Scan"));
 
-	connect(klamd->search_button,SIGNAL(clicked()),SLOT(contextEnable()));
-	connect(klamd->cancel_button,SIGNAL(clicked()),SLOT(contextDisable()));
+	//connect(klamd->search_button,SIGNAL(clicked()),SLOT(contextEnable()));
+	//connect(klamd->cancel_button,SIGNAL(clicked()),SLOT(contextDisable()));
 
 		
 	freshklam = new Freshklam(this);
@@ -172,14 +172,15 @@
 }
 
 bool Klamav::queryClose() {
-	if ((klamd->isKlamdAlive()) || (freshklam->isFreshklamAlive())){
+/*	if (freshklam->isFreshklamAlive()){
         KMessageBox::information (this,i18n("<p>KlamAV will stay open in the system tray. <br><br>"
-        " <b>Remember</b> - you can't close KlamAV while <br> auto-scanning "
-        " and/or auto-updating are still running!</p>"),"KlamAV","dontshow");
+        " <b>Remember</b> - you can't close KlamAV while <br> "
+        " auto-updating is still running!</p>"),"KlamAV","dontshow");
 		hide();
 		return false;
 
 	}
+*/
 	return true;
 }
 
@@ -213,8 +214,8 @@
 		_tray->setPixmap(KSystemTray::loadIcon("klamavbwdl"));
 	else*/
 	_tray->setPixmap(KSystemTray::loadIcon("klamav_on_acc_disabled"));
-	DisableKlamd->setEnabled(FALSE);
-	EnableKlamd->setEnabled(TRUE);
+	//DisableKlamd->setEnabled(FALSE);
+	//EnableKlamd->setEnabled(TRUE);
 }
 
 
diff -Nur -x '*.orig' -x '*~' klamav-0.45/src/klamd.cpp klamav-0.45.new/src/klamd.cpp
--- klamav-0.45/src/klamd.cpp	2009-02-17 15:51:40.000000000 -0500
+++ klamav-0.45.new/src/klamd.cpp	2009-02-18 15:11:45.000000000 -0500
@@ -912,8 +912,8 @@
 }
 
 bool  Klamd::isKlamdAlive(){
-	if (klamdAlive)
-		return true;
+	//if (klamdAlive)
+	//	return true;
 	return false;
 
 }
openSUSE Build Service is sponsored by