Merge pull request #4864 from Zamoca42/fix/wsl-window-maximize-bug

fix: A bug with Wayland display (Error 71) in WSL
This commit is contained in:
Kiril Videlov 2024-09-10 17:23:34 +02:00 committed by GitHub
commit 620ea1418f
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -38,7 +38,7 @@ fn main() {
.target(LogTarget::LogDir)
.level(log::LevelFilter::Error);
tauri::Builder::default()
let builder = tauri::Builder::default()
.setup(move |tauri_app| {
let window = gitbutler_tauri::window::create(
&tauri_app.handle(),
@ -118,7 +118,6 @@ fn main() {
Ok(())
})
.plugin(tauri_plugin_window_state::Builder::default().build())
.plugin(tauri_plugin_single_instance::init(|_, _, _| {}))
.plugin(tauri_plugin_context_menu::init())
.plugin(tauri_plugin_store::Builder::default().build())
@ -239,7 +238,12 @@ fn main() {
}
_ => {}
}
})
});
#[cfg(not(target_os = "linux"))]
let builder = builder.plugin(tauri_plugin_window_state::Builder::default().build());
builder
.build(tauri_context)
.expect("Failed to build tauri app")
.run(|app_handle, event| {