Add open vim keymap command (#9953)
Release Notes: - Added a `vim: open default keymap` command to show the default Vim keymap ([#8593](https://github.com/zed-industries/zed/issues/8593)). Co-authored-by: Marshall Bowers <elliott.codes@gmail.com>
This commit is contained in:
parent
d1ad96782c
commit
339b29ef17
3 changed files with 30 additions and 3 deletions
|
@ -112,10 +112,16 @@ pub fn initialize_workspace(app_state: Arc<AppState>, cx: &mut AppContext) {
|
|||
let center_pane = workspace.active_pane().clone();
|
||||
initialize_pane(workspace, ¢er_pane, cx);
|
||||
cx.subscribe(&workspace_handle, {
|
||||
move |workspace, _, event, cx| {
|
||||
if let workspace::Event::PaneAdded(pane) = event {
|
||||
move |workspace, _, event, cx| match event {
|
||||
workspace::Event::PaneAdded(pane) => {
|
||||
initialize_pane(workspace, pane, cx);
|
||||
}
|
||||
workspace::Event::OpenBundledFile {
|
||||
text,
|
||||
title,
|
||||
language,
|
||||
} => open_bundled_file(workspace, text.clone(), title, language, cx),
|
||||
_ => {}
|
||||
}
|
||||
})
|
||||
.detach();
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue