mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-01-29 00:35:38 +08:00
refactor(tray): comment out enable_tray_icon references for future removal #5161
Since network speed display in Tray on menu has been removed
This commit is contained in:
@@ -203,8 +203,7 @@ pub struct IVerge {
|
|||||||
|
|
||||||
pub enable_tray_speed: Option<bool>,
|
pub enable_tray_speed: Option<bool>,
|
||||||
|
|
||||||
pub enable_tray_icon: Option<bool>,
|
// pub enable_tray_icon: Option<bool>,
|
||||||
|
|
||||||
/// show proxy groups directly on tray root menu
|
/// show proxy groups directly on tray root menu
|
||||||
pub tray_inline_proxy_groups: Option<bool>,
|
pub tray_inline_proxy_groups: Option<bool>,
|
||||||
|
|
||||||
@@ -419,7 +418,7 @@ impl IVerge {
|
|||||||
webdav_username: None,
|
webdav_username: None,
|
||||||
webdav_password: None,
|
webdav_password: None,
|
||||||
enable_tray_speed: Some(false),
|
enable_tray_speed: Some(false),
|
||||||
enable_tray_icon: Some(true),
|
// enable_tray_icon: Some(true),
|
||||||
tray_inline_proxy_groups: Some(false),
|
tray_inline_proxy_groups: Some(false),
|
||||||
enable_global_hotkey: Some(true),
|
enable_global_hotkey: Some(true),
|
||||||
enable_auto_light_weight_mode: Some(false),
|
enable_auto_light_weight_mode: Some(false),
|
||||||
@@ -515,7 +514,7 @@ impl IVerge {
|
|||||||
patch!(webdav_username);
|
patch!(webdav_username);
|
||||||
patch!(webdav_password);
|
patch!(webdav_password);
|
||||||
patch!(enable_tray_speed);
|
patch!(enable_tray_speed);
|
||||||
patch!(enable_tray_icon);
|
// patch!(enable_tray_icon);
|
||||||
patch!(tray_inline_proxy_groups);
|
patch!(tray_inline_proxy_groups);
|
||||||
patch!(enable_auto_light_weight_mode);
|
patch!(enable_auto_light_weight_mode);
|
||||||
patch!(auto_light_weight_minutes);
|
patch!(auto_light_weight_minutes);
|
||||||
@@ -609,7 +608,7 @@ pub struct IVergeResponse {
|
|||||||
pub webdav_username: Option<String>,
|
pub webdav_username: Option<String>,
|
||||||
pub webdav_password: Option<String>,
|
pub webdav_password: Option<String>,
|
||||||
pub enable_tray_speed: Option<bool>,
|
pub enable_tray_speed: Option<bool>,
|
||||||
pub enable_tray_icon: Option<bool>,
|
// pub enable_tray_icon: Option<bool>,
|
||||||
pub tray_inline_proxy_groups: Option<bool>,
|
pub tray_inline_proxy_groups: Option<bool>,
|
||||||
pub enable_auto_light_weight_mode: Option<bool>,
|
pub enable_auto_light_weight_mode: Option<bool>,
|
||||||
pub auto_light_weight_minutes: Option<u64>,
|
pub auto_light_weight_minutes: Option<u64>,
|
||||||
@@ -686,7 +685,7 @@ impl From<IVerge> for IVergeResponse {
|
|||||||
webdav_username: verge.webdav_username,
|
webdav_username: verge.webdav_username,
|
||||||
webdav_password: verge.webdav_password,
|
webdav_password: verge.webdav_password,
|
||||||
enable_tray_speed: verge.enable_tray_speed,
|
enable_tray_speed: verge.enable_tray_speed,
|
||||||
enable_tray_icon: verge.enable_tray_icon,
|
// enable_tray_icon: verge.enable_tray_icon,
|
||||||
tray_inline_proxy_groups: verge.tray_inline_proxy_groups,
|
tray_inline_proxy_groups: verge.tray_inline_proxy_groups,
|
||||||
enable_auto_light_weight_mode: verge.enable_auto_light_weight_mode,
|
enable_auto_light_weight_mode: verge.enable_auto_light_weight_mode,
|
||||||
auto_light_weight_minutes: verge.auto_light_weight_minutes,
|
auto_light_weight_minutes: verge.auto_light_weight_minutes,
|
||||||
|
|||||||
@@ -94,7 +94,7 @@ fn determine_update_flags(patch: &IVerge) -> i32 {
|
|||||||
let http_enabled = patch.verge_http_enabled;
|
let http_enabled = patch.verge_http_enabled;
|
||||||
let http_port = patch.verge_port;
|
let http_port = patch.verge_port;
|
||||||
let enable_tray_speed = patch.enable_tray_speed;
|
let enable_tray_speed = patch.enable_tray_speed;
|
||||||
let enable_tray_icon = patch.enable_tray_icon;
|
// let enable_tray_icon = patch.enable_tray_icon;
|
||||||
let enable_global_hotkey = patch.enable_global_hotkey;
|
let enable_global_hotkey = patch.enable_global_hotkey;
|
||||||
let tray_event = &patch.tray_event;
|
let tray_event = &patch.tray_event;
|
||||||
let home_cards = patch.home_cards.clone();
|
let home_cards = patch.home_cards.clone();
|
||||||
@@ -149,7 +149,7 @@ fn determine_update_flags(patch: &IVerge) -> i32 {
|
|||||||
|| tun_tray_icon.is_some()
|
|| tun_tray_icon.is_some()
|
||||||
|| tray_icon.is_some()
|
|| tray_icon.is_some()
|
||||||
|| enable_tray_speed.is_some()
|
|| enable_tray_speed.is_some()
|
||||||
|| enable_tray_icon.is_some()
|
// || enable_tray_icon.is_some()
|
||||||
{
|
{
|
||||||
update_flags |= UpdateFlags::SystrayIcon as i32;
|
update_flags |= UpdateFlags::SystrayIcon as i32;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -307,7 +307,7 @@ export const LayoutViewer = forwardRef<DialogRef>((_, ref) => {
|
|||||||
</GuardState>
|
</GuardState>
|
||||||
</Item>
|
</Item>
|
||||||
)} */}
|
)} */}
|
||||||
{OS === "macos" && (
|
{/* {OS === "macos" && (
|
||||||
<Item>
|
<Item>
|
||||||
<ListItemText primary={t("Enable Tray Icon")} />
|
<ListItemText primary={t("Enable Tray Icon")} />
|
||||||
<GuardState
|
<GuardState
|
||||||
@@ -326,7 +326,7 @@ export const LayoutViewer = forwardRef<DialogRef>((_, ref) => {
|
|||||||
<Switch edge="end" />
|
<Switch edge="end" />
|
||||||
</GuardState>
|
</GuardState>
|
||||||
</Item>
|
</Item>
|
||||||
)}
|
)} */}
|
||||||
<Item>
|
<Item>
|
||||||
<ListItemText primary={t("Show Proxy Groups Inline")} />
|
<ListItemText primary={t("Show Proxy Groups Inline")} />
|
||||||
<GuardState
|
<GuardState
|
||||||
|
|||||||
2
src/services/types.d.ts
vendored
2
src/services/types.d.ts
vendored
@@ -803,7 +803,7 @@ interface IVergeConfig {
|
|||||||
sysproxy_tray_icon?: boolean;
|
sysproxy_tray_icon?: boolean;
|
||||||
tun_tray_icon?: boolean;
|
tun_tray_icon?: boolean;
|
||||||
enable_tray_speed?: boolean;
|
enable_tray_speed?: boolean;
|
||||||
enable_tray_icon?: boolean;
|
// enable_tray_icon?: boolean;
|
||||||
tray_inline_proxy_groups?: boolean;
|
tray_inline_proxy_groups?: boolean;
|
||||||
enable_tun_mode?: boolean;
|
enable_tun_mode?: boolean;
|
||||||
enable_auto_light_weight_mode?: boolean;
|
enable_auto_light_weight_mode?: boolean;
|
||||||
|
|||||||
Reference in New Issue
Block a user