gui: MainWindow: Set, save and restore ignore patterns
Dieser Commit ist enthalten in:
Ursprung
c2bd1b526b
Commit
ae57a22078
@ -72,6 +72,9 @@ MainWindow::MainWindow(QWidget *parent, QString socketPath) : QMainWindow(parent
|
||||
QStringList indexPaths = settings.value("indexPaths").toStringList();
|
||||
ui->lstPaths->addItems(indexPaths);
|
||||
|
||||
QString ignorePatterns = settings.value("ignorePatterns").toString();
|
||||
ui->txtIgnorePatterns->setText(ignorePatterns);
|
||||
|
||||
ui->spinPreviewPage->setValue(1);
|
||||
ui->spinPreviewPage->setMinimum(1);
|
||||
}
|
||||
@ -196,9 +199,12 @@ void MainWindow::startIndexing()
|
||||
pathSettingsValue.append(path);
|
||||
}
|
||||
this->indexer->setTargetPaths(paths);
|
||||
QString ignorePatterns = ui->txtIgnorePatterns->text();
|
||||
this->indexer->setIgnorePattern(ignorePatterns.split(";"));
|
||||
this->indexer->beginIndexing();
|
||||
QSettings settings;
|
||||
settings.setValue("indexPaths", pathSettingsValue);
|
||||
settings.setValue("ignorePatterns", ignorePatterns);
|
||||
ui->btnStartIndexing->setText("Stop indexing");
|
||||
}
|
||||
|
||||
|
@ -27,7 +27,7 @@
|
||||
<enum>QTabWidget::South</enum>
|
||||
</property>
|
||||
<property name="currentIndex">
|
||||
<number>1</number>
|
||||
<number>0</number>
|
||||
</property>
|
||||
<widget class="QWidget" name="resultsTab">
|
||||
<attribute name="title">
|
||||
@ -333,7 +333,7 @@
|
||||
</widget>
|
||||
</item>
|
||||
<item row="6" column="0">
|
||||
<widget class="QLineEdit" name="lineEdit"/>
|
||||
<widget class="QLineEdit" name="txtIgnorePatterns"/>
|
||||
</item>
|
||||
<item row="10" column="0">
|
||||
<widget class="QPushButton" name="btnStartIndexing">
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren