From 5f9bb6a7e7b0599dfd3b838894b5fe4f77d27797 Mon Sep 17 00:00:00 2001 From: Julia Radzhabova Date: Fri, 2 Mar 2018 11:52:15 +0300 Subject: [PATCH] [SSE] Fix Bug 37041 --- apps/spreadsheeteditor/main/app/view/CellEditor.js | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/apps/spreadsheeteditor/main/app/view/CellEditor.js b/apps/spreadsheeteditor/main/app/view/CellEditor.js index 9cb0fbd79..b5678ed54 100644 --- a/apps/spreadsheeteditor/main/app/view/CellEditor.js +++ b/apps/spreadsheeteditor/main/app/view/CellEditor.js @@ -81,8 +81,11 @@ define([ this.$btnfunc = $('#ce-func-label', this.el); var me = this; - this.$cellname.on('focusin', function(e){ - me.$cellname.select().one('mouseup', function (e) {e.preventDefault();}); + this.$cellname.on('focus', function(e){ + var txt = me.$cellname[0]; + txt.selectionStart = 0; + txt.selectionEnd = txt.value.length; + txt.scrollLeft = txt.scrollWidth; }); this.$btnfunc.addClass('disabled');