gpui: Update docs to reflect removal of View, ViewContext, WindowContext (#24008)
This PR updates function signatures, docstrings, and gpui's other documentation to reflect it's new state following the merge of `Model` and `View` into `Entity` as well as the removal of `WindowContext`. Release Notes: - N/A
This commit is contained in:
parent
027fe1b4b5
commit
0c94bdc8e4
25 changed files with 330 additions and 329 deletions
|
@ -2337,7 +2337,7 @@ pub mod tests {
|
|||
let project = Project::test(fs.clone(), ["/dir".as_ref()], cx).await;
|
||||
let window = cx.add_window(|window, cx| Workspace::test_new(project, window, cx));
|
||||
let workspace = window;
|
||||
let search_bar = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
|
||||
let active_item = cx.read(|cx| {
|
||||
workspace
|
||||
|
@ -2577,7 +2577,7 @@ pub mod tests {
|
|||
let project = Project::test(fs.clone(), ["/dir".as_ref()], cx).await;
|
||||
let window = cx.add_window(|window, cx| Workspace::test_new(project, window, cx));
|
||||
let workspace = window;
|
||||
let search_bar = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
|
||||
let active_item = cx.read(|cx| {
|
||||
workspace
|
||||
|
@ -2879,7 +2879,7 @@ pub mod tests {
|
|||
});
|
||||
let window = cx.add_window(|window, cx| Workspace::test_new(project, window, cx));
|
||||
let workspace = window.root(cx).unwrap();
|
||||
let search_bar = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
|
||||
let active_item = cx.read(|cx| {
|
||||
workspace
|
||||
|
@ -2997,7 +2997,7 @@ pub mod tests {
|
|||
let project = Project::test(fs.clone(), ["/dir".as_ref()], cx).await;
|
||||
let window = cx.add_window(|window, cx| Workspace::test_new(project, window, cx));
|
||||
let workspace = window.root(cx).unwrap();
|
||||
let search_bar = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
|
||||
window
|
||||
.update(cx, {
|
||||
|
@ -3333,8 +3333,8 @@ pub mod tests {
|
|||
.update(cx, |this, _, _| this.panes().to_owned())
|
||||
.unwrap();
|
||||
|
||||
let search_bar_1 = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar_2 = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar_1 = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar_2 = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
|
||||
assert_eq!(panes.len(), 1);
|
||||
let first_pane = panes.first().cloned().unwrap();
|
||||
|
@ -3587,7 +3587,7 @@ pub mod tests {
|
|||
.focus_handle(cx)
|
||||
.contains_focused(window, cx))
|
||||
.unwrap());
|
||||
let search_bar = window.build_model(cx, |_, _| ProjectSearchBar::new());
|
||||
let search_bar = window.build_entity(cx, |_, _| ProjectSearchBar::new());
|
||||
window
|
||||
.update(cx, {
|
||||
let search_bar = search_bar.clone();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue