mirror of
https://github.com/slint-ui/slint.git
synced 2025-08-31 15:47:26 +00:00
live-preview: Recursively set debug-handler
This commit is contained in:
parent
bd3c001c5d
commit
d21e6680a3
2 changed files with 15 additions and 2 deletions
|
@ -965,9 +965,10 @@ impl ComponentDefinition {
|
|||
handler: impl Fn(&Option<i_slint_compiler::diagnostics::SourceLocation>, &str) + 'static,
|
||||
_: i_slint_core::InternalToken,
|
||||
) {
|
||||
generativity::make_guard!(guard);
|
||||
let handler = Rc::new(handler);
|
||||
*self.inner.unerase(guard).debug_handler.borrow_mut() = handler;
|
||||
|
||||
generativity::make_guard!(guard);
|
||||
self.inner.unerase(guard).recursively_set_debug_handler(handler);
|
||||
}
|
||||
/// Creates a new instance of the component and returns a shared handle to it.
|
||||
pub fn create(&self) -> Result<ComponentInstance, PlatformError> {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue