chore: update gpui
This commit is contained in:
@@ -574,8 +574,8 @@ impl DockArea {
|
||||
window,
|
||||
move |_, _, event, window, cx| {
|
||||
if let PanelEvent::LayoutChanged = event {
|
||||
cx.spawn_in(window, |view, mut window| async move {
|
||||
_ = view.update_in(&mut window, |view, window, cx| {
|
||||
cx.spawn_in(window, async move |view, window| {
|
||||
_ = view.update_in(window, |view, window, cx| {
|
||||
view.update_toggle_button_tab_panels(window, cx)
|
||||
});
|
||||
})
|
||||
@@ -609,8 +609,8 @@ impl DockArea {
|
||||
move |_, panel, event, window, cx| match event {
|
||||
PanelEvent::ZoomIn => {
|
||||
let panel = panel.clone();
|
||||
cx.spawn_in(window, |view, mut window| async move {
|
||||
_ = view.update_in(&mut window, |view, window, cx| {
|
||||
cx.spawn_in(window, async move |view, window| {
|
||||
_ = view.update_in(window, |view, window, cx| {
|
||||
view.set_zoomed_in(panel, window, cx);
|
||||
cx.notify();
|
||||
});
|
||||
@@ -618,15 +618,15 @@ impl DockArea {
|
||||
.detach();
|
||||
}
|
||||
PanelEvent::ZoomOut => cx
|
||||
.spawn_in(window, |view, mut window| async move {
|
||||
_ = view.update_in(&mut window, |view, window, cx| {
|
||||
.spawn_in(window, async move |view, window| {
|
||||
_ = view.update_in(window, |view, window, cx| {
|
||||
view.set_zoomed_out(window, cx);
|
||||
});
|
||||
})
|
||||
.detach(),
|
||||
PanelEvent::LayoutChanged => {
|
||||
cx.spawn_in(window, |view, mut window| async move {
|
||||
_ = view.update_in(&mut window, |view, window, cx| {
|
||||
cx.spawn_in(window, async move |view, window| {
|
||||
_ = view.update_in(window, |view, window, cx| {
|
||||
view.update_toggle_button_tab_panels(window, cx)
|
||||
});
|
||||
})
|
||||
|
||||
@@ -181,7 +181,7 @@ impl TabPanel {
|
||||
self.focus_active_panel(window, cx);
|
||||
|
||||
// Sync the active state to all panels
|
||||
cx.spawn(|view, cx| async move {
|
||||
cx.spawn(async move |view, cx| {
|
||||
_ = cx.update(|cx| {
|
||||
_ = view.update(cx, |view, cx| {
|
||||
if let Some(last_active) = view.panels.get(last_active_ix) {
|
||||
@@ -255,7 +255,7 @@ impl TabPanel {
|
||||
window: &mut Window,
|
||||
cx: &mut Context<Self>,
|
||||
) {
|
||||
cx.spawn_in(window, |view, mut cx| async move {
|
||||
cx.spawn_in(window, async move |view, cx| {
|
||||
cx.update(|window, cx| {
|
||||
view.update(cx, |view, cx| {
|
||||
view.will_split_placement = Some(placement);
|
||||
@@ -986,7 +986,7 @@ impl TabPanel {
|
||||
});
|
||||
}
|
||||
|
||||
cx.spawn_in(window, |_, mut cx| async move {
|
||||
cx.spawn_in(window, async move |_, cx| {
|
||||
cx.update(|window, cx| {
|
||||
tab_panel.update(cx, |view, cx| view.remove_self_if_empty(window, cx))
|
||||
})
|
||||
@@ -1021,9 +1021,9 @@ impl TabPanel {
|
||||
|
||||
self.is_zoomed = !self.is_zoomed;
|
||||
|
||||
cx.spawn(|view, cx| {
|
||||
cx.spawn({
|
||||
let is_zoomed = self.is_zoomed;
|
||||
async move {
|
||||
async move |view, cx| {
|
||||
_ = cx.update(|cx| {
|
||||
_ = view.update(cx, |view, cx| {
|
||||
view.set_zoomed(is_zoomed, cx);
|
||||
|
||||
Reference in New Issue
Block a user