Maintain application metadata in beacon connection

This commit is contained in:
Héctor Ramón Jiménez 2025-05-01 04:19:44 +02:00
parent dc69fdee46
commit e82b10da77
No known key found for this signature in database
GPG key ID: 7CC46565708259A7
6 changed files with 88 additions and 21 deletions

View file

@ -174,7 +174,15 @@ impl<P: Program> Application<P> {
Self: 'static,
{
#[cfg(all(feature = "debug", not(target_arch = "wasm32")))]
let program = iced_devtools::attach(self.raw);
let program = {
iced_debug::init(iced_debug::Metadata {
name: P::name(),
theme: None,
can_time_travel: cfg!(feature = "time-travel"),
});
iced_devtools::attach(self.raw)
};
#[cfg(any(not(feature = "debug"), target_arch = "wasm32"))]
let program = self.raw;

View file

@ -118,7 +118,15 @@ impl<P: Program> Daemon<P> {
Self: 'static,
{
#[cfg(all(feature = "debug", not(target_arch = "wasm32")))]
let program = iced_devtools::attach(self.raw);
let program = {
iced_debug::init(iced_debug::Metadata {
name: P::name(),
theme: None,
can_time_travel: cfg!(feature = "time-travel"),
});
iced_devtools::attach(self.raw)
};
#[cfg(any(not(feature = "debug"), target_arch = "wasm32"))]
let program = self.raw;