diff --git a/makespec/BUILDVERSION b/makespec/BUILDVERSION index 600eb9a4..0a15a267 100644 --- a/makespec/BUILDVERSION +++ b/makespec/BUILDVERSION @@ -1 +1 @@ -5689 +5691 diff --git a/src/base/models/CoreObjectModels.hpp b/src/base/models/CoreObjectModels.hpp index 90d75284..fa87d9b7 100644 --- a/src/base/models/CoreObjectModels.hpp +++ b/src/base/models/CoreObjectModels.hpp @@ -265,8 +265,10 @@ namespace Qv2ray::base::objects QList alpn; QList certificates; bool disableSystemRoot; - TLSObject() : serverName(), allowInsecure(), allowInsecureCiphers(), disableSessionResumption(true), certificates(), disableSystemRoot(){}; - JSONSTRUCT_REGISTER(TLSObject, F(serverName, allowInsecure, allowInsecureCiphers, disableSessionResumption, alpn, certificates, disableSystemRoot)) + TLSObject() + : serverName(), allowInsecure(), allowInsecureCiphers(), disableSessionResumption(true), certificates(), disableSystemRoot(){}; + JSONSTRUCT_REGISTER(TLSObject, F(serverName, allowInsecure, allowInsecureCiphers, disableSessionResumption, alpn, certificates, + disableSystemRoot)) }; } // namespace transfer // @@ -363,8 +365,9 @@ namespace Qv2ray::base::objects int alterId; QString security; int level; - UserObject() : id(""), alterId(64), security("auto"), level(0){}; - JSONSTRUCT_REGISTER(UserObject, F(id, alterId, security, level)) + QString testsEnabled; + UserObject() : id(), alterId(64), security("auto"), level(0), testsEnabled("none"){}; + JSONSTRUCT_REGISTER(UserObject, F(id, alterId, security, level, testsEnabled)) }; QString address; diff --git a/src/ui/editors/w_OutboundEditor.cpp b/src/ui/editors/w_OutboundEditor.cpp index 7331c634..dbf3d583 100644 --- a/src/ui/editors/w_OutboundEditor.cpp +++ b/src/ui/editors/w_OutboundEditor.cpp @@ -93,8 +93,8 @@ OUTBOUND OutboundEditor::GenerateConnectionJson() } else if (outboundType == "shadowsocks") { - //streaming = QJsonObject(); - //LOG(MODULE_CONNECTION, "Shadowsocks outbound does not need StreamSettings.") + // streaming = QJsonObject(); + // LOG(MODULE_CONNECTION, "Shadowsocks outbound does not need StreamSettings.") QJsonArray servers; shadowsocks.address = address; shadowsocks.port = port; @@ -110,8 +110,8 @@ OUTBOUND OutboundEditor::GenerateConnectionJson() } socks.address = address; socks.port = port; - //streaming = QJsonObject(); - //LOG(MODULE_CONNECTION, "Socks outbound does not need StreamSettings.") + // streaming = QJsonObject(); + // LOG(MODULE_CONNECTION, "Socks outbound does not need StreamSettings.") QJsonArray servers; servers.append(socks.toJson()); settings["servers"] = servers; @@ -170,6 +170,7 @@ void OutboundEditor::ReloadGUI() idLineEdit->setText(vmess.users.front().id); alterLineEdit->setValue(vmess.users.front().alterId); securityCombo->setCurrentText(vmess.users.front().security); + testsEnabledCombo->setCurrentText(vmess.users.front().testsEnabled); } else if (outboundType == "shadowsocks") { @@ -343,3 +344,8 @@ void OutboundEditor::on_socks_PasswordTxt_textEdited(const QString &arg1) socks.users.push_back({}); socks.users.front().pass = arg1; } + +void OutboundEditor::on_testsEnabledCombo_currentIndexChanged(const QString &arg1) +{ + vmess.users.front().testsEnabled = arg1; +} diff --git a/src/ui/editors/w_OutboundEditor.hpp b/src/ui/editors/w_OutboundEditor.hpp index 4038ee01..682838ab 100644 --- a/src/ui/editors/w_OutboundEditor.hpp +++ b/src/ui/editors/w_OutboundEditor.hpp @@ -1,4 +1,4 @@ -#pragma once +#pragma once #include "base/Qv2rayBase.hpp" #include "components/plugins/QvPluginHost.hpp" #include "ui/messaging/QvMessageBus.hpp" @@ -44,6 +44,8 @@ class OutboundEditor void on_socks_PasswordTxt_textEdited(const QString &arg1); void on_securityCombo_currentIndexChanged(const QString &arg1); + void on_testsEnabledCombo_currentIndexChanged(const QString &arg1); + private: QString tag; void ReloadGUI(); diff --git a/src/ui/editors/w_OutboundEditor.ui b/src/ui/editors/w_OutboundEditor.ui index f81242be..abaf8f36 100644 --- a/src/ui/editors/w_OutboundEditor.ui +++ b/src/ui/editors/w_OutboundEditor.ui @@ -285,6 +285,30 @@ + + + + Tests + + + + + + + true + + + + none + + + + + VMessAEAD + + + +