X-Git-Url: https://git.mdrn.pl/fnpeditor.git/blobdiff_plain/e32eab0deee844e3df8dfdfd784da674260c2351..18d3b92:/src/editor/modules/documentCanvas/canvas/keyboard.js?ds=sidebyside diff --git a/src/editor/modules/documentCanvas/canvas/keyboard.js b/src/editor/modules/documentCanvas/canvas/keyboard.js index 99201bc..924a880 100644 --- a/src/editor/modules/documentCanvas/canvas/keyboard.js +++ b/src/editor/modules/documentCanvas/canvas/keyboard.js @@ -342,6 +342,10 @@ var keyEventHandlers = [ }, { success: function() { if(goto) { + if(!doc.containsNode(goto.wlxmlNode)) { + goto = s.startElement; + caretTo = s.startOffset; + } s.canvas.setCurrentElement(goto, {caretTo: caretTo}); } }