Remove more references to 'model' in GPUI APIs (#23693)

Release Notes:

- N/A
This commit is contained in:
Mikayla Maki 2025-01-26 20:00:27 -08:00 committed by GitHub
parent a6b1514246
commit 9cae96f82f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
115 changed files with 309 additions and 311 deletions

View file

@ -73,7 +73,7 @@ pub fn init(cx: &mut App) {
.and_then(|room| room.read(cx).channel_id());
if let Some(channel_id) = channel_id {
let workspace = cx.model().clone();
let workspace = cx.entity().clone();
window.defer(cx, move |window, cx| {
ChannelView::open(channel_id, None, workspace, window, cx)
.detach_and_log_err(cx)
@ -239,7 +239,7 @@ impl CollabPanel {
)
.detach();
let model = cx.model().downgrade();
let model = cx.entity().downgrade();
let list_state = ListState::new(
0,
gpui::ListAlignment::Top,
@ -1040,7 +1040,7 @@ impl CollabPanel {
window: &mut Window,
cx: &mut Context<Self>,
) {
let this = cx.model().clone();
let this = cx.entity().clone();
if !(role == proto::ChannelRole::Guest
|| role == proto::ChannelRole::Talker
|| role == proto::ChannelRole::Member)
@ -1170,7 +1170,7 @@ impl CollabPanel {
.channel_for_id(clipboard.channel_id)
.map(|channel| channel.name.clone())
});
let this = cx.model().clone();
let this = cx.entity().clone();
let context_menu = ContextMenu::build(window, cx, |mut context_menu, window, cx| {
if self.has_subchannels(ix) {
@ -1337,7 +1337,7 @@ impl CollabPanel {
window: &mut Window,
cx: &mut Context<Self>,
) {
let this = cx.model().clone();
let this = cx.entity().clone();
let in_room = ActiveCall::global(cx).read(cx).room().is_some();
let context_menu = ContextMenu::build(window, cx, |mut context_menu, _, _| {