Handy/src-tauri/src/main.rs
CJ Pais e8902ee33e
Set WEBKIT_DISABLE_DMABUF_RENDERER=1 in env (#427)
* default WEBKIT_DISABLE_DMABUF_RENDERER disable

* try even earlier?
2025-12-11 13:01:04 +07:00

16 lines
507 B
Rust

// Prevents additional console window on Windows in release, DO NOT REMOVE!!
#![cfg_attr(not(debug_assertions), windows_subsystem = "windows")]
fn main() {
#[cfg(target_os = "linux")]
{
if std::path::Path::new("/dev/dri").exists()
&& std::env::var("WAYLAND_DISPLAY").is_err()
&& std::env::var("XDG_SESSION_TYPE").unwrap_or_default() == "x11"
{
std::env::set_var("WEBKIT_DISABLE_DMABUF_RENDERER", "1");
}
}
handy_app_lib::run()
}