mirror of
https://github.com/MatsuriDayo/nekoray.git
synced 2025-12-17 20:44:38 +03:00
system proxy format (windows)
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
#include "ui_dialog_basic_settings.h"
|
||||
|
||||
#include "qv2ray/v2/ui/widgets/editors/w_JsonEditor.hpp"
|
||||
#include "fmt/Preset.hpp"
|
||||
#include "ui/ThemeManager.hpp"
|
||||
#include "main/GuiUtils.hpp"
|
||||
#include "main/NekoRay.hpp"
|
||||
@@ -78,6 +79,22 @@ DialogBasicSettings::DialogBasicSettings(QWidget *parent)
|
||||
C_EDIT_JSON_ALLOW_EMPTY(custom_inbound)
|
||||
});
|
||||
|
||||
#ifdef Q_OS_WIN
|
||||
connect(ui->sys_proxy_format, &QPushButton::clicked, this, [=] {
|
||||
bool ok;
|
||||
auto str = QInputDialog::getItem(this, ui->sys_proxy_format->text() + " (Windows)",
|
||||
tr("Advanced system proxy settings. Please select a format."),
|
||||
Preset::Windows::system_proxy_format,
|
||||
Preset::Windows::system_proxy_format.indexOf(
|
||||
NekoRay::dataStore->system_proxy_format),
|
||||
false, &ok
|
||||
);
|
||||
if (ok) NekoRay::dataStore->system_proxy_format = str;
|
||||
});
|
||||
#else
|
||||
ui->sys_proxy_format->hide();
|
||||
#endif
|
||||
|
||||
// Style
|
||||
if (IS_NEKO_BOX) {
|
||||
ui->connection_statistics_box->setDisabled(true);
|
||||
|
||||
Reference in New Issue
Block a user