fix: holy motherfucking shit that took so long

This commit is contained in:
Rio Keefe
2025-04-29 15:31:32 +01:00
parent 385a0cd186
commit 9b006836c6
8 changed files with 126 additions and 103 deletions

View File

@@ -1,13 +1,18 @@
mod commands;
mod state;
pub mod utils;
#[cfg(target_os = "linux")]
mod window;
#[cfg(any(target_os = "linux", target_os = "macos", target_os = "windows"))]
mod screenshot;
#[cfg(target_os = "linux")]
mod commands;
#[cfg(target_os = "linux")]
mod shortcut;
#[cfg(target_os = "linux")]
mod state;
#[cfg(target_os = "linux")]
use state::new_shared_watcher_state;
#[cfg(target_os = "linux")]
use window::setup_window;
#[cfg(any(target_os = "linux", target_os = "macos", target_os = "windows"))]
@@ -47,12 +52,12 @@ pub fn desktop() {
#[cfg(any(target_os = "ios", target_os = "android"))]
pub fn android() {
tauri::Builder::default()
.plugin(tauri_plugin_fs::init())
.plugin(tauri_plugin_store::Builder::new().build())
.plugin(tauri_plugin_http::init())
.plugin(tauri_plugin_sharetarget::init())
//.plugin(tauri_plugin_fs::init())
//.plugin(tauri_plugin_store::Builder::new().build())
//.plugin(tauri_plugin_http::init())
//.plugin(tauri_plugin_sharetarget::init())
.setup(|app| {
setup_window(app)?;
// setup_window(app)?;
Ok(())
})

View File

@@ -51,6 +51,7 @@ fn screenshot(path: &PathBuf) -> Result<Output, String> {
}
/// Takes a screenshot of a selected area and returns the image data as base64
#[cfg(target_os = "linux")]
pub fn take_area_screenshot<R: Runtime>(app: &AppHandle<R>) -> Result<String, String> {
// Create a temporary file path
let temp_dir = std::env::temp_dir();