Store AnyViewHandle inside ViewHandle and Deref to it
This commit is contained in:
parent
59fb4b3d29
commit
82a713fd1d
32 changed files with 154 additions and 204 deletions
|
@ -137,11 +137,7 @@ impl TestAppContext {
|
|||
(window_id, view)
|
||||
}
|
||||
|
||||
pub fn add_view<T, F>(
|
||||
&mut self,
|
||||
parent_handle: impl Into<AnyViewHandle>,
|
||||
build_view: F,
|
||||
) -> ViewHandle<T>
|
||||
pub fn add_view<T, F>(&mut self, parent_handle: &AnyViewHandle, build_view: F) -> ViewHandle<T>
|
||||
where
|
||||
T: View,
|
||||
F: FnOnce(&mut ViewContext<T>) -> T,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue