From 7d2bbd9e7b68e398044fe24294e45e903181e56c Mon Sep 17 00:00:00 2001 From: DuckSoft Date: Tue, 12 May 2020 20:12:49 +0800 Subject: [PATCH 1/2] add warning when users switch off api subsystem --- src/ui/w_PreferencesWindow.cpp | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/ui/w_PreferencesWindow.cpp b/src/ui/w_PreferencesWindow.cpp index a83ae8a9..6af797ce 100644 --- a/src/ui/w_PreferencesWindow.cpp +++ b/src/ui/w_PreferencesWindow.cpp @@ -1157,7 +1157,15 @@ void PreferencesWindow::on_enableAPI_stateChanged(int arg1) { LOADINGCHECK NEEDRESTART + CurrentConfig.apiConfig.enableAPI = arg1 == Qt::Checked; + if (arg1 == Qt::Unchecked) + { + const auto msgAPIDisableTitle = tr("Disabling API Subsystem"); + const auto msgAPIDisableMsg = tr("Disabling API subsystem will also disable the statistics function of Qv2ray.") + NEWLINE + // + tr("Speed chart and traffic statistics will be disabled."); + QvMessageBoxWarn(this, msgAPIDisableTitle, msgAPIDisableMsg); + } } void PreferencesWindow::on_updateChannelCombo_currentIndexChanged(int index) From 78aa2f645d083d98956970a2f692f303a8174b11 Mon Sep 17 00:00:00 2001 From: DuckSoft Date: Tue, 12 May 2020 20:20:54 +0800 Subject: [PATCH 2/2] updating translations --- translations/en_US.ts | 12 ++++++++++++ translations/ja_JP.ts | 12 ++++++++++++ translations/ru_RU.ts | 12 ++++++++++++ translations/zh_CN.ts | 12 ++++++++++++ 4 files changed, 48 insertions(+) diff --git a/translations/en_US.ts b/translations/en_US.ts index ebfea120..41df5f9f 100644 --- a/translations/en_US.ts +++ b/translations/en_US.ts @@ -1734,6 +1734,18 @@ But could damage your server if improperly used. For example, for updating subscriptions. + + Disabling API Subsystem + + + + Disabling API subsystem will also disable the statistics function of Qv2ray. + + + + Speed chart and traffic statistics will be disabled. + + QObject diff --git a/translations/ja_JP.ts b/translations/ja_JP.ts index 729473ae..288224b2 100644 --- a/translations/ja_JP.ts +++ b/translations/ja_JP.ts @@ -2450,6 +2450,18 @@ For example, for updating subscriptions. これらの設定はQv2ray自体のためのものです。 例えば、サブスクリプションの更新などです。 + + Disabling API Subsystem + APIサブシステムを無効 + + + Disabling API subsystem will also disable the statistics function of Qv2ray. + APIサブシステムを無効にすると、Qv2rayの統計機能も無効になります。 + + + Speed chart and traffic statistics will be disabled. + スピードチャートや交通統計は無効になります。 + QObject diff --git a/translations/ru_RU.ts b/translations/ru_RU.ts index b82073f9..425a6614 100644 --- a/translations/ru_RU.ts +++ b/translations/ru_RU.ts @@ -2349,6 +2349,18 @@ But could damage your server if improperly used. For example, for updating subscriptions. + + Disabling API Subsystem + + + + Disabling API subsystem will also disable the statistics function of Qv2ray. + + + + Speed chart and traffic statistics will be disabled. + + QObject diff --git a/translations/zh_CN.ts b/translations/zh_CN.ts index c2b03b9c..c1a9d3cc 100644 --- a/translations/zh_CN.ts +++ b/translations/zh_CN.ts @@ -2080,6 +2080,18 @@ For example, for updating subscriptions. 这些设定是针对 Qv2ray 本身的。 例如,用在更新订阅时。 + + Disabling API Subsystem + 禁用 API 子系统 + + + Disabling API subsystem will also disable the statistics function of Qv2ray. + 如果禁用 API 子系统,Qv2ray 的统计功能也会被一同禁用。 + + + Speed chart and traffic statistics will be disabled. + 速度图表和流量统计功能将不再可用。 + QObject