add clipboard monitor

This commit is contained in:
polv committed 2026-03-05 23:28:44 +07:00
1 parent 79031b3b32
commit 29a4d14893
7 files changed
+409 -15

No files matched your search

+1
View File
@@ -28,3 +28,4 @@ serde_json = "1.0.149"
serde = "1.0.228"
zip = "8.1.0"
tokio = { version = "1.50.0", features = ["io-util"] }
tauri-plugin-clipboard-manager = "2"
+2 -1
View File
@@ -9,6 +9,7 @@
"core:default",
"opener:default",
"http:default",
"fs:default"
"fs:default",
"clipboard-manager:allow-read-text"
]
}
+3 -8
View File
@@ -12,6 +12,7 @@ pub fn run() {
.plugin(tauri_plugin_fs::init())
.plugin(tauri_plugin_http::init())
.plugin(tauri_plugin_opener::init())
.plugin(tauri_plugin_clipboard_manager::init())
.setup(|app| {
let app_dir = app.path().app_config_dir()?;
create_dir_all(&app_dir)?;
@@ -34,12 +35,6 @@ pub fn run() {
execute_sql,
download_url,
])
.build(tauri::generate_context!())
.expect("error while running tauri application")
.run(|_app_handle, event| match event {
// On exit handler should be avoided for mobile
// and rusqlite already closes gracefully by default
tauri::RunEvent::ExitRequested { .. } => {}
_ => {}
});
.run(tauri::generate_context!())
.expect("error while running tauri application");
}