diff --git a/src/QvCoreConfigOperations.h b/src/QvCoreConfigOperations.h index a32c5d2a..f308082c 100644 --- a/src/QvCoreConfigOperations.h +++ b/src/QvCoreConfigOperations.h @@ -56,7 +56,7 @@ namespace Qv2ray bool SaveConnectionConfig(QJsonObject obj, const QString *alias); bool RenameConnection(QString originalName, QString newName); // VMess Protocol - QJsonObject ConvertConfigFromVMessString(QString vmess); + QJsonObject ConvertConfigFromVMessString(QString vmess, QString source = QV2RAY_CONFIG_TYPE_CONNECTIONSTRING); QJsonObject ConvertConfigFromFile(QString sourceFilePath, bool overrideInbounds); // Load Configs QMap GetConnections(list connections); diff --git a/src/QvCoreConfigOperations_Convertion.cpp b/src/QvCoreConfigOperations_Convertion.cpp index fa314ea8..edca6160 100644 --- a/src/QvCoreConfigOperations_Convertion.cpp +++ b/src/QvCoreConfigOperations_Convertion.cpp @@ -11,7 +11,7 @@ namespace Qv2ray } // This generates global config containing only one outbound.... - QJsonObject ConvertConfigFromVMessString(QString str) + QJsonObject ConvertConfigFromVMessString(QString str, QString source) { DROOT QStringRef vmessJsonB64(&str, 8, str.length() - 8); @@ -66,7 +66,7 @@ namespace Qv2ray outbounds.append(outbound); root.insert("outbounds", outbounds); root.insert("QV2RAY_ALIAS", QString::fromStdString(vmessConf.ps)); - root.insert(QV2RAY_CONFIG_TYPE_JSON_KEY, QV2RAY_CONFIG_TYPE_CONNECTIONSTRING); + root.insert(QV2RAY_CONFIG_TYPE_JSON_KEY, source); RROOT } diff --git a/src/w_RouteEditor.cpp b/src/w_RouteEditor.cpp index d77f5c3e..49a883a2 100644 --- a/src/w_RouteEditor.cpp +++ b/src/w_RouteEditor.cpp @@ -1,5 +1,5 @@ #include "w_RouteEditor.h" -#include "ui_w_OutboundEditor.h" +#include "ui_w_RouteEditor.h" RouteEditor::RouteEditor(QWidget *parent) : QDialog(parent), diff --git a/src/w_SubscribeEditor.ui b/src/w_SubscribeEditor.ui index f6e5c863..c84d9942 100644 --- a/src/w_SubscribeEditor.ui +++ b/src/w_SubscribeEditor.ui @@ -98,10 +98,10 @@ - 530 - 101 - 181 - 121 + 430 + 10 + 281 + 211