Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

vim: Load keymap after base keymap (#24161)

Conrad Irwine17f3071899e
diff --git a/crates/zed/src/zed.rs b/crates/zed/src/zed.rs
index 9e0c92f1895..3daa543855d 100644
--- a/crates/zed/src/zed.rs
+++ b/crates/zed/src/zed.rs
@@ -1239,13 +1239,14 @@ pub fn load_default_keymap(cx: &mut App) {
}
cx.bind_keys(KeymapFile::load_asset(DEFAULT_KEYMAP_PATH, cx).unwrap());
- if VimModeSetting::get_global(cx).0 {
- cx.bind_keys(KeymapFile::load_asset(VIM_KEYMAP_PATH, cx).unwrap());
- }
if let Some(asset_path) = base_keymap.asset_path() {
cx.bind_keys(KeymapFile::load_asset(asset_path, cx).unwrap());
}
+
+ if VimModeSetting::get_global(cx).0 {
+ cx.bind_keys(KeymapFile::load_asset(VIM_KEYMAP_PATH, cx).unwrap());
+ }
}
pub fn handle_settings_changed(error: Option<anyhow::Error>, cx: &mut App) {