diff --git a/runtime/src/app_window.rs b/runtime/src/app_window.rs index a03a3440..57bf80d1 100644 --- a/runtime/src/app_window.rs +++ b/runtime/src/app_window.rs @@ -28,6 +28,15 @@ pub fn start_tauri() { let app = tauri::Builder::default() .setup(move |app| { let window = app.get_window("main").expect("Failed to get main window."); + + // Register a callback for file drop events: + window.on_window_event(|event| + if let tauri::WindowEvent::FileDrop(files) = event { + info!(Source = "Tauri"; "files were dropped: {files:?}"); + } + ); + + // Save the main window for later access: *MAIN_WINDOW.lock().unwrap() = Some(window); info!(Source = "Bootloader Tauri"; "Setup is running."); diff --git a/runtime/tauri.conf.json b/runtime/tauri.conf.json index ed4161f5..e85077b5 100644 --- a/runtime/tauri.conf.json +++ b/runtime/tauri.conf.json @@ -40,7 +40,8 @@ "resizable": true, "title": "MindWork AI Studio", "width": 1920, - "height": 1080 + "height": 1080, + "fileDropEnabled": true } ], "security": {