[add][fix] Added Windows start with boot support and fixed UI.

This commit is contained in:
Leroy.H.Y 2019-12-28 09:30:47 +08:00
parent 62d72a2ddf
commit 80d5465ded
9 changed files with 666 additions and 543 deletions

View File

@ -1 +1 @@
2396
2398

View File

@ -27,6 +27,7 @@ include(3rdparty/QNodeEditor/QNodeEditor.pri)
CONFIG += lrelease embed_translations
SOURCES += \
src/components/QvAutoStartConfigurator.cpp \
src/components/QvComponentsHandler.cpp \
src/components/QvPACHandler.cpp \
src/components/QvSystemProxyConfigurator.cpp \
@ -75,6 +76,7 @@ HEADERS += \
src/QvCoreConfigObjects.hpp \
src/QvCoreConfigOperations.hpp \
src/QvUtils.hpp \
src/components/QvAutoStartConfigurator.hpp \
src/components/QvComponentsHandler.hpp \
src/components/QvCoreInteractions.hpp \
src/components/QvHTTPRequestHelper.hpp \

View File

@ -0,0 +1,39 @@
#include "QvAutoStartConfigurator.hpp"
#include <QSettings>
#include <QApplication>
namespace Qv2ray
{
namespace Components
{
bool InstallAutoStart()
{
#ifdef Q_OS_WIN
QSettings settings("HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Run", QSettings::NativeFormat);
auto path = qApp->applicationFilePath();
// Make it suitable for Windows.
if (path.contains(" ")) {
path = "\"" + path + "\"";
}
path = path.replace('/', '\\');
LOG(MODULE_CONFIG, "Qv2ray executable path: " + path.toStdString())
settings.setValue("Qv2ray", path);
return true;
#else
return false;
#endif
}
bool RemoveAutoStart()
{
#ifdef Q_OS_WIN
QSettings settings("HKEY_CURRENT_USER\\Software\\Microsoft\\Windows\\CurrentVersion\\Run", QSettings::NativeFormat);
settings.remove("Qv2ray");
return true;
#else
return false;
#endif
}
}
}

View File

@ -0,0 +1,17 @@
#ifndef QVAUTOSTARTCONFIGURATOR_H
#define QVAUTOSTARTCONFIGURATOR_H
#include "QvUtils.hpp"
namespace Qv2ray
{
namespace Components
{
bool InstallAutoStart();
bool RemoveAutoStart();
}
}
using namespace Qv2ray::Components;
#endif // QVAUTOSTARTCONFIGURATOR_H

View File

@ -222,6 +222,8 @@ int main(int argc, char *argv[])
"Copyright (c) 2019 Nikolaos Ftylitakis (@ftylitak): QZXing (Apache2)" NEWLINE
"Copyright (c) 2016 Singein (@Singein): ScreenShot (MIT)" NEWLINE
"Copyright (c) 2016 Nikhil Marathe (@nikhilm): QHttpServer (MIT)" NEWLINE
"Copyright (c) 2019 Itay Grudev (@itay-grudev): SingleApplication (MIT)" NEWLINE
"Copyright (c) 2019 paceholder (@paceholder): nodeeditor (QNodeEditor modified by lhy0403) (BSD-3-Clause)" NEWLINE
NEWLINE
"Qv2ray " QV2RAY_VERSION_STRING " running on " +
(QSysInfo::prettyProductName() + " " + QSysInfo::currentCpuArchitecture()).toStdString() + NEWLINE)

View File

