Fix Bug 35715, fix Bug 35714.
This commit is contained in:
parent
86b84cb487
commit
c5d19bfb89
|
@ -114,14 +114,17 @@ define([
|
||||||
'menu:show': this.onFileMenu.bind(this, 'show')
|
'menu:show': this.onFileMenu.bind(this, 'show')
|
||||||
},
|
},
|
||||||
'Common.Views.Header': {
|
'Common.Views.Header': {
|
||||||
'print': this.onPrint.bind(this),
|
'print': function (opts) {
|
||||||
|
var _main = this.getApplication().getController('Main');
|
||||||
|
_main.onPrint();
|
||||||
|
},
|
||||||
'downloadas': function (opts) {
|
'downloadas': function (opts) {
|
||||||
var _main = this.getApplication().getController('Main');
|
var _main = this.getApplication().getController('Main');
|
||||||
var _file_type = _main.document.fileType,
|
var _file_type = _main.document.fileType,
|
||||||
_format;
|
_format;
|
||||||
if ( !!_file_type ) {
|
if ( !!_file_type ) {
|
||||||
if ( /^pdf|xps|djvu/i.test(_file_type) ) {
|
if ( /^pdf|xps|djvu/i.test(_file_type) ) {
|
||||||
this.api.asc_DownloadOrigin();
|
_main.api.asc_DownloadOrigin();
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
_format = Asc.c_oAscFileType[ _file_type.toUpperCase() ];
|
_format = Asc.c_oAscFileType[ _file_type.toUpperCase() ];
|
||||||
|
|
|
@ -128,7 +128,10 @@ define([
|
||||||
'menu:show': this.onFileMenu.bind(this, 'show')
|
'menu:show': this.onFileMenu.bind(this, 'show')
|
||||||
},
|
},
|
||||||
'Common.Views.Header': {
|
'Common.Views.Header': {
|
||||||
'print': this.onPrint.bind(this),
|
'print': function (opts) {
|
||||||
|
var _main = this.getApplication().getController('Main');
|
||||||
|
_main.onPrint();
|
||||||
|
},
|
||||||
'downloadas': function (opts) {
|
'downloadas': function (opts) {
|
||||||
var _main = this.getApplication().getController('Main');
|
var _main = this.getApplication().getController('Main');
|
||||||
var _file_type = _main.document.fileType,
|
var _file_type = _main.document.fileType,
|
||||||
|
|
|
@ -79,7 +79,10 @@ define([
|
||||||
'settings:apply': _.bind(this.applyFormulaSettings, this)
|
'settings:apply': _.bind(this.applyFormulaSettings, this)
|
||||||
},
|
},
|
||||||
'Common.Views.Header': {
|
'Common.Views.Header': {
|
||||||
'print': this.onPrint.bind(this),
|
'print': function (opts) {
|
||||||
|
var _main = this.getApplication().getController('Main');
|
||||||
|
_main.onPrint();
|
||||||
|
},
|
||||||
'downloadas': function (opts) {
|
'downloadas': function (opts) {
|
||||||
var _main = this.getApplication().getController('Main');
|
var _main = this.getApplication().getController('Main');
|
||||||
var _file_type = _main.appOptions.spreadsheet.fileType,
|
var _file_type = _main.appOptions.spreadsheet.fileType,
|
||||||
|
|
Loading…
Reference in a new issue