mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
IDEA-60172 Ctrl + Y doesn't delete the line
This commit is contained in:
+2
-2
@@ -45,8 +45,8 @@ public class DeleteLineAction extends TextComponentEditorAction {
|
||||
int selectionEnd = selectionModel.getSelectionEnd();
|
||||
selectionModel.removeSelection();
|
||||
int lineStartOffset = document.getLineStartOffset(document.getLineNumber(selectionStart));
|
||||
int lineEndOffset = document.getLineEndOffset(document.getLineNumber(selectionEnd));
|
||||
document.deleteString(lineStartOffset, lineEndOffset);
|
||||
int nextLineStartOffset = Math.min(document.getTextLength(), document.getLineStartOffset(document.getLineNumber(selectionEnd) + 1));
|
||||
document.deleteString(lineStartOffset, nextLineStartOffset);
|
||||
return;
|
||||
}
|
||||
deleteLineAtCaret(editor);
|
||||
|
||||
Reference in New Issue
Block a user