@ -1,4 +1,5 @@
#include <QFileDialog>
#include "w_PreferencesWindow.hpp"
#include <QFileDialog>
#include <QColorDialog>
#include <QStyleFactory>
#include <QStyle>
@ -9,8 +10,8 @@
#include "QvNetSpeedPlugin.hpp"
#include "QvCoreConfigOperations.hpp"
#include "w_PreferencesWindow.hpp"
#include "QvHTTPRequestHelper.hpp"
#include "QvAutoStartConfigurator.hpp"
#define LOADINGCHECK if(!finishedLoading) return;
#define NEEDRESTART if(finishedLoading) IsConnectionPropertyChanged = true;
@ -771,10 +772,11 @@ void PreferencesWindow::on_pacGoBtn_clicked()
QString gfwLocation;
QString fileContent;
auto request = new QvHttpRequestHelper();
LOG(MODULE_PROXY, "Downloading GFWList file.")
switch (gfwListCB->currentIndex()) {
case 0:
gfwLocation = "https://raw.githubusercontent.com/gfwlist/gfwlist/master/gfwlist.txt";
gfwLocation = "https://gitlab.com/gfwlist/gfwlist/raw/master/gfwlist.txt";
fileContent = QString::fromUtf8(request->syncget(gfwLocation));
break;
@ -794,7 +796,7 @@ void PreferencesWindow::on_pacGoBtn_clicked()
break;
case 4:
gfwLocation = "https://gitlab.com/gfwlist/gfwlist/raw/master/gfwlist.txt";
gfwLocation = "https://raw.githubusercontent.com/gfwlist/gfwlist/master/gfwlist.txt";
fileContent = QString::fromUtf8(request->syncget(gfwLocation));
break;
@ -812,7 +814,9 @@ void PreferencesWindow::on_pacGoBtn_clicked()
break;
}
//
LOG(MODULE_NETWORK, "Fetched: " + gfwLocation.toStdString())
if (!QDir(QV2RAY_RULES_DIR).exists()) {
QDir(QV2RAY_RULES_DIR).mkpath(QV2RAY_RULES_DIR);
}
@ -878,3 +882,21 @@ void PreferencesWindow::on_autoStartConnCombo_currentIndexChanged(const QString
LOADINGCHECK
CurrentConfig.autoStartConfig.connectionName = arg1.toStdString();
}
void PreferencesWindow::on_installBootStart_clicked()
{
if (InstallAutoStart()) {
QvMessageBox(this, tr("Start with boot"), tr("Successfully installed starting with boot."));
} else {
QvMessageBox(this, tr("Start with boot"), tr("Only Windows platform is supported currently."));
}
}
void PreferencesWindow::on_removeBootStart_clicked()
{
if (RemoveAutoStart()) {
QvMessageBox(this, tr("Start with boot"), tr("Successfully removed starting with boot."));
} else {
QvMessageBox(this, tr("Start with boot"), tr("Only Windows platform is supported currently."));
}
}

View File

@ -134,6 +134,10 @@ class PreferencesWindow : public QDialog, private Ui::PreferencesWindow
void on_autoStartConnCombo_currentIndexChanged(const QString &arg1);
void on_installBootStart_clicked();
void on_removeBootStart_clicked();
private:
// Set ui parameters for a line;
void ShowLineParameters(QvBarLine &line);

View File

