diff --git a/js/3rdparty/webodf/webodf-debug.js b/js/3rdparty/webodf/webodf-debug.js index fcebfe47..bbce700b 100644 --- a/js/3rdparty/webodf/webodf-debug.js +++ b/js/3rdparty/webodf/webodf-debug.js @@ -1,4 +1,4 @@ -var webodf_version = "0.4.2-2010-ge06842f"; +var webodf_version = "0.4.2-2039-gdbdc4e9"; function Runtime() { } Runtime.prototype.getVariable = function(name) { @@ -1797,7 +1797,7 @@ core.CSSUnits = function CSSUnits() { element = (node); rect = element.getBoundingClientRect(); if(quirks.elementBCRIgnoresBodyScroll) { - return({left:rect.left + body.scrollLeft, right:rect.right + body.scrollLeft, top:rect.top + body.scrollTop, bottom:rect.bottom + body.scrollTop}) + return({left:rect.left + body.scrollLeft, right:rect.right + body.scrollLeft, top:rect.top + body.scrollTop, bottom:rect.bottom + body.scrollTop, width:rect.width, height:rect.height}) } return rect } @@ -11714,7 +11714,11 @@ ops.OpRemoveText = function OpRemoveText() { paragraphs = odfUtils.getParagraphElements(range); range.detach(); textNodes.forEach(function(element) { - collapseRules.mergeChildrenIntoParent(element) + if(element.parentNode) { + collapseRules.mergeChildrenIntoParent(element) + }else { + runtime.log("WARN: text element has already been removed from it's container") + } }); function merge(destination, paragraph) { return mergeParagraphs(destination, paragraph, collapseRules) @@ -13817,11 +13821,13 @@ gui.IOSSafariSupport = function(eventManager) { this.destroy = function(callback) { eventManager.unsubscribe("focus", suppressFocusScrollIfKeyboardOpen); eventTrap.removeAttribute("autocapitalize"); + eventTrap.style.WebkitTransform = ""; callback() }; function init() { eventManager.subscribe("focus", suppressFocusScrollIfKeyboardOpen); - eventTrap.setAttribute("autocapitalize", "off") + eventTrap.setAttribute("autocapitalize", "off"); + eventTrap.style.WebkitTransform = "translateX(-10000px)" } init() }; diff --git a/js/3rdparty/webodf/webodf.js b/js/3rdparty/webodf/webodf.js index 2690b0fd..69580804 100644 --- a/js/3rdparty/webodf/webodf.js +++ b/js/3rdparty/webodf/webodf.js @@ -1,5 +1,5 @@ // Input 0 -var webodf_version="0.4.2-2010-ge06842f"; +var webodf_version="0.4.2-2039-gdbdc4e9"; // Input 1 function Runtime(){}Runtime.prototype.getVariable=function(k){};Runtime.prototype.toJson=function(k){};Runtime.prototype.fromJson=function(k){};Runtime.prototype.byteArrayFromString=function(k,h){};Runtime.prototype.byteArrayToString=function(k,h){};Runtime.prototype.read=function(k,h,b,p){};Runtime.prototype.readFile=function(k,h,b){};Runtime.prototype.readFileSync=function(k,h){};Runtime.prototype.loadXML=function(k,h){};Runtime.prototype.writeFile=function(k,h,b){}; Runtime.prototype.isFile=function(k,h){};Runtime.prototype.getFileSize=function(k,h){};Runtime.prototype.deleteFile=function(k,h){};Runtime.prototype.log=function(k,h){};Runtime.prototype.setTimeout=function(k,h){};Runtime.prototype.clearTimeout=function(k){};Runtime.prototype.libraryPaths=function(){};Runtime.prototype.currentDirectory=function(){};Runtime.prototype.setCurrentDirectory=function(k){};Runtime.prototype.type=function(){};Runtime.prototype.getDOMImplementation=function(){}; @@ -101,8 +101,8 @@ c)&&0<=b.compareBoundaryPoints(Range.START_TO_END,c)};this.getNodesInRange=funct a.currentNode=b):b.startOffset===(b.startContainer.nodeType===Node.TEXT_NODE?b.startContainer.length:b.startContainer.childNodes.length)?(b=b.startContainer,a.currentNode=b,a.lastChild(),b=a.nextNode()):(b=b.startContainer,a.currentNode=b);b&&c(b)===NodeFilter.FILTER_ACCEPT&&m.push(b);for(b=a.nextNode();b;){c=e.compareDocumentPosition(b);if(0!==c&&0===(c&d))break;m.push(b);b=a.nextNode()}return m};this.normalizeTextNodes=function(b){b&&b.nextSibling&&(b=d(b,b.nextSibling));b&&b.previousSibling&&d(b.previousSibling, b)};this.rangeContainsNode=function(b,c){var a=c.ownerDocument.createRange(),m=c.ownerDocument.createRange(),e;a.setStart(b.startContainer,b.startOffset);a.setEnd(b.endContainer,b.endOffset);m.selectNodeContents(c);e=h(a,m);a.detach();m.detach();return e};this.mergeIntoParent=n;this.removeUnwantedNodes=g;this.getElementsByTagNameNS=function(b,c,a){var m=[];b=b.getElementsByTagNameNS(c,a);m.length=a=b.length;for(c=0;ca.width&&(m=a.width/f);c>a.height&&(e=a.height/c);m=Math.min(m,e);a=f*m;f=c*m;e=n.getOdfCanvas().odfContainer().rootElement.styles;c=r.toLowerCase();var m=p.hasOwnProperty(c)?p[c]:null,t;c=[];runtime.assert(null!==m,"Image type is not supported: "+r);m="Pictures/"+b.generateImageName()+m;t=new ops.OpSetBlob;t.init({memberid:h,filename:m,mimetype:r,content:l});c.push(t);g.getStyleElement("Graphics","graphic",[e])||(r=new ops.OpAddStyle,r.init({memberid:h,styleName:"Graphics",styleFamily:"graphic",