Commit 70f1594d authored by Alexander.Trofimov's avatar Alexander.Trofimov Committed by Alexander.Trofimov

CCollaborativeEditing перевел на prototype

git-svn-id: svn://192.168.3.15/activex/AVS/Sources/TeamlabOffice/trunk/OfficeWeb@55435 954022d7-b5bf-4e40-9824-e11837661b57
parent 88cf1440
......@@ -964,7 +964,6 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
},
_asc_sendTrack: function (callback, url, rdata) {
var oThis = this;
asc_ajax({
type: 'POST',
url: url,
......@@ -1049,7 +1048,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
var oAdditionalData = {};
oAdditionalData["c"] = "save";
oAdditionalData["id"] = this.documentId;
oAdditionalData["userid"] = this.documentUserId,
oAdditionalData["userid"] = this.documentUserId;
oAdditionalData["vkey"] = this.documentVKey;
oAdditionalData["outputformat"] = this.documentFormatSave;
if(c_oAscFileType.CSV == this.documentFormatSave)
......@@ -1071,7 +1070,7 @@ var ASC_DOCS_API_USE_EMBEDDED_FONTS = "@@ASC_DOCS_API_USE_EMBEDDED_FONTS";
var oAdditionalData = {};
oAdditionalData["c"] = "save";
oAdditionalData["id"] = this.documentId;
oAdditionalData["userid"] = this.documentUserId,
oAdditionalData["userid"] = this.documentUserId;
oAdditionalData["vkey"] = this.documentVKey;
oAdditionalData["outputformat"] = sFormat;
if(null != sSaveKey)
......
......@@ -55,68 +55,63 @@
return this;
}
CCollaborativeEditing.prototype = {
/** @type CCollaborativeEditing */
constructor: CCollaborativeEditing,
init: function () {
},
CCollaborativeEditing.prototype.init = function () {
};
// Очищаем индексы пересчета (при открытии это необходимо)
clearRecalcIndex: function () {
CCollaborativeEditing.prototype.clearRecalcIndex = function () {
delete this.m_oRecalcIndexColumns;
delete this.m_oRecalcIndexRows;
this.m_oRecalcIndexColumns = {};
this.m_oRecalcIndexRows = {};
},
};
// Разрешено ли совместное редактирование
isCoAuthoringExcellEnable: function() {
CCollaborativeEditing.prototype.isCoAuthoringExcellEnable = function() {
return ASC_SPREADSHEET_API_CO_AUTHORING_ENABLE;
},
};
// Начало совместного редактирования
startCollaborationEditing: function() {
CCollaborativeEditing.prototype.startCollaborationEditing = function() {
this.m_bIsCollaborative = true;
},
};
// Выставление режима view
setViewerMode: function (isViewerMode) {
CCollaborativeEditing.prototype.setViewerMode = function (isViewerMode) {
this.m_bIsViewerMode = isViewerMode;
},
};
getCollaborativeEditing: function () {
CCollaborativeEditing.prototype.getCollaborativeEditing = function () {
if (true !== this.isCoAuthoringExcellEnable() || this.m_bIsViewerMode)
return false;
return this.m_bIsCollaborative;
},
};
//-----------------------------------------------------------------------------------
// Функции для проверки залоченности объектов
//-----------------------------------------------------------------------------------
getGlobalLock: function () {
CCollaborativeEditing.prototype.getGlobalLock = function () {
return this.m_bGlobalLock;
},
getGlobalLockEditCell: function () {
};
CCollaborativeEditing.prototype.getGlobalLockEditCell = function () {
return this.m_bGlobalLockEditCell;
},
onStartEditCell: function () {
};
CCollaborativeEditing.prototype.onStartEditCell = function () {
// Вызывать эту функцию только в случае редактирования ячейки и если мы не одни редактируем!!!
if (this.getCollaborativeEditing())
this.m_bGlobalLockEditCell = true;
},
onStopEditCell: function () {
};
CCollaborativeEditing.prototype.onStopEditCell = function () {
// Вызывать эту функцию только в случае окончания редактирования ячейки!!!
this.m_bGlobalLockEditCell = false;
},
onStartCheckLock: function () {
};
CCollaborativeEditing.prototype.onStartCheckLock = function () {
this.m_arrCheckLocks.length = 0;
},
addCheckLock: function (oItem) {
};
CCollaborativeEditing.prototype.addCheckLock = function (oItem) {
this.m_arrCheckLocks.push (oItem);
},
onEndCheckLock: function (callback) {
};
CCollaborativeEditing.prototype.onEndCheckLock = function (callback) {
var t = this;
if (this.m_arrCheckLocks.length > 0) {
// Отправляем запрос на сервер со списком элементов
......@@ -133,8 +128,9 @@
// Снимаем глобальный лок (для редактирования ячейки)
this.m_bGlobalLockEditCell = false;
}
},
onCallbackAskLock: function(result, callback) {
};
CCollaborativeEditing.prototype.onCallbackAskLock = function(result, callback) {
// Снимаем глобальный лок
this.m_bGlobalLock = false;
// Снимаем глобальный лок (для редактирования ячейки)
......@@ -158,29 +154,29 @@
} else if (result["error"]) {
asc_applyFunction(callback, false);
}
},
addUnlock: function (LockClass) {
};
CCollaborativeEditing.prototype.addUnlock = function (LockClass) {
this.m_arrNeedUnlock.push (LockClass);
},
addUnlock2: function (Lock) {
};
CCollaborativeEditing.prototype.addUnlock2 = function (Lock) {
this.m_arrNeedUnlock2.push (Lock);
},
};
removeUnlock: function (Lock) {
CCollaborativeEditing.prototype.removeUnlock = function (Lock) {
for (var i = 0; i < this.m_arrNeedUnlock.length; ++i)
if (Lock.Element["guid"] === this.m_arrNeedUnlock[i].Element["guid"]) {
this.m_arrNeedUnlock.splice(i, 1);
return true;
}
return false;
},
};
addChanges: function (oChanges) {
CCollaborativeEditing.prototype.addChanges = function (oChanges) {
this.m_arrChanges.push (oChanges);
},
};
// Возвращает - нужно ли отправлять end action
applyChanges: function () {
CCollaborativeEditing.prototype.applyChanges = function () {
if (!this.isCoAuthoringExcellEnable())
return true;
......@@ -197,9 +193,9 @@
}
return true;
},
};
sendChanges: function () {
CCollaborativeEditing.prototype.sendChanges = function () {
if (!this.isCoAuthoringExcellEnable())
return;
......@@ -271,9 +267,9 @@
if (bCheckRedraw || bRedrawGraphicObjects)
this.handlers.trigger("showDrawingObjects");
}
},
};
getRecalcIndexSave: function (oRecalcIndex) {
CCollaborativeEditing.prototype.getRecalcIndexSave = function (oRecalcIndex) {
var result = {};
var element = null;
for (var sheetId in oRecalcIndex) {
......@@ -289,16 +285,16 @@
}
return result;
},
};
S4: function () {
CCollaborativeEditing.prototype.S4 = function () {
return (((1 + Math.random()) * 0x10000) | 0).toString(16).substring(1);
},
createGUID: function () {
};
CCollaborativeEditing.prototype.createGUID = function () {
return (this.S4() + this.S4() + "-" + this.S4() + "-" + this.S4() + "-" + this.S4() + "-" + this.S4() + this.S4() + this.S4());
},
};
getLockInfo: function (typeElem, subType, sheetId, info) {
CCollaborativeEditing.prototype.getLockInfo = function (typeElem, subType, sheetId, info) {
var oLockInfo = new asc_lockInfo();
oLockInfo["sheetId"] = sheetId;
oLockInfo["type"] = typeElem;
......@@ -306,15 +302,15 @@
oLockInfo["guid"] = this.createGUID();
oLockInfo["rangeOrObjectId"] = info;
return oLockInfo;
},
};
getLockByElem: function (element, type) {
CCollaborativeEditing.prototype.getLockByElem = function (element, type) {
var arrayElements = (c_oAscLockTypes.kLockTypeMine === type) ? this.m_arrNeedUnlock2 : this.m_arrNeedUnlock;
for (var i = 0; i < arrayElements.length; ++i)
if (element["guid"] === arrayElements[i].Element["guid"])
return arrayElements[i];
return null;
},
};
/**
* Проверка lock для элемента
......@@ -322,7 +318,7 @@
* @param {c_oAscLockTypes} type сами(kLockTypeMine) или кто-то другой
* @param {Boolean} bCheckOnlyLockAll проверять только lock для свойств всего листа (либо только проверять удален ли лист, а не просто залочен)
*/
getLockIntersection: function (element, type, bCheckOnlyLockAll) {
CCollaborativeEditing.prototype.getLockIntersection = function (element, type, bCheckOnlyLockAll) {
var arrayElements = (c_oAscLockTypes.kLockTypeMine === type) ? this.m_arrNeedUnlock2 : this.m_arrNeedUnlock;
var oUnlockElement = null, rangeTmp1, rangeTmp2;
for (var i = 0; i < arrayElements.length; ++i) {
......@@ -368,9 +364,9 @@
}
}
return false;
},
};
getLockElem: function (typeElem, type, sheetId) {
CCollaborativeEditing.prototype.getLockElem = function (typeElem, type, sheetId) {
var arrayElements = (c_oAscLockTypes.kLockTypeMine === type) ? this.m_arrNeedUnlock2 : this.m_arrNeedUnlock;
var count = arrayElements.length;
var element = null, oRangeOrObjectId = null;
......@@ -430,26 +426,26 @@
}
return result;
},
};
getLockCellsMe: function (sheetId) {
CCollaborativeEditing.prototype.getLockCellsMe = function (sheetId) {
return this.getLockElem(c_oAscLockTypeElem.Range, c_oAscLockTypes.kLockTypeMine, sheetId);
},
getLockCellsOther: function (sheetId) {
};
CCollaborativeEditing.prototype.getLockCellsOther = function (sheetId) {
return this.getLockElem(c_oAscLockTypeElem.Range, c_oAscLockTypes.kLockTypeOther, sheetId);
},
getLockObjectsMe: function (sheetId) {
};
CCollaborativeEditing.prototype.getLockObjectsMe = function (sheetId) {
return this.getLockElem(c_oAscLockTypeElem.Object, c_oAscLockTypes.kLockTypeMine, sheetId);
},
getLockObjectsOther: function (sheetId) {
};
CCollaborativeEditing.prototype.getLockObjectsOther = function (sheetId) {
return this.getLockElem(c_oAscLockTypeElem.Object, c_oAscLockTypes.kLockTypeOther, sheetId);
},
};
/**
* Проверка lock для всего листа
* @param {Number} sheetId элемент для проверки lock
* @return {c_oAscMouseMoveLockedObjectType} oLockedObjectType
*/
isLockAllOther: function (sheetId) {
CCollaborativeEditing.prototype.isLockAllOther = function (sheetId) {
var arrayElements = this.m_arrNeedUnlock;
var count = arrayElements.length;
var element = null;
......@@ -466,9 +462,9 @@
}
}
return oLockedObjectType;
},
};
_recalcLockArray: function (typeLock, oRecalcIndexColumns, oRecalcIndexRows) {
CCollaborativeEditing.prototype._recalcLockArray = function (typeLock, oRecalcIndexColumns, oRecalcIndexRows) {
var arrayElements = (c_oAscLockTypes.kLockTypeMine === typeLock) ? this.m_arrNeedUnlock2 : this.m_arrNeedUnlock;
var count = arrayElements.length;
var element = null, oRangeOrObjectId = null;
......@@ -499,9 +495,9 @@
oRangeOrObjectId["r2"] = oRecalcIndexRows[sheetId].getLockMe(oRangeOrObjectId["r2"]);
}
}
},
};
// Пересчет только для чужих Lock при сохранении на клиенте, который добавлял/удалял строки или столбцы
_recalcLockArrayOthers: function () {
CCollaborativeEditing.prototype._recalcLockArrayOthers = function () {
var typeLock = c_oAscLockTypes.kLockTypeOther;
var arrayElements = (c_oAscLockTypes.kLockTypeMine === typeLock) ? this.m_arrNeedUnlock2 : this.m_arrNeedUnlock;
var count = arrayElements.length;
......@@ -530,9 +526,9 @@
oRangeOrObjectId["r2"] = this.m_oRecalcIndexRows[sheetId].getLockOther(oRangeOrObjectId["r2"]);
}
}
},
};
addRecalcIndex: function (type, oRecalcIndex) {
CCollaborativeEditing.prototype.addRecalcIndex = function (type, oRecalcIndex) {
var nIndex = 0;
var nRecalcType = c_oAscRecalcIndexTypes.RecalcIndexAdd;
var oRecalcIndexElement = null;
......@@ -563,26 +559,26 @@
}
return oRecalcIndexResult;
},
};
// Undo для добавления/удаления столбцов
undoCols: function (sheetId, count) {
CCollaborativeEditing.prototype.undoCols = function (sheetId, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId))
return;
this.m_oRecalcIndexColumns[sheetId].remove(count);
}
},
};
// Undo для добавления/удаления строк
undoRows: function (sheetId, count) {
CCollaborativeEditing.prototype.undoRows = function (sheetId, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId))
return;
this.m_oRecalcIndexRows[sheetId].remove(count);
}
},
};
removeCols: function (sheetId, position, count) {
CCollaborativeEditing.prototype.removeCols = function (sheetId, position, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId)) {
this.m_oRecalcIndexColumns[sheetId] = new CRecalcIndex();
......@@ -590,8 +586,8 @@
this.m_oRecalcIndexColumns[sheetId].add(c_oAscRecalcIndexTypes.RecalcIndexRemove, position,
count, /*bIsSaveIndex*/false);
}
},
addCols: function (sheetId, position, count) {
};
CCollaborativeEditing.prototype.addCols = function (sheetId, position, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId)) {
this.m_oRecalcIndexColumns[sheetId] = new CRecalcIndex();
......@@ -599,8 +595,8 @@
this.m_oRecalcIndexColumns[sheetId].add(c_oAscRecalcIndexTypes.RecalcIndexAdd, position,
count, /*bIsSaveIndex*/false);
}
},
removeRows: function (sheetId, position, count) {
};
CCollaborativeEditing.prototype.removeRows = function (sheetId, position, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId)) {
this.m_oRecalcIndexRows[sheetId] = new CRecalcIndex();
......@@ -608,8 +604,8 @@
this.m_oRecalcIndexRows[sheetId].add(c_oAscRecalcIndexTypes.RecalcIndexRemove, position,
count, /*bIsSaveIndex*/false);
}
},
addRows: function (sheetId, position, count) {
};
CCollaborativeEditing.prototype.addRows = function (sheetId, position, count) {
if (this.isCoAuthoringExcellEnable()) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId)) {
this.m_oRecalcIndexRows[sheetId] = new CRecalcIndex();
......@@ -617,8 +613,8 @@
this.m_oRecalcIndexRows[sheetId].add(c_oAscRecalcIndexTypes.RecalcIndexAdd, position,
count, /*bIsSaveIndex*/false);
}
},
addColsRange: function (sheetId, range) {
};
CCollaborativeEditing.prototype.addColsRange = function (sheetId, range) {
if (!this.m_oInsertColumns.hasOwnProperty(sheetId)) {
this.m_oInsertColumns[sheetId] = [];
}
......@@ -637,8 +633,8 @@
}
if (isAddNewRange)
arrInsertColumns.push(range);
},
addRowsRange: function (sheetId, range) {
};
CCollaborativeEditing.prototype.addRowsRange = function (sheetId, range) {
if (!this.m_oInsertRows.hasOwnProperty(sheetId)) {
this.m_oInsertRows[sheetId] = [];
}
......@@ -657,8 +653,8 @@
}
if (isAddNewRange)
arrInsertRows.push(range);
},
removeColsRange: function (sheetId, range) {
};
CCollaborativeEditing.prototype.removeColsRange = function (sheetId, range) {
if (!this.m_oInsertColumns.hasOwnProperty(sheetId))
return;
var arrInsertColumns = this.m_oInsertColumns[sheetId];
......@@ -686,8 +682,8 @@
arrInsertColumns[i].c2 -= countCols;
}
}
},
removeRowsRange: function (sheetId, range) {
};
CCollaborativeEditing.prototype.removeRowsRange = function (sheetId, range) {
if (!this.m_oInsertRows.hasOwnProperty(sheetId))
return;
var arrInsertRows = this.m_oInsertRows[sheetId];
......@@ -715,8 +711,8 @@
arrInsertRows[i].r2 -= countRows;
}
}
},
isIntersectionInCols: function (sheetId, col) {
};
CCollaborativeEditing.prototype.isIntersectionInCols = function (sheetId, col) {
if (!this.m_oInsertColumns.hasOwnProperty(sheetId))
return false;
var arrInsertColumns = this.m_oInsertColumns[sheetId];
......@@ -725,8 +721,8 @@
return true;
}
return false;
},
isIntersectionInRows: function (sheetId, row) {
};
CCollaborativeEditing.prototype.isIntersectionInRows = function (sheetId, row) {
if (!this.m_oInsertRows.hasOwnProperty(sheetId))
return false;
var arrInsertRows = this.m_oInsertRows[sheetId];
......@@ -735,53 +731,52 @@
return true;
}
return false;
},
getArrayInsertColumnsBySheetId: function (sheetId) {
};
CCollaborativeEditing.prototype.getArrayInsertColumnsBySheetId = function (sheetId) {
if (!this.m_oInsertColumns.hasOwnProperty(sheetId))
return [];
return this.m_oInsertColumns[sheetId];
},
getArrayInsertRowsBySheetId: function (sheetId) {
};
CCollaborativeEditing.prototype.getArrayInsertRowsBySheetId = function (sheetId) {
if (!this.m_oInsertRows.hasOwnProperty(sheetId))
return [];
return this.m_oInsertRows[sheetId];
},
getLockMeColumn: function (sheetId, col) {
};
CCollaborativeEditing.prototype.getLockMeColumn = function (sheetId, col) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId))
return col;
return this.m_oRecalcIndexColumns[sheetId].getLockMe(col);
},
getLockMeRow: function (sheetId, row) {
};
CCollaborativeEditing.prototype.getLockMeRow = function (sheetId, row) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId))
return row;
return this.m_oRecalcIndexRows[sheetId].getLockMe(row);
},
};
// Только когда от других пользователей изменения колонок (для пересчета)
getLockMeColumn2: function (sheetId, col) {
CCollaborativeEditing.prototype.getLockMeColumn2 = function (sheetId, col) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId))
return col;
return this.m_oRecalcIndexColumns[sheetId].getLockMe2(col);
},
};
// Только когда от других пользователей изменения строк (для пересчета)
getLockMeRow2: function (sheetId, row) {
CCollaborativeEditing.prototype.getLockMeRow2 = function (sheetId, row) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId))
return row;
return this.m_oRecalcIndexRows[sheetId].getLockMe2(row);
},
};
// Только для принятия изменений от других пользователей! (для пересчета только в сохранении)
getLockOtherColumn2: function (sheetId, col) {
CCollaborativeEditing.prototype.getLockOtherColumn2 = function (sheetId, col) {
if (!this.m_oRecalcIndexColumns.hasOwnProperty(sheetId))
return col;
return this.m_oRecalcIndexColumns[sheetId].getLockSaveOther(col);
},
};
// Только для принятия изменений от других пользователей! (для пересчета только в сохранении)
getLockOtherRow2: function (sheetId, row) {
CCollaborativeEditing.prototype.getLockOtherRow2 = function (sheetId, row) {
if (!this.m_oRecalcIndexRows.hasOwnProperty(sheetId))
return row;
return this.m_oRecalcIndexRows[sheetId].getLockSaveOther(row);
}
};
/**
......@@ -805,25 +800,19 @@
return this;
}
CLock.prototype = {
/** @type CLock */
constructor: CLock,
init: function () {
},
getType: function () {
CLock.prototype.init = function () {
};
CLock.prototype.getType = function () {
return this.Type;
},
setType: function (newType) {
};
CLock.prototype.setType = function (newType) {
if (newType === c_oAscLockTypes.kLockTypeNone)
this.UserId = null;
this.Type = newType;
},
};
Lock: function(bMine) {
CLock.prototype.Lock = function(bMine) {
if (c_oAscLockTypes.kLockTypeNone === this.Type)
{
if (true === bMine)
......@@ -831,15 +820,10 @@
else
this.Type = c_oAscLockTypes.kLockTypeOther;
}
},
};
setUserId: function(UserId) {
CLock.prototype.setUserId = function(UserId) {
this.UserId = UserId;
},
getUserId: function() {
return this.UserId;
}
};
function CRecalcIndexElement(recalcType, position, bIsSaveIndex) {
......@@ -855,11 +839,8 @@
return this;
}
CRecalcIndexElement.prototype = {
constructor: CRecalcIndexElement,
// Пересчет для других
getLockOther: function (position, type) {
CRecalcIndexElement.prototype.getLockOther = function (position, type) {
var inc = (c_oAscRecalcIndexTypes.RecalcIndexAdd === this._recalcType) ? +1 : -1;
if (position === this._position && c_oAscRecalcIndexTypes.RecalcIndexRemove === this._recalcType &&
true === this.m_bIsSaveIndex) {
......@@ -877,9 +858,9 @@
return position;
else
return (position + inc);
},
};
// Пересчет для других (только для сохранения)
getLockSaveOther: function (position, type) {
CRecalcIndexElement.prototype.getLockSaveOther = function (position, type) {
if (this.m_bIsSaveIndex)
return position;
......@@ -900,23 +881,22 @@
return position;
else
return (position + inc);
},
};
// Пересчет для себя
getLockMe: function (position) {
CRecalcIndexElement.prototype.getLockMe = function (position) {
var inc = (c_oAscRecalcIndexTypes.RecalcIndexAdd === this._recalcType) ? -1 : +1;
if (position < this._position)
return position;
else
return (position + inc);
},
};
// Только когда от других пользователей изменения (для пересчета)
getLockMe2: function (position) {
CRecalcIndexElement.prototype.getLockMe2 = function (position) {
var inc = (c_oAscRecalcIndexTypes.RecalcIndexAdd === this._recalcType) ? -1 : +1;
if (true !== this.m_bIsSaveIndex || position < this._position)
return position;
else
return (position + inc);
}
};
function CRecalcIndex() {
......@@ -929,23 +909,21 @@
return this;
}
CRecalcIndex.prototype = {
constructor: CRecalcIndex,
add: function (recalcType, position, count, bIsSaveIndex) {
CRecalcIndex.prototype.add = function (recalcType, position, count, bIsSaveIndex) {
for (var i = 0; i < count; ++i)
this._arrElements.push(new CRecalcIndexElement(recalcType, position, bIsSaveIndex));
},
};
// Удаляет из пересчета, для undo
remove: function (count) {
CRecalcIndex.prototype.remove = function (count) {
for (var i = 0; i < count; ++i)
this._arrElements.pop();
},
clear: function () {
};
CRecalcIndex.prototype.clear = function () {
this._arrElements.length = 0;
},
};
// Пересчет для других
getLockOther: function (position, type) {
CRecalcIndex.prototype.getLockOther = function (position, type) {
var newPosition = position;
/*var count = this._arrElements.length;
for (var i = 0; i < count; ++i) {
......@@ -976,9 +954,9 @@
}
return newPosition;
},
};
// Пересчет для других (только для сохранения)
getLockSaveOther: function (position, type) {
CRecalcIndex.prototype.getLockSaveOther = function (position, type) {
var newPosition = position;
var count = this._arrElements.length;
for (var i = 0; i < count; ++i) {
......@@ -988,9 +966,9 @@
}
return newPosition;
},
};
// Пересчет для себя
getLockMe: function (position) {
CRecalcIndex.prototype.getLockMe = function (position) {
var newPosition = position;
var count = this._arrElements.length;
if (0 >= count)
......@@ -1014,9 +992,9 @@
}
return newPosition;
},
};
// Только когда от других пользователей изменения (для пересчета)
getLockMe2: function (position) {
CRecalcIndex.prototype.getLockMe2 = function (position) {
var newPosition = position;
var count = this._arrElements.length;
if (0 >= count)
......@@ -1040,7 +1018,6 @@
}
return newPosition;
}
};
/*
......
......@@ -1548,7 +1548,6 @@
this.view.MobileTouchManager.onTouchStart(event);
};
asc_CEventsController.prototype._onTouchMove = function (event){
var n = new Date().getTime();
this.view.MobileTouchManager.onTouchMove(event);
};
asc_CEventsController.prototype._onTouchEnd = function (event){
......
......@@ -49,12 +49,12 @@
* Widget for displaying and editing Workbook object
* -----------------------------------------------------------------------------
* @param {Workbook} model Workbook
* @param {EventsController} controller Events controller
* @param {asc.asc_CEventsController} controller Events controller
* @param {HandlersList} handlers Events handlers for WorkbookView events
* @param {Element} elem Container element
* @param {Element} inputElem Input element for top line editor
* @param {Object} Api
* @param {asc_CCollaborativeEditing} collaborativeEditing
* @param {CCollaborativeEditing} collaborativeEditing
* @param {c_oAscFontRenderingModeType} fontRenderingMode
* @param {Object} settings Settings
*
......
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