Commit 194369ca authored by Boris Kocherov's avatar Boris Kocherov

make save button work only if document modified

parent 1ea6ec32
......@@ -927,7 +927,11 @@ define([
Common.Gateway.on('processrightschange', _.bind(me.onProcessRightsChange, me));
Common.Gateway.on('processmouse', _.bind(me.onProcessMouse, me));
Common.Gateway.on('refreshhistory', _.bind(me.onRefreshHistory, me));
Common.Gateway.on('save', _.bind(me.api.asc_Save, me.api));
Common.Gateway.on('save', function () {
if (me.api.isDocumentModified()) {
me.api.asc_Save();
}
});
Common.Gateway.on('downloadas', _.bind(me.onDownloadAs, me));
Common.Gateway.sendInfo({mode:me.appOptions.isEdit?'edit':'view'});
......
......@@ -708,7 +708,11 @@ define([
Common.Gateway.on('processsaveresult', _.bind(me.onProcessSaveResult, me));
Common.Gateway.on('processrightschange', _.bind(me.onProcessRightsChange, me));
Common.Gateway.on('processmouse', _.bind(me.onProcessMouse, me));
Common.Gateway.on('save', _.bind(me.api.asc_Save, me.api));
Common.Gateway.on('save', function () {
if (me.api.isDocumentModified()) {
me.api.asc_Save();
}
});
Common.Gateway.on('downloadas', _.bind(me.onDownloadAs, me));
Common.Gateway.sendInfo({mode:me.appOptions.isEdit?'edit':'view'});
......
......@@ -712,7 +712,11 @@ define([
Common.Gateway.on('processsaveresult', _.bind(me.onProcessSaveResult, me));
Common.Gateway.on('processrightschange', _.bind(me.onProcessRightsChange, me));
Common.Gateway.on('processmouse', _.bind(me.onProcessMouse, me));
Common.Gateway.on('save', _.bind(me.api.asc_Save, me.api));
Common.Gateway.on('save', function () {
if (me.api.asc_isDocumentModified()) {
me.api.asc_Save();
}
});
Common.Gateway.on('downloadas', _.bind(me.onDownloadAs, me));
Common.Gateway.sendInfo({mode:me.appOptions.isEdit?'edit':'view'});
......
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