@@ -214,7 +214,7 @@
"shift-d": "vim::DeleteToEndOfLine",
"shift-j": "vim::JoinLines",
"y": ["vim::PushOperator", "Yank"],
- "shift-y": "vim::YankToEndOfLine",
+ "shift-y": "vim::YankLine",
"i": "vim::InsertBefore",
"shift-i": "vim::InsertFirstNonWhitespace",
"a": "vim::InsertAfter",
@@ -52,7 +52,6 @@ actions!(
DeleteToEndOfLine,
Yank,
YankLine,
- YankToEndOfLine,
ChangeCase,
ConvertToUpperCase,
ConvertToLowerCase,
@@ -77,7 +76,6 @@ pub(crate) fn register(editor: &mut Editor, cx: &mut ViewContext<Vim>) {
Vim::action(editor, cx, Vim::convert_to_upper_case);
Vim::action(editor, cx, Vim::convert_to_lower_case);
Vim::action(editor, cx, Vim::yank_line);
- Vim::action(editor, cx, Vim::yank_to_end_of_line);
Vim::action(editor, cx, Vim::toggle_comments);
Vim::action(editor, cx, Vim::paste);
@@ -428,18 +426,6 @@ impl Vim {
self.yank_motion(motion::Motion::CurrentLine, count, cx)
}
- fn yank_to_end_of_line(&mut self, _: &YankToEndOfLine, cx: &mut ViewContext<Self>) {
- self.record_current_action(cx);
- let count = self.take_count(cx);
- self.yank_motion(
- motion::Motion::EndOfLine {
- display_lines: false,
- },
- count,
- cx,
- )
- }
-
fn toggle_comments(&mut self, _: &ToggleComments, cx: &mut ViewContext<Self>) {
self.record_current_action(cx);
self.update_editor(cx, |_, editor, cx| {
@@ -1408,15 +1394,6 @@ mod test {
);
}
- #[gpui::test]
- async fn test_shift_y(cx: &mut gpui::TestAppContext) {
- let mut cx = NeovimBackedTestContext::new(cx).await;
-
- cx.set_shared_state("helˇlo\n").await;
- cx.simulate_shared_keystrokes("shift-y").await;
- cx.shared_clipboard().await.assert_eq("lo");
- }
-
#[gpui::test]
async fn test_r(cx: &mut gpui::TestAppContext) {
let mut cx = NeovimBackedTestContext::new(cx).await;
@@ -1,4 +0,0 @@
-{"Put":{"state":"helˇlo\n"}}
-{"Key":"shift-y"}
-{"Get":{"state":"helˇlo\n","mode":"Normal"}}
-{"ReadRegister":{"name":"\"","value":"lo"}}