From e57ed9344816b3eb5ecf12a8ff1df6de16b0931f Mon Sep 17 00:00:00 2001 From: BerndN Date: Thu, 26 Mar 2020 13:42:16 +0100 Subject: [PATCH 1/2] [22639] Fix backspaceKey backspaceKey in position 1 of line 1 returning wrong position to SE --- .../behaviors/revsecommoneditorbehavior.livecodescript | 2 ++ 1 file changed, 2 insertions(+) diff --git a/Toolset/palettes/script editor/behaviors/revsecommoneditorbehavior.livecodescript b/Toolset/palettes/script editor/behaviors/revsecommoneditorbehavior.livecodescript index f9eca8a84d..954407a535 100644 --- a/Toolset/palettes/script editor/behaviors/revsecommoneditorbehavior.livecodescript +++ b/Toolset/palettes/script editor/behaviors/revsecommoneditorbehavior.livecodescript @@ -2480,8 +2480,10 @@ on backspaceKey put __GetPreference("editor,autoformat", true) into tAutoFormat if tAutoFormat then + if tTo is 0 then put 1 into tTo put caretPositionLeft(tLineStart, tTo, tScript) + 1 into tAt else + if tTo is 0 then put 1 into tTo put tTo into tAt end if put tTo - tAt + 1 into tLength From f9332f265d1686cc02935a8f65201af3c86fb0b7 Mon Sep 17 00:00:00 2001 From: BerndN Date: Thu, 26 Mar 2020 13:44:47 +0100 Subject: [PATCH 2/2] Create bugfix-22639.md --- notes/bugfix-22639.md | 1 + 1 file changed, 1 insertion(+) create mode 100644 notes/bugfix-22639.md diff --git a/notes/bugfix-22639.md b/notes/bugfix-22639.md new file mode 100644 index 0000000000..0434e0f5b2 --- /dev/null +++ b/notes/bugfix-22639.md @@ -0,0 +1 @@ +# Fix backspaceKey returning wrong position to SE