Desktop: Add native file dialogs (#2939)

* Add native open file dialog

* Add native save file dialog

* Fix integer underflow in defer message handler

* Update nix flake

* Cleanup

---------

Co-authored-by: Dennis Kobert <dennis@kobert.dev>
This commit is contained in:
Timon
2025-08-04 13:58:33 +00:00
committed by GitHub
co-authored by Dennis Kobert
parent c98477d8ed
commit 7cb42b9523
15 changed files with 665 additions and 64 deletions
@@ -12,6 +12,7 @@ use graph_craft::document::NodeId;
use graphene_std::raster::Image;
use graphene_std::raster::color::Color;
use graphene_std::text::{Font, TextAlign};
use std::path::PathBuf;
#[cfg(not(target_family = "wasm"))]
use crate::messages::portfolio::document::overlays::utility_types::OverlayContext;
@@ -63,6 +64,12 @@ pub enum FrontendMessage {
#[serde(rename = "commitDate")]
commit_date: String,
},
TriggerSaveDocument {
document_id: DocumentId,
name: String,
path: Option<PathBuf>,
document: String,
},
TriggerDownloadImage {
svg: String,
name: String,