Remove property
This commit is contained in:
parent
546f4782d1
commit
cdce150db5
@ -123,8 +123,7 @@ void SettingsEditor::setSettings(const Settings &settings)
|
|||||||
ui->ignoreSslCheck->setChecked(settings.ignoreSslErrors);
|
ui->ignoreSslCheck->setChecked(settings.ignoreSslErrors);
|
||||||
ui->translatorDebugCheck->setChecked(settings.debugMode);
|
ui->translatorDebugCheck->setChecked(settings.debugMode);
|
||||||
ui->translateTimeoutSpin->setValue(settings.translationTimeout.count());
|
ui->translateTimeoutSpin->setValue(settings.translationTimeout.count());
|
||||||
translatorsDir_ = settings.translatorsDir;
|
updateTranslators(settings.translatorsDir, settings.translators);
|
||||||
updateTranslators(settings.translators);
|
|
||||||
|
|
||||||
ui->trayRadio->setChecked(settings.resultShowType == ResultMode::Tooltip);
|
ui->trayRadio->setChecked(settings.resultShowType == ResultMode::Tooltip);
|
||||||
ui->dialogRadio->setChecked(settings.resultShowType == ResultMode::Widget);
|
ui->dialogRadio->setChecked(settings.resultShowType == ResultMode::Widget);
|
||||||
@ -177,11 +176,12 @@ void SettingsEditor::updateCorrectionsTable()
|
|||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
||||||
void SettingsEditor::updateTranslators(const QStringList &enabled)
|
void SettingsEditor::updateTranslators(const QString &path,
|
||||||
|
const QStringList &enabled)
|
||||||
{
|
{
|
||||||
ui->translatorList->clear();
|
ui->translatorList->clear();
|
||||||
|
|
||||||
QDir dir(translatorsDir_);
|
QDir dir(path);
|
||||||
if (!dir.exists())
|
if (!dir.exists())
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
@ -25,9 +25,8 @@ private:
|
|||||||
void openTessdataDialog();
|
void openTessdataDialog();
|
||||||
void updateTesseractLanguages();
|
void updateTesseractLanguages();
|
||||||
void updateCorrectionsTable();
|
void updateCorrectionsTable();
|
||||||
void updateTranslators(const QStringList &enabled);
|
void updateTranslators(const QString &path, const QStringList &enabled);
|
||||||
void updateTranslationLanguages();
|
void updateTranslationLanguages();
|
||||||
|
|
||||||
Ui::SettingsEditor *ui;
|
Ui::SettingsEditor *ui;
|
||||||
QString translatorsDir_;
|
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user