Updated application.

This commit is contained in:
agolybev
2015-08-17 17:19:04 +03:00
parent cd34405d7e
commit a7b9b3a979
330 changed files with 81139 additions and 172701 deletions

View File

@@ -95,6 +95,9 @@
if (this.mode.canCoAuthoring && this.mode.canChat) {
this.api.asc_registerCallback("asc_onCoAuthoringChatReceiveMessage", _.bind(this.onApiChatMessage, this));
}
if (!this.mode.canLicense) {
this.api.SetCollaborativeMarksShowType(c_oAscCollaborativeMarksShowType.None);
}
this.leftMenu.getMenu("file").setApi(api);
if (this.mode.canUseHistory) {
this.getApplication().getController("Common.Controllers.History").setApi(this.api);
@@ -202,7 +205,7 @@
default:
value = c_oAscCollaborativeMarksShowType.LastChanges;
}
this.api.SetCollaborativeMarksShowType(value);
this.api.SetCollaborativeMarksShowType(this.mode.canLicense ? value : c_oAscCollaborativeMarksShowType.None);
value = window.localStorage.getItem("de-settings-livecomment");
(!(value !== null && parseInt(value) == 0)) ? this.api.asc_showComments() : this.api.asc_hideComments();
value = window.localStorage.getItem("de-settings-fontrender");

View File

@@ -307,11 +307,9 @@
arrColors.push(user.get("colorval"));
var changes = version.changes,
change, i;
if (changes) {
if (changes.length > 0) {
arrVersions[arrVersions.length - 1].set("changeid", changes.length - 1);
arrVersions[arrVersions.length - 1].set("docIdPrev", docIdPrev);
}
if (changes && changes.length > 0) {
arrVersions[arrVersions.length - 1].set("changeid", changes.length - 1);
arrVersions[arrVersions.length - 1].set("docIdPrev", docIdPrev);
for (i = changes.length - 2; i >= 0; i--) {
change = changes[i];
user = usersStore.findUser(change.user.id);
@@ -338,6 +336,10 @@
}));
arrColors.push(user.get("colorval"));
}
} else {
if (ver == 0 && versions.length == 1) {
arrVersions[arrVersions.length - 1].set("docId", version.key + "1");
}
}
}
}