Allow modals to override their dismissal

Co-Authored-By: Mikayla Maki <mikayla.c.maki@gmail.com>
This commit is contained in:
Joseph T. Lyons 2023-12-08 15:26:06 -05:00
parent 1c850f495c
commit 113c7287df
13 changed files with 118 additions and 46 deletions

View file

@ -16,7 +16,7 @@ use util::{
channel::{parse_zed_link, ReleaseChannel, RELEASE_CHANNEL},
ResultExt,
};
use workspace::Workspace;
use workspace::{ModalView, Workspace};
use zed_actions::OpenZedURL;
actions!(Toggle);
@ -26,6 +26,8 @@ pub fn init(cx: &mut AppContext) {
cx.observe_new_views(CommandPalette::register).detach();
}
impl ModalView for CommandPalette {}
pub struct CommandPalette {
picker: View<Picker<CommandPaletteDelegate>>,
}