Add scoped overlay hosts

This commit is contained in:
iris committed 2026-09-10 18:49:03 -04:00
1 parent a33fbca966
commit 44a5da378b
14 files changed
+882 -27

No files matched your search

+4 -4
View File
@@ -22,14 +22,14 @@ pub trait WidgetLike<Rsc: UiRsc, Tag>: Sized {
}
}
fn set_root(self, rsc: &mut Rsc, root: &mut impl HasRoot) {
fn set_root(self, rsc: &mut Rsc, root: &mut impl HasRoot<Rsc>) {
let id = self.add_strong(rsc);
root.set_root(id);
root.set_root(rsc, id);
}
}
pub trait HasRoot {
fn set_root(&mut self, root: StrongWidget);
pub trait HasRoot<Rsc> {
fn set_root(&mut self, rsc: &mut Rsc, root: StrongWidget);
}
pub trait WidgetArrLike<Rsc, const LEN: usize, Tag> {