mirror of
https://github.com/chylex/IntelliJ-IdeaVim.git
synced 2025-05-20 05:34:03 +02:00
Fix missing offset adjusting
This issue was found by property test
This commit is contained in:
parent
2c7b966ec2
commit
cda85ae534
@ -49,7 +49,9 @@ abstract class VimMotionGroupBase : VimMotionGroup {
|
|||||||
editor.mode.isEndAllowedIgnoringOnemore,
|
editor.mode.isEndAllowedIgnoringOnemore,
|
||||||
)
|
)
|
||||||
val newPos = VimVisualPosition(line, normalisedColumn, false)
|
val newPos = VimVisualPosition(line, normalisedColumn, false)
|
||||||
return editor.visualPositionToOffset(newPos).toAdjustedMotionOrError(intendedColumn)
|
val newOffset = editor.visualPositionToOffset(newPos)
|
||||||
|
val adjustedOffset = editor.normalizeOffset(newOffset, editor.isEndAllowed)
|
||||||
|
return adjustedOffset.toAdjustedMotionOrError(intendedColumn)
|
||||||
}
|
}
|
||||||
|
|
||||||
if (line < 0) {
|
if (line < 0) {
|
||||||
|
Loading…
Reference in New Issue
Block a user