Jelajahi Sumber

板式文件切换双页在切换成双页,保留原来的显示百分比

unknown 5 tahun lalu
induk
melakukan
273d3df734
1 mengubah file dengan 14 tambahan dan 1 penghapusan
  1. 14 1
      o2web/source/x_component_process_Xform/Documenteditor.js

+ 14 - 1
o2web/source/x_component_process_Xform/Documenteditor.js

@@ -1681,7 +1681,15 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor =  new Cla
     },
     },
     _singlePage: function(){
     _singlePage: function(){
         //if (this.editMode) this._readFiletext();
         //if (this.editMode) this._readFiletext();
-        this.zoom(1);
+
+        var scale = this.singlePageZoom || 1;
+        if( this.singlePageZoom && this.singlePageZoom.toInt() != 1 ){
+            this.isScale = true;
+            this.scale = this.singlePageZoom;
+            this.singlePageZoom = null;
+        }
+
+        this.zoom(scale);
         this._checkScale();
         this._checkScale();
 
 
         var w = this.contentNode.getSize().x;
         var w = this.contentNode.getSize().x;
@@ -1752,6 +1760,11 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor =  new Cla
 
 
     _doublePage: function(){
     _doublePage: function(){
         if (this.editMode) this._switchReadOrEditInline();
         if (this.editMode) this._switchReadOrEditInline();
+
+        if( this.zoomSelectAction ){
+            this.singlePageZoom = ( this.zoomSelectAction.options[this.zoomSelectAction.selectedIndex].value ).toFloat();
+        }
+
         this.zoom(1);
         this.zoom(1);
         this.createWaitSplitPage();
         this.createWaitSplitPage();
         window.setTimeout(function(){
         window.setTimeout(function(){