@ -48,6 +48,8 @@
<attribute name="title">
<string>General</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout_7">
<item>
<layout class="QFormLayout" name="formLayout_5">
<item row="0" column="0">
<widget class="QLabel" name="label_35">
@ -67,6 +69,13 @@
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_5">
<property name="text">
<string>Start With Boot</string>
</property>
</widget>
</item>
<item row="2" column="0">
<layout class="QVBoxLayout" name="verticalLayout_6">
<item>
<spacer name="verticalSpacer_7">
@ -103,7 +112,7 @@
</item>
</layout>
</item>
<item row="1" column="1">
<item row="2" column="1">
<layout class="QGridLayout" name="gridLayout_6" columnstretch="0,0,0,1">
<item row="1" column="2">
<widget class="QCheckBox" name="darkTrayCB">
@ -161,14 +170,14 @@
</item>
</layout>
</item>
<item row="2" column="0">
<item row="3" column="0">
<widget class="QLabel" name="label_6">
<property name="text">
<string>Language</string>
</property>
</widget>
</item>
<item row="2" column="1">
<item row="3" column="1">
<widget class="QComboBox" name="languageComboBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Preferred" vsizetype="Fixed">
@ -194,14 +203,14 @@
</item>
</widget>
</item>
<item row="3" column="0">
<item row="4" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Log Level</string>
</property>
</widget>
</item>
<item row="3" column="1">
<item row="4" column="1">
<widget class="QComboBox" name="logLevelComboBox">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
@ -242,44 +251,7 @@
</item>
</widget>
</item>
<item row="4" column="0">
<layout class="QVBoxLayout" name="verticalLayout_9">
<item>
<spacer name="verticalSpacer_6">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QLabel" name="label_19">
<property name="text">
<string>Auto Connect</string>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer_8">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="4" column="1">
<item row="5" column="1">
<layout class="QGridLayout" name="gridLayout_8" columnstretch="0,0,1">
<item row="1" column="1">
<widget class="QLabel" name="label_61">
@ -328,28 +300,28 @@
</item>
</layout>
</item>
<item row="5" column="0">
<item row="6" column="0">
<widget class="QLabel" name="label_7">
<property name="text">
<string>Transparent Proxy</string>
</property>
</widget>
</item>
<item row="5" column="1">
<item row="6" column="1">
<widget class="QCheckBox" name="tProxyCheckBox">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="6" column="0">
<item row="7" column="0">
<widget class="QLabel" name="label_46">
<property name="text">
<string>V2ray Core Path</string>
</property>
</widget>
</item>
<item row="6" column="1">
<item row="7" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_12">
<item>
<widget class="QLineEdit" name="vCorePathTxt">
@ -367,14 +339,14 @@
</item>
</layout>
</item>
<item row="7" column="0">
<item row="8" column="0">
<widget class="QLabel" name="label_15">
<property name="text">
<string>V2ray Assets Path</string>
</property>
</widget>
</item>
<item row="7" column="1">
<item row="8" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_5">
<item>
<widget class="QLineEdit" name="vCoreAssetsPathTxt"/>
@ -388,8 +360,76 @@
</item>
</layout>
</item>
<item row="8" column="0" colspan="2">
<layout class="QVBoxLayout" name="verticalLayout_7">
<item row="5" column="0">
<layout class="QVBoxLayout" name="verticalLayout_9">
<item>
<spacer name="verticalSpacer_6">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
<item>
<widget class="QLabel" name="label_19">
<property name="text">
<string>Auto Connect</string>
</property>
</widget>
</item>
<item>
<spacer name="verticalSpacer_8">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>0</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
<item row="1" column="1">
<layout class="QHBoxLayout" name="horizontalLayout_7">
<item>
<widget class="QPushButton" name="installBootStart">
<property name="text">
<string>(Re)Install</string>
</property>
</widget>
</item>
<item>
<widget class="QPushButton" name="removeBootStart">
<property name="text">
<string>Remove</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_6">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</item>
<item>
<spacer name="verticalSpacer_9">
<property name="orientation">
@ -398,20 +438,18 @@
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
<height>183</height>
</size>
</property>
</spacer>
</item>
</layout>
</item>
</layout>
</widget>
<widget class="QWidget" name="tab_3">
<attribute name="title">
<string>Inbound Settings</string>
</attribute>
<layout class="QVBoxLayout" name="verticalLayout" stretch="0,1">
<layout class="QVBoxLayout" name="verticalLayout">
<item>
<layout class="QFormLayout" name="formLayout_4">
<item row="0" column="0">
@ -487,20 +525,119 @@
</item>
<item>
<layout class="QGridLayout" name="gridLayout_7">
<item row="0" column="0" rowspan="2">
<widget class="QGroupBox" name="socksGroupBox">
<property name="title">
<string>SOCKS Settings</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<item row="0" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Port</string>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QSpinBox" name="socksPortLE">
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>65535</number>
</property>
<property name="value">
<number>1081</number>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_14">
<property name="text">
<string>UDP Support</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QCheckBox" name="socksUDPCB">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_25">
<property name="text">
<string>Local IP (For UDP)</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QLineEdit" name="socksUDPIP">
<property name="placeholderText">
<string notr="true">127.0.0.1</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_10">
<property name="text">
<string>Authentication</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QCheckBox" name="socksAuthCB">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_11">
<property name="text">
<string>Username</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QLineEdit" name="socksAuthUsernameTxt">
<property name="placeholderText">
<string notr="true">user</string>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_12">
<property name="text">
<string>Password</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QLineEdit" name="socksAuthPasswordTxt">
<property name="placeholderText">
<string notr="true">pass</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
<item row="0" column="1">
<widget class="QGroupBox" name="httpGroupBox">
<property name="title">
<string>HTTP Settings</string>
</property>
<layout class="QFormLayout" name="formLayout_7">
<item row="1" column="0">
<item row="0" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Port</string>
</property>
</widget>
</item>
<item row="1" column="1">
<item row="0" column="1">
<widget class="QSpinBox" name="httpPortLE">
<property name="minimum">
<number>1</number>
@ -513,42 +650,42 @@
</property>
</widget>
</item>
<item row="2" column="0">
<item row="1" column="0">
<widget class="QLabel" name="label_9">
<property name="text">
<string>Authentication</string>
</property>
</widget>
</item>
<item row="2" column="1">
<item row="1" column="1">
<widget class="QCheckBox" name="httpAuthCB">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="3" column="0">
<item row="2" column="0">
<widget class="QLabel" name="label_2">
<property name="text">
<string>Username</string>
</property>
</widget>
</item>
<item row="3" column="1">
<item row="2" column="1">
<widget class="QLineEdit" name="httpAuthUsernameTxt">
<property name="placeholderText">
<string notr="true">user</string>
</property>
</widget>
</item>
<item row="4" column="0">
<item row="3" column="0">
<widget class="QLabel" name="label_13">
<property name="text">
<string>Password</string>
</property>
</widget>
</item>
<item row="4" column="1">
<item row="3" column="1">
<widget class="QLineEdit" name="httpAuthPasswordTxt">
<property name="placeholderText">
<string notr="true">pass</string>
@ -630,6 +767,11 @@
<layout class="QHBoxLayout" name="horizontalLayout_2">
<item>
<widget class="QComboBox" name="gfwListCB">
<item>
<property name="text">
<string>Mirror: Gitlab</string>
</property>
</item>
<item>
<property name="text">
<string>Github</string>
@ -650,11 +792,6 @@
<string>Mirror: Bitbucket</string>
</property>
</item>
<item>
<property name="text">
<string>Mirror: Gitlab</string>
</property>
</item>
<item>
<property name="text">
<string>Mirror: TuxFamily</string>
@ -693,106 +830,20 @@
</layout>
</widget>
</item>
<item row="0" column="0" rowspan="2">
<widget class="QGroupBox" name="socksGroupBox">
<property name="title">
<string>SOCKS Settings</string>
</property>
<layout class="QFormLayout" name="formLayout_2">
<item row="1" column="0">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Port</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QSpinBox" name="socksPortLE">
<property name="minimum">
<number>1</number>
</property>
<property name="maximum">
<number>65535</number>
</property>
<property name="value">
<number>1081</number>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_14">
<property name="text">
<string>UDP Support</string>
</property>
</widget>
</item>
<item row="2" column="1">
<widget class="QCheckBox" name="socksUDPCB">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="3" column="0">
<widget class="QLabel" name="label_25">
<property name="text">
<string>Local IP (For UDP)</string>
</property>
</widget>
</item>
<item row="3" column="1">
<widget class="QLineEdit" name="socksUDPIP">
<property name="placeholderText">
<string notr="true">127.0.0.1</string>
</property>
</widget>
</item>
<item row="4" column="0">
<widget class="QLabel" name="label_10">
<property name="text">
<string>Authentication</string>
</property>
</widget>
</item>
<item row="4" column="1">
<widget class="QCheckBox" name="socksAuthCB">
<property name="text">
<string>Enabled</string>
</property>
</widget>
</item>
<item row="5" column="0">
<widget class="QLabel" name="label_11">
<property name="text">
<string>Username</string>
</property>
</widget>
</item>
<item row="5" column="1">
<widget class="QLineEdit" name="socksAuthUsernameTxt">
<property name="placeholderText">
<string notr="true">user</string>
</property>
</widget>
</item>
<item row="6" column="0">
<widget class="QLabel" name="label_12">
<property name="text">
<string>Password</string>
</property>
</widget>
</item>
<item row="6" column="1">
<widget class="QLineEdit" name="socksAuthPasswordTxt">
<property name="placeholderText">
<string notr="true">pass</string>
</property>
</widget>
</item>
</layout>
</widget>
</item>
</layout>
<item>
<spacer name="verticalSpacer_10">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
@ -1029,14 +1080,14 @@
<string>Network Toolbar Settings</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_3">
<item row="3" column="1">
<item row="4" column="1">
<widget class="QPushButton" name="applyNSBarSettingsBtn">
<property name="text">
<string>Apply Network Speed Bar UI Settings</string>
</property>
</widget>
</item>
<item row="2" column="0" rowspan="3">
<item row="3" column="0" rowspan="3">
<widget class="QGroupBox" name="groupBox_6">
<property name="title">
<string>Items</string>
@ -1181,14 +1232,7 @@
</layout>
</widget>
</item>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="label_33">
<property name="text">
<string>You can config how the network speed toolbar looks like in this panel</string>
</property>
</widget>
</item>
<item row="2" column="1">
<item row="3" column="1">
<widget class="QFrame" name="nsBarVerticalLayout">
<layout class="QVBoxLayout" name="verticalLayout_2">
<item>
@ -1357,7 +1401,14 @@
</layout>
</widget>
</item>
<item row="1" column="0">
<item row="1" column="0" colspan="2">
<widget class="QLabel" name="label_33">
<property name="text">
<string>You can config how the network speed toolbar looks like in this panel</string>
</property>
</widget>
</item>
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="label_64">
<property name="font">
<font>
@ -1370,7 +1421,7 @@
<string notr="true">color: red</string>
</property>
<property name="text">
<string>This feature is not stable enough.</string>
<string>This feature is not stable enough and no documentation is provoded, please use it as your own risk!</string>
</property>
</widget>
</item>
@ -1471,62 +1522,8 @@
</layout>
</item>
<item>
<layout class="QGridLayout" name="gridLayout_5" columnstretch="0,1">
<item row="0" column="1">
<widget class="QLabel" name="qvBuildTime">
<property name="text">
<string/>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label_26">
<property name="text">
<string>Built Time</string>
</property>
</widget>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_27">
<property name="text">
<string>Official Repo</string>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="label_28">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;a href=&quot;https://github.com/lhy0403/Qv2ray&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#2980b9;&quot;&gt;https://github.com/lhy0403/Qv2ray&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</item>
<item>
<layout class="QHBoxLayout" name="horizontalLayout_9">
<item>
<widget class="QLabel" name="label_29">
<property name="text">
<string>License:</string>
</property>
</widget>
</item>
<item>
<layout class="QGridLayout" name="gridLayout_5" columnstretch="0,0">
<item row="2" column="1">
<widget class="QLabel" name="label_30">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
@ -1553,18 +1550,55 @@
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer_5">
<property name="orientation">
<enum>Qt::Horizontal</enum>
<item row="1" column="0">
<widget class="QLabel" name="label_27">
<property name="text">
<string>Official Repo:</string>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</widget>
</item>
<item row="0" column="1">
<widget class="QLabel" name="qvBuildTime">
<property name="text">
<string/>
</property>
</spacer>
</widget>
</item>
<item row="1" column="1">
<widget class="QLabel" name="label_28">
<property name="sizePolicy">
<sizepolicy hsizetype="Expanding" vsizetype="Preferred">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;a href=&quot;https://github.com/lhy0403/Qv2ray&quot;&gt;&lt;span style=&quot; text-decoration: underline; color:#2980b9;&quot;&gt;https://github.com/lhy0403/Qv2ray&lt;/span&gt;&lt;/a&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="textFormat">
<enum>Qt::RichText</enum>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<property name="openExternalLinks">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0">
<widget class="QLabel" name="label_29">
<property name="text">
<string>License:</string>
</property>
</widget>
</item>
<item row="0" column="0">
<widget class="QLabel" name="label_26">
<property name="text">
<string>Built Time:</string>
</property>
</widget>
</item>
</layout>
</item>
@ -1580,22 +1614,24 @@
<string>&lt;!DOCTYPE HTML PUBLIC &quot;-//W3C//DTD HTML 4.0//EN&quot; &quot;http://www.w3.org/TR/REC-html40/strict.dtd&quot;&gt;
&lt;html&gt;&lt;head&gt;&lt;meta name=&quot;qrichtext&quot; content=&quot;1&quot; /&gt;&lt;style type=&quot;text/css&quot;&gt;
p, li { white-space: pre-wrap; }
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'Noto Sans'; font-size:10pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; font-weight:600; color:#d68952;&quot;&gt;This program comes with ABSOLUTELY NO WARRANTY.&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; font-weight:600; color:#d68952;&quot;&gt;This is free software, and you are welcome to redistribute it under certain conditions.&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (C) 2019 Leroy.H.Y (@lhy0403): Qv2ray Current Developer&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (C) 2019 Hork (@aliyuchang33): Hv2ray Initial Designs &amp;amp; gRPC implementation&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (C) 2019 SOneWinstone (@SoneWinstone): Hv2ray/Qv2ray HTTP Request Helper&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Qv2ray ArtWork Done By ArielAxionL (@axionl)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;TheBadGateway (@thebadgateway): Qv2ray Russian Translations&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Riko (@rikakomoe): Qv2ray patch 8a8c1a/PR115&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Noto Sans'; color:#d68952;&quot;&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; font-weight:600; color:#d68952;&quot;&gt;Libraries that have been used in Qv2ray are listed below (Sorted by date added):&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (c) 2019 dridk (@dridk): X2Struct (Apache)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (c) 2011 SCHUTZ Sacha (@dridk): QJsonModel (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (c) 2019 Nikolaos Ftylitakis (@ftylitak): QZXing (Apache2)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (c) 2016 Singein (@Singein): ScreenShot (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'Noto Sans'; color:#d68952;&quot;&gt;Copyright (c) 2016 Nikhil Marathe (@nikhilm): QHttpServer (MIT)&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
&lt;/style&gt;&lt;/head&gt;&lt;body style=&quot; font-family:'MS Shell Dlg 2'; font-size:8.25pt; font-weight:400; font-style:normal;&quot;&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; font-weight:600; color:#d68952;&quot;&gt;This program comes with ABSOLUTELY NO WARRANTY.&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; font-weight:600; color:#d68952;&quot;&gt;This is free software, and you are welcome to redistribute it under certain conditions.&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (C) 2019 Leroy.H.Y (@lhy0403): Qv2ray Current Developer&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (C) 2019 Hork (@aliyuchang33): Hv2ray Initial Designs &amp;amp; gRPC implementation&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (C) 2019 SOneWinstone (@SoneWinstone): Hv2ray/Qv2ray HTTP Request Helper&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Qv2ray ArtWork designs done by ArielAxionL (@axionl)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;TheBadGateway (@thebadgateway): Qv2ray Russian Translations&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Riko (@rikakomoe): Qv2ray patch 8a8c1a/PR115&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot;-qt-paragraph-type:empty; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px; font-family:'Noto Sans'; font-size:10pt; color:#d68952;&quot;&gt;&lt;br /&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; font-weight:600; color:#d68952;&quot;&gt;Libraries that have been used in Qv2ray are listed below (Sorted by date added):&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2019 dridk (@dridk): X2Struct (Apache)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2011 SCHUTZ Sacha (@dridk): QJsonModel (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2019 Nikolaos Ftylitakis (@ftylitak): QZXing (Apache2)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2016 Singein (@Singein): ScreenShot (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2016 Nikhil Marathe (@nikhilm): QHttpServer (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2019 Itay Grudev (@itay-grudev): SingleApplication (MIT)&lt;/span&gt;&lt;/p&gt;
&lt;p style=&quot; margin-top:0px; margin-bottom:0px; margin-left:0px; margin-right:0px; -qt-block-indent:0; text-indent:0px;&quot;&gt;&lt;span style=&quot; font-family:'MonoSpace'; font-size:10pt; color:#d68952;&quot;&gt;Copyright (c) 2019 paceholder (@paceholder): nodeeditor (QNodeEditor modified by lhy0403) (BSD-3-Clause)&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
</widget>
</item>

View File

@ -63,6 +63,7 @@ RouteEditor::RouteEditor(QJsonObject connection, QWidget *parent) : QDialog(pare
{
setupUi(this);
isLoading = true;
setWindowFlags(windowFlags() | Qt::WindowMaximizeButtonHint);
//
SetupNodeWidget();
//