截图模块初始化

This commit is contained in:
zhongluofeng
2026-07-31 18:30:55 +08:00
parent 9d8f963cc6
commit 66575c6166
16 changed files with 1011 additions and 481 deletions
+20 -3
View File
@@ -9,6 +9,7 @@ mod monitor_kernel;
mod network_monitor;
mod osd_window;
mod process_manager;
mod screenshot;
mod snap_fix;
mod tray_menu;
@@ -43,6 +44,12 @@ use process_manager::{
get_all_process_status, get_process_status, start_monitoring_thread, start_process,
stop_all_processes, stop_process, ProcessManager,
};
use screenshot::commands::{
screenshot_capture_fullscreen, screenshot_capture_window, screenshot_copy_image,
screenshot_crop_stored, screenshot_enum_windows, screenshot_get_editor_image,
screenshot_save_png, screenshot_set_editor_image, screenshot_take_fullscreen,
screenshot_window_from_point,
};
use clipboard::{
ClipboardManager,
clipboard_clear, clipboard_copy_back, clipboard_count, clipboard_delete, clipboard_get_history,
@@ -51,7 +58,7 @@ use clipboard::{
clipboard_set_pinned, clipboard_show_popup, clipboard_show_window, clipboard_start,
clipboard_status, clipboard_stop, clipboard_unregister_shortcut,
};
use tray_menu::{tray_menu_action, tray_menu_hide, tray_menu_show_window};
use tray_menu::{tray_menu_action, tray_menu_hide, tray_menu_ready};
#[tauri::command]
fn greet(name: &str) -> String {
@@ -185,8 +192,18 @@ pub fn run() {
clipboard_paste_to_target,
tray_menu_action,
tray_menu_hide,
tray_menu_show_window,
snap_fix::fix_snap_background
tray_menu_ready,
snap_fix::fix_snap_background,
screenshot_capture_fullscreen,
screenshot_take_fullscreen,
screenshot_crop_stored,
screenshot_window_from_point,
screenshot_enum_windows,
screenshot_capture_window,
screenshot_set_editor_image,
screenshot_get_editor_image,
screenshot_copy_image,
screenshot_save_png
])
.setup(|app| {
// 初始化日志系统,日志目录: {app_data_dir}/logs/