refactor custom json

This commit is contained in:
arm64v8a
2023-04-17 17:49:07 +09:00
parent 4620d8aca2
commit 1c8ae4ef4f
12 changed files with 126 additions and 79 deletions

View File

@@ -14,14 +14,12 @@ namespace NekoRay::fmt {
QString flow = "";
QSharedPointer<V2rayStreamSettings> stream = QSharedPointer<V2rayStreamSettings>(new V2rayStreamSettings());
QString custom = "";
explicit TrojanVLESSBean(int _proxy_type) : AbstractBean(0) {
proxy_type = _proxy_type;
_add(new configItem("pass", &password, itemType::string));
_add(new configItem("flow", &flow, itemType::string));
_add(new configItem("stream", dynamic_cast<JsonStore *>(stream.get()), itemType::jsonStore));
_add(new configItem("custom", &custom, itemType::string));
};
QString DisplayType() override { return proxy_type == proxy_VLESS ? "VLESS" : "Trojan"; };