Commit 31d63dac authored by Dmitry.Vikulov's avatar Dmitry.Vikulov Committed by Alexander.Trofimov

FormulaSelector: исправлен баг с dblClick в Mozilla

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55074 954022d7-b5bf-4e40-9824-e11837661b57
parent 24a55c66
......@@ -1707,6 +1707,19 @@
selector.style["fontSize"] = "12px";
document.body.appendChild(selector);
// Selection hack
var clearSelection = function() {
if (document.selection && document.selection.empty) {
document.selection.empty();
}
else if (window.getSelection) {
var sel = window.getSelection();
sel.removeAllRanges();
}
}
// TODO: В Mozilla избавиться от селекта текста при dblclick
var combo = document.createElement("ul");
combo.id = "formulaList";
combo.style["margin"] = 0;
......@@ -1737,7 +1750,7 @@
}
item.ondblclick = function(e) {
if ( e && (e.button === 0) ) {
var formulaName = this.innerText;
var formulaName = this.innerText || this.textContent;
var insertText = formulaName.substring(_this.input.value.length - 1) + "(";
_this._addChars(insertText);
_this._removeFormulaSelector();
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment