43 Commits

Author SHA1 Message Date
wonfen
23b0493d0b perf: optimize network requests and update logic to support aborting 2025-05-04 11:25:48 +08:00
wonfen
32b6821b8a feat: add network manager to optimize network request handling 2025-04-30 21:30:28 +08:00
Tunglies
9d9dd73790 chore: remove fast-dev profile and enhance dev profile settings 2025-04-27 15:13:34 +08:00
tiegen
7383459b9a
feat: clean proxy settings before exit (#3404) 2025-04-26 18:09:53 +08:00
wonfen
d6a79316a6 feat: toggle next auto-update time on subscription card click and show update result feedback 2025-04-25 17:17:34 +08:00
wonfen
8d62c0d521 feat: auto-fallback to Clash proxy on scheduled subscription updates; refactor fallback logic and add request timeout 2025-04-24 22:51:45 +08:00
wonfen
05b910dc17 feat: close all connections when disable sysporxy 2025-04-19 15:10:49 +08:00
逐雁南飛
b70cad537c 添加代理主机的设置,允许代理设置为其他IP(非127.0.0.1) (#2963)
允许下拉选择ip地址(支持IPv6)、localhost、以及当前系统的主机名,同时兼容手工输入
2025-04-17 16:47:21 +08:00
Tunglies
1970155c51 fix: macos use hotkey closing window can not entry auto-lightweight-mode #3326 2025-04-12 03:29:57 +08:00
Tunglies
51ef1329be Refactor async runtime usage with AsyncHandler wrapper 2025-04-11 18:00:35 +08:00
Tunglies
b6a6f5f434 Add AsyncHandler for wrapping task spawning 2025-04-11 17:30:30 +08:00
Tunglies
0b8d08d13b Update logging macros usage in timer module
Replace log macros with custom logging macros in timer module
2025-04-05 11:36:38 +08:00
Tunglies
0de304d4e3 Fix and Optimize
fix: #3187 and #3096, silent startup can not trigger lightweight mode
fix: optimize startup initializing processing
2025-04-05 10:28:27 +08:00
wonfen
7b5fd104de fix: #3227, use async operations to avoid blocking on 2025-04-01 12:52:59 +08:00
Tunglies
3fa130695c rm: setup_window_state_monitor for temporary due to unkown window control behavior 2025-03-31 21:52:50 +08:00
Tunglies
ad1f2bea3b fix: unused Result 2025-03-31 21:44:12 +08:00
Tunglies
cd4bfdd743 feat: change proxy mode to close connections if enable auto close connections 2025-03-31 21:43:29 +08:00
wonfen
1bd503a654 feat: add error prompt for initial config loading to prevent switching to invalid subscription 2025-03-30 10:56:30 +08:00
Tunglies
e8e16f7d57 refactor(logging): replace log_err! with structured logging_error! calls
refactor(cm-service): better error handling from Backend to Frontend
2025-03-28 03:39:34 +08:00
Tunglies
d91653b218 feat: add config log type and improve window logging 2025-03-26 16:43:26 +08:00
Tunglies
98d3a48710 refactor: replace println with logging in core validation and tray quit function 2025-03-26 04:31:38 +08:00
Tunglies
df5424d55e feat: add logging module and update running mode terminology 2025-03-25 23:05:09 +08:00
Tunglies
f50fe9159d refactor: remove deprecated lightweight module and adjust macOS activation policy 2025-03-24 20:11:38 +08:00
Tunglies
09f6917638 fix: update lightweight mode implementation and fix MacOS dock icon visibility 2025-03-24 19:16:21 +08:00
Tunglies
1a7c076e07 feat: add option to enable/disable tray icon display on MacOS 2025-03-23 16:37:27 +08:00
Tunglies
d669650758 feat: add lightweight mode entry and related hotkey support 2025-03-23 03:10:48 +08:00
Tunglies
1d88d98ea1 feat: ensure Mihomo and Verge services are running before executing commands 2025-03-22 17:05:42 +08:00
wonfen
2ab923da87 fix: port setting sync problem 2025-03-21 12:28:51 +08:00
Tunglies
84a5cf6b89 feat(hotkey): macos support CMD+W to close window as default 2025-03-20 13:02:26 +08:00
Tunglies
81b5501b0e feat: implement auto lightweight mode timer functionality
This commit implements the automatic lightweight mode feature with timer functionality:

- Rename configuration properties from auto_enter_lite_mode to enable_auto_light_weight_mode and auto_enter_lite_mode_delay to auto_light_weight_minutes for better clarity
- Add window event listeners to detect when window is closed or gets focus
- Implement timer system to automatically enter lightweight mode after configured time
- Remove exit_lightweight_mode function as it's no longer needed with the new implementation
- Update UI components to reflect the new property names
- Add logging for lightweight mode operations
- Initialize lightweight mode based on user configuration at startup

The feature now allows users to set a timer that will automatically enter lightweight mode
after closing the main window, which can be cancelled by focusing the window again.
2025-03-20 06:01:38 +08:00
Tunglies
91ccb3045c feat: implement lightweight mode functionality and update related settings 2025-03-20 03:23:14 +08:00
wonfen
61f019f194 fix: cannot detect service mode on home card 2025-03-19 05:25:38 +08:00
Tunglies
772ecdd3b0 refactor: improve proxy retrieval and add window destruction method 2025-03-19 02:04:01 +08:00
Tunglies
d6a48deb5a refactor(config): use bitflags for tracking update operations
Replace multiple boolean variables with a bitflag approach for tracking
required update operations in the patch_verge function. This improves
code maintainability and potentially performance by:

1. Using a single integer variable with bit operations instead of multiple booleans
2. Defining clear flags as enum variants for better code readability
3. Simplifying flag checks with bitwise operations

The UpdateFlags enum provides a clear and type-safe way to represent
different types of updates needed when patching Verge configuration.
2025-03-15 18:42:57 +08:00
Tunglies
1ec7a0f23c refactor: update request method handling to use reqwest::Method enum
fix: duplicated checks tray menu
2025-03-15 13:23:17 +08:00
wonfen
1f99cee78b feat: home page 2025-03-14 13:31:34 +08:00
Tunglies
b57c6e408a chore: git hooks for linter and formatter 2025-03-13 12:51:20 +08:00
Mimi
124934b012 feat: additional macos tray event handling option for menu display (#2958) 2025-03-13 10:08:38 +08:00
Tunglies
15e54df67c refactor: streamline clash mode handling and improve API interactions 2025-03-08 22:41:14 +08:00
wonfen
54d5586a60 perf: faster app exit 2025-03-07 13:44:07 +08:00
Tunglies
c957ea7b24 feat: fish env export support 2025-03-02 23:20:10 +08:00
Tunglies
9ee011514a refactor: rename cmds module to cmd for better consistency (#2830)
- Renamed `cmds` module to `cmd` for better naming consistency
- Reorganized command modules into separate files under src/cmd/
- Updated all imports and references to use the new module name
- Fixed missing dependency in webdav.rs to reference core::backup
- Updated tray module to use new cmd namespace
- Improved uwp.rs module structure using platform-specific implementations
- Removed unnecessary imports from various command files
2025-03-01 22:52:43 +08:00
Tunglies
184fd4a1ba refactor: reorganize feat.rs into modular structure (#2827)
Split the monolithic feat.rs file into specialized modules:
- backup.rs: WebDAV backup and restore functions
- clash.rs: Core management and testing functions
- config.rs: Configuration handling
- profile.rs: Profile management
- proxy.rs: Proxy and TUN mode controls
- window.rs: Dashboard window management

This improves code organization, readability, and maintainability
by grouping related functionality into logical modules.
2025-03-01 20:44:35 +08:00