mirror of
https://github.com/clash-verge-rev/clash-verge-rev.git
synced 2026-04-18 08:21:34 +08:00
refactor(linux): move Linux-specific mime.rs and workarounds.rs to utils/linux
This commit is contained in:
parent
4ab2720ac4
commit
712b8ff19b
@ -230,7 +230,7 @@ pub fn run() {
|
|||||||
}
|
}
|
||||||
|
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(target_os = "linux")]
|
||||||
utils::workarounds::apply_nvidia_dmabuf_renderer_workaround();
|
utils::linux::workarounds::apply_nvidia_dmabuf_renderer_workaround();
|
||||||
|
|
||||||
let _ = utils::dirs::init_portable_flag();
|
let _ = utils::dirs::init_portable_flag();
|
||||||
|
|
||||||
|
|||||||
@ -493,7 +493,7 @@ pub fn init_scheme() -> Result<()> {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
crate::utils::mime::ensure_mimeapps_entries(DESKTOP_FILE, DEEP_LINK_SCHEMES)?;
|
crate::utils::linux::mime::ensure_mimeapps_entries(DESKTOP_FILE, DEEP_LINK_SCHEMES)?;
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
#[cfg(target_os = "macos")]
|
#[cfg(target_os = "macos")]
|
||||||
|
|||||||
2
src-tauri/src/utils/linux/mod.rs
Normal file
2
src-tauri/src/utils/linux/mod.rs
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
pub mod mime;
|
||||||
|
pub mod workarounds;
|
||||||
@ -5,7 +5,7 @@ pub mod help;
|
|||||||
pub mod i18n;
|
pub mod i18n;
|
||||||
pub mod init;
|
pub mod init;
|
||||||
#[cfg(target_os = "linux")]
|
#[cfg(target_os = "linux")]
|
||||||
pub mod mime;
|
pub mod linux;
|
||||||
pub mod network;
|
pub mod network;
|
||||||
pub mod notification;
|
pub mod notification;
|
||||||
pub mod resolve;
|
pub mod resolve;
|
||||||
@ -13,5 +13,3 @@ pub mod server;
|
|||||||
pub mod singleton;
|
pub mod singleton;
|
||||||
pub mod tmpl;
|
pub mod tmpl;
|
||||||
pub mod window_manager;
|
pub mod window_manager;
|
||||||
#[cfg(target_os = "linux")]
|
|
||||||
pub mod workarounds;
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user