Fix migrate banner not showing markdown on file changes (#30575)
Fixes case where on file (settings/keymap) changes banner would appear but markdown was not visible. Regression caused by refactor happened in https://github.com/zed-industries/zed/pull/30456. Release Notes: - N/A
This commit is contained in:
parent
8db0333b04
commit
1a0eedb787
1 changed files with 9 additions and 9 deletions
|
@ -76,15 +76,15 @@ impl MigrationBanner {
|
||||||
migration_type,
|
migration_type,
|
||||||
migrated,
|
migrated,
|
||||||
} => {
|
} => {
|
||||||
if self.migration_type == Some(*migration_type) {
|
if *migrated {
|
||||||
let location = if *migrated {
|
self.migration_type = Some(*migration_type);
|
||||||
ToolbarItemLocation::Secondary
|
self.show(cx);
|
||||||
} else {
|
} else {
|
||||||
ToolbarItemLocation::Hidden
|
cx.emit(ToolbarItemEvent::ChangeLocation(
|
||||||
};
|
ToolbarItemLocation::Hidden,
|
||||||
cx.emit(ToolbarItemEvent::ChangeLocation(location));
|
));
|
||||||
cx.notify();
|
self.reset(cx);
|
||||||
}
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue