diff --git a/src/lib/gui/dialogs/SettingsDialog.cpp b/src/lib/gui/dialogs/SettingsDialog.cpp index 28159bf1c..79a1830f0 100644 --- a/src/lib/gui/dialogs/SettingsDialog.cpp +++ b/src/lib/gui/dialogs/SettingsDialog.cpp @@ -96,7 +96,7 @@ void SettingsDialog::initConnections() const connect(ui->comboTlsKeyLength, &QComboBox::currentIndexChanged, this, &SettingsDialog::updateRequestedKeySize); connect(ui->btnTlsCertPath, &QPushButton::clicked, this, &SettingsDialog::browseCertificatePath); connect(ui->btnBrowseLog, &QPushButton::clicked, this, &SettingsDialog::browseLogPath); - connect(ui->cbLogToFile, &QCheckBox::toggled, this, &SettingsDialog::setLogToFile); + connect(ui->groupLogToFile, &QGroupBox::toggled, this, &SettingsDialog::setLogToFile); connect(ui->comboLogLevel, &QComboBox::currentIndexChanged, this, &SettingsDialog::logLevelChanged); connect(ui->comboLanguage, &QComboBox::currentTextChanged, this, [](const QString &lang) { const auto shortName = I18N::nativeTo639Name(lang); @@ -110,7 +110,6 @@ void SettingsDialog::initConnections() const connect(ui->comboInterface, &QComboBox::currentIndexChanged, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->comboTlsKeyLength, &QComboBox::currentIndexChanged, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->comboLanguage, &QComboBox::currentIndexChanged, this, &SettingsDialog::setButtonBoxEnabledButtons); - connect(ui->cbLogToFile, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->cbAutoHide, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->cbPreventSleep, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->cbCloseToTray, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); @@ -120,6 +119,7 @@ void SettingsDialog::initConnections() const connect(ui->cbUseWlClipboard, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->cbShowVersion, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->cbRequireClientCert, &QCheckBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); + connect(ui->groupLogToFile, &QGroupBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->groupService, &QGroupBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->groupSecurity, &QGroupBox::toggled, this, &SettingsDialog::setButtonBoxEnabledButtons); connect(ui->lineLogFilename, &QLineEdit::textChanged, this, &SettingsDialog::setButtonBoxEnabledButtons); @@ -203,7 +203,7 @@ void SettingsDialog::accept() Settings::setValue(Settings::Core::Port, ui->sbPort->value()); Settings::setValue(Settings::Core::Interface, ui->comboInterface->currentData()); Settings::setValue(Settings::Log::Level, ui->comboLogLevel->currentIndex()); - Settings::setValue(Settings::Log::ToFile, ui->cbLogToFile->isChecked()); + Settings::setValue(Settings::Log::ToFile, ui->groupLogToFile->isChecked()); Settings::setValue(Settings::Log::File, ui->lineLogFilename->text()); Settings::setValue(Settings::Daemon::Elevate, ui->cbElevateDaemon->isChecked()); Settings::setValue(Settings::Gui::Autohide, ui->cbAutoHide->isChecked()); @@ -234,7 +234,7 @@ void SettingsDialog::loadFromConfig() { ui->sbPort->setValue(Settings::value(Settings::Core::Port).toInt()); ui->comboLogLevel->setCurrentIndex(Settings::value(Settings::Log::Level).toInt()); - ui->cbLogToFile->setChecked(Settings::value(Settings::Log::ToFile).toBool()); + ui->groupLogToFile->setChecked(Settings::value(Settings::Log::ToFile).toBool()); ui->lineLogFilename->setText(Settings::value(Settings::Log::File).toString()); ui->cbAutoHide->setChecked(Settings::value(Settings::Gui::Autohide).toBool()); ui->cbPreventSleep->setChecked(Settings::value(Settings::Core::PreventSleep).toBool()); @@ -324,14 +324,14 @@ void SettingsDialog::updateControls() { const bool writable = Settings::isWritable(); const bool serviceChecked = ui->groupService->isChecked(); - const bool logToFile = ui->cbLogToFile->isChecked(); + const bool logToFile = ui->groupLogToFile->isChecked(); ui->buttonBox->button(QDialogButtonBox::Save)->setEnabled(writable); ui->sbPort->setEnabled(writable); ui->comboInterface->setEnabled(writable); ui->comboLogLevel->setEnabled(writable); - ui->cbLogToFile->setEnabled(writable); + ui->groupLogToFile->setEnabled(writable); ui->cbAutoHide->setEnabled(writable); ui->cbAutoUpdate->setEnabled(writable); ui->cbPreventSleep->setEnabled(writable); @@ -381,7 +381,7 @@ bool SettingsDialog::isModified() const return ( (ui->sbPort->value() != Settings::value(Settings::Core::Port).toInt()) || (ui->comboLogLevel->currentIndex() != Settings::value(Settings::Log::Level).toInt()) || - (ui->cbLogToFile->isChecked() != Settings::value(Settings::Log::ToFile).toBool()) || + (ui->groupLogToFile->isChecked() != Settings::value(Settings::Log::ToFile).toBool()) || (ui->lineLogFilename->text() != Settings::value(Settings::Log::File).toString()) || (ui->cbAutoHide->isChecked() != Settings::value(Settings::Gui::Autohide).toBool()) || (ui->cbPreventSleep->isChecked() != Settings::value(Settings::Core::PreventSleep).toBool()) || @@ -409,7 +409,7 @@ bool SettingsDialog::isDefault() const return ( (ui->sbPort->value() == Settings::defaultValue(Settings::Core::Port).toInt()) && (ui->comboLogLevel->currentIndex() == Settings::defaultValue(Settings::Log::Level).toInt()) && - (ui->cbLogToFile->isChecked() == Settings::defaultValue(Settings::Log::ToFile).toBool()) && + (ui->groupLogToFile->isChecked() == Settings::defaultValue(Settings::Log::ToFile).toBool()) && (ui->lineLogFilename->text() == Settings::defaultValue(Settings::Log::File).toString()) && (ui->cbAutoHide->isChecked() == Settings::defaultValue(Settings::Gui::Autohide).toBool()) && (ui->cbPreventSleep->isChecked() == Settings::defaultValue(Settings::Core::PreventSleep).toBool()) && @@ -434,7 +434,7 @@ void SettingsDialog::resetToDefault() { ui->sbPort->setValue(Settings::defaultValue(Settings::Core::Port).toInt()); ui->comboLogLevel->setCurrentIndex(Settings::defaultValue(Settings::Log::Level).toInt()); - ui->cbLogToFile->setChecked(Settings::defaultValue(Settings::Log::ToFile).toBool()); + ui->groupLogToFile->setChecked(Settings::defaultValue(Settings::Log::ToFile).toBool()); ui->lineLogFilename->setText(Settings::defaultValue(Settings::Log::File).toString()); ui->cbAutoHide->setChecked(Settings::defaultValue(Settings::Gui::Autohide).toBool()); ui->cbPreventSleep->setChecked(Settings::defaultValue(Settings::Core::PreventSleep).toBool()); diff --git a/src/lib/gui/dialogs/SettingsDialog.ui b/src/lib/gui/dialogs/SettingsDialog.ui index d6fd16314..61c70f730 100644 --- a/src/lib/gui/dialogs/SettingsDialog.ui +++ b/src/lib/gui/dialogs/SettingsDialog.ui @@ -7,7 +7,7 @@ 0 0 549 - 755 + 529 @@ -278,7 +278,214 @@ 20 - 40 + 0 + + + + + + + + + &Logs + + + + 12 + + + 25 + + + 12 + + + + + + + + 0 + 0 + + + + Level + + + + + + + + Fatal + + + + + Error + + + + + Warning + + + + + Note + + + + + Info + + + + + Debug + + + + + Debug1 + + + + + Debug2 + + + + + + + + + + Log to file + + + true + + + + + + + 0 + 0 + + + + + 3 + + + 0 + + + 0 + + + 0 + + + 0 + + + + + + 0 + 0 + + + + Log path + + + + + + + Qt::Orientation::Horizontal + + + QSizePolicy::Policy::Minimum + + + + 17 + 25 + + + + + + + + true + + + + 0 + 0 + + + + + + + + true + + + PointingHandCursor + + + + + + + + + true + + + + + + + + + + + + + Enable GUI debug messages + + + + + + + Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. + + + true + + + + + + + Qt::Orientation::Vertical + + + + 20 + 0 @@ -400,206 +607,6 @@ - - - - - 0 - 0 - - - - Logs - - - - 9 - - - - - - 0 - 0 - - - - Level - - - - - - - - Fatal - - - - - Error - - - - - Warning - - - - - Note - - - - - Info - - - - - Debug - - - - - Debug1 - - - - - Debug2 - - - - - - - - - 0 - 0 - - - - - 3 - - - 0 - - - 0 - - - 0 - - - 0 - - - - - - 0 - 0 - - - - Log path - - - - - - - Qt::Orientation::Horizontal - - - QSizePolicy::Policy::Minimum - - - - 20 - 20 - - - - - - - - true - - - - 0 - 0 - - - - - - - - true - - - PointingHandCursor - - - - - - - - - true - - - - - - - - - - Log to file - - - - - - - Qt::Orientation::Horizontal - - - - 40 - 20 - - - - - - - - Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. - - - true - - - - - - - Enable GUI debug messages - - - - - - diff --git a/translations/deskflow_es.ts b/translations/deskflow_es.ts index 42449eb29..5cf47e49c 100644 --- a/translations/deskflow_es.ts +++ b/translations/deskflow_es.ts @@ -1223,18 +1223,10 @@ Al habilitar esta opción, se deshabilitará la interfaz gráfica de usuario (GU Network IP IP de red - - Logs - Registros - Log path Ruta de registro - - Log to file - Registrar en archivo - Fatal Fatal @@ -1375,6 +1367,14 @@ Al habilitar esta opción, se deshabilitará la interfaz gráfica de usuario (GU Include version in the window title Incluir la versión en el título de la ventana + + Log to file + Registrar en archivo + + + &Logs + &Registro + i18n diff --git a/translations/deskflow_it.ts b/translations/deskflow_it.ts index bcddb1192..711bb6fdc 100644 --- a/translations/deskflow_it.ts +++ b/translations/deskflow_it.ts @@ -1223,18 +1223,10 @@ L'abilitazione di questa impostazione disabiliterà l'interfaccia graf Network IP IP di rete - - Logs - Log - Log path Percorso log - - Log to file - Salva log su file - Fatal Fatale @@ -1375,6 +1367,14 @@ L'abilitazione di questa impostazione disabiliterà l'interfaccia graf Include version in the window title Includi la versione nel titolo della finestra + + Log to file + Salva log su file + + + &Logs + &Logs + i18n diff --git a/translations/deskflow_ja.ts b/translations/deskflow_ja.ts index a309fa701..23a866fba 100644 --- a/translations/deskflow_ja.ts +++ b/translations/deskflow_ja.ts @@ -1224,10 +1224,6 @@ Enabling this setting will disable the server config GUI. Network IP IPアドレス - - Logs - ログ - Level レベル @@ -1268,10 +1264,6 @@ Enabling this setting will disable the server config GUI. Log path ログファイルのパス - - Log to file - ファイルにログを保存する - Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. デバッグレベルのログ取得は性能に影響が出ることがあります。不具合の修正やバグレポートの送信に必要な場合にのみ使用してください。 @@ -1376,6 +1368,14 @@ Enabling this setting will disable the server config GUI. Include version in the window title ウィンドウタイトルにバージョン情報を含める + + Log to file + ファイルにログを保存する + + + &Logs + ログ(&L) + i18n diff --git a/translations/deskflow_ko.ts b/translations/deskflow_ko.ts index fa6f92a6e..daa50c93a 100644 --- a/translations/deskflow_ko.ts +++ b/translations/deskflow_ko.ts @@ -1222,10 +1222,6 @@ Enabling this setting will disable the server config GUI. Network IP 네트워크 IP - - Logs - 로그 - Level 레벨 @@ -1266,10 +1262,6 @@ Enabling this setting will disable the server config GUI. Log path 로그 경로 - - Log to file - 파일로 로그 저장 - Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. 디버그 로그 레벨은 성능에 영향을 줄 수 있습니다. 문제를 디버깅하거나 버그 신고에 첨부할 로그를 수집할 때만 디버그 레벨을 사용하세요. @@ -1374,6 +1366,14 @@ Enabling this setting will disable the server config GUI. Include version in the window title 창 제목에 버전 정보 포함 + + Log to file + 파일로 로그 저장 + + + &Logs + 로그 (&L) + i18n diff --git a/translations/deskflow_ru.ts b/translations/deskflow_ru.ts index bb23bd202..178587204 100644 --- a/translations/deskflow_ru.ts +++ b/translations/deskflow_ru.ts @@ -1222,10 +1222,6 @@ Enabling this setting will disable the server config GUI. Network IP Сетевой IP-адрес - - Logs - Журналы - Level Уровень @@ -1266,10 +1262,6 @@ Enabling this setting will disable the server config GUI. Log path Путь к журналам - - Log to file - Записывать в файл - Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. Уровень отладки может повлиять на производительность. Используйте его только для поиска неисправностей. @@ -1374,6 +1366,14 @@ Enabling this setting will disable the server config GUI. Include version in the window title Включить номер версии в заголовок окна + + Log to file + Записывать в файл + + + &Logs + &Журнал + i18n diff --git a/translations/deskflow_zh_CN.ts b/translations/deskflow_zh_CN.ts index 2391a9efa..501078b44 100644 --- a/translations/deskflow_zh_CN.ts +++ b/translations/deskflow_zh_CN.ts @@ -1224,10 +1224,6 @@ Enabling this setting will disable the server config GUI. Network IP 网络 IP - - Logs - 日志 - Level 级别 @@ -1268,10 +1264,6 @@ Enabling this setting will disable the server config GUI. Log path 日志路径 - - Log to file - 记录日志到文件 - Using a Debug log level may affect performance. Only use a Debug level if you are attempting to debug an issue or are gathering logs to submit with a bug report. 使用调试日志级别可能会影响性能。仅当您尝试调试问题或收集日志以提交 Bug 报告时,才使用调试级别。 @@ -1376,6 +1368,14 @@ Enabling this setting will disable the server config GUI. Include version in the window title 在窗口标题中包含版本信息 + + Log to file + 记录日志到文件 + + + &Logs + 日志(&L) + i18n