mirror of
https://github.com/tauri-apps/tauri-plugin-single-instance.git
synced 2026-02-04 02:41:18 +01:00
feat: pass an AppHandle to the callback
This commit is contained in:
@@ -9,6 +9,6 @@
|
||||
"author": "",
|
||||
"license": "MIT",
|
||||
"dependencies": {
|
||||
"@tauri-apps/cli": "^1.0.0-rc.0"
|
||||
"@tauri-apps/cli": "^1.0.0-rc.15"
|
||||
}
|
||||
}
|
||||
|
||||
729
examples/vanilla/src-tauri/Cargo.lock
generated
729
examples/vanilla/src-tauri/Cargo.lock
generated
File diff suppressed because it is too large
Load Diff
@@ -10,11 +10,11 @@ rust-version = "1.57"
|
||||
[dependencies]
|
||||
serde_json = "1.0"
|
||||
serde = { version = "1.0", features = [ "derive" ] }
|
||||
tauri = { version = "1.0.0-rc.6", features = ["api-all"] }
|
||||
tauri = { version = "1.0.0-rc.16", features = ["api-all"] }
|
||||
tauri-plugin-single-instance = { path = "../../../" }
|
||||
|
||||
[build-dependencies]
|
||||
tauri-build = { version = "1.0.0-rc.5", features = [] }
|
||||
tauri-build = { version = "1.0.0-rc.14", features = [] }
|
||||
|
||||
[features]
|
||||
default = [ "custom-protocol" ]
|
||||
|
||||
@@ -5,8 +5,8 @@
|
||||
|
||||
fn main() {
|
||||
tauri::Builder::default()
|
||||
.plugin(tauri_plugin_single_instance::init(|argv, cwd| {
|
||||
println!("{argv:?}, {cwd}");
|
||||
.plugin(tauri_plugin_single_instance::init(|app, argv, cwd| {
|
||||
println!("{}, {argv:?}, {cwd}", app.package_info().name);
|
||||
}))
|
||||
.run(tauri::generate_context!())
|
||||
.expect("error while running tauri application");
|
||||
|
||||
Reference in New Issue
Block a user