aboutsummaryrefslogtreecommitdiff
path: root/src-qt5/core-utils/lumina-search
diff options
context:
space:
mode:
Diffstat (limited to 'src-qt5/core-utils/lumina-search')
-rw-r--r--src-qt5/core-utils/lumina-search/MainUI.cpp4
-rw-r--r--src-qt5/core-utils/lumina-search/Worker.cpp3
2 files changed, 5 insertions, 2 deletions
diff --git a/src-qt5/core-utils/lumina-search/MainUI.cpp b/src-qt5/core-utils/lumina-search/MainUI.cpp
index 93ee7411..b3e28f8a 100644
--- a/src-qt5/core-utils/lumina-search/MainUI.cpp
+++ b/src-qt5/core-utils/lumina-search/MainUI.cpp
@@ -17,7 +17,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){
ui->tool_configure->setVisible(false); //app search initially set
livetime = new QTimer(this);
- livetime->setInterval(300); //1/3 second for live searches
+ livetime->setInterval(500); //1/2 second for live searches
livetime->setSingleShot(true);
workthread = new QThread(this);
@@ -56,6 +56,7 @@ MainUI::MainUI() : QMainWindow(), ui(new Ui::MainUI){
}
MainUI::~MainUI(){
+ searcher->StopSearch();
workthread->quit();
workthread->wait();
}
@@ -189,6 +190,7 @@ void MainUI::foundSearchItem(QString path){
}
//Now add it to the widget
ui->listWidget->addItem(it);
+ if(ui->listWidget->count()>100){ searcher->StopSearch(); } //just in case
}
void MainUI::stopSearch(){
diff --git a/src-qt5/core-utils/lumina-search/Worker.cpp b/src-qt5/core-utils/lumina-search/Worker.cpp
index 677d2b4b..df1a0c3c 100644
--- a/src-qt5/core-utils/lumina-search/Worker.cpp
+++ b/src-qt5/core-utils/lumina-search/Worker.cpp
@@ -52,7 +52,8 @@ bool Worker::searchDir(QString dirpath){
tmp = dir.entryList(QDir::Dirs | QDir::NoDotAndDotDot , QDir::Name);
for(int i=0; i<tmp.length(); i++){
if(stopsearch){ return true; }
- if( skipDirs.contains(dir.absoluteFilePath(tmp[i])) ){ continue; } //this dir is skipped
+ if( skipDirs.contains(dir.absoluteFilePath(tmp[i])) || tmp[i]=="proc" ){ continue; } //this dir is skipped
+ //Special case - skip the "proc" directory heirarchy (highly-recursive layout for *every* process which is running)
if( searchDir(dir.absoluteFilePath(tmp[i])) ){ return true; }
}
return false;
bgstack15