[DE] Added option for show/hide resolved comments.
This commit is contained in:
parent
7f548712d4
commit
556b0c55ae
|
@ -307,7 +307,8 @@ define([
|
||||||
}
|
}
|
||||||
|
|
||||||
value = Common.localStorage.getItem("de-settings-livecomment");
|
value = Common.localStorage.getItem("de-settings-livecomment");
|
||||||
(!(value!==null && parseInt(value) == 0)) ? this.api.asc_showComments() : this.api.asc_hideComments();
|
var resolved = Common.localStorage.getItem("de-settings-resolvedcomment");
|
||||||
|
(!(value!==null && parseInt(value) == 0)) ? this.api.asc_showComments(!(resolved!==null && parseInt(resolved) == 0)) : this.api.asc_hideComments();
|
||||||
/** coauthoring end **/
|
/** coauthoring end **/
|
||||||
|
|
||||||
value = Common.localStorage.getItem("de-settings-fontrender");
|
value = Common.localStorage.getItem("de-settings-fontrender");
|
||||||
|
@ -515,9 +516,12 @@ define([
|
||||||
},
|
},
|
||||||
|
|
||||||
commentsShowHide: function(mode) {
|
commentsShowHide: function(mode) {
|
||||||
var value = Common.localStorage.getItem("de-settings-livecomment");
|
var value = Common.localStorage.getItem("de-settings-livecomment"),
|
||||||
if (value !== null && 0 === parseInt(value)) {
|
resolved = Common.localStorage.getItem("de-settings-resolvedcomment");
|
||||||
(mode === 'show') ? this.api.asc_showComments() : this.api.asc_hideComments();
|
value = (value!==null && parseInt(value) == 0);
|
||||||
|
resolved = (resolved!==null && parseInt(resolved) == 0);
|
||||||
|
if (value || resolved) {
|
||||||
|
(mode === 'show') ? this.api.asc_showComments(true) : ((!value) ? this.api.asc_showComments(!resolved) : this.api.asc_hideComments());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (mode === 'show') {
|
if (mode === 'show') {
|
||||||
|
|
|
@ -736,7 +736,8 @@ define([
|
||||||
/** coauthoring begin **/
|
/** coauthoring begin **/
|
||||||
value = Common.localStorage.getItem("de-settings-livecomment");
|
value = Common.localStorage.getItem("de-settings-livecomment");
|
||||||
this.isLiveCommenting = !(value!==null && parseInt(value) == 0);
|
this.isLiveCommenting = !(value!==null && parseInt(value) == 0);
|
||||||
this.isLiveCommenting ? this.api.asc_showComments() : this.api.asc_hideComments();
|
var resolved = Common.localStorage.getItem("de-settings-resolvedcomment");
|
||||||
|
this.isLiveCommenting ? this.api.asc_showComments(!(resolved!==null && parseInt(resolved) == 0)) : this.api.asc_hideComments();
|
||||||
/** coauthoring end **/
|
/** coauthoring end **/
|
||||||
|
|
||||||
value = Common.localStorage.getItem("de-settings-zoom");
|
value = Common.localStorage.getItem("de-settings-zoom");
|
||||||
|
|
|
@ -115,6 +115,10 @@ define([
|
||||||
'<td class="left"><label><%= scope.txtLiveComment %></label></td>',
|
'<td class="left"><label><%= scope.txtLiveComment %></label></td>',
|
||||||
'<td class="right"><div id="fms-chb-live-comment"/></td>',
|
'<td class="right"><div id="fms-chb-live-comment"/></td>',
|
||||||
'</tr>','<tr class="divider coauth"></tr>',
|
'</tr>','<tr class="divider coauth"></tr>',
|
||||||
|
'<tr class="coauth">',
|
||||||
|
'<td class="left"></td>',
|
||||||
|
'<td class="right"><div id="fms-chb-resolved-comment"/></td>',
|
||||||
|
'</tr>','<tr class="divider coauth"></tr>',
|
||||||
/** coauthoring end **/
|
/** coauthoring end **/
|
||||||
'<tr class="edit">',
|
'<tr class="edit">',
|
||||||
'<td class="left"><label><%= scope.txtSpellCheck %></label></td>',
|
'<td class="left"><label><%= scope.txtSpellCheck %></label></td>',
|
||||||
|
@ -185,6 +189,13 @@ define([
|
||||||
this.chLiveComment = new Common.UI.CheckBox({
|
this.chLiveComment = new Common.UI.CheckBox({
|
||||||
el: $('#fms-chb-live-comment'),
|
el: $('#fms-chb-live-comment'),
|
||||||
labelText: this.strLiveComment
|
labelText: this.strLiveComment
|
||||||
|
}).on('change', _.bind(function(field, newValue, oldValue, eOpts){
|
||||||
|
this.chResolvedComment.setDisabled(field.getValue()!=='checked');
|
||||||
|
}, this));
|
||||||
|
|
||||||
|
this.chResolvedComment = new Common.UI.CheckBox({
|
||||||
|
el: $('#fms-chb-resolved-comment'),
|
||||||
|
labelText: this.strResolvedComment
|
||||||
});
|
});
|
||||||
/** coauthoring end **/
|
/** coauthoring end **/
|
||||||
|
|
||||||
|
@ -341,6 +352,9 @@ define([
|
||||||
value = Common.localStorage.getItem("de-settings-livecomment");
|
value = Common.localStorage.getItem("de-settings-livecomment");
|
||||||
this.chLiveComment.setValue(!(value!==null && parseInt(value) == 0));
|
this.chLiveComment.setValue(!(value!==null && parseInt(value) == 0));
|
||||||
|
|
||||||
|
value = Common.localStorage.getItem("de-settings-resolvedcomment");
|
||||||
|
this.chResolvedComment.setValue(!(value!==null && parseInt(value) == 0));
|
||||||
|
|
||||||
value = Common.localStorage.getItem("de-settings-coauthmode");
|
value = Common.localStorage.getItem("de-settings-coauthmode");
|
||||||
if (value===null && Common.localStorage.getItem("de-settings-autosave")===null &&
|
if (value===null && Common.localStorage.getItem("de-settings-autosave")===null &&
|
||||||
this.mode.customization && this.mode.customization.autosave===false)
|
this.mode.customization && this.mode.customization.autosave===false)
|
||||||
|
@ -390,6 +404,7 @@ define([
|
||||||
Common.localStorage.setItem("de-settings-zoom", this.cmbZoom.getValue());
|
Common.localStorage.setItem("de-settings-zoom", this.cmbZoom.getValue());
|
||||||
/** coauthoring begin **/
|
/** coauthoring begin **/
|
||||||
Common.localStorage.setItem("de-settings-livecomment", this.chLiveComment.isChecked() ? 1 : 0);
|
Common.localStorage.setItem("de-settings-livecomment", this.chLiveComment.isChecked() ? 1 : 0);
|
||||||
|
Common.localStorage.setItem("de-settings-resolvedcomment", this.chResolvedComment.isChecked() ? 1 : 0);
|
||||||
if (this.mode.isEdit && !this.mode.isOffline && this.mode.canCoAuthoring) {
|
if (this.mode.isEdit && !this.mode.isOffline && this.mode.canCoAuthoring) {
|
||||||
Common.localStorage.setItem("de-settings-coauthmode", this.cmbCoAuthMode.getValue());
|
Common.localStorage.setItem("de-settings-coauthmode", this.cmbCoAuthMode.getValue());
|
||||||
Common.localStorage.setItem(this.cmbCoAuthMode.getValue() ? "de-settings-showchanges-fast" : "de-settings-showchanges-strict", this.cmbShowChanges.getValue());
|
Common.localStorage.setItem(this.cmbCoAuthMode.getValue() ? "de-settings-showchanges-fast" : "de-settings-showchanges-strict", this.cmbShowChanges.getValue());
|
||||||
|
@ -462,7 +477,8 @@ define([
|
||||||
txtFitPage: 'Fit to Page',
|
txtFitPage: 'Fit to Page',
|
||||||
txtFitWidth: 'Fit to Width',
|
txtFitWidth: 'Fit to Width',
|
||||||
textForceSave: 'Save to Server',
|
textForceSave: 'Save to Server',
|
||||||
strForcesave: 'Always save to server (otherwise save to server on document close)'
|
strForcesave: 'Always save to server (otherwise save to server on document close)',
|
||||||
|
strResolvedComment: 'Turn on display of the resolved comments'
|
||||||
}, DE.Views.FileMenuPanels.Settings || {}));
|
}, DE.Views.FileMenuPanels.Settings || {}));
|
||||||
|
|
||||||
DE.Views.FileMenuPanels.RecentFiles = Common.UI.BaseView.extend({
|
DE.Views.FileMenuPanels.RecentFiles = Common.UI.BaseView.extend({
|
||||||
|
|
|
@ -979,6 +979,7 @@
|
||||||
"DE.Views.FileMenuPanels.Settings.txtPt": "Point",
|
"DE.Views.FileMenuPanels.Settings.txtPt": "Point",
|
||||||
"DE.Views.FileMenuPanels.Settings.txtSpellCheck": "Spell Checking",
|
"DE.Views.FileMenuPanels.Settings.txtSpellCheck": "Spell Checking",
|
||||||
"DE.Views.FileMenuPanels.Settings.txtWin": "as Windows",
|
"DE.Views.FileMenuPanels.Settings.txtWin": "as Windows",
|
||||||
|
"DE.Views.FileMenuPanels.Settings.strResolvedComment": "Turn on display of the resolved comments",
|
||||||
"DE.Views.HeaderFooterSettings.textBottomCenter": "Bottom Center",
|
"DE.Views.HeaderFooterSettings.textBottomCenter": "Bottom Center",
|
||||||
"DE.Views.HeaderFooterSettings.textBottomLeft": "Bottom Left",
|
"DE.Views.HeaderFooterSettings.textBottomLeft": "Bottom Left",
|
||||||
"DE.Views.HeaderFooterSettings.textBottomRight": "Bottom Right",
|
"DE.Views.HeaderFooterSettings.textBottomRight": "Bottom Right",
|
||||||
|
|
|
@ -454,7 +454,7 @@ define([
|
||||||
/** coauthoring begin **/
|
/** coauthoring begin **/
|
||||||
value = Common.localStorage.getItem("de-settings-livecomment");
|
value = Common.localStorage.getItem("de-settings-livecomment");
|
||||||
this.isLiveCommenting = !(value!==null && parseInt(value) == 0);
|
this.isLiveCommenting = !(value!==null && parseInt(value) == 0);
|
||||||
this.isLiveCommenting ? this.api.asc_showComments() : this.api.asc_hideComments();
|
this.isLiveCommenting ? this.api.asc_showComments(true) : this.api.asc_hideComments();
|
||||||
/** coauthoring end **/
|
/** coauthoring end **/
|
||||||
|
|
||||||
value = Common.localStorage.getItem("de-settings-zoom");
|
value = Common.localStorage.getItem("de-settings-zoom");
|
||||||
|
|
Loading…
Reference in a new issue