Bläddra i källkod

正文历史痕迹工具栏在IOS端展现的问题修复

huqi 5 år sedan
förälder
incheckning
583a9fc5d1

+ 1 - 1
o2web/source/o2_core/o2/o2.more.js

@@ -506,7 +506,7 @@
         },
         "getParentSrcollNode": function(){
             var node = this.getParent();
-            while (node && (node.getScrollSize().y<=node.getSize().y || (node.getStyle("overflow")!=="auto" &&  node.getStyle("overflow-y")!=="auto"))){
+            while (node && (node.getScrollSize().y-2<=node.getSize().y || (node.getStyle("overflow")!=="auto" &&  node.getStyle("overflow-y")!=="auto"))){
                 node = node.getParent();
             }
             return node || null;

+ 5 - 2
o2web/source/x_component_process_Xform/Documenteditor.js

@@ -724,14 +724,17 @@ MWF.xApplication.process.Xform.Documenteditor = MWF.APPDocumenteditor =  new Cla
     // },
     resizeToolbar: function(){
         if (this.toolbarNode){
-            var p = this.toolNode.getPosition(this.form.app.content);
+            var p = this.toolNode.getPosition(this.scrollNode);
             var size = this.toolNode.getSize();
             var pl = this.toolbarNode.getStyle("padding-left").toInt();
             var pr = this.toolbarNode.getStyle("padding-right").toInt();
             var x = size.x-pl-pr;
 
+            //var pNode = this.toolNode.getOffsetParent();
+
+
             if (p.y<0){
-                this.toolbarNode.inject(this.form.node);
+                this.toolbarNode.inject(this.scrollNode);
                 this.toolbarNode.setStyles({
                     "position": "absolute",
                     "width": ""+x+"px",

+ 2 - 1
o2web/source/x_component_process_Xform/lp/zh-cn.js

@@ -223,7 +223,8 @@ MWF.xApplication.process.Xform.LP = {
         "prev": "上一个修改记录",
         "exit": "退出痕迹审查",
         "diff_patch_count": "共有{history}个历史版本,{diff}处修订。",
-        "original": "原始版本"
+        "original": "原始版本",
+        "nodiff": "目前还没有历史修改信息"
     }
 
 };

+ 5 - 0
o2web/source/x_component_process_Xform/widget/DocumentHistory.js

@@ -7,6 +7,7 @@ MWF.xApplication.process.Xform.widget.DocumentHistory = new Class({
         "inforTime": 2000
     },
     initialize: function(documentEditor, options){
+        debugger;
         this.setOptions(options);
         this.documentEditor = documentEditor;
         this.css = this.documentEditor.css;
@@ -32,6 +33,8 @@ MWF.xApplication.process.Xform.widget.DocumentHistory = new Class({
                     if (!layout.mobile) this.loadHistoryList();
                     if (callback) callback();
                 }.bind(this));
+            }else{
+                this.documentEditor.form.app.notice(MWF.xApplication.process.Xform.LP.documentHistory.nodiff, "info", this.documentEditor.node);
             }
         }.bind(this));
     },
@@ -483,6 +486,8 @@ MWF.xApplication.process.Xform.widget.DocumentHistory = new Class({
                     if (callback) callback();
 
                 }.bind(this));
+            }else{
+                this.documentEditor.form.app.notice(MWF.xApplication.process.Xform.LP.documentHistory.nodiff, "info", this.documentEditor.node);
             }
         }.bind(this));
     },