Desktop: Move preferences persistence to native (#3138)

* Move preference persistence to native

* Pass preferences as struct instead of serialized to string
This commit is contained in:
Timon
2025-09-09 16:22:25 +00:00
committed by GitHub
parent 4261b7dad1
commit 50be13522b
12 changed files with 80 additions and 20 deletions
@@ -1,7 +1,7 @@
use graphene_std::Color;
use graphene_std::raster::Image;
use graphite_editor::messages::app_window::app_window_message_handler::AppWindowPlatform;
use graphite_editor::messages::prelude::{AppWindowMessage, DocumentMessage, PortfolioMessage};
use graphite_editor::messages::prelude::{AppWindowMessage, DocumentMessage, PortfolioMessage, PreferencesMessage};
use crate::messages::Platform;
@@ -140,5 +140,9 @@ pub(super) fn handle_desktop_wrapper_message(dispatcher: &mut DesktopWrapperMess
let message = PortfolioMessage::SelectDocument { document_id: id };
dispatcher.queue_editor_message(message.into());
}
DesktopWrapperMessage::LoadPreferences { preferences } => {
let message = PreferencesMessage::Load { preferences };
dispatcher.queue_editor_message(message.into());
}
}
}