Fix merge error.

This commit is contained in:
iaom 2021-11-11 10:03:57 +08:00
parent e95136e6bb
commit 4083ee024d
4 changed files with 5 additions and 7 deletions

View File

@ -271,8 +271,8 @@ void SettingsWidget::clearLayout(QLayout * layout) {
* @brief SettingsWidget::refreshIndexState
*/
void SettingsWidget::refreshIndexState() {
// qDebug()<<"FileUtils::_index_status: "<<FileUtils::_index_status;
if(FileUtils::_index_status != 0) {
// qDebug()<<"FileUtils::indexStatus: "<<FileUtils::indexStatus;
if(FileUtils::indexStatus != 0) {
this->setIndexState(true);
} else {
this->setIndexState(false);
@ -280,8 +280,8 @@ void SettingsWidget::refreshIndexState() {
m_indexNumLabel->setText(QString("%1/%2").arg(QString::number(SearchManager::getCurrentIndexCount())).arg(QString::number(FileUtils::_max_index_count)));
m_timer = new QTimer;
connect(m_timer, &QTimer::timeout, this, [ = ]() {
qDebug() << "FileUtils::_index_status: " << FileUtils::_index_status;
if(FileUtils::_index_status != 0) {
qDebug() << "FileUtils::indexStatus: " << FileUtils::indexStatus;
if(FileUtils::indexStatus != 0) {
this->setIndexState(true);
} else {
this->setIndexState(false);

View File

@ -108,7 +108,7 @@ void searchMethod(FileUtils::SearchMethod sm){
printf("enum class error!!!\n");
qWarning("enum class error!!!\n");
}
if (FileUtils::SearchMethod::INDEXSEARCH == sm && 0 == FileUtils::_index_status) {
if (FileUtils::SearchMethod::INDEXSEARCH == sm && 0 == FileUtils::indexStatus) {
qWarning() << "start first index";
FirstIndex fi("/home/zhangzihao/Desktop");
fi.start();

View File

@ -236,7 +236,6 @@ void InotifyWatch::slotEvent(char *buf, ssize_t len)
{
// eventProcess(socket);
if(FileUtils::SearchMethod::INDEXSEARCH == FileUtils::searchMethod) {
++FileUtils::_index_status;
pid_t pid;
pid = fork();
if(pid == 0) {

View File

@ -30,7 +30,6 @@
#include "index/searchmethodmanager.h"
#include "index/first-index.h"
#include "index/ukui-search-qdbus.h"
#include "index/inotify-index.h"
#include "index/search-manager.h"