Commit afe4fe14 authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

addEventListener input on focus

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@53387 954022d7-b5bf-4e40-9824-e11837661b57
parent 1ee20500
......@@ -212,19 +212,12 @@
.on("input." + namespace, function () {return t._onInputTextArea.apply(t, arguments);});
// check input, it may have zero len, for mobile version
if (t.input) {
if (t.input && t.input.addEventListener) {
// Не поддерживаем drop на верхнюю строку
if (document.addEventListener) {
t.input.addEventListener("drop", function (e) {
e.preventDefault();
return false;
}, false);
} else {
t.input.attachEvent("ondrop", function (e) {
e.preventDefault();
return false;
});
}
t.input.addEventListener("drop", function (e) {
e.preventDefault();
return false;
}, false);
}
},
......
......@@ -348,18 +348,19 @@
});
$(this.input)
.on("focus", function () {
self.input.isFocused = true;
if (self.controller.settings.isViewerMode) {
return;
}
self.controller.setStrictClose(true);
self.cellEditor.callTopLineMouseup = true;
if (!self.controller.isCellEditMode && !self.controller.isFillHandleMode) {
self._onEditCell(0, 0, /*isCoord*/false, /*isFocus*/true);
}
});
if (this.input && this.input.addEventListener) {
this.input.addEventListener("focus", function () {
self.input.isFocused = true;
if (self.controller.settings.isViewerMode) {
return;
}
self.controller.setStrictClose(true);
self.cellEditor.callTopLineMouseup = true;
if (!self.controller.isCellEditMode && !self.controller.isFillHandleMode) {
self._onEditCell(0, 0, /*isCoord*/false, /*isFocus*/true);
}
}, false);
}
this.cellEditor = new asc_CE(this.element, this.input, this.fmgrGraphics, this.m_oFont,
/*handlers*/{
......
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