From d539db4437c076b0897453e988cfa775de6e6099 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Fri, 6 Feb 2015 15:37:00 +0100 Subject: [PATCH] Properly setting caret after codeBox upon insert --- wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js index 3fefe1a1d0..81eb1f6eb6 100644 --- a/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js +++ b/wcfsetup/install/files/js/3rdParty/redactor/plugins/wbbcode.js @@ -1941,7 +1941,7 @@ RedactorPlugins.wbbcode = function() { // document.execCommand('insertHTML') seems to drop 'contenteditable="false"' for root element $codeBox.attr('contenteditable', 'false'); - this.caret.setAfter($codeBox); + this.wutil.setCaretAfter($codeBox[0]); this.modal.close(); }, this)); -- 2.20.1