Fix Bug 35715, fix Bug 35714.

This commit is contained in:
Julia Radzhabova 2017-08-23 14:51:27 +03:00
parent 86b84cb487
commit c5d19bfb89
3 changed files with 13 additions and 4 deletions

View file

@ -114,14 +114,17 @@ define([
'menu:show': this.onFileMenu.bind(this, 'show')
},
'Common.Views.Header': {
'print': this.onPrint.bind(this),
'print': function (opts) {
var _main = this.getApplication().getController('Main');
_main.onPrint();
},
'downloadas': function (opts) {
var _main = this.getApplication().getController('Main');
var _file_type = _main.document.fileType,
_format;
if ( !!_file_type ) {
if ( /^pdf|xps|djvu/i.test(_file_type) ) {
this.api.asc_DownloadOrigin();
_main.api.asc_DownloadOrigin();
return;
} else {
_format = Asc.c_oAscFileType[ _file_type.toUpperCase() ];

View file

@ -128,7 +128,10 @@ define([
'menu:show': this.onFileMenu.bind(this, 'show')
},
'Common.Views.Header': {
'print': this.onPrint.bind(this),
'print': function (opts) {
var _main = this.getApplication().getController('Main');
_main.onPrint();
},
'downloadas': function (opts) {
var _main = this.getApplication().getController('Main');
var _file_type = _main.document.fileType,

View file

@ -79,7 +79,10 @@ define([
'settings:apply': _.bind(this.applyFormulaSettings, this)
},
'Common.Views.Header': {
'print': this.onPrint.bind(this),
'print': function (opts) {
var _main = this.getApplication().getController('Main');
_main.onPrint();
},
'downloadas': function (opts) {
var _main = this.getApplication().getController('Main');
var _file_type = _main.appOptions.spreadsheet.fileType,