parent
69813539f7
commit
7eba1fb1e2
19 changed files with 4284 additions and 4193 deletions
|
@ -1,3 +1,10 @@
|
|||
30-AUG-2018: 9.1.1
|
||||
|
||||
- Simpler provided/required interface shapes
|
||||
- Fixes comic style for filled swimlanes
|
||||
- Fixes preview for general sidebar
|
||||
- Uses mxGraph 3.9.9 beta 9
|
||||
|
||||
29-AUG-2018: 9.1.0
|
||||
|
||||
- Adds content inspection in proxy server
|
||||
|
|
2
VERSION
2
VERSION
|
@ -1 +1 @@
|
|||
9.1.0
|
||||
9.1.1
|
|
@ -548,10 +548,10 @@ this.direction==mxConstants.DIRECTION_WEST);if(f){b=Math.min(a.width,b*this.scal
|
|||
mxSwimlane.prototype.getArcSize=function(a,b,c){a=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100;return c*a*3};mxSwimlane.prototype.isHorizontal=function(){return 1==mxUtils.getValue(this.style,mxConstants.STYLE_HORIZONTAL,1)};
|
||||
mxSwimlane.prototype.paintVertexShape=function(a,b,c,d,e){var f=this.getTitleSize(),g=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE),k=1==mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_LINE,1),l=0,f=this.isHorizontal()?Math.min(f,e):Math.min(f,d);a.translate(b,c);this.isRounded?(l=this.getArcSize(d,e,f),this.paintRoundedSwimlane(a,b,c,d,e,f,l,g,k)):this.paintSwimlane(a,b,c,d,e,f,g,k);g=mxUtils.getValue(this.style,mxConstants.STYLE_SEPARATORCOLOR,mxConstants.NONE);
|
||||
this.paintSeparator(a,b,c,d,e,f,g);null!=this.image&&(e=this.getImageBounds(b,c,d,e),a.image(e.x-b,e.y-c,e.width,e.height,this.image,!1,!1,!1));this.glass&&(a.setShadow(!1),this.paintGlassEffect(a,0,0,d,f,l))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,k){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),a.rect(0,0,d,e),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,e),a.lineTo(f,e),(k||f>=d)&&
|
||||
a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,k,l){g=Math.min(e-f,Math.min(f,g));k!=mxConstants.NONE&&(a.save(),a.setFillColor(k),a.roundrect(0,0,d,e,g,g),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(l||f>=e)&&a.close(),a.fillAndStroke(),f<e&&k==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e-g),a.quadTo(0,
|
||||
e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(l||f>=d)&&a.close(),a.fillAndStroke(),f<d&&k==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,k){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,
|
||||
e),a.lineTo(f,e),(k||f>=d)&&a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,k,l){g=Math.min(e-f,Math.min(f,g));k!=mxConstants.NONE&&(a.save(),a.setFillColor(k),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(l||f>=e)&&a.close(),a.fillAndStroke(),f<e&&k==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,
|
||||
f),a.lineTo(0,e-g),a.quadTo(0,e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(l||f>=d)&&a.close(),a.fillAndStroke(),f<d&&k==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSeparator=function(a,b,c,d,e,f,g){g!=mxConstants.NONE&&(a.setStrokeColor(g),a.setDashed(!0),a.begin(),this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,e)):(a.moveTo(f,0),a.lineTo(d,0)),a.stroke(),a.setDashed(!1))};mxSwimlane.prototype.getImageBounds=function(a,b,c,d){return this.isHorizontal()?new mxRectangle(a+c-this.imageSize,b,this.imageSize,this.imageSize):new mxRectangle(a,b,this.imageSize,this.imageSize)};function mxGraphLayout(a){this.graph=a}
|
||||
mxGraphLayout.prototype.graph=null;mxGraphLayout.prototype.useBoundingBox=!0;mxGraphLayout.prototype.parent=null;mxGraphLayout.prototype.moveCell=function(a,b,c){};mxGraphLayout.prototype.execute=function(a){};mxGraphLayout.prototype.getGraph=function(){return this.graph};mxGraphLayout.prototype.getConstraint=function(a,b,c,d){c=this.graph.view.getState(b);b=null!=c?c.style:this.graph.getCellStyle(b);return null!=b?b[a]:null};
|
||||
mxGraphLayout.traverse=function(a,b,c,d,e){if(null!=c&&null!=a&&(b=null!=b?b:!0,e=e||new mxDictionary,!e.get(a)&&(e.put(a,!0),d=c(a,d),null==d||d))&&(d=this.graph.model.getEdgeCount(a),0<d))for(var f=0;f<d;f++){var g=this.graph.model.getEdgeAt(a,f),k=this.graph.model.getTerminal(g,!0)==a;if(!b||k)k=this.graph.view.getVisibleTerminal(g,!k),this.traverse(k,b,c,g,e)}};
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
CACHE MANIFEST
|
||||
|
||||
# THIS FILE WAS GENERATED. DO NOT MODIFY!
|
||||
# 08/29/2018 11:24 AM
|
||||
# 08/30/2018 06:43 PM
|
||||
|
||||
app.html
|
||||
index.html?offline=1
|
||||
|
|
Binary file not shown.
Before Width: | Height: | Size: 18 KiB After Width: | Height: | Size: 18 KiB |
Binary file not shown.
Before Width: | Height: | Size: 24 KiB After Width: | Height: | Size: 31 KiB |
Binary file not shown.
Before Width: | Height: | Size: 12 KiB After Width: | Height: | Size: 16 KiB |
1270
src/main/webapp/js/app.min.js
vendored
1270
src/main/webapp/js/app.min.js
vendored
File diff suppressed because it is too large
Load diff
1834
src/main/webapp/js/atlas-viewer.min.js
vendored
1834
src/main/webapp/js/atlas-viewer.min.js
vendored
File diff suppressed because one or more lines are too long
2442
src/main/webapp/js/atlas.min.js
vendored
2442
src/main/webapp/js/atlas.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -1017,6 +1017,33 @@
|
|||
{fill: '#cce5ff', stroke: '#36393d'}, {fill: '#ffff88', stroke: '#36393d'},
|
||||
{fill: '#cdeb8b', stroke: '#36393d'}, {fill: '#ffcccc', stroke: '#36393d'}]];
|
||||
|
||||
StyleFormatPanel.prototype.findCommonProperties = function(cell, properties, addAll)
|
||||
{
|
||||
if (properties == null) return;
|
||||
|
||||
var view = this.editorUi.editor.graph.view;
|
||||
var state = view.getState(cell);
|
||||
|
||||
if (state != null)
|
||||
{
|
||||
var custProperties = state.shape.customProperties;
|
||||
|
||||
for (var i = 0; custProperties && i < custProperties.length; i++)
|
||||
{
|
||||
var p = custProperties[i];
|
||||
|
||||
if (addAll)
|
||||
{
|
||||
properties[p.name] = p;
|
||||
}
|
||||
else if (properties[p.name] == null || (properties[p.name] != null && properties[p.name].type != p.type))
|
||||
{
|
||||
delete properties[p.name];
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
* Adds predefiend styles.
|
||||
*/
|
||||
|
@ -1035,7 +1062,24 @@
|
|||
styleFormatPanelInit.apply(this, arguments);
|
||||
|
||||
if (urlParams['properties'] == '1')
|
||||
this.container.appendChild(this.addProperties(this.createPanel(), sstate));
|
||||
{
|
||||
var properties = {};
|
||||
var vertices = sstate.vertices;
|
||||
var edges = sstate.edges;
|
||||
|
||||
for (var i = 0; i < vertices.length; i++)
|
||||
{
|
||||
this.findCommonProperties(vertices[i], properties, i == 0);
|
||||
}
|
||||
|
||||
for (var i = 0; i < edges.length; i++)
|
||||
{
|
||||
this.findCommonProperties(edges[i], properties, vertices.length == 0 && i == 0);
|
||||
}
|
||||
|
||||
if (Object.getOwnPropertyNames(properties).length > 0)
|
||||
this.container.appendChild(this.addProperties(this.createPanel(), properties, sstate));
|
||||
}
|
||||
};
|
||||
|
||||
/**
|
||||
|
@ -1075,7 +1119,7 @@
|
|||
/**
|
||||
* Create Properties Panel
|
||||
*/
|
||||
StyleFormatPanel.prototype.addProperties = function(div, state)
|
||||
StyleFormatPanel.prototype.addProperties = function(div, properties, state)
|
||||
{
|
||||
var that = this;
|
||||
var graph = this.editorUi.editor.graph;
|
||||
|
@ -1147,13 +1191,13 @@
|
|||
return input;
|
||||
};
|
||||
|
||||
function createPropertyRow(pName, pDiplayName, pValue, pType, isOdd)
|
||||
function createPropertyRow(pName, pDiplayName, pValue, pType, pEnumList, isOdd)
|
||||
{
|
||||
var row = document.createElement('tr');
|
||||
row.className = "propRow" + (isOdd? "Alt" : "");
|
||||
var td = document.createElement('td');
|
||||
td.className = "propRowCell";
|
||||
td.innerHTML = mxUtils.htmlEntities(pDiplayName);
|
||||
td.innerHTML = mxUtils.htmlEntities(mxResources.get(pDiplayName, null, pDiplayName));
|
||||
row.appendChild(td);
|
||||
td = document.createElement('td');
|
||||
td.className = "propRowCell";
|
||||
|
@ -1166,15 +1210,15 @@
|
|||
{
|
||||
td.appendChild(createCheckbox(pName, pValue));
|
||||
}
|
||||
else if (pType.type == "enum")
|
||||
else if (pType == "enum")
|
||||
{
|
||||
for (var i = 0; i < pType.options.length; i++)
|
||||
for (var i = 0; i < pEnumList.length; i++)
|
||||
{
|
||||
var op = pType.options[i];
|
||||
var op = pEnumList[i];
|
||||
|
||||
if (op.val == pValue)
|
||||
{
|
||||
td.innerHTML = mxUtils.htmlEntities(op.dispName);
|
||||
td.innerHTML = mxUtils.htmlEntities(mxResources.get(op.dispName, null, op.dispName));
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
@ -1184,16 +1228,16 @@
|
|||
var select = document.createElement('select');
|
||||
setElementPos(td, select);
|
||||
|
||||
for (var i = 0; i < pType.options.length; i++)
|
||||
for (var i = 0; i < pEnumList.length; i++)
|
||||
{
|
||||
var op = pType.options[i];
|
||||
var op = pEnumList[i];
|
||||
var opElem = document.createElement('option');
|
||||
opElem.value = mxUtils.htmlEntities(op.val);
|
||||
opElem.innerHTML = mxUtils.htmlEntities(op.dispName);
|
||||
opElem.innerHTML = mxUtils.htmlEntities(mxResources.get(op.dispName, null, op.dispName));
|
||||
select.appendChild(opElem);
|
||||
}
|
||||
|
||||
select.value = mxUtils.htmlEntities(pValue);
|
||||
select.value = pValue;
|
||||
|
||||
document.body.appendChild(select);
|
||||
|
||||
|
@ -1204,15 +1248,16 @@
|
|||
|
||||
mxEvent.addListener(select, 'change', function()
|
||||
{
|
||||
applyStyleVal(pName, select.value);
|
||||
td.innerHTML = mxUtils.htmlEntities(select.value);
|
||||
var newVal = mxUtils.htmlEntities(select.value);
|
||||
applyStyleVal(pName, newVal);
|
||||
td.innerHTML = newVal;
|
||||
});
|
||||
select.focus();
|
||||
}));
|
||||
}
|
||||
else
|
||||
{
|
||||
td.innerHTML = mxUtils.htmlEntities(pValue);
|
||||
td.innerHTML = pValue;
|
||||
mxEvent.addListener(td, 'click', mxUtils.bind(that, function()
|
||||
{
|
||||
var input = document.createElement('input');
|
||||
|
@ -1233,9 +1278,9 @@
|
|||
|
||||
function setInputVal()
|
||||
{
|
||||
var newVal = pType == "int"? parseInt(input.value) + '' : input.value;
|
||||
var newVal = mxUtils.htmlEntities(pType == "int"? parseInt(input.value) + '' : input.value);
|
||||
applyStyleVal(pName, newVal);
|
||||
td.innerHTML = mxUtils.htmlEntities(newVal);
|
||||
td.innerHTML = newVal;
|
||||
}
|
||||
|
||||
mxEvent.addListener(input, 'change', setInputVal);
|
||||
|
@ -1279,36 +1324,12 @@
|
|||
grid.appendChild(hrow);
|
||||
|
||||
var isOdd = false;
|
||||
for (var key in state.style)
|
||||
for (var key in properties)
|
||||
{
|
||||
var pValue = state.style[key];
|
||||
|
||||
//skip non-common properties (which are set to empty string)
|
||||
if (pValue == "") continue;
|
||||
|
||||
var type = "string";
|
||||
var pValue = mxUtils.htmlEntities(state.style[key]);
|
||||
var prop = properties[key];
|
||||
|
||||
if (typeof pValue == "string" && pValue.indexOf("#") == 0 && pValue.length == 7)
|
||||
{
|
||||
type = "color";
|
||||
}
|
||||
else if (pValue == '1')
|
||||
{
|
||||
type = 'bool';
|
||||
}
|
||||
else if (parseInt(pValue) == parseFloat(pValue))
|
||||
{
|
||||
type = "int";
|
||||
}
|
||||
else if (isFinite(parseFloat(pValue)))
|
||||
{
|
||||
type = "float";
|
||||
}
|
||||
else if (pValue == 'middle')
|
||||
{
|
||||
type = {type: 'enum', options: [{val: 'middle', dispName: 'Middle'}, {val: 'bottom', dispName: 'Bottom'}, {val: 'top', dispName: 'Top'}]};
|
||||
}
|
||||
grid.appendChild(createPropertyRow(key, key.charAt(0).toUpperCase() + key.substr(1), pValue, type, isOdd));
|
||||
grid.appendChild(createPropertyRow(key, prop.dispName, pValue, prop.type, prop.enumList, isOdd));
|
||||
isOdd = !isOdd;
|
||||
}
|
||||
|
||||
|
|
|
@ -747,7 +747,7 @@
|
|||
// Space savers
|
||||
var sb = this;
|
||||
var gn = 'mxgraph.veeam.3d';
|
||||
var dt = 'veeam 3d three dimension vmware virtual machine ';
|
||||
var dt = 'veeam 3d vmware virtual machine ';
|
||||
|
||||
var w = 2.0;
|
||||
var h = 2.0;
|
||||
|
|
446
src/main/webapp/js/embed-static.min.js
vendored
446
src/main/webapp/js/embed-static.min.js
vendored
|
@ -36,18 +36,18 @@ function(){return null!==this.k};f.prototype.V=function(){return this.h&&decodeU
|
|||
this.l};f.prototype.ba=function(a){if("object"===typeof a&&!(a instanceof Array)&&(a instanceof Object||"[object Array]"!==Object.prototype.toString.call(a))){var b=[],c=-1,d;for(d in a){var e=a[d];"string"===typeof e&&(b[++c]=d,b[++c]=e)}a=b}for(var b=[],c="",f=0;f<a.length;)d=a[f++],e=a[f++],b.push(c,encodeURIComponent(d.toString())),c="&",e&&b.push("=",encodeURIComponent(e.toString()));this.l=b.join("")};f.prototype.fa=function(a){this.o=a?a:null};f.prototype.Z=function(){return null!==this.o};
|
||||
var l=/^(?:([^:/?#]+):)?(?:\/\/(?:([^/?#]*)@)?([^/?#:@]*)(?::([0-9]+))?)?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/,m=/[#\/\?@]/g,n=/[\#\?]/g;f.parse=a;f.create=function(a,d,e,g,h,k,l){a=new f(b(a,m),b(d,m),"string"==typeof e?encodeURIComponent(e):null,0<g?g.toString():null,b(h,n),null,"string"==typeof l?encodeURIComponent(l):null);k&&("string"===typeof k?a.O(k.replace(/[^?&=0-9A-Za-z_\-~.%]/g,c)):a.ba(k));return a};f.N=e;f.ma=d;f.ha={ua:function(b){return/\.html$/.test(a(b).U())?"text/html":"application/javascript"},
|
||||
N:function(b,c){return b?e(a(b),a(c)).toString():""+c}};return f}();"undefined"!==typeof window&&(window.URI=f);var g=void 0,h=void 0,k=void 0,l=void 0;(function(){function a(a){return"string"===typeof a?'url("'+a.replace(x,c)+'")':'url("about:blank")'}function c(a){return y[a]}function d(a,b){return a?f.ha.N(a,b):b}function n(a,b,c){if(!c)return null;var d=(""+a).match(u);return!d||d[1]&&!D.test(d[1])?null:c(a,b)}function w(a){return a.replace(/^-(?:apple|css|epub|khtml|moz|mso?|o|rim|wap|webkit|xv)-(?=[a-z])/,
|
||||
"")}var x=/[\n\f\r\"\'()*<>]/g,y={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},u=/^(?:([^:/?# ]+):)?/,D=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function C(f,g,h,k,l){f=w(f);var m=b[f];if(m&&"object"===typeof m){for(var p=m.cssPropBits,v=p&80,q=p&1536,r=NaN,B=0,u=0;B<g.length;++B){var t=g[B].toLowerCase(),z=t.charCodeAt(0),x,L,y,D,H,E;if(32===z)t="";else if(34===z)t=16===v?h?a(n(d(k,e(g[B].substring(1,t.length-1))),f,h)):"":
|
||||
p&8&&!(v&v-1)?t:"";else if("inherit"!==t){if(H=m.cssLitGroup){var F;if(!(F=m.cssLitMap)){F={};for(var K=H.length;0<=--K;)for(var R=H[K],fa=R.length;0<=--fa;)F[R[fa]]=c;F=m.cssLitMap=F}H=F}else H=c;if(E=H,E[w(t)]!==c)if(35===z&&/^#(?:[0-9a-f]{3}){1,2}$/.test(t))t=p&2?t:"";else if(48<=z&&57>=z)t=p&1?t:"";else if(x=t.charCodeAt(1),L=t.charCodeAt(2),y=48<=x&&57>=x,D=48<=L&&57>=L,43===z&&(y||46===x&&D))t=p&1?(y?"":"0")+t.substring(1):"";else if(45===z&&(y||46===x&&D))t=p&4?(y?"-":"-0")+t.substring(1):
|
||||
p&1?"0":"";else if(46===z&&y)t=p&1?"0"+t:"";else if('url("'===t.substring(0,5))t=h&&p&16?a(n(d(k,g[B].substring(5,t.length-2)),f,h)):"";else if("("===t.charAt(t.length-1))a:{H=g;F=B;t=1;K=F+1;for(z=H.length;K<z&&t;)R=H[K++],t+=")"===R?-1:/^[^"']*\($/.test(R);if(!t)for(t=H[F].toLowerCase(),z=w(t),H=H.splice(F,K-F,""),F=m.cssFns,K=0,R=F.length;K<R;++K)if(F[K].substring(0,z.length)==z){H[0]=H[H.length-1]="";C(F[K],H,h,k);t=t+H.join(" ")+")";break a}t=""}else t=q&&/^-?[a-z_][\w\-]*$/.test(t)&&!/__$/.test(t)?
|
||||
"")}var x=/[\n\f\r\"\'()*<>]/g,y={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},u=/^(?:([^:/?# ]+):)?/,D=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function C(f,g,h,k,l){f=w(f);var m=b[f];if(m&&"object"===typeof m){for(var p=m.cssPropBits,v=p&80,q=p&1536,r=NaN,B=0,u=0;B<g.length;++B){var t=g[B].toLowerCase(),z=t.charCodeAt(0),x,L,y,D,G,E;if(32===z)t="";else if(34===z)t=16===v?h?a(n(d(k,e(g[B].substring(1,t.length-1))),f,h)):"":
|
||||
p&8&&!(v&v-1)?t:"";else if("inherit"!==t){if(G=m.cssLitGroup){var F;if(!(F=m.cssLitMap)){F={};for(var K=G.length;0<=--K;)for(var Q=G[K],fa=Q.length;0<=--fa;)F[Q[fa]]=c;F=m.cssLitMap=F}G=F}else G=c;if(E=G,E[w(t)]!==c)if(35===z&&/^#(?:[0-9a-f]{3}){1,2}$/.test(t))t=p&2?t:"";else if(48<=z&&57>=z)t=p&1?t:"";else if(x=t.charCodeAt(1),L=t.charCodeAt(2),y=48<=x&&57>=x,D=48<=L&&57>=L,43===z&&(y||46===x&&D))t=p&1?(y?"":"0")+t.substring(1):"";else if(45===z&&(y||46===x&&D))t=p&4?(y?"-":"-0")+t.substring(1):
|
||||
p&1?"0":"";else if(46===z&&y)t=p&1?"0"+t:"";else if('url("'===t.substring(0,5))t=h&&p&16?a(n(d(k,g[B].substring(5,t.length-2)),f,h)):"";else if("("===t.charAt(t.length-1))a:{G=g;F=B;t=1;K=F+1;for(z=G.length;K<z&&t;)Q=G[K++],t+=")"===Q?-1:/^[^"']*\($/.test(Q);if(!t)for(t=G[F].toLowerCase(),z=w(t),G=G.splice(F,K-F,""),F=m.cssFns,K=0,Q=F.length;K<Q;++K)if(F[K].substring(0,z.length)==z){G[0]=G[G.length-1]="";C(F[K],G,h,k);t=t+G.join(" ")+")";break a}t=""}else t=q&&/^-?[a-z_][\w\-]*$/.test(t)&&!/__$/.test(t)?
|
||||
l&&512===q?g[B]+l:1024===q&&b[t]&&"number"===typeof b[t].oa?t:"":/^\w+$/.test(t)&&64===v&&p&8?r+1===u?(g[r]=g[r].substring(0,g[r].length-1)+" "+t+'"',""):(r=u,'"'+t+'"'):""}t&&(g[u++]=t)}1===u&&'url("about:blank")'===g[0]&&(u=0);g.length=u}else g.length=0}}();var F=/^(active|after|before|blank|checked|default|disabled|drop|empty|enabled|first|first-child|first-letter|first-line|first-of-type|fullscreen|focus|hover|in-range|indeterminate|invalid|last-child|last-of-type|left|link|only-child|only-of-type|optional|out-of-range|placeholder-shown|read-only|read-write|required|right|root|scope|user-error|valid|visited)$/,
|
||||
E={};E[">"]=E["+"]=E["~"]=E;h=function(a,b,c){function d(d,k){function l(c,d,e){var h,k,l,n,v,Z=!0;h="";c<d&&((v=a[c],"*"===v)?(++c,h=v):/^[a-zA-Z]/.test(v)&&(k=g(v.toLowerCase(),[]))&&("tagName"in k&&(v=k.tagName),++c,h=v));for(n=l=k="";Z&&c<d;++c)if(v=a[c],"#"===v.charAt(0))/^#_|__$|[^\w#:\-]/.test(v)?Z=!1:k+=v+f;else if("."===v)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(v=a[c])&&!/^_|__$/.test(v)?k+="."+v:Z=!1;else if(c+1<d&&"["===a[c]){++c;var C=a[c++].toLowerCase();v=p.m[h+"::"+C];v!==+v&&(v=p.m["*::"+
|
||||
C]);var q;b.ia?(q=b.ia(h,C),"string"!==typeof q&&(Z=!1,q=C),Z&&v!==+v&&(v=p.d.NONE)):(q=C,v!==+v&&(Z=!1));var r=C="",B=!1;/^[~^$*|]?=$/.test(a[c])&&(C=a[c++],r=a[c++],/^[0-9A-Za-z:_\-]+$/.test(r)?r='"'+r+'"':"]"===r&&(r='""',--c),/^"([^\"\\]|\\.)*"$/.test(r)||(Z=!1),(B="i"===a[c])&&++c);"]"!==a[c]&&(++c,Z=!1);switch(v){case p.d.CLASSES:case p.d.LOCAL_NAME:case p.d.NONE:break;case p.d.GLOBAL_NAME:case p.d.ID:case p.d.IDREF:"="!==C&&"~="!==C&&"$="!==C||'""'==r||B?"|="===C||""===C||(Z=!1):r='"'+r.substring(1,
|
||||
r.length-1)+f+'"';break;case p.d.URI:case p.d.URI_FRAGMENT:""!==C&&(Z=!1);break;default:Z=!1}Z&&(l+="["+q.replace(/[^\w-]/g,"\\$&")+C+r+(B?" i]":"]"))}else if(c<d&&":"===a[c])if(v=a[++c],F.test(v))n+=":"+v;else break;else break;c!==d&&(Z=!1);Z&&(c=(h+k).replace(/[^ .*#\w-]/g,"\\$&")+l+n+e)&&m.push(c);return Z}" "===a[d]&&++d;k-1!==d&&" "===a[k]&&--k;for(var m=[],n=d,v=!0,C=d;v&&C<k;++C){var q=a[C];if(E[q]===E||" "===q)l(n,C,q)?n=C+1:v=!1}l(n,k,"")||(v=!1);return v?(m.length&&(n=m.join(""),null!==
|
||||
E={};E[">"]=E["+"]=E["~"]=E;h=function(a,b,c){function d(d,k){function l(c,d,e){var h,k,l,n,v,Y=!0;h="";c<d&&((v=a[c],"*"===v)?(++c,h=v):/^[a-zA-Z]/.test(v)&&(k=g(v.toLowerCase(),[]))&&("tagName"in k&&(v=k.tagName),++c,h=v));for(n=l=k="";Y&&c<d;++c)if(v=a[c],"#"===v.charAt(0))/^#_|__$|[^\w#:\-]/.test(v)?Y=!1:k+=v+f;else if("."===v)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(v=a[c])&&!/^_|__$/.test(v)?k+="."+v:Y=!1;else if(c+1<d&&"["===a[c]){++c;var C=a[c++].toLowerCase();v=p.m[h+"::"+C];v!==+v&&(v=p.m["*::"+
|
||||
C]);var q;b.ia?(q=b.ia(h,C),"string"!==typeof q&&(Y=!1,q=C),Y&&v!==+v&&(v=p.d.NONE)):(q=C,v!==+v&&(Y=!1));var r=C="",B=!1;/^[~^$*|]?=$/.test(a[c])&&(C=a[c++],r=a[c++],/^[0-9A-Za-z:_\-]+$/.test(r)?r='"'+r+'"':"]"===r&&(r='""',--c),/^"([^\"\\]|\\.)*"$/.test(r)||(Y=!1),(B="i"===a[c])&&++c);"]"!==a[c]&&(++c,Y=!1);switch(v){case p.d.CLASSES:case p.d.LOCAL_NAME:case p.d.NONE:break;case p.d.GLOBAL_NAME:case p.d.ID:case p.d.IDREF:"="!==C&&"~="!==C&&"$="!==C||'""'==r||B?"|="===C||""===C||(Y=!1):r='"'+r.substring(1,
|
||||
r.length-1)+f+'"';break;case p.d.URI:case p.d.URI_FRAGMENT:""!==C&&(Y=!1);break;default:Y=!1}Y&&(l+="["+q.replace(/[^\w-]/g,"\\$&")+C+r+(B?" i]":"]"))}else if(c<d&&":"===a[c])if(v=a[++c],F.test(v))n+=":"+v;else break;else break;c!==d&&(Y=!1);Y&&(c=(h+k).replace(/[^ .*#\w-]/g,"\\$&")+l+n+e)&&m.push(c);return Y}" "===a[d]&&++d;k-1!==d&&" "===a[k]&&--k;for(var m=[],n=d,v=!0,C=d;v&&C<k;++C){var q=a[C];if(E[q]===E||" "===q)l(n,C,q)?n=C+1:v=!1}l(n,k,"")||(v=!1);return v?(m.length&&(n=m.join(""),null!==
|
||||
e&&(n="."+e+" "+n),h.push(n)),!0):!c||c(a.slice(d,k))}var e=b.na,f=b.L,g=b.Aa,h=[],k=0,l,m=0,n;for(l=0;l<a.length;++l)(n=a[l],"("==n||"["==n?(++m,0):")"==n||"]"==n?(m&&--m,0):" "==a[l]&&(m||E[a[l-1]]===E||E[a[l+1]]===E))||(a[k++]=a[l]);a.length=k;k=a.length;for(l=m=0;l<k;++l)if(","===a[l]){if(!d(m,l))return null;m=l+1}return d(m,k)?h:null};(function(){var a=/^\w/,b=/^(?:(?:(?:(?:only|not) )?(?:all|aural|braille|embossed|handheld|print|projection|screen|speech|tty|tv)|\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))(?: and ?\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))*)(?: , (?:(?:(?:(?:only|not) )?(?:all|aural|braille|embossed|handheld|print|projection|screen|speech|tty|tv)|\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))(?: and ?\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))*))*$/i;
|
||||
l=function(c){c=c.slice();for(var d=c.length,e=0,f=0;f<d;++f){var g=c[f];" "!=g&&(c[e++]=g)}c.length=e;c=c.join(" ");return c.length?b.test(c)?a.test(c)?c:"not all , "+c:"not all":""}})();(function(){function a(a){var b=/^\s*[']([^']*)[']\s*$/,c=/^\s*url\s*[(]["]([^"]*)["][)]\s*$/,d=/^\s*url\s*[(][']([^']*)['][)]\s*$/,e=/^\s*url\s*[(]([^)]*)[)]\s*$/,f;return(f=/^\s*["]([^"]*)["]\s*$/.exec(a))||(f=b.exec(a))||(f=c.exec(a))||(f=d.exec(a))||(f=e.exec(a))?f[1]:null}function b(c,e,f,k,p,q,r){function C(){t=
|
||||
G.length&&null===G[G.length-1]}var v=void 0,B=r||[0],G=[],t=!1;m(e,{startStylesheet:function(){v=[]},endStylesheet:function(){},startAtrule:function(e,g){if(t)e=null;else if("@media"===e)v.push("@media"," ",l(g));else if("@keyframes"===e||"@-webkit-keyframes"===e){var h=g[0];1!==g.length||/__$|[^\w\-]/.test(h)?e=null:(v.push(e," ",h+f.L),e="@keyframes")}else if("@import"===e&&0<g.length)if(e=null,"function"===typeof q){var m=l(g.slice(1));if("not all"!==m){++B[0];var C=[];v.push(C);var r=n(d(c,a(g[0])),
|
||||
function(a){var c=b(r,a.qa,f,k,p,q,B);--B[0];a=m?{toString:function(){return"@media "+m+" {"+c.result+"}"}}:c.result;C[0]=a;q(a,!!B[0])},p)}}else window.console&&window.console.log("@import "+g.join(" ")+" elided");t=!e;G.push(e)},endAtrule:function(){G.pop();t||v.push(";");C()},startBlock:function(){t||v.push("{")},endBlock:function(){t||(v.push("}"),t=!0)},startRuleset:function(a){if(!t){var b=void 0;"@keyframes"===G[G.length-1]?(b=a.join(" ").match(/^ *(?:from|to|\d+(?:\.\d+)?%) *(?:, *(?:from|to|\d+(?:\.\d+)?%) *)*$/i),
|
||||
t=!b,b&&(b=b[0].replace(/ +/g,""))):(a=h(a,f),a&&a.length?b=a.join(", "):t=!0);t||v.push(b,"{")}G.push(null)},endRuleset:function(){G.pop();t||v.push("}");C()},declaration:function(a,b){if(!t){var d=!1,e=b.length;2<=e&&"!"===b[e-2]&&"important"===b[e-1].toLowerCase()&&(d=!0,b.length-=2);g(a,b,k,c,f.L);b.length&&v.push(a,":",b.join(" "),d?" !important;":";")}}});return{result:{toString:function(){return v.join("")}},va:!!B[0]}}k=function(a,c,d,e){return b(a,c,d,e,void 0,void 0).result.toString()}})()})();
|
||||
H.length&&null===H[H.length-1]}var v=void 0,B=r||[0],H=[],t=!1;m(e,{startStylesheet:function(){v=[]},endStylesheet:function(){},startAtrule:function(e,g){if(t)e=null;else if("@media"===e)v.push("@media"," ",l(g));else if("@keyframes"===e||"@-webkit-keyframes"===e){var h=g[0];1!==g.length||/__$|[^\w\-]/.test(h)?e=null:(v.push(e," ",h+f.L),e="@keyframes")}else if("@import"===e&&0<g.length)if(e=null,"function"===typeof q){var m=l(g.slice(1));if("not all"!==m){++B[0];var C=[];v.push(C);var r=n(d(c,a(g[0])),
|
||||
function(a){var c=b(r,a.qa,f,k,p,q,B);--B[0];a=m?{toString:function(){return"@media "+m+" {"+c.result+"}"}}:c.result;C[0]=a;q(a,!!B[0])},p)}}else window.console&&window.console.log("@import "+g.join(" ")+" elided");t=!e;H.push(e)},endAtrule:function(){H.pop();t||v.push(";");C()},startBlock:function(){t||v.push("{")},endBlock:function(){t||(v.push("}"),t=!0)},startRuleset:function(a){if(!t){var b=void 0;"@keyframes"===H[H.length-1]?(b=a.join(" ").match(/^ *(?:from|to|\d+(?:\.\d+)?%) *(?:, *(?:from|to|\d+(?:\.\d+)?%) *)*$/i),
|
||||
t=!b,b&&(b=b[0].replace(/ +/g,""))):(a=h(a,f),a&&a.length?b=a.join(", "):t=!0);t||v.push(b,"{")}H.push(null)},endRuleset:function(){H.pop();t||v.push("}");C()},declaration:function(a,b){if(!t){var d=!1,e=b.length;2<=e&&"!"===b[e-2]&&"important"===b[e-1].toLowerCase()&&(d=!0,b.length-=2);g(a,b,k,c,f.L);b.length&&v.push(a,":",b.join(" "),d?" !important;":";")}}});return{result:{toString:function(){return v.join("")}},va:!!B[0]}}k=function(a,c,d,e){return b(a,c,d,e,void 0,void 0).result.toString()}})()})();
|
||||
"undefined"!==typeof window&&(window.sanitizeCssProperty=g,window.sanitizeCssSelectorList=h,window.sanitizeStylesheet=k,window.sanitizeMediaQuery=l);var m,n;(function(){function a(a,c,d,e,f){for(var g=c++;c<d&&"{"!==a[c]&&";"!==a[c];)++c;if(c<d&&(f||";"===a[c])){f=g+1;var h=c;f<d&&" "===a[f]&&++f;h>f&&" "===a[h-1]&&--h;e.startAtrule&&e.startAtrule(a[g].toLowerCase(),a.slice(f,h));c="{"===a[c]?b(a,c,d,e):c+1;e.endAtrule&&e.endAtrule()}return c}function b(d,e,f,g){++e;for(g.startBlock&&g.startBlock();e<
|
||||
f;){var h=d[e].charAt(0);if("}"==h){++e;break}e=" "===h||";"===h?e+1:"@"===h?a(d,e,f,g,!1):"{"===h?b(d,e,f,g):c(d,e,f,g)}g.endBlock&&g.endBlock();return e}function c(a,b,c,d){var f=b,h=e(a,b,c,!0);if(0>h)return h=~h,h===f?h+1:h;var k=a[h];if("{"!==k)return h===f?h+1:h;b=h+1;h>f&&" "===a[h-1]&&--h;for(d.startRuleset&&d.startRuleset(a.slice(f,h));b<c;){k=a[b];if("}"===k){++b;break}b=" "===k?b+1:g(a,b,c,d)}d.endRuleset&&d.endRuleset();return b}function e(a,b,c,d){for(var e,f=[],g=-1;b<c;++b)if(e=a[b].charAt(0),
|
||||
"["===e||"("===e)f[++g]=e;else if("]"===e&&"["===f[g]||")"===e&&"("===f[g])--g;else if("{"===e||"}"===e||";"===e||"@"===e||":"===e&&!d)break;0<=g&&(b=~(b+1));return b}function f(a,b,c){for(;b<c&&";"!==a[b]&&"}"!==a[b];)++b;return b<c&&";"===a[b]?b+1:b}function g(a,b,c,d){var g=a[b++];if(!h.test(g))return f(a,b,c);b<c&&" "===a[b]&&++b;if(b==c||":"!==a[b])return f(a,b,c);++b;b<c&&" "===a[b]&&++b;var k=e(a,b,c,!1);if(0>k)k=~k;else{for(var l=[],m=0,n=b;n<k;++n)b=a[n]," "!==b&&(l[m++]=b);if(k<c){do{b=
|
||||
|
@ -71,21 +71,21 @@ frameset:"HTMLFrameSetElement",h1:"HTMLHeadingElement",h2:"HTMLHeadingElement",h
|
|||
li:"HTMLLIElement",link:"HTMLLinkElement",map:"HTMLMapElement",mark:"HTMLElement",menu:"HTMLMenuElement",meta:"HTMLMetaElement",meter:"HTMLMeterElement",nav:"HTMLElement",nobr:"HTMLElement",noembed:"HTMLElement",noframes:"HTMLElement",noscript:"HTMLElement",object:"HTMLObjectElement",ol:"HTMLOListElement",optgroup:"HTMLOptGroupElement",option:"HTMLOptionElement",output:"HTMLOutputElement",p:"HTMLParagraphElement",param:"HTMLParamElement",pre:"HTMLPreElement",progress:"HTMLProgressElement",q:"HTMLQuoteElement",
|
||||
s:"HTMLElement",samp:"HTMLElement",script:"HTMLScriptElement",section:"HTMLElement",select:"HTMLSelectElement",small:"HTMLElement",source:"HTMLSourceElement",span:"HTMLSpanElement",strike:"HTMLElement",strong:"HTMLElement",style:"HTMLStyleElement",sub:"HTMLElement",summary:"HTMLElement",sup:"HTMLElement",table:"HTMLTableElement",tbody:"HTMLTableSectionElement",td:"HTMLTableDataCellElement",textarea:"HTMLTextAreaElement",tfoot:"HTMLTableSectionElement",th:"HTMLTableHeaderCellElement",thead:"HTMLTableSectionElement",
|
||||
time:"HTMLTimeElement",title:"HTMLTitleElement",tr:"HTMLTableRowElement",track:"HTMLTrackElement",tt:"HTMLElement",u:"HTMLElement",ul:"HTMLUListElement","var":"HTMLElement",video:"HTMLVideoElement",wbr:"HTMLElement"};p.ELEMENT_DOM_INTERFACES=p.Q;p.P={NOT_LOADED:0,SAME_DOCUMENT:1,NEW_DOCUMENT:2};p.ueffects=p.P;p.J={"a::href":2,"area::href":2,"audio::src":1,"blockquote::cite":0,"command::icon":1,"del::cite":0,"form::action":2,"img::src":1,"input::src":1,"ins::cite":0,"q::cite":0,"video::poster":1,"video::src":1};
|
||||
p.URIEFFECTS=p.J;p.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};p.ltypes=p.M;p.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};p.LOADERTYPES=p.I;"undefined"!==typeof window&&(window.html4=p);a=function(a){function b(a,b){var c;if(ba.hasOwnProperty(b))c=ba[b];else{var d=b.match(X);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(v))?String.fromCharCode(parseInt(d[1],
|
||||
16)):G&&Q.test(b)?(G.innerHTML="&"+b+";",d=G.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(ca,b)}function d(a){return(""+a).replace(J,"&").replace(T,"<").replace(ea,">").replace(aa,""")}function e(a){return a.replace(N,"&$1").replace(T,"<").replace(ea,">")}function g(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
|
||||
d=a+"";if(W)d=d.split(e);else{for(var f=[],g=0,h;null!==(h=e.exec(d));)f.push(d.substring(g,h.index)),f.push(h[0]),g=h.index+h[0].length;f.push(d.substring(g));d=f}k(b,d,0,{r:!1,C:!1},c)}}function h(a,b,c,d,e){return function(){k(a,b,c,d,e)}}function k(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var g,k,n,v=c.length;d<v;){var p=c[d++],C=c[d];switch(p){case "&":M.test(C)?(b.e&&b.e("&"+C,f,O,h(b,c,d,e,f)),d++):b.e&&b.e("&",f,O,h(b,c,d,e,f));break;case "</":if(g=/^([-\w:]+)[^\'\"]*/.exec(C))if(g[0].length===
|
||||
C.length&&">"===c[d+1])d+=2,n=g[1].toLowerCase(),b.t&&b.t(n,f,O,h(b,c,d,e,f));else{var Z=c,R=d,q=b,r=f,Y=O,G=e,Q=m(Z,R);Q?(q.t&&q.t(Q.name,r,Y,h(q,Z,R,G,r)),d=Q.next):d=Z.length}else b.e&&b.e("</",f,O,h(b,c,d,e,f));break;case "<":if(g=/^([-\w:]+)\s*\/?/.exec(C))if(g[0].length===C.length&&">"===c[d+1]){d+=2;n=g[1].toLowerCase();b.w&&b.w(n,[],f,O,h(b,c,d,e,f));var t=a.f[n];t&U&&(d=l(c,{name:n,next:d,c:t},b,f,O,e))}else{var Z=c,R=b,q=f,r=O,Y=e,B=m(Z,d);B?(R.w&&R.w(B.name,B.R,q,r,h(R,Z,B.next,Y,q)),
|
||||
d=B.c&U?l(Z,B,R,q,r,Y):B.next):d=Z.length}else b.e&&b.e("<",f,O,h(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(k=d+1;k<v&&(">"!==c[k]||!/--$/.test(c[k-1]));k++);if(k<v){if(b.A){var u=c.slice(d,k).join("");b.A(u.substr(0,u.length-2),f,O,h(b,c,k+1,e,f))}d=k+1}else e.C=!0}e.C&&b.e&&b.e("<!--",f,O,h(b,c,d,e,f));break;case "<!":if(/^\w/.test(C)){if(!e.r){for(k=d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<!",f,O,h(b,c,d,e,f))}else b.e&&b.e("<!",f,O,h(b,c,d,e,f));break;case "<?":if(!e.r){for(k=
|
||||
d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<?",f,O,h(b,c,d,e,f));break;case ">":b.e&&b.e(">",f,O,h(b,c,d,e,f));break;case "":break;default:b.e&&b.e(p,f,O,h(b,c,d,e,f))}}b.B&&b.B(f)}catch(ma){if(ma!==O)throw ma;}}function l(b,c,d,f,g,k){var l=b.length;R.hasOwnProperty(c.name)||(R[c.name]=RegExp("^"+c.name+"(?:[\\s\\/]|$)","i"));for(var m=R[c.name],n=c.next,v=c.next+1;v<l&&("</"!==b[v-1]||!m.test(b[v]));v++);v<l&&--v;l=b.slice(n,v).join("");if(c.c&a.c.CDATA)d.z&&d.z(l,f,g,h(d,b,
|
||||
p.URIEFFECTS=p.J;p.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};p.ltypes=p.M;p.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};p.LOADERTYPES=p.I;"undefined"!==typeof window&&(window.html4=p);a=function(a){function b(a,b){var c;if(ca.hasOwnProperty(b))c=ca[b];else{var d=b.match(W);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(v))?String.fromCharCode(parseInt(d[1],
|
||||
16)):H&&R.test(b)?(H.innerHTML="&"+b+";",d=H.textContent,ca[b]=d):"&"+b+";"}return c}function c(a){return a.replace(da,b)}function d(a){return(""+a).replace(J,"&").replace(aa,"<").replace(ea,">").replace(U,""")}function e(a){return a.replace(M,"&$1").replace(aa,"<").replace(ea,">")}function g(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
|
||||
d=a+"";if(S)d=d.split(e);else{for(var f=[],g=0,h;null!==(h=e.exec(d));)f.push(d.substring(g,h.index)),f.push(h[0]),g=h.index+h[0].length;f.push(d.substring(g));d=f}k(b,d,0,{r:!1,C:!1},c)}}function h(a,b,c,d,e){return function(){k(a,b,c,d,e)}}function k(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var g,k,n,v=c.length;d<v;){var p=c[d++],C=c[d];switch(p){case "&":N.test(C)?(b.e&&b.e("&"+C,f,O,h(b,c,d,e,f)),d++):b.e&&b.e("&",f,O,h(b,c,d,e,f));break;case "</":if(g=/^([-\w:]+)[^\'\"]*/.exec(C))if(g[0].length===
|
||||
C.length&&">"===c[d+1])d+=2,n=g[1].toLowerCase(),b.t&&b.t(n,f,O,h(b,c,d,e,f));else{var Y=c,Q=d,q=b,r=f,X=O,R=e,H=m(Y,Q);H?(q.t&&q.t(H.name,r,X,h(q,Y,Q,R,r)),d=H.next):d=Y.length}else b.e&&b.e("</",f,O,h(b,c,d,e,f));break;case "<":if(g=/^([-\w:]+)\s*\/?/.exec(C))if(g[0].length===C.length&&">"===c[d+1]){d+=2;n=g[1].toLowerCase();b.w&&b.w(n,[],f,O,h(b,c,d,e,f));var t=a.f[n];t&Z&&(d=l(c,{name:n,next:d,c:t},b,f,O,e))}else{var Y=c,Q=b,q=f,r=O,X=e,B=m(Y,d);B?(Q.w&&Q.w(B.name,B.R,q,r,h(Q,Y,B.next,X,q)),
|
||||
d=B.c&Z?l(Y,B,Q,q,r,X):B.next):d=Y.length}else b.e&&b.e("<",f,O,h(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(k=d+1;k<v&&(">"!==c[k]||!/--$/.test(c[k-1]));k++);if(k<v){if(b.A){var u=c.slice(d,k).join("");b.A(u.substr(0,u.length-2),f,O,h(b,c,k+1,e,f))}d=k+1}else e.C=!0}e.C&&b.e&&b.e("<!--",f,O,h(b,c,d,e,f));break;case "<!":if(/^\w/.test(C)){if(!e.r){for(k=d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<!",f,O,h(b,c,d,e,f))}else b.e&&b.e("<!",f,O,h(b,c,d,e,f));break;case "<?":if(!e.r){for(k=
|
||||
d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<?",f,O,h(b,c,d,e,f));break;case ">":b.e&&b.e(">",f,O,h(b,c,d,e,f));break;case "":break;default:b.e&&b.e(p,f,O,h(b,c,d,e,f))}}b.B&&b.B(f)}catch(ha){if(ha!==O)throw ha;}}function l(b,c,d,f,g,k){var l=b.length;Q.hasOwnProperty(c.name)||(Q[c.name]=RegExp("^"+c.name+"(?:[\\s\\/]|$)","i"));for(var m=Q[c.name],n=c.next,v=c.next+1;v<l&&("</"!==b[v-1]||!m.test(b[v]));v++);v<l&&--v;l=b.slice(n,v).join("");if(c.c&a.c.CDATA)d.z&&d.z(l,f,g,h(d,b,
|
||||
v,k,f));else if(c.c&a.c.RCDATA)d.F&&d.F(e(l),f,g,h(d,b,v,k,f));else throw Error("bug");return v}function m(b,d){var e=/^([-\w:]+)/.exec(b[d]),f={};f.name=e[1].toLowerCase();f.c=a.f[f.name];for(var g=b[d].substr(e[0].length),h=d+1,k=b.length;h<k&&">"!==b[h];h++)g+=b[h];if(!(k<=h)){for(var l=[];""!==g;)if(e=P.exec(g))if(e[4]&&!e[5]||e[6]&&!e[7]){for(var e=e[4]||e[6],m=!1,g=[g,b[h++]];h<k;h++){if(m){if(">"===b[h])break}else 0<=b[h].indexOf(e)&&(m=!0);g.push(b[h])}if(k<=h)break;g=g.join("")}else{var m=
|
||||
e[1].toLowerCase(),n;if(e[2]){n=e[3];var v=n.charCodeAt(0);if(34===v||39===v)n=n.substr(1,n.length-2);n=c(n.replace(I,""))}else n="";l.push(m,n);g=g.substr(e[0].length)}else g=g.replace(/^[\s\S][^a-z\s]*/,"");f.R=l;f.next=h+1;return f}}function n(b){function c(a,b){f||b.push(a)}var e,f;return g({startDoc:function(){e=[];f=!1},startTag:function(c,g,h){if(!f&&a.f.hasOwnProperty(c)){var k=a.f[c];if(!(k&a.c.FOLDABLE)){var l=b(c,g);if(l){if("object"!==typeof l)throw Error("tagPolicy did not return object (old API?)");
|
||||
if("attribs"in l)g=l.attribs;else throw Error("tagPolicy gave no attribs");var m;"tagName"in l?(m=l.tagName,l=a.f[m]):(m=c,l=k);if(k&a.c.OPTIONAL_ENDTAG){var n=e[e.length-1];n&&n.D===c&&(n.v!==m||c!==m)&&h.push("</",n.v,">")}k&a.c.EMPTY||e.push({D:c,v:m});h.push("<",m);c=0;for(n=g.length;c<n;c+=2){var v=g[c],C=g[c+1];null!==C&&void 0!==C&&h.push(" ",v,'="',d(C),'"')}h.push(">");k&a.c.EMPTY&&!(l&a.c.EMPTY)&&h.push("</",m,">")}else f=!(k&a.c.EMPTY)}}},endTag:function(b,c){if(f)f=!1;else if(a.f.hasOwnProperty(b)){var d=
|
||||
a.f[b];if(!(d&(a.c.EMPTY|a.c.FOLDABLE))){if(d&a.c.OPTIONAL_ENDTAG)for(d=e.length;0<=--d;){var g=e[d].D;if(g===b)break;if(!(a.f[g]&a.c.OPTIONAL_ENDTAG))return}else for(d=e.length;0<=--d&&e[d].D!==b;);if(!(0>d)){for(g=e.length;--g>d;){var h=e[g].v;a.f[h]&a.c.OPTIONAL_ENDTAG||c.push("</",h,">")}d<e.length&&(b=e[d].v);e.length=d;c.push("</",b,">")}}}},pcdata:c,rcdata:c,cdata:c,endDoc:function(a){for(;e.length;e.length--)a.push("</",e[e.length-1].v,">")}})}function p(a,b,c,d,e){if(!e)return null;try{var g=
|
||||
f.parse(""+a);if(g&&(!g.K()||fa.test(g.W()))){var h=e(g,b,c,d);return h?h.toString():null}}catch(ia){}return null}function r(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function C(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function L(b,c,d,e,f){for(var g=0;g<c.length;g+=2){var h=c[g],k=c[g+1],l=k,m=null,n;if((n=
|
||||
b+"::"+h,a.m.hasOwnProperty(n))||(n="*::"+h,a.m.hasOwnProperty(n)))m=a.m[n];if(null!==m)switch(m){case a.d.NONE:break;case a.d.SCRIPT:k=null;f&&r(f,b,h,l,k);break;case a.d.STYLE:if("undefined"===typeof V){k=null;f&&r(f,b,h,l,k);break}var v=[];V(k,{declaration:function(b,c){var e=b.toLowerCase();S(e,c,d?function(b){return p(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&v.push(e+": "+c.join(" "))}});k=0<v.length?v.join(" ; "):null;f&&r(f,b,h,l,k);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:k=
|
||||
e?e(k):k;f&&r(f,b,h,l,k);break;case a.d.URI:k=p(k,C(a.J,b,h),C(a.I,b,h),{TYPE:"MARKUP",XML_ATTR:h,XML_TAG:b},d);f&&r(f,b,h,l,k);break;case a.d.URI_FRAGMENT:k&&"#"===k.charAt(0)?(k=k.substring(1),k=e?e(k):k,null!==k&&void 0!==k&&(k="#"+k)):k=null;f&&r(f,b,h,l,k);break;default:k=null,f&&r(f,b,h,l,k)}else k=null,f&&r(f,b,h,l,k);c[g+1]=k}return c}function K(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&r(d,e,void 0,void 0,void 0);else return{attribs:L(e,f,b,c,d)}}}function H(a,b){var c=[];n(b)(a,
|
||||
c);return c.join("")}var V,S;"undefined"!==typeof window&&(V=window.parseCssDeclarations,S=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},X=/^#(\d+)$/,v=/^#x([0-9A-Fa-f]+)$/,Q=/^[A-Za-z][A-za-z0-9]+$/,G="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,I=/\0/g,ca=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,M=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,J=/&/g,N=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,T=
|
||||
/[<]/g,ea=/>/g,aa=/\"/g,P=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,W=3==="a,b".split(/(,)/).length,U=a.c.CDATA|a.c.RCDATA,O={},R={},fa=/^(?:https?|mailto|data)$/i,Y={};Y.pa=Y.escapeAttrib=d;Y.ra=Y.makeHtmlSanitizer=n;Y.sa=Y.makeSaxParser=g;Y.ta=Y.makeTagPolicy=K;Y.wa=Y.normalizeRCData=e;Y.xa=Y.sanitize=function(a,b,c,d){return H(a,K(b,c,d))};Y.ya=Y.sanitizeAttribs=L;Y.za=Y.sanitizeWithPolicy=H;Y.Ba=Y.unescapeEntities=c;return Y}(p);c=a.sanitize;"undefined"!==
|
||||
f.parse(""+a);if(g&&(!g.K()||fa.test(g.W()))){var h=e(g,b,c,d);return h?h.toString():null}}catch(na){}return null}function r(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function C(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function L(b,c,d,e,f){for(var g=0;g<c.length;g+=2){var h=c[g],k=c[g+1],l=k,m=null,n;if((n=
|
||||
b+"::"+h,a.m.hasOwnProperty(n))||(n="*::"+h,a.m.hasOwnProperty(n)))m=a.m[n];if(null!==m)switch(m){case a.d.NONE:break;case a.d.SCRIPT:k=null;f&&r(f,b,h,l,k);break;case a.d.STYLE:if("undefined"===typeof V){k=null;f&&r(f,b,h,l,k);break}var v=[];V(k,{declaration:function(b,c){var e=b.toLowerCase();T(e,c,d?function(b){return p(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&v.push(e+": "+c.join(" "))}});k=0<v.length?v.join(" ; "):null;f&&r(f,b,h,l,k);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:k=
|
||||
e?e(k):k;f&&r(f,b,h,l,k);break;case a.d.URI:k=p(k,C(a.J,b,h),C(a.I,b,h),{TYPE:"MARKUP",XML_ATTR:h,XML_TAG:b},d);f&&r(f,b,h,l,k);break;case a.d.URI_FRAGMENT:k&&"#"===k.charAt(0)?(k=k.substring(1),k=e?e(k):k,null!==k&&void 0!==k&&(k="#"+k)):k=null;f&&r(f,b,h,l,k);break;default:k=null,f&&r(f,b,h,l,k)}else k=null,f&&r(f,b,h,l,k);c[g+1]=k}return c}function K(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&r(d,e,void 0,void 0,void 0);else return{attribs:L(e,f,b,c,d)}}}function G(a,b){var c=[];n(b)(a,
|
||||
c);return c.join("")}var V,T;"undefined"!==typeof window&&(V=window.parseCssDeclarations,T=window.sanitizeCssProperty);var ca={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},W=/^#(\d+)$/,v=/^#x([0-9A-Fa-f]+)$/,R=/^[A-Za-z][A-za-z0-9]+$/,H="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,I=/\0/g,da=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,N=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,J=/&/g,M=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,aa=
|
||||
/[<]/g,ea=/>/g,U=/\"/g,P=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,S=3==="a,b".split(/(,)/).length,Z=a.c.CDATA|a.c.RCDATA,O={},Q={},fa=/^(?:https?|mailto|data)$/i,X={};X.pa=X.escapeAttrib=d;X.ra=X.makeHtmlSanitizer=n;X.sa=X.makeSaxParser=g;X.ta=X.makeTagPolicy=K;X.wa=X.normalizeRCData=e;X.xa=X.sanitize=function(a,b,c,d){return G(a,K(b,c,d))};X.ya=X.sanitizeAttribs=L;X.za=X.sanitizeWithPolicy=G;X.Ba=X.unescapeEntities=c;return X}(p);c=a.sanitize;"undefined"!==
|
||||
typeof window&&(window.html=a,window.html_sanitize=c)})();var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(a,b){var c="",d,e,f,g,h,k,l=0;for(null!=b&&b||(a=Base64._utf8_encode(a));l<a.length;)d=a.charCodeAt(l++),e=a.charCodeAt(l++),f=a.charCodeAt(l++),g=d>>2,d=(d&3)<<4|e>>4,h=(e&15)<<2|f>>6,k=f&63,isNaN(e)?h=k=64:isNaN(f)&&(k=64),c=c+this._keyStr.charAt(g)+this._keyStr.charAt(d)+this._keyStr.charAt(h)+this._keyStr.charAt(k);return c},decode:function(a,b){b=null!=b?b:!1;var c="",d,e,f,g,h,k=0;for(a=a.replace(/[^A-Za-z0-9\+\/\=]/g,
|
||||
"");k<a.length;)d=this._keyStr.indexOf(a.charAt(k++)),e=this._keyStr.indexOf(a.charAt(k++)),g=this._keyStr.indexOf(a.charAt(k++)),h=this._keyStr.indexOf(a.charAt(k++)),d=d<<2|e>>4,e=(e&15)<<4|g>>2,f=(g&3)<<6|h,c+=String.fromCharCode(d),64!=g&&(c+=String.fromCharCode(e)),64!=h&&(c+=String.fromCharCode(f));b||(c=Base64._utf8_decode(c));return c},_utf8_encode:function(a){a=a.replace(/\r\n/g,"\n");for(var b="",c=0;c<a.length;c++){var d=a.charCodeAt(c);128>d?b+=String.fromCharCode(d):(127<d&&2048>d?b+=
|
||||
String.fromCharCode(d>>6|192):(b+=String.fromCharCode(d>>12|224),b+=String.fromCharCode(d>>6&63|128)),b+=String.fromCharCode(d&63|128))}return b},_utf8_decode:function(a){var b="",c=0,d;for(c1=c2=0;c<a.length;)d=a.charCodeAt(c),128>d?(b+=String.fromCharCode(d),c++):191<d&&224>d?(c2=a.charCodeAt(c+1),b+=String.fromCharCode((d&31)<<6|c2&63),c+=2):(c2=a.charCodeAt(c+1),c3=a.charCodeAt(c+2),b+=String.fromCharCode((d&15)<<12|(c2&63)<<6|c3&63),c+=3);return b}};!function(a){"object"==typeof exports&&"undefined"!=typeof module?module.exports=a():"function"==typeof define&&define.amd?define([],a):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).pako=a()}(function(){return function b(c,d,e){function f(h,l){if(!d[h]){if(!c[h]){var k="function"==typeof require&&require;if(!l&&k)return k(h,!0);if(g)return g(h,!0);k=Error("Cannot find module '"+h+"'");throw k.code="MODULE_NOT_FOUND",k;}k=d[h]={exports:{}};
|
||||
|
@ -107,76 +107,76 @@ d?(c[h++]=192|d>>>6,c[h++]=128|63&d):65536>d?(c[h++]=224|d>>>12,c[h++]=128|d>>>6
|
|||
2===h?31:3===h?15:7;1<h&&d<l;)g=g<<6|63&b[d++],h--;1<h?m[f++]=65533:65536>g?m[f++]=g:(g-=65536,m[f++]=55296|g>>10&1023,m[f++]=56320|1023&g)}return e(m,f)};d.utf8border=function(b,c){var d;c=c||b.length;c>b.length&&(c=b.length);for(d=c-1;0<=d&&128===(192&b[d]);)d--;return 0>d?c:0===d?c:d+k[b[d]]>c?d:c}},{"./common":3}],5:[function(b,c,d){c.exports=function(b,c,d,h){var e=65535&b|0;b=b>>>16&65535|0;for(var f;0!==d;){f=2E3<d?2E3:d;d-=f;do e=e+c[h++]|0,b=b+e|0;while(--f);e%=65521;b%=65521}return e|b<<
|
||||
16|0}},{}],6:[function(b,c,d){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],7:[function(b,c,d){var e=function(){for(var b,c=[],d=0;256>d;d++){b=d;for(var e=
|
||||
0;8>e;e++)b=1&b?3988292384^b>>>1:b>>>1;c[d]=b}return c}();c.exports=function(b,c,d,k){d=k+d;for(b^=-1;k<d;k++)b=b>>>8^e[255&(b^c[k])];return b^-1}},{}],8:[function(b,c,d){function e(b,c){return b.msg=B[c],c}function f(b){for(var c=b.length;0<=--c;)b[c]=0}function g(b){var c=b.state,d=c.pending;d>b.avail_out&&(d=b.avail_out);0!==d&&(u.arraySet(b.output,c.pending_buf,c.pending_out,d,b.next_out),b.next_out+=d,c.pending_out+=d,b.total_out+=d,b.avail_out-=d,c.pending-=d,0===c.pending&&(c.pending_out=0))}
|
||||
function h(b,c){D._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function k(b,c){b.pending_buf[b.pending++]=c}function l(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function m(b,c){var d,e,f=b.max_chain_length,g=b.strstart,h=b.prev_length,k=b.nice_match,l=b.strstart>b.w_size-T?b.strstart-(b.w_size-T):0,m=b.window,v=b.w_mask,n=b.prev,C=b.strstart+N,p=m[g+h-1],q=m[g+h];b.prev_length>=b.good_match&&(f>>=
|
||||
2);k>b.lookahead&&(k=b.lookahead);do if(d=c,m[d+h]===q&&m[d+h-1]===p&&m[d]===m[g]&&m[++d]===m[g+1]){g+=2;for(d++;m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&g<C;);if(e=N-(C-g),g=C-N,e>h){if(b.match_start=c,h=e,e>=k)break;p=m[g+h-1];q=m[g+h]}}while((c=n[c&v])>l&&0!==--f);return h<=b.lookahead?h:b.lookahead}function n(b){var c,d,e,f,g=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=g+(g-T)){u.arraySet(b.window,
|
||||
function h(b,c){D._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function k(b,c){b.pending_buf[b.pending++]=c}function l(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function m(b,c){var d,e,f=b.max_chain_length,g=b.strstart,h=b.prev_length,k=b.nice_match,l=b.strstart>b.w_size-aa?b.strstart-(b.w_size-aa):0,m=b.window,v=b.w_mask,n=b.prev,C=b.strstart+M,p=m[g+h-1],q=m[g+h];b.prev_length>=b.good_match&&(f>>=
|
||||
2);k>b.lookahead&&(k=b.lookahead);do if(d=c,m[d+h]===q&&m[d+h-1]===p&&m[d]===m[g]&&m[++d]===m[g+1]){g+=2;for(d++;m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&g<C;);if(e=M-(C-g),g=C-M,e>h){if(b.match_start=c,h=e,e>=k)break;p=m[g+h-1];q=m[g+h]}}while((c=n[c&v])>l&&0!==--f);return h<=b.lookahead?h:b.lookahead}function n(b){var c,d,e,f,g=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=g+(g-aa)){u.arraySet(b.window,
|
||||
b.window,g,g,0);b.match_start-=g;b.strstart-=g;b.block_start-=g;c=d=b.hash_size;do e=b.head[--c],b.head[c]=e>=g?e-g:0;while(--d);c=d=g;do e=b.prev[--c],b.prev[c]=e>=g?e-g:0;while(--d);f+=g}if(0===b.strm.avail_in)break;c=b.strm;e=b.window;var h=b.strstart+b.lookahead,k=c.avail_in;if(d=(k>f&&(k=f),0===k?0:(c.avail_in-=k,u.arraySet(e,c.input,c.next_in,k,h),1===c.state.wrap?c.adler=F(c.adler,e,k,h):2===c.state.wrap&&(c.adler=E(c.adler,e,k,h)),c.next_in+=k,c.total_in+=k,k)),b.lookahead+=d,b.lookahead+
|
||||
b.insert>=J)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+J-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<J)););}while(b.lookahead<T&&0!==b.strm.avail_in)}function p(b,c){for(var d,e;;){if(b.lookahead<T){if(n(b),b.lookahead<T&&c===A)return P;if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
|
||||
J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-T&&(b.match_length=m(b,d)),b.match_length>=J)if(e=D._tr_tally(b,b.strstart-b.match_start,b.match_length-J),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=J){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
|
||||
b.strstart++}else b.strstart+=b.match_length,b.match_length=0,b.ins_h=b.window[b.strstart],b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+1])&b.hash_mask;else e=D._tr_tally(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++;if(e&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?U:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:W}function r(b,c){for(var d,e,f;;){if(b.lookahead<T){if(n(b),b.lookahead<T&&c===A)return P;if(0===
|
||||
b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),b.prev_length=b.match_length,b.prev_match=b.match_start,b.match_length=J-1,0!==d&&b.prev_length<b.max_lazy_match&&b.strstart-d<=b.w_size-T&&(b.match_length=m(b,d),5>=b.match_length&&(b.strategy===V||b.match_length===J&&4096<b.strstart-b.match_start)&&(b.match_length=J-1)),b.prev_length>=J&&b.match_length<=b.prev_length){f=
|
||||
b.insert>=J)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+J-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<J)););}while(b.lookahead<aa&&0!==b.strm.avail_in)}function p(b,c){for(var d,e;;){if(b.lookahead<aa){if(n(b),b.lookahead<aa&&c===A)return P;if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
|
||||
J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-aa&&(b.match_length=m(b,d)),b.match_length>=J)if(e=D._tr_tally(b,b.strstart-b.match_start,b.match_length-J),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=J){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
|
||||
b.strstart++}else b.strstart+=b.match_length,b.match_length=0,b.ins_h=b.window[b.strstart],b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+1])&b.hash_mask;else e=D._tr_tally(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++;if(e&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:S}function r(b,c){for(var d,e,f;;){if(b.lookahead<aa){if(n(b),b.lookahead<aa&&c===A)return P;
|
||||
if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),b.prev_length=b.match_length,b.prev_match=b.match_start,b.match_length=J-1,0!==d&&b.prev_length<b.max_lazy_match&&b.strstart-d<=b.w_size-aa&&(b.match_length=m(b,d),5>=b.match_length&&(b.strategy===V||b.match_length===J&&4096<b.strstart-b.match_start)&&(b.match_length=J-1)),b.prev_length>=J&&b.match_length<=b.prev_length){f=
|
||||
b.strstart+b.lookahead-J;e=D._tr_tally(b,b.strstart-1-b.prev_match,b.prev_length-J);b.lookahead-=b.prev_length-1;b.prev_length-=2;do++b.strstart<=f&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart);while(0!==--b.prev_length);if(b.match_available=0,b.match_length=J-1,b.strstart++,e&&(h(b,!1),0===b.strm.avail_out))return P}else if(b.match_available){if(e=D._tr_tally(b,0,b.window[b.strstart-1]),e&&h(b,!1),
|
||||
b.strstart++,b.lookahead--,0===b.strm.avail_out)return P}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(D._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?U:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:W}function q(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function t(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
|
||||
this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=X;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
|
||||
this.ins_h=0;this.dyn_ltree=new u.Buf16(2*ca);this.dyn_dtree=new u.Buf16(2*(2*G+1));this.bl_tree=new u.Buf16(2*(2*I+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new u.Buf16(M+1);this.heap=new u.Buf16(2*Q+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new u.Buf16(2*Q+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function z(b){var c;
|
||||
return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ea:aa,b.adler=2===c.wrap?0:1,c.last_flush=A,D._tr_init(c),L):e(b,K)}function w(b){var c=z(b);c===L&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=y[b.level].max_lazy,b.good_match=y[b.level].good_length,b.nice_match=y[b.level].nice_length,b.max_chain_length=y[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
|
||||
b.prev_length=J-1,b.match_available=0,b.ins_h=0);return c}function x(b,c,d,f,g,h){if(!b)return K;var k=1;if(c===H&&(c=6),0>f?(k=0,f=-f):15<f&&(k=2,f-=16),1>g||g>v||d!==X||8>f||15<f||0>c||9<c||0>h||h>S)return e(b,K);8===f&&(f=9);var l=new t;return b.state=l,l.strm=b,l.wrap=k,l.gzhead=null,l.w_bits=f,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=g+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+J-1)/J),l.window=new u.Buf8(2*l.w_size),l.head=new u.Buf16(l.hash_size),
|
||||
l.prev=new u.Buf16(l.w_size),l.lit_bufsize=1<<g+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new u.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=c,l.strategy=h,l.method=d,w(b)}var y,u=b("../utils/common"),D=b("./trees"),F=b("./adler32"),E=b("./crc32"),B=b("./messages"),A=0,C=4,L=0,K=-2,H=-1,V=1,S=4,ba=2,X=8,v=9,Q=286,G=30,I=19,ca=2*Q+1,M=15,J=3,N=258,T=N+J+1,ea=42,aa=113,P=1,W=2,U=3,O=4;y=[new q(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
|
||||
(d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(n(b),0===b.lookahead&&c===A)return P;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,h(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-T&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=0,c===C?(h(b,!0),0===b.strm.avail_out?U:O):(b.strstart>b.block_start&&h(b,!1),P)}),new q(4,4,8,4,p),new q(4,5,16,8,p),new q(4,6,32,
|
||||
32,p),new q(4,4,16,16,r),new q(8,16,32,32,r),new q(8,16,128,128,r),new q(8,32,128,256,r),new q(32,128,258,1024,r),new q(32,258,258,4096,r)];d.deflateInit=function(b,c){return x(b,c,X,15,8,0)};d.deflateInit2=x;d.deflateReset=w;d.deflateResetKeep=z;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?K:(b.state.gzhead=c,L):K};d.deflate=function(b,c){var d,m,v,p;if(!b||!b.state||5<c||0>c)return b?e(b,K):K;if(m=b.state,!b.output||!b.input&&0!==b.avail_in||666===m.status&&c!==C)return e(b,
|
||||
b.strstart++,b.lookahead--,0===b.strm.avail_out)return P}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(D._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:S}function q(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function t(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
|
||||
this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=W;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
|
||||
this.ins_h=0;this.dyn_ltree=new u.Buf16(2*da);this.dyn_dtree=new u.Buf16(2*(2*H+1));this.bl_tree=new u.Buf16(2*(2*I+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new u.Buf16(N+1);this.heap=new u.Buf16(2*R+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new u.Buf16(2*R+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function z(b){var c;
|
||||
return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ca,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ea:U,b.adler=2===c.wrap?0:1,c.last_flush=A,D._tr_init(c),L):e(b,K)}function w(b){var c=z(b);c===L&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=y[b.level].max_lazy,b.good_match=y[b.level].good_length,b.nice_match=y[b.level].nice_length,b.max_chain_length=y[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
|
||||
b.prev_length=J-1,b.match_available=0,b.ins_h=0);return c}function x(b,c,d,f,g,h){if(!b)return K;var k=1;if(c===G&&(c=6),0>f?(k=0,f=-f):15<f&&(k=2,f-=16),1>g||g>v||d!==W||8>f||15<f||0>c||9<c||0>h||h>T)return e(b,K);8===f&&(f=9);var l=new t;return b.state=l,l.strm=b,l.wrap=k,l.gzhead=null,l.w_bits=f,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=g+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+J-1)/J),l.window=new u.Buf8(2*l.w_size),l.head=new u.Buf16(l.hash_size),
|
||||
l.prev=new u.Buf16(l.w_size),l.lit_bufsize=1<<g+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new u.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=c,l.strategy=h,l.method=d,w(b)}var y,u=b("../utils/common"),D=b("./trees"),F=b("./adler32"),E=b("./crc32"),B=b("./messages"),A=0,C=4,L=0,K=-2,G=-1,V=1,T=4,ca=2,W=8,v=9,R=286,H=30,I=19,da=2*R+1,N=15,J=3,M=258,aa=M+J+1,ea=42,U=113,P=1,S=2,Z=3,O=4;y=[new q(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
|
||||
(d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(n(b),0===b.lookahead&&c===A)return P;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,h(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-aa&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=0,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):(b.strstart>b.block_start&&h(b,!1),P)}),new q(4,4,8,4,p),new q(4,5,16,8,p),new q(4,6,
|
||||
32,32,p),new q(4,4,16,16,r),new q(8,16,32,32,r),new q(8,16,128,128,r),new q(8,32,128,256,r),new q(32,128,258,1024,r),new q(32,258,258,4096,r)];d.deflateInit=function(b,c){return x(b,c,W,15,8,0)};d.deflateInit2=x;d.deflateReset=w;d.deflateResetKeep=z;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?K:(b.state.gzhead=c,L):K};d.deflate=function(b,c){var d,m,v,p;if(!b||!b.state||5<c||0>c)return b?e(b,K):K;if(m=b.state,!b.output||!b.input&&0!==b.avail_in||666===m.status&&c!==C)return e(b,
|
||||
0===b.avail_out?-5:K);if(m.strm=b,d=m.last_flush,m.last_flush=c,m.status===ea)2===m.wrap?(b.adler=0,k(m,31),k(m,139),k(m,8),m.gzhead?(k(m,(m.gzhead.text?1:0)+(m.gzhead.hcrc?2:0)+(m.gzhead.extra?4:0)+(m.gzhead.name?8:0)+(m.gzhead.comment?16:0)),k(m,255&m.gzhead.time),k(m,m.gzhead.time>>8&255),k(m,m.gzhead.time>>16&255),k(m,m.gzhead.time>>24&255),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,255&m.gzhead.os),m.gzhead.extra&&m.gzhead.extra.length&&(k(m,255&m.gzhead.extra.length),k(m,m.gzhead.extra.length>>
|
||||
8&255)),m.gzhead.hcrc&&(b.adler=E(b.adler,m.pending_buf,m.pending,0)),m.gzindex=0,m.status=69):(k(m,0),k(m,0),k(m,0),k(m,0),k(m,0),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,3),m.status=aa)):(v=X+(m.w_bits-8<<4)<<8,v|=(2<=m.strategy||2>m.level?0:6>m.level?1:6===m.level?2:3)<<6,0!==m.strstart&&(v|=32),m.status=aa,l(m,v+(31-v%31)),0!==m.strstart&&(l(m,b.adler>>>16),l(m,65535&b.adler)),b.adler=1);if(69===m.status)if(m.gzhead.extra){for(v=m.pending;m.gzindex<(65535&m.gzhead.extra.length)&&(m.pending!==
|
||||
8&255)),m.gzhead.hcrc&&(b.adler=E(b.adler,m.pending_buf,m.pending,0)),m.gzindex=0,m.status=69):(k(m,0),k(m,0),k(m,0),k(m,0),k(m,0),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,3),m.status=U)):(v=W+(m.w_bits-8<<4)<<8,v|=(2<=m.strategy||2>m.level?0:6>m.level?1:6===m.level?2:3)<<6,0!==m.strstart&&(v|=32),m.status=U,l(m,v+(31-v%31)),0!==m.strstart&&(l(m,b.adler>>>16),l(m,65535&b.adler)),b.adler=1);if(69===m.status)if(m.gzhead.extra){for(v=m.pending;m.gzindex<(65535&m.gzhead.extra.length)&&(m.pending!==
|
||||
m.pending_buf_size||(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v)),g(b),v=m.pending,m.pending!==m.pending_buf_size));)k(m,255&m.gzhead.extra[m.gzindex]),m.gzindex++;m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));m.gzindex===m.gzhead.extra.length&&(m.gzindex=0,m.status=73)}else m.status=73;if(73===m.status)if(m.gzhead.name){v=m.pending;do{if(m.pending===m.pending_buf_size&&(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-
|
||||
v,v)),g(b),v=m.pending,m.pending===m.pending_buf_size)){p=1;break}p=m.gzindex<m.gzhead.name.length?255&m.gzhead.name.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.gzindex=0,m.status=91)}else m.status=91;if(91===m.status)if(m.gzhead.comment){v=m.pending;do{if(m.pending===m.pending_buf_size&&(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v)),g(b),v=m.pending,m.pending===m.pending_buf_size)){p=
|
||||
1;break}p=m.gzindex<m.gzhead.comment.length?255&m.gzhead.comment.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.status=103)}else m.status=103;if(103===m.status&&(m.gzhead.hcrc?(m.pending+2>m.pending_buf_size&&g(b),m.pending+2<=m.pending_buf_size&&(k(m,255&b.adler),k(m,b.adler>>8&255),b.adler=0,m.status=aa)):m.status=aa),0!==m.pending){if(g(b),0===b.avail_out)return m.last_flush=-1,L}else if(0===b.avail_in&&(c<<1)-
|
||||
(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==C)return e(b,-5);if(666===m.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==m.lookahead||c!==A&&666!==m.status){var q;if(2===m.strategy)a:{for(var r;;){if(0===m.lookahead&&(n(m),0===m.lookahead)){if(c===A){q=P;break a}break}if(m.match_length=0,r=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++,r&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?U:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?
|
||||
P:W)}else if(3===m.strategy)a:{var Q,G;for(r=m.window;;){if(m.lookahead<=N){if(n(m),m.lookahead<=N&&c===A){q=P;break a}if(0===m.lookahead)break}if(m.match_length=0,m.lookahead>=J&&0<m.strstart&&(G=m.strstart-1,Q=r[G],Q===r[++G]&&Q===r[++G]&&Q===r[++G])){for(d=m.strstart+N;Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&G<d;);m.match_length=N-(d-G);m.match_length>m.lookahead&&(m.match_length=m.lookahead)}if(m.match_length>=J?(q=D._tr_tally(m,1,m.match_length-
|
||||
J),m.lookahead-=m.match_length,m.strstart+=m.match_length,m.match_length=0):(q=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++),q&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?U:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?P:W)}else q=y[m.level].func(m,c);if(q!==U&&q!==O||(m.status=666),q===P||q===U)return 0===b.avail_out&&(m.last_flush=-1),L;if(q===W&&(1===c?D._tr_align(m):5!==c&&(D._tr_stored_block(m,0,0,!1),3===c&&(f(m.head),0===
|
||||
1;break}p=m.gzindex<m.gzhead.comment.length?255&m.gzhead.comment.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.status=103)}else m.status=103;if(103===m.status&&(m.gzhead.hcrc?(m.pending+2>m.pending_buf_size&&g(b),m.pending+2<=m.pending_buf_size&&(k(m,255&b.adler),k(m,b.adler>>8&255),b.adler=0,m.status=U)):m.status=U),0!==m.pending){if(g(b),0===b.avail_out)return m.last_flush=-1,L}else if(0===b.avail_in&&(c<<1)-
|
||||
(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==C)return e(b,-5);if(666===m.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==m.lookahead||c!==A&&666!==m.status){var q;if(2===m.strategy)a:{for(var r;;){if(0===m.lookahead&&(n(m),0===m.lookahead)){if(c===A){q=P;break a}break}if(m.match_length=0,r=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++,r&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?Z:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?
|
||||
P:S)}else if(3===m.strategy)a:{var H,R;for(r=m.window;;){if(m.lookahead<=M){if(n(m),m.lookahead<=M&&c===A){q=P;break a}if(0===m.lookahead)break}if(m.match_length=0,m.lookahead>=J&&0<m.strstart&&(R=m.strstart-1,H=r[R],H===r[++R]&&H===r[++R]&&H===r[++R])){for(d=m.strstart+M;H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&R<d;);m.match_length=M-(d-R);m.match_length>m.lookahead&&(m.match_length=m.lookahead)}if(m.match_length>=J?(q=D._tr_tally(m,1,m.match_length-
|
||||
J),m.lookahead-=m.match_length,m.strstart+=m.match_length,m.match_length=0):(q=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++),q&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?Z:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?P:S)}else q=y[m.level].func(m,c);if(q!==Z&&q!==O||(m.status=666),q===P||q===Z)return 0===b.avail_out&&(m.last_flush=-1),L;if(q===S&&(1===c?D._tr_align(m):5!==c&&(D._tr_stored_block(m,0,0,!1),3===c&&(f(m.head),0===
|
||||
m.lookahead&&(m.strstart=0,m.block_start=0,m.insert=0))),g(b),0===b.avail_out))return m.last_flush=-1,L}return c!==C?L:0>=m.wrap?1:(2===m.wrap?(k(m,255&b.adler),k(m,b.adler>>8&255),k(m,b.adler>>16&255),k(m,b.adler>>24&255),k(m,255&b.total_in),k(m,b.total_in>>8&255),k(m,b.total_in>>16&255),k(m,b.total_in>>24&255)):(l(m,b.adler>>>16),l(m,65535&b.adler)),g(b),0<m.wrap&&(m.wrap=-m.wrap),0!==m.pending?L:1)};d.deflateEnd=function(b){var c;return b&&b.state?(c=b.state.status,c!==ea&&69!==c&&73!==c&&91!==
|
||||
c&&103!==c&&c!==aa&&666!==c?e(b,K):(b.state=null,c===aa?e(b,-3):L)):K};d.deflateSetDictionary=function(b,c){var d,e,g,h,k,m,l;e=c.length;if(!b||!b.state||(d=b.state,h=d.wrap,2===h||1===h&&d.status!==ea||d.lookahead))return K;1===h&&(b.adler=F(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===h&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),k=new u.Buf8(d.w_size),u.arraySet(k,c,e-d.w_size,d.w_size,0),c=k,e=d.w_size);k=b.avail_in;m=b.next_in;l=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(n(d);d.lookahead>=
|
||||
c&&103!==c&&c!==U&&666!==c?e(b,K):(b.state=null,c===U?e(b,-3):L)):K};d.deflateSetDictionary=function(b,c){var d,e,g,h,k,m,l;e=c.length;if(!b||!b.state||(d=b.state,h=d.wrap,2===h||1===h&&d.status!==ea||d.lookahead))return K;1===h&&(b.adler=F(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===h&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),k=new u.Buf8(d.w_size),u.arraySet(k,c,e-d.w_size,d.w_size,0),c=k,e=d.w_size);k=b.avail_in;m=b.next_in;l=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(n(d);d.lookahead>=
|
||||
J;){e=d.strstart;g=d.lookahead-(J-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[e+J-1])&d.hash_mask,d.prev[e&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=e,e++;while(--g);d.strstart=e;d.lookahead=J-1;n(d)}return d.strstart+=d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=J-1,d.match_available=0,b.next_in=m,b.input=l,b.avail_in=k,d.wrap=h,L};d.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":3,"./adler32":5,"./crc32":7,"./messages":13,
|
||||
"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,l,m,n,p,r,q,t,z,w,x,y,u,D,F,E,B,A,C,L,K,H;d=b.state;e=b.next_in;K=b.input;f=e+(b.avail_in-5);l=b.next_out;H=b.output;m=l-(c-b.avail_out);n=l+(b.avail_out-257);p=d.dmax;r=d.wsize;q=d.whave;t=d.wnext;z=d.window;w=d.hold;x=d.bits;y=d.lencode;u=d.distcode;D=(1<<d.lenbits)-
|
||||
1;F=(1<<d.distbits)-1;a:do b:for(15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8),E=y[w&D];;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,0===B)H[l++]=65535&E;else{if(!(16&B)){if(0===(64&B)){E=y[(65535&E)+(w&(1<<B)-1)];continue b}if(32&B){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}A=65535&E;(B&=15)&&(x<B&&(w+=K[e++]<<x,x+=8),A+=w&(1<<B)-1,w>>>=B,x-=B);15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8);E=u[w&F];c:for(;;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,!(16&B)){if(0===(64&B)){E=u[(65535&
|
||||
E)+(w&(1<<B)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(C=65535&E,B&=15,x<B&&(w+=K[e++]<<x,x+=8,x<B&&(w+=K[e++]<<x,x+=8)),C+=w&(1<<B)-1,C>p){b.msg="invalid distance too far back";d.mode=30;break a}if(w>>>=B,x-=B,B=l-m,C>B){if(B=C-B,B>q&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(E=0,L=z,0===t){if(E+=r-B,B<A){A-=B;do H[l++]=z[E++];while(--B);E=l-C;L=H}}else if(t<B){if(E+=r+t-B,B-=t,B<A){A-=B;do H[l++]=z[E++];while(--B);if(E=0,t<A){B=t;A-=B;do H[l++]=z[E++];
|
||||
while(--B);E=l-C;L=H}}}else if(E+=t-B,B<A){A-=B;do H[l++]=z[E++];while(--B);E=l-C;L=H}for(;2<A;)H[l++]=L[E++],H[l++]=L[E++],H[l++]=L[E++],A-=3;A&&(H[l++]=L[E++],1<A&&(H[l++]=L[E++]))}else{E=l-C;do H[l++]=H[E++],H[l++]=H[E++],H[l++]=H[E++],A-=3;while(2<A);A&&(H[l++]=H[E++],1<A&&(H[l++]=H[E++]))}break}}break}while(e<f&&l<n);A=x>>3;e-=A;x-=A<<3;b.next_in=e;b.next_out=l;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=l<n?257+(n-l):257-(l-n);d.hold=w&(1<<x)-1;d.bits=x}},{}],11:[function(b,c,d){function e(b){return(b>>>
|
||||
"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,l,m,n,p,r,q,t,z,w,x,y,u,D,F,E,B,A,C,L,K,G;d=b.state;e=b.next_in;K=b.input;f=e+(b.avail_in-5);l=b.next_out;G=b.output;m=l-(c-b.avail_out);n=l+(b.avail_out-257);p=d.dmax;r=d.wsize;q=d.whave;t=d.wnext;z=d.window;w=d.hold;x=d.bits;y=d.lencode;u=d.distcode;D=(1<<d.lenbits)-
|
||||
1;F=(1<<d.distbits)-1;a:do b:for(15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8),E=y[w&D];;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,0===B)G[l++]=65535&E;else{if(!(16&B)){if(0===(64&B)){E=y[(65535&E)+(w&(1<<B)-1)];continue b}if(32&B){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}A=65535&E;(B&=15)&&(x<B&&(w+=K[e++]<<x,x+=8),A+=w&(1<<B)-1,w>>>=B,x-=B);15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8);E=u[w&F];c:for(;;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,!(16&B)){if(0===(64&B)){E=u[(65535&
|
||||
E)+(w&(1<<B)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(C=65535&E,B&=15,x<B&&(w+=K[e++]<<x,x+=8,x<B&&(w+=K[e++]<<x,x+=8)),C+=w&(1<<B)-1,C>p){b.msg="invalid distance too far back";d.mode=30;break a}if(w>>>=B,x-=B,B=l-m,C>B){if(B=C-B,B>q&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(E=0,L=z,0===t){if(E+=r-B,B<A){A-=B;do G[l++]=z[E++];while(--B);E=l-C;L=G}}else if(t<B){if(E+=r+t-B,B-=t,B<A){A-=B;do G[l++]=z[E++];while(--B);if(E=0,t<A){B=t;A-=B;do G[l++]=z[E++];
|
||||
while(--B);E=l-C;L=G}}}else if(E+=t-B,B<A){A-=B;do G[l++]=z[E++];while(--B);E=l-C;L=G}for(;2<A;)G[l++]=L[E++],G[l++]=L[E++],G[l++]=L[E++],A-=3;A&&(G[l++]=L[E++],1<A&&(G[l++]=L[E++]))}else{E=l-C;do G[l++]=G[E++],G[l++]=G[E++],G[l++]=G[E++],A-=3;while(2<A);A&&(G[l++]=G[E++],1<A&&(G[l++]=G[E++]))}break}}break}while(e<f&&l<n);A=x>>3;e-=A;x-=A<<3;b.next_in=e;b.next_out=l;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=l<n?257+(n-l):257-(l-n);d.hold=w&(1<<x)-1;d.bits=x}},{}],11:[function(b,c,d){function e(b){return(b>>>
|
||||
24&255)+(b>>>8&65280)+((65280&b)<<8)+((255&b)<<24)}function f(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new r.Buf16(320);this.work=new r.Buf16(288);this.distdyn=this.lendyn=null;this.was=
|
||||
this.back=this.sane=0}function g(b){var c;return b&&b.state?(c=b.state,b.total_in=b.total_out=c.total=0,b.msg="",c.wrap&&(b.adler=1&c.wrap),c.mode=u,c.last=0,c.havedict=0,c.dmax=32768,c.head=null,c.hold=0,c.bits=0,c.lencode=c.lendyn=new r.Buf32(D),c.distcode=c.distdyn=new r.Buf32(F),c.sane=1,c.back=-1,x):y}function h(b){var c;return b&&b.state?(c=b.state,c.wsize=0,c.whave=0,c.wnext=0,g(b)):y}function k(b,c){var d,e;return b&&b.state?(e=b.state,0>c?(d=0,c=-c):(d=(c>>4)+1,48>c&&(c&=15)),c&&(8>c||15<
|
||||
c)?y:(null!==e.window&&e.wbits!==c&&(e.window=null),e.wrap=d,e.wbits=c,h(b))):y}function l(b,c){var d,e;return b?(e=new f,b.state=e,e.window=null,d=k(b,c),d!==x&&(b.state=null),d):y}function m(b,c,d,e){var f;b=b.state;return null===b.window&&(b.wsize=1<<b.wbits,b.wnext=0,b.whave=0,b.window=new r.Buf8(b.wsize)),e>=b.wsize?(r.arraySet(b.window,c,d-b.wsize,b.wsize,0),b.wnext=0,b.whave=b.wsize):(f=b.wsize-b.wnext,f>e&&(f=e),r.arraySet(b.window,c,d-e,f,b.wnext),e-=f,e?(r.arraySet(b.window,c,d-e,e,0),b.wnext=
|
||||
e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var n,p,r=b("../utils/common"),q=b("./adler32"),t=b("./crc32"),z=b("./inffast"),w=b("./inftrees"),x=0,y=-2,u=1,D=852,F=592,E=!0;d.inflateReset=h;d.inflateReset2=k;d.inflateResetKeep=g;d.inflateInit=function(b){return l(b,15)};d.inflateInit2=l;d.inflate=function(b,c){var d,f,g,h,k,l,B,A,v,Q,G,I,ca,M,J,N,D,F,aa,P,W,U,O=0,R=new r.Buf8(4),fa=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
|
||||
!b.output||!b.input&&0!==b.avail_in)return y;d=b.state;12===d.mode&&(d.mode=13);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;Q=l;G=B;W=x;a:for(;;)switch(d.mode){case u:if(0===d.wrap){d.mode=13;break}for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(2&d.wrap&&35615===A){d.check=0;R[0]=255&A;R[1]=A>>>8&255;d.check=t(d.check,R,2,0);v=A=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&A)<<8)+(A>>8))%31){b.msg="incorrect header check";
|
||||
e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var n,p,r=b("../utils/common"),q=b("./adler32"),t=b("./crc32"),z=b("./inffast"),w=b("./inftrees"),x=0,y=-2,u=1,D=852,F=592,E=!0;d.inflateReset=h;d.inflateReset2=k;d.inflateResetKeep=g;d.inflateInit=function(b){return l(b,15)};d.inflateInit2=l;d.inflate=function(b,c){var d,f,g,h,k,l,B,A,v,R,H,I,da,N,J,M,D,F,U,P,S,Z,O=0,Q=new r.Buf8(4),fa=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
|
||||
!b.output||!b.input&&0!==b.avail_in)return y;d=b.state;12===d.mode&&(d.mode=13);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;R=l;H=B;S=x;a:for(;;)switch(d.mode){case u:if(0===d.wrap){d.mode=13;break}for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(2&d.wrap&&35615===A){d.check=0;Q[0]=255&A;Q[1]=A>>>8&255;d.check=t(d.check,Q,2,0);v=A=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&A)<<8)+(A>>8))%31){b.msg="incorrect header check";
|
||||
d.mode=30;break}if(8!==(15&A)){b.msg="unknown compression method";d.mode=30;break}if(A>>>=4,v-=4,P=(15&A)+8,0===d.wbits)d.wbits=P;else if(P>d.wbits){b.msg="invalid window size";d.mode=30;break}d.dmax=1<<P;b.adler=d.check=1;d.mode=512&A?10:12;v=A=0;break;case 2:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(d.flags=A,8!==(255&d.flags)){b.msg="unknown compression method";d.mode=30;break}if(57344&d.flags){b.msg="unknown header flags set";d.mode=30;break}d.head&&(d.head.text=A>>8&1);512&d.flags&&
|
||||
(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0;d.mode=3;case 3:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.time=A);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,R[2]=A>>>16&255,R[3]=A>>>24&255,d.check=t(d.check,R,4,0));v=A=0;d.mode=4;case 4:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.xflags=255&A,d.head.os=A>>8);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0;d.mode=5;case 5:if(1024&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}d.length=A;d.head&&(d.head.extra_len=A);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(I=d.length,I>l&&(I=l),I&&(d.head&&(P=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),r.arraySet(d.head.extra,f,h,I,P)),512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,d.length-=I),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===l)break a;I=0;do P=f[h+
|
||||
(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0;d.mode=3;case 3:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.time=A);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,Q[2]=A>>>16&255,Q[3]=A>>>24&255,d.check=t(d.check,Q,4,0));v=A=0;d.mode=4;case 4:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.xflags=255&A,d.head.os=A>>8);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0;d.mode=5;case 5:if(1024&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}d.length=A;d.head&&(d.head.extra_len=A);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(I=d.length,I>l&&(I=l),I&&(d.head&&(P=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),r.arraySet(d.head.extra,f,h,I,P)),512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,d.length-=I),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===l)break a;I=0;do P=f[h+
|
||||
I++],d.head&&P&&65536>d.length&&(d.head.name+=String.fromCharCode(P));while(P&&I<l);if(512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,P)break a}else d.head&&(d.head.name=null);d.length=0;d.mode=8;case 8:if(4096&d.flags){if(0===l)break a;I=0;do P=f[h+I++],d.head&&P&&65536>d.length&&(d.head.comment+=String.fromCharCode(P));while(P&&I<l);if(512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,P)break a}else d.head&&(d.head.comment=null);d.mode=9;case 9:if(512&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}if(A!==(65535&d.check)){b.msg="header crc mismatch";d.mode=30;break}v=A=0}d.head&&(d.head.hcrc=d.flags>>9&1,d.head.done=!0);b.adler=d.check=0;d.mode=12;break;case 10:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}b.adler=d.check=e(A);v=A=0;d.mode=11;case 11:if(0===d.havedict)return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,2;b.adler=d.check=1;d.mode=12;case 12:if(5===c||6===c)break a;case 13:if(d.last){A>>>=7&v;v-=7&v;d.mode=27;break}for(;3>v;){if(0===
|
||||
l)break a;l--;A+=f[h++]<<v;v+=8}switch(d.last=1&A,A>>>=1,--v,3&A){case 0:d.mode=14;break;case 1:N=d;if(E){n=new r.Buf32(512);p=new r.Buf32(32);for(M=0;144>M;)N.lens[M++]=8;for(;256>M;)N.lens[M++]=9;for(;280>M;)N.lens[M++]=7;for(;288>M;)N.lens[M++]=8;w(1,N.lens,0,288,n,0,N.work,{bits:9});for(M=0;32>M;)N.lens[M++]=5;w(2,N.lens,0,32,p,0,N.work,{bits:5});E=!1}N.lencode=n;N.lenbits=9;N.distcode=p;N.distbits=5;if(d.mode=20,6===c){A>>>=2;v-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
|
||||
l)break a;l--;A+=f[h++]<<v;v+=8}switch(d.last=1&A,A>>>=1,--v,3&A){case 0:d.mode=14;break;case 1:M=d;if(E){n=new r.Buf32(512);p=new r.Buf32(32);for(N=0;144>N;)M.lens[N++]=8;for(;256>N;)M.lens[N++]=9;for(;280>N;)M.lens[N++]=7;for(;288>N;)M.lens[N++]=8;w(1,M.lens,0,288,n,0,M.work,{bits:9});for(N=0;32>N;)M.lens[N++]=5;w(2,M.lens,0,32,p,0,M.work,{bits:5});E=!1}M.lencode=n;M.lenbits=9;M.distcode=p;M.distbits=5;if(d.mode=20,6===c){A>>>=2;v-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
|
||||
d.mode=30}A>>>=2;v-=2;break;case 14:A>>>=7&v;for(v-=7&v;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if((65535&A)!==(A>>>16^65535)){b.msg="invalid stored block lengths";d.mode=30;break}if(d.length=65535&A,A=0,v=0,d.mode=15,6===c)break a;case 15:d.mode=16;case 16:if(I=d.length){if(I>l&&(I=l),I>B&&(I=B),0===I)break a;r.arraySet(g,f,h,I,k);l-=I;h+=I;B-=I;k+=I;d.length-=I;break}d.mode=12;break;case 17:for(;14>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(d.nlen=(31&A)+257,A>>>=5,v-=5,d.ndist=(31&A)+
|
||||
1,A>>>=5,v-=5,d.ncode=(15&A)+4,A>>>=4,v-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.lens[fa[d.have++]]=7&A;A>>>=3;v-=3}for(;19>d.have;)d.lens[fa[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,U={bits:d.lenbits},W=w(0,d.lens,0,19,d.lencode,0,d.work,U),d.lenbits=U.bits,W){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
|
||||
d.nlen+d.ndist;){for(;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(16>N)A>>>=J,v-=J,d.lens[d.have++]=N;else{if(16===N){for(M=J+2;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A>>>=J,v-=J,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}P=d.lens[d.have-1];I=3+(3&A);A>>>=2;v-=2}else if(17===N){for(M=J+3;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=3+(7&A);A>>>=3;v-=3}else{for(M=J+7;v<M;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=11+(127&A);A>>>=7;v-=7}if(d.have+I>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;I--;)d.lens[d.have++]=P}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,U={bits:d.lenbits},W=w(1,d.lens,0,d.nlen,d.lencode,0,d.work,U),d.lenbits=U.bits,W){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,U={bits:d.distbits},W=w(2,d.lens,d.nlen,d.ndist,
|
||||
d.distcode,0,d.work,U),d.distbits=U.bits,W){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=l&&258<=B){b.next_out=k;b.avail_out=B;b.next_in=h;b.avail_in=l;d.hold=A;d.bits=v;z(b,G);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,M=O>>>16&255,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(M&&0===(240&M)){D=
|
||||
J;F=M;for(aa=N;O=d.lencode[aa+((A&(1<<D+F)-1)>>D)],J=O>>>24,M=O>>>16&255,N=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,d.length=N,0===M){d.mode=26;break}if(32&M){d.back=-1;d.mode=12;break}if(64&M){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&M;d.mode=22;case 22:if(d.extra){for(M=d.extra;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.length+=A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}d.was=d.length;d.mode=
|
||||
23;case 23:for(;O=d.distcode[A&(1<<d.distbits)-1],J=O>>>24,M=O>>>16&255,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(0===(240&M)){D=J;F=M;for(aa=N;O=d.distcode[aa+((A&(1<<D+F)-1)>>D)],J=O>>>24,M=O>>>16&255,N=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,64&M){b.msg="invalid distance code";d.mode=30;break}d.offset=N;d.extra=15&M;d.mode=24;case 24:if(d.extra){for(M=d.extra;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.offset+=
|
||||
A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===B)break a;if(I=G-B,d.offset>I){if(I=d.offset-I,I>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}I>d.wnext?(I-=d.wnext,ca=d.wsize-I):ca=d.wnext-I;I>d.length&&(I=d.length);M=d.window}else M=g,ca=k-d.offset,I=d.length;I>B&&(I=B);B-=I;d.length-=I;do g[k++]=M[ca++];while(--I);0===d.length&&(d.mode=21);break;case 26:if(0===B)break a;
|
||||
g[k++]=d.length;B--;d.mode=21;break;case 27:if(d.wrap){for(;32>v;){if(0===l)break a;l--;A|=f[h++]<<v;v+=8}if(G-=B,b.total_out+=G,d.total+=G,G&&(b.adler=d.check=d.flags?t(d.check,g,G,k-G):q(d.check,g,G,k-G)),G=B,(d.flags?A:e(A))!==d.check){b.msg="incorrect data check";d.mode=30;break}v=A=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}v=A=0}d.mode=29;case 29:W=1;break a;case 30:W=
|
||||
-3;break a;case 31:return-4;default:return y}return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,(d.wsize||G!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&m(b,b.output,b.next_out,G-b.avail_out)?(d.mode=31,-4):(Q-=b.avail_in,G-=b.avail_out,b.total_in+=Q,b.total_out+=G,d.total+=G,d.wrap&&G&&(b.adler=d.check=d.flags?t(d.check,g,G,b.next_out-G):q(d.check,g,G,b.next_out-G)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===Q&&0===G||4===
|
||||
c)&&W===x&&(W=-5),W)};d.inflateEnd=function(b){if(!b||!b.state)return y;var c=b.state;return c.window&&(c.window=null),b.state=null,x};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?y:(d.head=c,c.done=!1,x)):y};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?y:11===d.mode&&(e=1,e=q(e,c,f,0),e!==d.check)?-3:m(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,x)):y};d.inflateInfo="pako inflate (from Nodeca project)"},
|
||||
1,A>>>=5,v-=5,d.ncode=(15&A)+4,A>>>=4,v-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.lens[fa[d.have++]]=7&A;A>>>=3;v-=3}for(;19>d.have;)d.lens[fa[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,Z={bits:d.lenbits},S=w(0,d.lens,0,19,d.lencode,0,d.work,Z),d.lenbits=Z.bits,S){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
|
||||
d.nlen+d.ndist;){for(;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(16>M)A>>>=J,v-=J,d.lens[d.have++]=M;else{if(16===M){for(N=J+2;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A>>>=J,v-=J,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}P=d.lens[d.have-1];I=3+(3&A);A>>>=2;v-=2}else if(17===M){for(N=J+3;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=3+(7&A);A>>>=3;v-=3}else{for(N=J+7;v<N;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=11+(127&A);A>>>=7;v-=7}if(d.have+I>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;I--;)d.lens[d.have++]=P}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,Z={bits:d.lenbits},S=w(1,d.lens,0,d.nlen,d.lencode,0,d.work,Z),d.lenbits=Z.bits,S){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,Z={bits:d.distbits},S=w(2,d.lens,d.nlen,d.ndist,
|
||||
d.distcode,0,d.work,Z),d.distbits=Z.bits,S){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=l&&258<=B){b.next_out=k;b.avail_out=B;b.next_in=h;b.avail_in=l;d.hold=A;d.bits=v;z(b,H);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,N=O>>>16&255,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(N&&0===(240&N)){D=
|
||||
J;F=N;for(U=M;O=d.lencode[U+((A&(1<<D+F)-1)>>D)],J=O>>>24,N=O>>>16&255,M=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,d.length=M,0===N){d.mode=26;break}if(32&N){d.back=-1;d.mode=12;break}if(64&N){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&N;d.mode=22;case 22:if(d.extra){for(N=d.extra;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.length+=A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}d.was=d.length;d.mode=23;
|
||||
case 23:for(;O=d.distcode[A&(1<<d.distbits)-1],J=O>>>24,N=O>>>16&255,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(0===(240&N)){D=J;F=N;for(U=M;O=d.distcode[U+((A&(1<<D+F)-1)>>D)],J=O>>>24,N=O>>>16&255,M=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,64&N){b.msg="invalid distance code";d.mode=30;break}d.offset=M;d.extra=15&N;d.mode=24;case 24:if(d.extra){for(N=d.extra;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.offset+=
|
||||
A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===B)break a;if(I=H-B,d.offset>I){if(I=d.offset-I,I>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}I>d.wnext?(I-=d.wnext,da=d.wsize-I):da=d.wnext-I;I>d.length&&(I=d.length);N=d.window}else N=g,da=k-d.offset,I=d.length;I>B&&(I=B);B-=I;d.length-=I;do g[k++]=N[da++];while(--I);0===d.length&&(d.mode=21);break;case 26:if(0===B)break a;
|
||||
g[k++]=d.length;B--;d.mode=21;break;case 27:if(d.wrap){for(;32>v;){if(0===l)break a;l--;A|=f[h++]<<v;v+=8}if(H-=B,b.total_out+=H,d.total+=H,H&&(b.adler=d.check=d.flags?t(d.check,g,H,k-H):q(d.check,g,H,k-H)),H=B,(d.flags?A:e(A))!==d.check){b.msg="incorrect data check";d.mode=30;break}v=A=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}v=A=0}d.mode=29;case 29:S=1;break a;case 30:S=
|
||||
-3;break a;case 31:return-4;default:return y}return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,(d.wsize||H!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&m(b,b.output,b.next_out,H-b.avail_out)?(d.mode=31,-4):(R-=b.avail_in,H-=b.avail_out,b.total_in+=R,b.total_out+=H,d.total+=H,d.wrap&&H&&(b.adler=d.check=d.flags?t(d.check,g,H,b.next_out-H):q(d.check,g,H,b.next_out-H)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===R&&0===H||4===
|
||||
c)&&S===x&&(S=-5),S)};d.inflateEnd=function(b){if(!b||!b.state)return y;var c=b.state;return c.window&&(c.window=null),b.state=null,x};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?y:(d.head=c,c.done=!1,x)):y};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?y:11===d.mode&&(e=1,e=q(e,c,f,0),e!==d.check)?-3:m(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,x)):y};d.inflateInfo="pako inflate (from Nodeca project)"},
|
||||
{"../utils/common":3,"./adler32":5,"./crc32":7,"./inffast":10,"./inftrees":12}],12:[function(b,c,d){var e=b("../utils/common"),f=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],h=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],k=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,
|
||||
25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,p,r,q,t,z){var l,m,n,u,D,F,E,B,A=z.bits,C,L,K,H,V,S,ba=0,X,v=null,Q=0,G=new e.Buf16(16);u=new e.Buf16(16);var I=null,ca=0;for(C=0;15>=C;C++)G[C]=0;for(L=0;L<p;L++)G[c[d+L]]++;H=A;for(K=15;1<=K&&0===G[K];K--);if(H>K&&(H=K),0===K)return r[q++]=20971520,r[q++]=20971520,z.bits=1,0;for(A=1;A<K&&0===G[A];A++);H<A&&(H=A);for(C=l=1;15>=C;C++)if(l<<=1,l-=G[C],0>l)return-1;if(0<l&&(0===b||1!==K))return-1;u[1]=0;for(C=1;15>C;C++)u[C+1]=u[C]+G[C];
|
||||
for(L=0;L<p;L++)0!==c[d+L]&&(t[u[c[d+L]]++]=L);if(0===b?(v=I=t,D=19):1===b?(v=f,Q-=257,I=g,ca-=257,D=256):(v=h,I=k,D=-1),X=0,L=0,C=A,u=q,V=H,S=0,n=-1,ba=1<<H,p=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var M=0;;){M++;F=C-S;t[L]<D?(E=0,B=t[L]):t[L]>D?(E=I[ca+t[L]],B=v[Q+t[L]]):(E=96,B=0);l=1<<C-S;A=m=1<<V;do m-=l,r[u+(X>>S)+m]=F<<24|E<<16|B|0;while(0!==m);for(l=1<<C-1;X&l;)l>>=1;if(0!==l?(X&=l-1,X+=l):X=0,L++,0===--G[C]){if(C===K)break;C=c[d+t[L]]}if(C>H&&(X&p)!==n){0===S&&(S=H);u+=A;V=C-S;for(l=
|
||||
1<<V;V+S<K&&(l-=G[V+S],!(0>=l));)V++,l<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;n=X&p;r[n]=H<<24|V<<16|u-q|0}}return 0!==X&&(r[u+X]=C-S<<24|4194304),z.bits=H,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
|
||||
b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function h(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function k(b,c,d){b.bi_valid>ba-d?(b.bi_buf|=c<<b.bi_valid&65535,h(b,b.bi_buf),b.bi_buf=c>>ba-b.bi_valid,b.bi_valid+=d-ba):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function l(b,c,d){k(b,d[2*c],d[2*c+1])}function m(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
|
||||
while(0<--c);return d>>>1}function n(b,c,d){var e,f=Array(S+1),g=0;for(e=1;e<=S;e++)f[e]=g=g+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=m(f[e]++,e))}function p(b){var c;for(c=0;c<L;c++)b.dyn_ltree[2*c]=0;for(c=0;c<K;c++)b.dyn_dtree[2*c]=0;for(c=0;c<H;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*X]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function r(b){8<b.bi_valid?h(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function q(b,c,d,e){var f=2*c,g=2*d;
|
||||
return b[f]<b[g]||b[f]===b[g]&&e[c]<=e[d]}function t(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&q(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!q(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function z(b,c,d){var e,f,g,h,m=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*m]<<8|b.pending_buf[b.d_buf+2*m+1],f=b.pending_buf[b.l_buf+m],m++,0===e?l(b,f,c):(g=aa[f],l(b,g+C+1,c),h=I[g],0!==h&&(f-=P[g],k(b,f,h)),e--,g=256>e?ea[e]:ea[256+(e>>>7)],l(b,g,d),h=ca[g],0!==h&&
|
||||
(e-=W[g],k(b,e,h)));while(m<b.last_lit)}l(b,X,c)}function w(b,c){var d,e,f,g=c.dyn_tree;e=c.stat_desc.static_tree;var h=c.stat_desc.has_stree,k=c.stat_desc.elems,l=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<k;d++)0!==g[2*d]?(b.heap[++b.heap_len]=l=d,b.depth[d]=0):g[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>l?++l:0,g[2*f]=1,b.depth[f]=0,b.opt_len--,h&&(b.static_len-=e[2*f+1]);c.max_code=l;for(d=b.heap_len>>1;1<=d;d--)t(b,g,d);f=k;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],t(b,g,1),e=b.heap[1],
|
||||
b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,g[2*f]=g[2*d]+g[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,g[2*d+1]=g[2*e+1]=f,b.heap[1]=f++,t(b,g,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var m,v,h=c.dyn_tree,k=c.max_code,p=c.stat_desc.static_tree,q=c.stat_desc.has_stree,r=c.stat_desc.extra_bits,G=c.stat_desc.extra_base,Q=c.stat_desc.max_length,I=0;for(e=0;e<=S;e++)b.bl_count[e]=0;h[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=h[2*h[2*f+1]+1]+
|
||||
1,e>Q&&(e=Q,I++),h[2*f+1]=e,f>k||(b.bl_count[e]++,m=0,f>=G&&(m=r[f-G]),v=h[2*f],b.opt_len+=v*(e+m),q&&(b.static_len+=v*(p[2*f+1]+m)));if(0!==I){do{for(e=Q-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[Q]--;I-=2}while(0<I);for(e=Q;0!==e;e--)for(f=b.bl_count[e];0!==f;)m=b.heap[--d],m>k||(h[2*m+1]!==e&&(b.opt_len+=(e-h[2*m+1])*h[2*m],h[2*m+1]=e),f--)}n(g,l,b.bl_count)}function x(b,c,d){var e,f,g=-1,h=c[1],k=0,l=7,m=4;0===h&&(l=138,m=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=h,
|
||||
h=c[2*(e+1)+1],++k<l&&f===h||(k<m?b.bl_tree[2*f]+=k:0!==f?(f!==g&&b.bl_tree[2*f]++,b.bl_tree[2*v]++):10>=k?b.bl_tree[2*Q]++:b.bl_tree[2*G]++,k=0,g=f,0===h?(l=138,m=3):f===h?(l=6,m=3):(l=7,m=4))}function y(b,c,d){var e,f,g=-1,h=c[1],m=0,n=7,p=4;0===h&&(n=138,p=3);for(e=0;e<=d;e++)if(f=h,h=c[2*(e+1)+1],!(++m<n&&f===h)){if(m<p){do l(b,f,b.bl_tree);while(0!==--m)}else 0!==f?(f!==g&&(l(b,f,b.bl_tree),m--),l(b,v,b.bl_tree),k(b,m-3,2)):10>=m?(l(b,Q,b.bl_tree),k(b,m-3,3)):(l(b,G,b.bl_tree),k(b,m-11,7));m=
|
||||
0;g=f;0===h?(n=138,p=3):f===h?(n=6,p=3):(n=7,p=4)}}function u(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return E;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return B;for(c=32;c<C;c++)if(0!==b.dyn_ltree[2*c])return B;return E}function D(b,c,d,e){k(b,(A<<1)+(e?1:0),3);r(b);h(b,d);h(b,~d);F.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var F=b("../utils/common"),E=0,B=1,A=0,C=256,L=C+1+29,K=30,H=19,V=2*L+1,S=15,ba=16,X=256,v=16,Q=17,
|
||||
G=18,I=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],ca=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],M=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],J=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],N=Array(2*(L+2));e(N);var T=Array(2*K);e(T);var ea=Array(512);e(ea);var aa=Array(256);e(aa);var P=Array(29);e(P);var W=Array(K);e(W);var U,O,R,fa=!1;d._tr_init=function(b){if(!fa){var c,d,e,h=Array(S+1);for(e=d=0;28>e;e++)for(P[e]=d,c=0;c<1<<I[e];c++)aa[d++]=e;aa[d-1]=
|
||||
e;for(e=d=0;16>e;e++)for(W[e]=d,c=0;c<1<<ca[e];c++)ea[d++]=e;for(d>>=7;e<K;e++)for(W[e]=d<<7,c=0;c<1<<ca[e]-7;c++)ea[256+d++]=e;for(c=0;c<=S;c++)h[c]=0;for(c=0;143>=c;)N[2*c+1]=8,c++,h[8]++;for(;255>=c;)N[2*c+1]=9,c++,h[9]++;for(;279>=c;)N[2*c+1]=7,c++,h[7]++;for(;287>=c;)N[2*c+1]=8,c++,h[8]++;n(N,L+1,h);for(c=0;c<K;c++)T[2*c+1]=5,T[2*c]=m(c,5);U=new f(N,I,C+1,L,S);O=new f(T,ca,0,K,S);R=new f([],M,0,H,7);fa=!0}b.l_desc=new g(b.dyn_ltree,U);b.d_desc=new g(b.dyn_dtree,O);b.bl_desc=new g(b.bl_tree,R);
|
||||
b.bi_buf=0;b.bi_valid=0;p(b)};d._tr_stored_block=D;d._tr_flush_block=function(b,c,d,e){var f,g,h=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=u(b));w(b,b.l_desc);w(b,b.d_desc);x(b,b.dyn_ltree,b.l_desc.max_code);x(b,b.dyn_dtree,b.d_desc.max_code);w(b,b.bl_desc);for(h=H-1;3<=h&&0===b.bl_tree[2*J[h]+1];h--);h=(b.opt_len+=3*(h+1)+14,h);f=b.opt_len+3+7>>>3;g=b.static_len+3+7>>>3;g<=f&&(f=g)}else f=g=d+5;if(d+4<=f&&-1!==c)D(b,c,d,e);else if(4===b.strategy||g===f)k(b,2+(e?1:0),3),z(b,N,T);else{k(b,
|
||||
4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;h+=1;k(b,c-257,5);k(b,d-1,5);k(b,h-4,4);for(f=0;f<h;f++)k(b,b.bl_tree[2*J[f]+1],3);y(b,b.dyn_ltree,c-1);y(b,b.dyn_dtree,d-1);z(b,b.dyn_ltree,b.dyn_dtree)}p(b);e&&r(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(aa[d]+C+1)]++,b.dyn_dtree[2*(256>c?ea[c]:
|
||||
ea[256+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){k(b,2,3);l(b,X,N);16===b.bi_valid?(h(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,
|
||||
25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,p,r,q,t,z){var l,m,n,u,D,F,E,B,A=z.bits,C,L,K,G,V,T,ca=0,W,v=null,R=0,H=new e.Buf16(16);u=new e.Buf16(16);var I=null,da=0;for(C=0;15>=C;C++)H[C]=0;for(L=0;L<p;L++)H[c[d+L]]++;G=A;for(K=15;1<=K&&0===H[K];K--);if(G>K&&(G=K),0===K)return r[q++]=20971520,r[q++]=20971520,z.bits=1,0;for(A=1;A<K&&0===H[A];A++);G<A&&(G=A);for(C=l=1;15>=C;C++)if(l<<=1,l-=H[C],0>l)return-1;if(0<l&&(0===b||1!==K))return-1;u[1]=0;for(C=1;15>C;C++)u[C+1]=u[C]+H[C];
|
||||
for(L=0;L<p;L++)0!==c[d+L]&&(t[u[c[d+L]]++]=L);if(0===b?(v=I=t,D=19):1===b?(v=f,R-=257,I=g,da-=257,D=256):(v=h,I=k,D=-1),W=0,L=0,C=A,u=q,V=G,T=0,n=-1,ca=1<<G,p=ca-1,1===b&&852<ca||2===b&&592<ca)return 1;for(var N=0;;){N++;F=C-T;t[L]<D?(E=0,B=t[L]):t[L]>D?(E=I[da+t[L]],B=v[R+t[L]]):(E=96,B=0);l=1<<C-T;A=m=1<<V;do m-=l,r[u+(W>>T)+m]=F<<24|E<<16|B|0;while(0!==m);for(l=1<<C-1;W&l;)l>>=1;if(0!==l?(W&=l-1,W+=l):W=0,L++,0===--H[C]){if(C===K)break;C=c[d+t[L]]}if(C>G&&(W&p)!==n){0===T&&(T=G);u+=A;V=C-T;for(l=
|
||||
1<<V;V+T<K&&(l-=H[V+T],!(0>=l));)V++,l<<=1;if(ca+=1<<V,1===b&&852<ca||2===b&&592<ca)return 1;n=W&p;r[n]=G<<24|V<<16|u-q|0}}return 0!==W&&(r[u+W]=C-T<<24|4194304),z.bits=G,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
|
||||
b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function h(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function k(b,c,d){b.bi_valid>ca-d?(b.bi_buf|=c<<b.bi_valid&65535,h(b,b.bi_buf),b.bi_buf=c>>ca-b.bi_valid,b.bi_valid+=d-ca):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function l(b,c,d){k(b,d[2*c],d[2*c+1])}function m(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
|
||||
while(0<--c);return d>>>1}function n(b,c,d){var e,f=Array(T+1),g=0;for(e=1;e<=T;e++)f[e]=g=g+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=m(f[e]++,e))}function p(b){var c;for(c=0;c<L;c++)b.dyn_ltree[2*c]=0;for(c=0;c<K;c++)b.dyn_dtree[2*c]=0;for(c=0;c<G;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*W]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function r(b){8<b.bi_valid?h(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function q(b,c,d,e){var f=2*c,g=2*d;
|
||||
return b[f]<b[g]||b[f]===b[g]&&e[c]<=e[d]}function t(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&q(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!q(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function z(b,c,d){var e,f,g,h,m=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*m]<<8|b.pending_buf[b.d_buf+2*m+1],f=b.pending_buf[b.l_buf+m],m++,0===e?l(b,f,c):(g=U[f],l(b,g+C+1,c),h=I[g],0!==h&&(f-=P[g],k(b,f,h)),e--,g=256>e?ea[e]:ea[256+(e>>>7)],l(b,g,d),h=da[g],0!==h&&
|
||||
(e-=S[g],k(b,e,h)));while(m<b.last_lit)}l(b,W,c)}function w(b,c){var d,e,f,g=c.dyn_tree;e=c.stat_desc.static_tree;var h=c.stat_desc.has_stree,k=c.stat_desc.elems,l=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<k;d++)0!==g[2*d]?(b.heap[++b.heap_len]=l=d,b.depth[d]=0):g[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>l?++l:0,g[2*f]=1,b.depth[f]=0,b.opt_len--,h&&(b.static_len-=e[2*f+1]);c.max_code=l;for(d=b.heap_len>>1;1<=d;d--)t(b,g,d);f=k;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],t(b,g,1),e=b.heap[1],
|
||||
b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,g[2*f]=g[2*d]+g[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,g[2*d+1]=g[2*e+1]=f,b.heap[1]=f++,t(b,g,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var m,v,h=c.dyn_tree,k=c.max_code,p=c.stat_desc.static_tree,q=c.stat_desc.has_stree,r=c.stat_desc.extra_bits,R=c.stat_desc.extra_base,H=c.stat_desc.max_length,I=0;for(e=0;e<=T;e++)b.bl_count[e]=0;h[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=h[2*h[2*f+1]+1]+
|
||||
1,e>H&&(e=H,I++),h[2*f+1]=e,f>k||(b.bl_count[e]++,m=0,f>=R&&(m=r[f-R]),v=h[2*f],b.opt_len+=v*(e+m),q&&(b.static_len+=v*(p[2*f+1]+m)));if(0!==I){do{for(e=H-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[H]--;I-=2}while(0<I);for(e=H;0!==e;e--)for(f=b.bl_count[e];0!==f;)m=b.heap[--d],m>k||(h[2*m+1]!==e&&(b.opt_len+=(e-h[2*m+1])*h[2*m],h[2*m+1]=e),f--)}n(g,l,b.bl_count)}function x(b,c,d){var e,f,g=-1,h=c[1],k=0,l=7,m=4;0===h&&(l=138,m=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=h,
|
||||
h=c[2*(e+1)+1],++k<l&&f===h||(k<m?b.bl_tree[2*f]+=k:0!==f?(f!==g&&b.bl_tree[2*f]++,b.bl_tree[2*v]++):10>=k?b.bl_tree[2*R]++:b.bl_tree[2*H]++,k=0,g=f,0===h?(l=138,m=3):f===h?(l=6,m=3):(l=7,m=4))}function y(b,c,d){var e,f,g=-1,h=c[1],m=0,n=7,p=4;0===h&&(n=138,p=3);for(e=0;e<=d;e++)if(f=h,h=c[2*(e+1)+1],!(++m<n&&f===h)){if(m<p){do l(b,f,b.bl_tree);while(0!==--m)}else 0!==f?(f!==g&&(l(b,f,b.bl_tree),m--),l(b,v,b.bl_tree),k(b,m-3,2)):10>=m?(l(b,R,b.bl_tree),k(b,m-3,3)):(l(b,H,b.bl_tree),k(b,m-11,7));m=
|
||||
0;g=f;0===h?(n=138,p=3):f===h?(n=6,p=3):(n=7,p=4)}}function u(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return E;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return B;for(c=32;c<C;c++)if(0!==b.dyn_ltree[2*c])return B;return E}function D(b,c,d,e){k(b,(A<<1)+(e?1:0),3);r(b);h(b,d);h(b,~d);F.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var F=b("../utils/common"),E=0,B=1,A=0,C=256,L=C+1+29,K=30,G=19,V=2*L+1,T=15,ca=16,W=256,v=16,R=17,
|
||||
H=18,I=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],da=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],N=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],J=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],M=Array(2*(L+2));e(M);var aa=Array(2*K);e(aa);var ea=Array(512);e(ea);var U=Array(256);e(U);var P=Array(29);e(P);var S=Array(K);e(S);var Z,O,Q,fa=!1;d._tr_init=function(b){if(!fa){var c,d,e,h=Array(T+1);for(e=d=0;28>e;e++)for(P[e]=d,c=0;c<1<<I[e];c++)U[d++]=e;U[d-1]=e;
|
||||
for(e=d=0;16>e;e++)for(S[e]=d,c=0;c<1<<da[e];c++)ea[d++]=e;for(d>>=7;e<K;e++)for(S[e]=d<<7,c=0;c<1<<da[e]-7;c++)ea[256+d++]=e;for(c=0;c<=T;c++)h[c]=0;for(c=0;143>=c;)M[2*c+1]=8,c++,h[8]++;for(;255>=c;)M[2*c+1]=9,c++,h[9]++;for(;279>=c;)M[2*c+1]=7,c++,h[7]++;for(;287>=c;)M[2*c+1]=8,c++,h[8]++;n(M,L+1,h);for(c=0;c<K;c++)aa[2*c+1]=5,aa[2*c]=m(c,5);Z=new f(M,I,C+1,L,T);O=new f(aa,da,0,K,T);Q=new f([],N,0,G,7);fa=!0}b.l_desc=new g(b.dyn_ltree,Z);b.d_desc=new g(b.dyn_dtree,O);b.bl_desc=new g(b.bl_tree,
|
||||
Q);b.bi_buf=0;b.bi_valid=0;p(b)};d._tr_stored_block=D;d._tr_flush_block=function(b,c,d,e){var f,g,h=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=u(b));w(b,b.l_desc);w(b,b.d_desc);x(b,b.dyn_ltree,b.l_desc.max_code);x(b,b.dyn_dtree,b.d_desc.max_code);w(b,b.bl_desc);for(h=G-1;3<=h&&0===b.bl_tree[2*J[h]+1];h--);h=(b.opt_len+=3*(h+1)+14,h);f=b.opt_len+3+7>>>3;g=b.static_len+3+7>>>3;g<=f&&(f=g)}else f=g=d+5;if(d+4<=f&&-1!==c)D(b,c,d,e);else if(4===b.strategy||g===f)k(b,2+(e?1:0),3),z(b,M,aa);
|
||||
else{k(b,4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;h+=1;k(b,c-257,5);k(b,d-1,5);k(b,h-4,4);for(f=0;f<h;f++)k(b,b.bl_tree[2*J[f]+1],3);y(b,b.dyn_ltree,c-1);y(b,b.dyn_dtree,d-1);z(b,b.dyn_ltree,b.dyn_dtree)}p(b);e&&r(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(U[d]+C+1)]++,b.dyn_dtree[2*(256>
|
||||
c?ea[c]:ea[256+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){k(b,2,3);l(b,W,M);16===b.bi_valid?(h(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,
|
||||
c,d){d=b("./lib/utils/common").assign;var e=b("./lib/deflate"),f=b("./lib/inflate");b=b("./lib/zlib/constants");var g={};d(g,e,f,b);c.exports=g},{"./lib/deflate":1,"./lib/inflate":2,"./lib/utils/common":3,"./lib/zlib/constants":6}]},{},[])("/")});var JSON;JSON||(JSON={});
|
||||
(function(){function a(a){return 10>a?"0"+a:a}function b(a){e.lastIndex=0;return e.test(a)?'"'+a.replace(e,function(a){var b=h[a];return"string"===typeof b?b:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function c(a,d){var e,h,l,m,t=f,z,w=d[a];w&&"object"===typeof w&&"function"===typeof w.toJSON&&(w=w.toJSON(a));"function"===typeof k&&(w=k.call(d,a,w));switch(typeof w){case "string":return b(w);case "number":return isFinite(w)?""+w:"null";case "boolean":case "null":return""+w;
|
||||
case "object":if(!w)return"null";f+=g;z=[];if("[object Array]"===Object.prototype.toString.apply(w)){m=w.length;for(e=0;e<m;e+=1)z[e]=c(e,w)||"null";l=0===z.length?"[]":f?"[\n"+f+z.join(",\n"+f)+"\n"+t+"]":"["+z.join(",")+"]";f=t;return l}if(k&&"object"===typeof k)for(m=k.length,e=0;e<m;e+=1)"string"===typeof k[e]&&(h=k[e],(l=c(h,w))&&z.push(b(h)+(f?": ":":")+l));else for(h in w)Object.prototype.hasOwnProperty.call(w,h)&&(l=c(h,w))&&z.push(b(h)+(f?": ":":")+l);l=0===z.length?"{}":f?"{\n"+f+z.join(",\n"+
|
||||
|
@ -184,7 +184,7 @@ f)+"\n"+t+"}":"{"+z.join(",")+"}";f=t;return l}}"function"!==typeof Date.prototy
|
|||
e=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,f,g,h={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},k;"function"!==typeof JSON.stringify&&(JSON.stringify=function(a,b,d){var e;g=f="";if("number"===typeof d)for(e=0;e<d;e+=1)g+=" ";else"string"===typeof d&&(g=d);if((k=b)&&"function"!==typeof b&&("object"!==typeof b||"number"!==typeof b.length))throw Error("JSON.stringify");return c("",{"":a})});
|
||||
"function"!==typeof JSON.parse&&(JSON.parse=function(a,b){function c(a,d){var e,f,g=a[d];if(g&&"object"===typeof g)for(e in g)Object.prototype.hasOwnProperty.call(g,e)&&(f=c(g,e),void 0!==f?g[e]=f:delete g[e]);return b.call(a,d,g)}var e;a=""+a;d.lastIndex=0;d.test(a)&&(a=a.replace(d,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
|
||||
"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return e=eval("("+a+")"),"function"===typeof b?c({"":e},""):e;throw new SyntaxError("JSON.parse");})})();"undefined"===typeof window.mxBasePath&&(window.mxBasePath="https://www.draw.io/mxgraph/");window.mxLoadStylesheets=window.mxLoadStylesheets||!1;window.mxLoadResources=window.mxLoadResources||!1;window.mxLanguage=window.mxLanguage||"en";window.urlParams=window.urlParams||{};window.MAX_REQUEST_SIZE=window.MAX_REQUEST_SIZE||10485760;window.MAX_AREA=window.MAX_AREA||225E6;window.EXPORT_URL=window.EXPORT_URL||"/export";window.SAVE_URL=window.SAVE_URL||"/save";window.OPEN_URL=window.OPEN_URL||"/open";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";window.RESOURCE_BASE=window.RESOURCE_BASE||window.RESOURCES_PATH+"/grapheditor";window.STENCIL_PATH=window.STENCIL_PATH||"stencils";window.IMAGE_PATH=window.IMAGE_PATH||"images";
|
||||
window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"9.1.0",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
|
||||
window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"9.1.1",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
|
||||
0>navigator.userAgent.indexOf("Edge/"),IS_OP:0<=navigator.userAgent.indexOf("Opera/")||0<=navigator.userAgent.indexOf("OPR/"),IS_OT:0<=navigator.userAgent.indexOf("Presto/")&&0>navigator.userAgent.indexOf("Presto/2.4.")&&0>navigator.userAgent.indexOf("Presto/2.3.")&&0>navigator.userAgent.indexOf("Presto/2.2.")&&0>navigator.userAgent.indexOf("Presto/2.1.")&&0>navigator.userAgent.indexOf("Presto/2.0.")&&0>navigator.userAgent.indexOf("Presto/1."),IS_SF:0<=navigator.userAgent.indexOf("AppleWebKit/")&&
|
||||
0>navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_IOS:navigator.userAgent.match(/(iPad|iPhone|iPod)/g)?!0:!1,IS_GC:0<=navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_CHROMEAPP:null!=window.chrome&&null!=chrome.app&&null!=chrome.app.runtime,IS_FF:0<=navigator.userAgent.indexOf("Firefox/"),IS_MT:0<=navigator.userAgent.indexOf("Firefox/")&&0>navigator.userAgent.indexOf("Firefox/1.")&&0>navigator.userAgent.indexOf("Firefox/2.")||0<=navigator.userAgent.indexOf("Iceweasel/")&&
|
||||
0>navigator.userAgent.indexOf("Iceweasel/1.")&&0>navigator.userAgent.indexOf("Iceweasel/2.")||0<=navigator.userAgent.indexOf("SeaMonkey/")&&0>navigator.userAgent.indexOf("SeaMonkey/1.")||0<=navigator.userAgent.indexOf("Iceape/")&&0>navigator.userAgent.indexOf("Iceape/1."),IS_SVG:0<=navigator.userAgent.indexOf("Firefox/")||0<=navigator.userAgent.indexOf("Iceweasel/")||0<=navigator.userAgent.indexOf("Seamonkey/")||0<=navigator.userAgent.indexOf("Iceape/")||0<=navigator.userAgent.indexOf("Galeon/")||
|
||||
|
@ -531,7 +531,7 @@ mxArrowConnector.prototype.augmentBoundingBox=function(a){mxShape.prototype.augm
|
|||
mxArrowConnector.prototype.paintEdgeShape=function(a,b){var c=this.strokewidth;this.outline&&(c=Math.max(1,mxUtils.getNumber(this.style,mxConstants.STYLE_STROKEWIDTH,this.strokewidth)));for(var d=this.getStartArrowWidth()+c,e=this.getEndArrowWidth()+c,f=this.outline?this.getEdgeWidth()+c:this.getEdgeWidth(),g=this.isOpenEnded(),h=this.isMarkerStart(),k=this.isMarkerEnd(),l=g?0:this.arrowSpacing+c/2,m=this.startSize+c,c=this.endSize+c,n=this.isArrowRounded(),p=b[b.length-1],r=1;r<b.length-1&&b[r].x==
|
||||
b[0].x&&b[r].y==b[0].y;)r++;var q=b[r].x-b[0].x,r=b[r].y-b[0].y,t=Math.sqrt(q*q+r*r);if(0!=t){var z=q/t,w,x=z,y=r/t,u,D=y,t=f*y,F=-f*z,E=[];n?a.setLineJoin("round"):2<b.length&&a.setMiterLimit(1.42);a.begin();q=z;r=y;if(h&&!g)this.paintMarker(a,b[0].x,b[0].y,z,y,m,d,f,l,!0);else{w=b[0].x+t/2+l*z;u=b[0].y+F/2+l*y;var B=b[0].x-t/2+l*z,A=b[0].y-F/2+l*y;g?(a.moveTo(w,u),E.push(function(){a.lineTo(B,A)})):(a.moveTo(B,A),a.lineTo(w,u))}for(var C=u=w=0,t=0;t<b.length-2;t++)if(F=mxUtils.relativeCcw(b[t].x,
|
||||
b[t].y,b[t+1].x,b[t+1].y,b[t+2].x,b[t+2].y),w=b[t+2].x-b[t+1].x,u=b[t+2].y-b[t+1].y,C=Math.sqrt(w*w+u*u),0!=C&&(x=w/C,D=u/C,tmp=Math.max(Math.sqrt((z*x+y*D+1)/2),.04),w=z+x,u=y+D,C=Math.sqrt(w*w+u*u),0!=C)){w/=C;u/=C;var C=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),C=0!=F&&n?Math.max(.1,C):Math.max(tmp,.06),L=b[t+1].x+u*f/2/C,K=b[t+1].y-w*f/2/C;u=b[t+1].x-u*f/2/C;w=b[t+1].y+w*f/2/C;0!=F&&n?-1==F?(F=u+D*f,C=w-x*f,a.lineTo(u+y*f,w-z*f),a.quadTo(L,K,F,C),function(b,c){E.push(function(){a.lineTo(b,
|
||||
c)})}(u,w)):(a.lineTo(L,K),function(b,c){var d=L-y*f,e=K+z*f,g=L-D*f,h=K+x*f;E.push(function(){a.quadTo(b,c,d,e)});E.push(function(){a.lineTo(g,h)})}(u,w)):(a.lineTo(L,K),function(b,c){E.push(function(){a.lineTo(b,c)})}(u,w));z=x;y=D}t=f*D;F=-f*x;if(k&&!g)this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!1);else{a.lineTo(p.x-l*x+t/2,p.y-l*D+F/2);var H=p.x-l*x-t/2,V=p.y-l*D-F/2;g?(a.moveTo(H,V),E.splice(0,0,function(){a.moveTo(H,V)})):a.lineTo(H,V)}for(t=E.length-1;0<=t;t--)E[t]();g?(a.end(),a.stroke()):(a.close(),
|
||||
c)})}(u,w)):(a.lineTo(L,K),function(b,c){var d=L-y*f,e=K+z*f,g=L-D*f,h=K+x*f;E.push(function(){a.quadTo(b,c,d,e)});E.push(function(){a.lineTo(g,h)})}(u,w)):(a.lineTo(L,K),function(b,c){E.push(function(){a.lineTo(b,c)})}(u,w));z=x;y=D}t=f*D;F=-f*x;if(k&&!g)this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!1);else{a.lineTo(p.x-l*x+t/2,p.y-l*D+F/2);var G=p.x-l*x-t/2,V=p.y-l*D-F/2;g?(a.moveTo(G,V),E.splice(0,0,function(){a.moveTo(G,V)})):a.lineTo(G,V)}for(t=E.length-1;0<=t;t--)E[t]();g?(a.end(),a.stroke()):(a.close(),
|
||||
a.fillAndStroke());a.setShadow(!1);a.setMiterLimit(4);n&&a.setLineJoin("flat");2<b.length&&(a.setMiterLimit(4),h&&!g&&(a.begin(),this.paintMarker(a,b[0].x,b[0].y,q,r,m,d,f,l,!0),a.stroke(),a.end()),k&&!g&&(a.begin(),this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!0),a.stroke(),a.end()))}};
|
||||
mxArrowConnector.prototype.paintMarker=function(a,b,c,d,e,f,g,h,k,l){g=h/g;var m=h*e/2;h=-h*d/2;var n=(k+f)*d;f=(k+f)*e;l?a.moveTo(b-m+n,c-h+f):a.lineTo(b-m+n,c-h+f);a.lineTo(b-m/g+n,c-h/g+f);a.lineTo(b+k*d,c+k*e);a.lineTo(b+m/g+n,c+h/g+f);a.lineTo(b+m+n,c+h+f)};mxArrowConnector.prototype.isArrowRounded=function(){return this.isRounded};mxArrowConnector.prototype.getStartArrowWidth=function(){return mxConstants.ARROW_WIDTH};mxArrowConnector.prototype.getEndArrowWidth=function(){return mxConstants.ARROW_WIDTH};
|
||||
mxArrowConnector.prototype.getEdgeWidth=function(){return mxConstants.ARROW_WIDTH/3};mxArrowConnector.prototype.isOpenEnded=function(){return!1};mxArrowConnector.prototype.isMarkerStart=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE};mxArrowConnector.prototype.isMarkerEnd=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE};
|
||||
|
@ -607,10 +607,10 @@ this.direction==mxConstants.DIRECTION_WEST);if(f){b=Math.min(a.width,b*this.scal
|
|||
mxSwimlane.prototype.getArcSize=function(a,b,c){a=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100;return c*a*3};mxSwimlane.prototype.isHorizontal=function(){return 1==mxUtils.getValue(this.style,mxConstants.STYLE_HORIZONTAL,1)};
|
||||
mxSwimlane.prototype.paintVertexShape=function(a,b,c,d,e){var f=this.getTitleSize(),g=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE),h=1==mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_LINE,1),k=0,f=this.isHorizontal()?Math.min(f,e):Math.min(f,d);a.translate(b,c);this.isRounded?(k=this.getArcSize(d,e,f),this.paintRoundedSwimlane(a,b,c,d,e,f,k,g,h)):this.paintSwimlane(a,b,c,d,e,f,g,h);g=mxUtils.getValue(this.style,mxConstants.STYLE_SEPARATORCOLOR,mxConstants.NONE);
|
||||
this.paintSeparator(a,b,c,d,e,f,g);null!=this.image&&(e=this.getImageBounds(b,c,d,e),a.image(e.x-b,e.y-c,e.width,e.height,this.image,!1,!1,!1));this.glass&&(a.setShadow(!1),this.paintGlassEffect(a,0,0,d,f,k))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,h){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),a.rect(0,0,d,e),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(h||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,e),a.lineTo(f,e),(h||f>=d)&&
|
||||
a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,h,k){g=Math.min(e-f,Math.min(f,g));h!=mxConstants.NONE&&(a.save(),a.setFillColor(h),a.roundrect(0,0,d,e,g,g),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e-g),a.quadTo(0,
|
||||
e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(k||f>=d)&&a.close(),a.fillAndStroke(),f<d&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,h){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(h||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,
|
||||
e),a.lineTo(f,e),(h||f>=d)&&a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,h,k){g=Math.min(e-f,Math.min(f,g));h!=mxConstants.NONE&&(a.save(),a.setFillColor(h),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,
|
||||
f),a.lineTo(0,e-g),a.quadTo(0,e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(k||f>=d)&&a.close(),a.fillAndStroke(),f<d&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSeparator=function(a,b,c,d,e,f,g){g!=mxConstants.NONE&&(a.setStrokeColor(g),a.setDashed(!0),a.begin(),this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,e)):(a.moveTo(f,0),a.lineTo(d,0)),a.stroke(),a.setDashed(!1))};mxSwimlane.prototype.getImageBounds=function(a,b,c,d){return this.isHorizontal()?new mxRectangle(a+c-this.imageSize,b,this.imageSize,this.imageSize):new mxRectangle(a,b,this.imageSize,this.imageSize)};function mxGraphLayout(a){this.graph=a}
|
||||
mxGraphLayout.prototype.graph=null;mxGraphLayout.prototype.useBoundingBox=!0;mxGraphLayout.prototype.parent=null;mxGraphLayout.prototype.moveCell=function(a,b,c){};mxGraphLayout.prototype.execute=function(a){};mxGraphLayout.prototype.getGraph=function(){return this.graph};mxGraphLayout.prototype.getConstraint=function(a,b,c,d){c=this.graph.view.getState(b);b=null!=c?c.style:this.graph.getCellStyle(b);return null!=b?b[a]:null};
|
||||
mxGraphLayout.traverse=function(a,b,c,d,e){if(null!=c&&null!=a&&(b=null!=b?b:!0,e=e||new mxDictionary,!e.get(a)&&(e.put(a,!0),d=c(a,d),null==d||d))&&(d=this.graph.model.getEdgeCount(a),0<d))for(var f=0;f<d;f++){var g=this.graph.model.getEdgeAt(a,f),h=this.graph.model.getTerminal(g,!0)==a;if(!b||h)h=this.graph.view.getVisibleTerminal(g,!h),this.traverse(h,b,c,g,e)}};
|
||||
|
@ -1698,12 +1698,12 @@ return b||"0"!=mxUtils.getValue(c,mxConstants.STYLE_RESIZABLE,"1")&&"wrap"==c[mx
|
|||
g=this.view.translate;h=this.view.scale;e=e/h-(a?g.x:g.y);d=d/h-(a?g.x:g.y);this.getModel().beginUpdate();try{for(var k=(d-e)/(c.length-1),d=e,f=1;f<c.length-1;f++){var l=this.view.getState(this.model.getParent(c[f].cell)),m=this.getCellGeometry(c[f].cell),d=d+k;null!=m&&null!=l&&(m=m.clone(),a?m.x=Math.round(d-m.width/2)-l.origin.x:m.y=Math.round(d-m.height/2)-l.origin.y,this.getModel().setGeometry(c[f].cell,m))}}finally{this.getModel().endUpdate()}}}return b};Graph.prototype.isCloneEvent=function(a){return mxClient.IS_MAC&&
|
||||
mxEvent.isMetaDown(a)||mxEvent.isControlDown(a)};Graph.prototype.encodeCells=function(a){for(var b=this.cloneCells(a),c=new mxDictionary,d=0;d<a.length;d++)c.put(a[d],!0);for(d=0;d<b.length;d++){var e=this.view.getState(a[d]);if(null!=e){var f=this.getCellGeometry(b[d]);null==f||!f.relative||this.model.isEdge(a[d])||c.get(this.model.getParent(a[d]))||(f.relative=!1,f.x=e.x/e.view.scale-e.view.translate.x,f.y=e.y/e.view.scale-e.view.translate.y)}}c=new mxCodec;e=new mxGraphModel;f=e.getChildAt(e.getRoot(),
|
||||
0);for(d=0;d<a.length;d++)e.add(f,b[d]);return c.encode(e)};Graph.prototype.createSvgImageExport=function(){var a=new mxImageExport;a.getLinkForCellState=mxUtils.bind(this,function(a,b){return this.getLinkForCell(a.cell)});return a};Graph.prototype.getSvg=function(a,b,c,d,e,f,g,h){var k=this.useCssTransforms;k&&(this.useCssTransforms=!1,this.view.revalidate(),this.sizeDidChange());try{b=null!=b?b:1;c=null!=c?c:0;e=null!=e?e:!0;f=null!=f?f:!0;g=null!=g?g:!0;var l=f||d?this.getGraphBounds():this.getBoundingBox(this.getSelectionCells());
|
||||
if(null==l)throw Error(mxResources.get("drawingEmpty"));var m=this.view.scale,n=mxUtils.createXmlDocument(),p=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"svg"):n.createElement("svg");null!=a&&(null!=p.style?p.style.backgroundColor=a:p.setAttribute("style","background-color:"+a));null==n.createElementNS?(p.setAttribute("xmlns",mxConstants.NS_SVG),p.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):p.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink",mxConstants.NS_XLINK);
|
||||
a=b/m;p.setAttribute("width",Math.max(1,Math.ceil(l.width*a)+2*c)+"px");p.setAttribute("height",Math.max(1,Math.ceil(l.height*a)+2*c)+"px");p.setAttribute("version","1.1");d=p;if(e){var v=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"g"):n.createElement("g");v.setAttribute("transform","translate(0.5,0.5)");p.appendChild(v);n.appendChild(p);d=v}else n.appendChild(p);var q=this.createSvgCanvas(d);q.foOffset=e?-.5:0;q.textOffset=e?-.5:0;q.imageOffset=e?-.5:0;q.translate(Math.floor((c/
|
||||
b-l.x)/m),Math.floor((c/b-l.y)/m));var r=document.createElement("textarea"),t=q.createAlternateContent;q.createAlternateContent=function(a,b,c,d,e,f,g,h,k,l,m,n,p){var v=this.state;if(null!=this.foAltText&&(0==d||0!=v.fontSize&&f.length<5*d/v.fontSize)){var q=this.createElement("text");q.setAttribute("x",Math.round(d/2));q.setAttribute("y",Math.round((e+v.fontSize)/2));q.setAttribute("fill",v.fontColor||"black");q.setAttribute("text-anchor","middle");q.setAttribute("font-size",Math.round(v.fontSize)+
|
||||
"px");q.setAttribute("font-family",v.fontFamily);(v.fontStyle&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD&&q.setAttribute("font-weight","bold");(v.fontStyle&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC&&q.setAttribute("font-style","italic");(v.fontStyle&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&q.setAttribute("text-decoration","underline");try{return r.innerHTML=f,q.textContent=r.value,q}catch(Aa){return t.apply(this,arguments)}}else return t.apply(this,arguments)};var u=this.backgroundImage;
|
||||
if(null!=u){b=m/b;var G=this.view.translate,Q=new mxRectangle(G.x*b,G.y*b,u.width*b,u.height*b);mxUtils.intersects(l,Q)&&q.image(G.x,G.y,u.width,u.height,u.src,!0)}q.scale(a);q.textEnabled=g;h=null!=h?h:this.createSvgImageExport();var w=h.drawCellState;h.drawCellState=function(a,b){for(var c=a.view.graph,d=c.isCellSelected(a.cell),e=c.model.getParent(a.cell);!f&&!d&&null!=e;)d=c.isCellSelected(e),e=c.model.getParent(e);(f||d)&&w.apply(this,arguments)};h.drawState(this.getView().getState(this.model.root),
|
||||
q);return p}finally{k&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.createSvgCanvas=function(a){return new mxSvgCanvas2D(a)};Graph.prototype.getSelectedElement=function(){var a=null;if(window.getSelection){var b=window.getSelection();b.getRangeAt&&b.rangeCount&&(a=b.getRangeAt(0).commonAncestorContainer)}else document.selection&&(a=document.selection.createRange().parentElement());return a};Graph.prototype.getParentByName=function(a,b,c){for(;null!=a&&a.nodeName!=
|
||||
if(null==l)throw Error(mxResources.get("drawingEmpty"));var m=this.view.scale,n=mxUtils.createXmlDocument(),v=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"svg"):n.createElement("svg");null!=a&&(null!=v.style?v.style.backgroundColor=a:v.setAttribute("style","background-color:"+a));null==n.createElementNS?(v.setAttribute("xmlns",mxConstants.NS_SVG),v.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):v.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink",mxConstants.NS_XLINK);
|
||||
a=b/m;v.setAttribute("width",Math.max(1,Math.ceil(l.width*a)+2*c)+"px");v.setAttribute("height",Math.max(1,Math.ceil(l.height*a)+2*c)+"px");v.setAttribute("version","1.1");d=v;if(e){var p=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"g"):n.createElement("g");p.setAttribute("transform","translate(0.5,0.5)");v.appendChild(p);n.appendChild(v);d=p}else n.appendChild(v);var q=this.createSvgCanvas(d);q.foOffset=e?-.5:0;q.textOffset=e?-.5:0;q.imageOffset=e?-.5:0;q.translate(Math.floor((c/
|
||||
b-l.x)/m),Math.floor((c/b-l.y)/m));var r=document.createElement("textarea"),t=q.createAlternateContent;q.createAlternateContent=function(a,b,c,d,e,f,g,h,k,l,m,n,v){var p=this.state;if(null!=this.foAltText&&(0==d||0!=p.fontSize&&f.length<5*d/p.fontSize)){var q=this.createElement("text");q.setAttribute("x",Math.round(d/2));q.setAttribute("y",Math.round((e+p.fontSize)/2));q.setAttribute("fill",p.fontColor||"black");q.setAttribute("text-anchor","middle");q.setAttribute("font-size",Math.round(p.fontSize)+
|
||||
"px");q.setAttribute("font-family",p.fontFamily);(p.fontStyle&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD&&q.setAttribute("font-weight","bold");(p.fontStyle&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC&&q.setAttribute("font-style","italic");(p.fontStyle&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&q.setAttribute("text-decoration","underline");try{return r.innerHTML=f,q.textContent=r.value,q}catch(Da){return t.apply(this,arguments)}}else return t.apply(this,arguments)};var u=this.backgroundImage;
|
||||
if(null!=u){b=m/b;var H=this.view.translate,w=new mxRectangle(H.x*b,H.y*b,u.width*b,u.height*b);mxUtils.intersects(l,w)&&q.image(H.x,H.y,u.width,u.height,u.src,!0)}q.scale(a);q.textEnabled=g;h=null!=h?h:this.createSvgImageExport();var R=h.drawCellState;h.drawCellState=function(a,b){for(var c=a.view.graph,d=c.isCellSelected(a.cell),e=c.model.getParent(a.cell);!f&&!d&&null!=e;)d=c.isCellSelected(e),e=c.model.getParent(e);(f||d)&&R.apply(this,arguments)};h.drawState(this.getView().getState(this.model.root),
|
||||
q);return v}finally{k&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.createSvgCanvas=function(a){return new mxSvgCanvas2D(a)};Graph.prototype.getSelectedElement=function(){var a=null;if(window.getSelection){var b=window.getSelection();b.getRangeAt&&b.rangeCount&&(a=b.getRangeAt(0).commonAncestorContainer)}else document.selection&&(a=document.selection.createRange().parentElement());return a};Graph.prototype.getParentByName=function(a,b,c){for(;null!=a&&a.nodeName!=
|
||||
b;){if(a==c)return null;a=a.parentNode}return a};Graph.prototype.selectNode=function(a){var b=null;if(window.getSelection){if(b=window.getSelection(),b.getRangeAt&&b.rangeCount){var c=document.createRange();c.selectNode(a);b.removeAllRanges();b.addRange(c)}}else(b=document.selection)&&"Control"!=b.type&&(a=b.createRange(),a.collapse(!0),c=b.createRange(),c.setEndPoint("StartToStart",a),c.select())};Graph.prototype.insertRow=function(a,b){for(var c=a.tBodies[0],d=c.rows[0].cells,e=0,f=0;f<d.length;f++)var g=
|
||||
d[f].getAttribute("colspan"),e=e+(null!=g?parseInt(g):1);c=c.insertRow(b);for(f=0;f<e;f++)mxUtils.br(c.insertCell(-1));return c.cells[0]};Graph.prototype.deleteRow=function(a,b){a.tBodies[0].deleteRow(b)};Graph.prototype.insertColumn=function(a,b){var c=a.tHead;if(null!=c)for(var d=0;d<c.rows.length;d++){var e=document.createElement("th");c.rows[d].appendChild(e);mxUtils.br(e)}c=a.tBodies[0];for(d=0;d<c.rows.length;d++)e=c.rows[d].insertCell(b),mxUtils.br(e);return c.rows[0].cells[0<=b?b:c.rows[0].cells.length-
|
||||
1]};Graph.prototype.deleteColumn=function(a,b){if(0<=b)for(var c=a.tBodies[0].rows,d=0;d<c.length;d++)c[d].cells.length>b&&c[d].deleteCell(b)};Graph.prototype.pasteHtmlAtCaret=function(a){var b;if(window.getSelection){if(b=window.getSelection(),b.getRangeAt&&b.rangeCount){b=b.getRangeAt(0);b.deleteContents();var c=document.createElement("div");c.innerHTML=a;a=document.createDocumentFragment();for(var d;d=c.firstChild;)lastNode=a.appendChild(d);b.insertNode(a)}}else(b=document.selection)&&"Control"!=
|
||||
|
@ -1770,58 +1770,58 @@ mxUtils.getTextContent(c[d])));this.linkHint.appendChild(e)}}};mxEdgeHandler.pro
|
|||
this.labelShape&&(this.labelShape.node.style.display=this.graph.isEnabled()&&this.graph.getSelectionCount()<this.graph.graphHandler.maxCells?"":"none")});this.selectionHandler=mxUtils.bind(this,function(b,c){a()});this.graph.getSelectionModel().addListener(mxEvent.CHANGE,this.selectionHandler);this.changeHandler=mxUtils.bind(this,function(b,c){this.updateLinkHint(this.graph.getLinkForCell(this.state.cell),this.graph.getLinksForState(this.state));a();this.redrawHandles()});this.graph.getModel().addListener(mxEvent.CHANGE,
|
||||
this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell),c=this.graph.getLinksForState(this.state);if(null!=b||null!=c&&0<c.length)this.updateLinkHint(b,c),this.redrawHandles()};var L=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){L.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var K=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){K.apply(this);
|
||||
if(null!=this.state&&null!=this.linkHint){var a=new mxPoint(this.state.getCenterX(),this.state.getCenterY()),b=new mxRectangle(this.state.x,this.state.y-22,this.state.width+24,this.state.height+22),c=mxUtils.getBoundingBox(b,this.state.style[mxConstants.STYLE_ROTATION]||"0",a),a=null!=c?mxUtils.getBoundingBox(this.state,this.state.style[mxConstants.STYLE_ROTATION]||"0"):this.state,b=null!=this.state.text?this.state.text.boundingBox:null;null==c&&(c=this.state);c=c.y+c.height;null!=b&&(c=Math.max(c,
|
||||
b.y+b.height));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(c+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var H=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){H.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=
|
||||
function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var S=mxEdgeHandler.prototype.redrawHandles;
|
||||
mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(S.apply(this),null!=this.state&&null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.text.bounds&&(a=new mxRectangle(a.x,a.y,a.width,a.height),a.add(this.state.text.bounds));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(a.y+a.height+6+this.state.view.graph.tolerance)+"px"}};var ba=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=
|
||||
function(){ba.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var X=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){X.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),
|
||||
b.y+b.height));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(c+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var G=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){G.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=
|
||||
function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var T=mxEdgeHandler.prototype.redrawHandles;
|
||||
mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(T.apply(this),null!=this.state&&null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.text.bounds&&(a=new mxRectangle(a.x,a.y,a.width,a.height),a.add(this.state.text.bounds));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(a.y+a.height+6+this.state.view.graph.tolerance)+"px"}};var ca=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=
|
||||
function(){ca.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var W=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){W.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),
|
||||
this.changeHandler=null)}}();(function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function c(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function e(){mxCylinder.call(this)}function f(){mxActor.call(this)}function g(){mxCylinder.call(this)}function h(){mxActor.call(this)}function k(){mxActor.call(this)}function l(){mxActor.call(this)}function m(){mxActor.call(this)}function n(){mxActor.call(this)}function p(){mxActor.call(this)}function r(){mxActor.call(this)}function q(a,b){this.canvas=
|
||||
a;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.defaultVariation=b;this.originalLineTo=this.canvas.lineTo;this.canvas.lineTo=mxUtils.bind(this,q.prototype.lineTo);this.originalMoveTo=this.canvas.moveTo;this.canvas.moveTo=mxUtils.bind(this,q.prototype.moveTo);this.originalClose=this.canvas.close;this.canvas.close=mxUtils.bind(this,q.prototype.close);this.originalQuadTo=this.canvas.quadTo;this.canvas.quadTo=mxUtils.bind(this,q.prototype.quadTo);this.originalCurveTo=this.canvas.curveTo;
|
||||
this.canvas.curveTo=mxUtils.bind(this,q.prototype.curveTo);this.originalArcTo=this.canvas.arcTo;this.canvas.arcTo=mxUtils.bind(this,q.prototype.arcTo)}function t(){mxRectangleShape.call(this)}function z(){mxRectangleShape.call(this)}function w(){mxActor.call(this)}function x(){mxActor.call(this)}function y(){mxActor.call(this)}function u(){mxRectangleShape.call(this)}function D(){mxRectangleShape.call(this)}function F(){mxCylinder.call(this)}function E(){mxShape.call(this)}function B(){mxShape.call(this)}
|
||||
function A(){mxEllipse.call(this)}function C(){mxShape.call(this)}function L(){mxShape.call(this)}function K(){mxRectangleShape.call(this)}function H(){mxShape.call(this)}function V(){mxShape.call(this)}function S(){mxShape.call(this)}function ba(){mxCylinder.call(this)}function X(){mxDoubleEllipse.call(this)}function v(){mxDoubleEllipse.call(this)}function Q(){mxArrowConnector.call(this);this.spacing=0}function G(){mxArrowConnector.call(this);this.spacing=0}function I(){mxActor.call(this)}function ca(){mxRectangleShape.call(this)}
|
||||
function M(){mxActor.call(this)}function J(){mxActor.call(this)}function N(){mxActor.call(this)}function T(){mxActor.call(this)}function ea(){mxActor.call(this)}function aa(){mxActor.call(this)}function P(){mxActor.call(this)}function W(){mxActor.call(this)}function U(){mxActor.call(this)}function O(){mxActor.call(this)}function R(){mxEllipse.call(this)}function fa(){mxEllipse.call(this)}function Y(){mxEllipse.call(this)}function Z(){mxRhombus.call(this)}function wa(){mxEllipse.call(this)}function xa(){mxEllipse.call(this)}
|
||||
function ya(){mxEllipse.call(this)}function pa(){mxEllipse.call(this)}function qa(){mxActor.call(this)}function la(){mxActor.call(this)}function ia(){mxActor.call(this)}function ja(){mxConnector.call(this)}function Ba(a,b,c,d,e,f,g,h,k,l){g+=k;var m=d.clone();d.x-=e*(2*g+k);d.y-=f*(2*g+k);e*=g+k;f*=g+k;return function(){a.ellipse(m.x-e-g,m.y-f-g,2*g,2*g);l?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,
|
||||
Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};a.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?(a=parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale,new mxRectangle(a,a,0,0)):null};mxCellRenderer.registerShape("cube",
|
||||
a);var za=Math.tan(mxUtils.toRadians(30)),ka=(.5-za)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/za);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ka);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ka)*b);a.lineTo(0,.25*b);a.close();a.end()};mxCellRenderer.registerShape("isoRectangle",b);mxUtils.extend(c,mxCylinder);c.prototype.size=20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+za));f?(a.moveTo(0,.25*b),a.lineTo(.5*
|
||||
b,(.5-ka)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ka)*b),a.lineTo(.5*b,(1-ka)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ka),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ka)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.registerShape("isoCube",c);mxUtils.extend(d,mxCylinder);d.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(e/2,Math.round(e/8)+this.strokewidth-1);if(f&&null!=this.fill||!f&&null==this.fill)a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||
|
||||
(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,-b);f||(a.moveTo(0,b),a.curveTo(0,-b/3,d,-b/3,d,b),a.lineTo(d,e-b),a.curveTo(d,e+b/3,0,e+b/3,0,e-b),a.close())};d.prototype.getLabelMargins=function(a){return new mxRectangle(0,2.5*Math.min(a.height/2,Math.round(a.height/8)+this.strokewidth-1)*this.scale,0,0)};mxCellRenderer.registerShape("datastore",
|
||||
d);mxUtils.extend(e,mxCylinder);e.prototype.size=30;e.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(d-b,0),a.lineTo(d-b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.registerShape("note",e);mxUtils.extend(f,mxActor);f.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d/2,.5*e,d,0);a.quadTo(.5*
|
||||
d,e/2,d,e);a.quadTo(d/2,.5*e,0,e);a.quadTo(.5*d,e/2,0,0);a.end()};mxCellRenderer.registerShape("switch",f);mxUtils.extend(g,mxCylinder);g.prototype.tabWidth=60;g.prototype.tabHeight=20;g.prototype.tabPosition="right";g.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"tabWidth",this.tabWidth))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"tabHeight",this.tabHeight))));var g=mxUtils.getValue(this.style,"tabPosition",this.tabPosition);
|
||||
f?"left"==g?(a.moveTo(0,c),a.lineTo(b,c)):(a.moveTo(d-b,c),a.lineTo(d,c)):("left"==g?(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,c),a.lineTo(d,c)):(a.moveTo(0,c),a.lineTo(d-b,c),a.lineTo(d-b,0),a.lineTo(d,0)),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,c),a.close());a.end()};mxCellRenderer.registerShape("folder",g);mxUtils.extend(h,mxActor);h.prototype.size=30;h.prototype.isRoundable=function(){return!0};h.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size)))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("card",h);mxUtils.extend(k,mxActor);k.prototype.size=.4;k.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,b/2);a.quadTo(d/4,1.4*b,d/2,b/2);a.quadTo(3*
|
||||
d/4,b*(1-1.4),d,b/2);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};k.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=mxUtils.getValue(this.style,"size",this.size),c=a.width,d=a.height;if(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)return b*=d,new mxRectangle(a.x,a.y+b,c,d-2*b);b*=c;return new mxRectangle(a.x+b,a.y,c-
|
||||
2*b,d)}return a};mxCellRenderer.registerShape("tape",k);mxUtils.extend(l,mxActor);l.prototype.size=.3;l.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*a.height):null};l.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,0);a.lineTo(d,0);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/
|
||||
4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};mxCellRenderer.registerShape("document",l);var Ea=mxCylinder.prototype.getCylinderSize;mxCylinder.prototype.getCylinderSize=function(a,b,c,d){var e=mxUtils.getValue(this.style,"size");return null!=e?d*Math.max(0,Math.min(1,e)):Ea.apply(this,arguments)};mxCylinder.prototype.getLabelMargins=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=2*mxUtils.getValue(this.style,"size",.15);return new mxRectangle(0,Math.min(this.maxHeight*
|
||||
this.scale,a.height*b),0,0)}return null};mxUtils.extend(m,mxActor);m.prototype.size=.2;m.prototype.isRoundable=function(){return!0};m.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d-b,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("parallelogram",
|
||||
m);mxUtils.extend(n,mxActor);n.prototype.size=.2;n.prototype.isRoundable=function(){return!0};n.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("trapezoid",n);mxUtils.extend(p,mxActor);p.prototype.size=
|
||||
.5;p.prototype.redrawPath=function(a,b,c,d,e){a.setFillColor(null);b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(d,0),new mxPoint(b,0),new mxPoint(b,e/2),new mxPoint(0,e/2),new mxPoint(b,e/2),new mxPoint(b,e),new mxPoint(d,e)],this.isRounded,c,!1);a.end()};mxCellRenderer.registerShape("curlyBracket",p);mxUtils.extend(r,mxActor);r.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.setStrokeWidth(1);a.setFillColor(this.stroke);b=d/5;a.rect(0,0,b,e);a.fillAndStroke();a.rect(2*b,0,b,e);a.fillAndStroke();a.rect(4*b,0,b,e);a.fillAndStroke()};mxCellRenderer.registerShape("parallelMarker",r);q.prototype.moveTo=function(a,b){this.originalMoveTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;this.firstX=a;this.firstY=b};q.prototype.close=function(){null!=this.firstX&&null!=this.firstY&&(this.lineTo(this.firstX,this.firstY),this.originalClose.apply(this.canvas,
|
||||
arguments));this.originalClose.apply(this.canvas,arguments)};q.prototype.quadTo=function(a,b,c,d){this.originalQuadTo.apply(this.canvas,arguments);this.lastX=c;this.lastY=d};q.prototype.curveTo=function(a,b,c,d,e,f){this.originalCurveTo.apply(this.canvas,arguments);this.lastX=e;this.lastY=f};q.prototype.arcTo=function(a,b,c,d,e,f,g){this.originalArcTo.apply(this.canvas,arguments);this.lastX=f;this.lastY=g};q.prototype.lineTo=function(a,b){if(null!=this.lastX&&null!=this.lastY){var c=function(a){return"number"===
|
||||
typeof a?a?0>a?-1:1:a===a?0:NaN:NaN},d=Math.abs(a-this.lastX),e=Math.abs(b-this.lastY),f=Math.sqrt(d*d+e*e);if(2>f){this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;return}var g=Math.round(f/10),h=this.defaultVariation;5>g&&(g=5,h/=3);for(var k=c(a-this.lastX)*d/g,c=c(b-this.lastY)*e/g,d=d/f,e=e/f,f=0;f<g;f++){var l=(Math.random()-.5)*h;this.originalLineTo.call(this.canvas,k*f+this.lastX-l*e,c*f+this.lastY-l*d)}this.originalLineTo.call(this.canvas,a,b)}else this.originalLineTo.apply(this.canvas,
|
||||
arguments);this.lastX=a;this.lastY=b};q.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;this.canvas.curveTo=this.originalCurveTo;this.canvas.arcTo=this.originalArcTo};var Fa=mxShape.prototype.paint;mxShape.prototype.defaultJiggle=1.5;mxShape.prototype.paint=function(a){null!=this.style&&"0"!=mxUtils.getValue(this.style,"comic","0")&&null==a.handHiggle&&(a.handJiggle=
|
||||
new q(a,mxUtils.getValue(this.style,"jiggle",this.defaultJiggle)));Fa.apply(this,arguments);null!=a.handJiggle&&(a.handJiggle.destroy(),delete a.handJiggle)};mxRhombus.prototype.defaultJiggle=2;var Ga=mxRectangleShape.prototype.isHtmlAllowed;mxRectangleShape.prototype.isHtmlAllowed=function(){return(null==this.style||"0"==mxUtils.getValue(this.style,"comic","0"))&&Ga.apply(this,arguments)};var Ha=mxRectangleShape.prototype.paintBackground;mxRectangleShape.prototype.paintBackground=function(a,b,c,
|
||||
d,e){if(null==a.handJiggle)Ha.apply(this,arguments);else{var f=!0;null!=this.style&&(f="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(f||null!=this.fill&&this.fill!=mxConstants.NONE||null!=this.stroke&&this.stroke!=mxConstants.NONE)f||null!=this.fill&&this.fill!=mxConstants.NONE||(a.pointerEvents=!1),a.begin(),this.isRounded?("1"==mxUtils.getValue(this.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?f=Math.min(d/2,Math.min(e/2,mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2)):(f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.min(d*f,e*f)),a.moveTo(b+f,c),a.lineTo(b+d-f,c),a.quadTo(b+d,c,b+d,c+f),a.lineTo(b+d,c+e-f),a.quadTo(b+d,c+e,b+d-f,c+e),a.lineTo(b+f,c+e),a.quadTo(b,c+e,b,c+e-f),a.lineTo(b,c+f),a.quadTo(b,c,b+f,c)):(a.moveTo(b,c),a.lineTo(b+d,c),a.lineTo(b+d,c+e),a.lineTo(b,c+e),a.lineTo(b,c)),a.close(),a.end(),a.fillAndStroke()}};var Ia=mxRectangleShape.prototype.paintForeground;
|
||||
mxRectangleShape.prototype.paintForeground=function(a,b,c,d,e){null==a.handJiggle&&Ia.apply(this,arguments)};mxUtils.extend(t,mxRectangleShape);t.prototype.size=.1;t.prototype.isHtmlAllowed=function(){return!1};t.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,!0)==(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)){var b=a.width,c=a.height;a=new mxRectangle(a.x,a.y,b,c);var d=b*Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var e=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,d=Math.max(d,Math.min(b*e,c*e));a.x+=Math.round(d);a.width-=Math.round(2*d)}return a};t.prototype.paintForeground=function(a,b,c,d,e){var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*
|
||||
mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));f=Math.round(f);a.begin();a.moveTo(b+f,c);a.lineTo(b+f,c+e);a.moveTo(b+d-f,c);a.lineTo(b+d-f,c+e);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("process",t);mxUtils.extend(z,mxRectangleShape);z.prototype.paintBackground=function(a,b,c,d,e){a.setFillColor(mxConstants.NONE);a.rect(b,c,d,e);a.fill()};z.prototype.paintForeground=function(a,b,c,d,e){};mxCellRenderer.registerShape("transparent",
|
||||
z);mxUtils.extend(w,mxHexagon);w.prototype.size=30;w.prototype.position=.5;w.prototype.position2=.5;w.prototype.base=20;w.prototype.getLabelMargins=function(){return new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale)};w.prototype.isRoundable=function(){return!0};w.prototype.redrawPath=function(a,b,c,d,e){b=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",
|
||||
this.size))));var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position",this.position)))),g=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position2",this.position2)))),h=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"base",this.base))));this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-c),new mxPoint(Math.min(d,f+h),e-c),new mxPoint(g,e),new mxPoint(Math.max(0,f),e-c),new mxPoint(0,e-c)],this.isRounded,b,!0,[4])};mxCellRenderer.registerShape("callout",
|
||||
w);mxUtils.extend(x,mxActor);x.prototype.size=.2;x.prototype.fixedSize=20;x.prototype.isRoundable=function(){return!0};x.prototype.redrawPath=function(a,b,c,d,e){b="0"!=mxUtils.getValue(this.style,"fixedSize","0")?Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.fixedSize)))):d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,
|
||||
0),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(0,e),new mxPoint(b,e/2)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("step",x);mxUtils.extend(y,mxHexagon);y.prototype.size=.25;y.prototype.isRoundable=function(){return!0};y.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,
|
||||
0),new mxPoint(d-b,0),new mxPoint(d,.5*e),new mxPoint(d-b,e),new mxPoint(b,e),new mxPoint(0,.5*e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("hexagon",y);mxUtils.extend(u,mxRectangleShape);u.prototype.isHtmlAllowed=function(){return!1};u.prototype.paintForeground=function(a,b,c,d,e){var f=Math.min(d/5,e/5)+1;a.begin();a.moveTo(b+d/2,c+f);a.lineTo(b+d/2,c+e-f);a.moveTo(b+f,c+e/2);a.lineTo(b+d-f,c+e/2);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("plus",
|
||||
u);var Ca=mxRhombus.prototype.paintVertexShape;mxRhombus.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};mxRhombus.prototype.paintVertexShape=function(a,b,c,d,e){Ca.apply(this,arguments);if(!this.outline&&1==this.style["double"]){var f=2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||
|
||||
0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&(a.setShadow(!1),Ca.apply(this,[a,b,c,d,e]))}};mxUtils.extend(D,mxRectangleShape);D.prototype.isHtmlAllowed=function(){return!1};D.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};D.prototype.paintForeground=function(a,b,c,d,e){if(null!=this.style){if(!this.outline&&1==this.style["double"]){var f=
|
||||
Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&mxRectangleShape.prototype.paintBackground.apply(this,arguments)}a.setDashed(!1);var f=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+f]];if(null!=g){var h=this.style["symbol"+f+"Align"],k=this.style["symbol"+f+"VerticalAlign"],l=this.style["symbol"+f+"Width"],m=this.style["symbol"+f+"Height"],ra=this.style["symbol"+f+"Spacing"]||0,n=this.style["symbol"+f+"VSpacing"]||ra,
|
||||
p=this.style["symbol"+f+"ArcSpacing"];null!=p&&(p*=this.getArcSize(d+this.strokewidth,e+this.strokewidth),ra+=p,n+=p);var p=b,q=c,p=h==mxConstants.ALIGN_CENTER?p+(d-l)/2:h==mxConstants.ALIGN_RIGHT?p+(d-l-ra):p+ra,q=k==mxConstants.ALIGN_MIDDLE?q+(e-m)/2:k==mxConstants.ALIGN_BOTTOM?q+(e-m-n):q+n;a.save();h=new g;h.style=this.style;g.prototype.paintVertexShape.call(h,a,p,q,l,m);a.restore()}f++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("ext",
|
||||
D);mxUtils.extend(F,mxCylinder);F.prototype.redrawPath=function(a,b,c,d,e,f){f?(a.moveTo(0,0),a.lineTo(d/2,e/2),a.lineTo(d,0),a.end()):(a.moveTo(0,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(0,e),a.close())};mxCellRenderer.registerShape("message",F);mxUtils.extend(E,mxShape);E.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.ellipse(d/4,0,d/2,e/4);a.fillAndStroke();a.begin();a.moveTo(d/2,e/4);a.lineTo(d/2,2*e/3);a.moveTo(d/2,e/3);a.lineTo(0,e/3);a.moveTo(d/2,e/3);a.lineTo(d,e/3);a.moveTo(d/
|
||||
2,2*e/3);a.lineTo(0,e);a.moveTo(d/2,2*e/3);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlActor",E);mxUtils.extend(B,mxShape);B.prototype.getLabelMargins=function(a){return new mxRectangle(a.width/6,0,0,0)};B.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,e/4);a.lineTo(0,3*e/4);a.end();a.stroke();a.begin();a.moveTo(0,e/2);a.lineTo(d/6,e/2);a.end();a.stroke();a.ellipse(d/6,0,5*d/6,e);a.fillAndStroke()};mxCellRenderer.registerShape("umlBoundary",
|
||||
B);mxUtils.extend(A,mxEllipse);A.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/8,c+e);a.lineTo(b+7*d/8,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("umlEntity",A);mxUtils.extend(C,mxShape);C.prototype.paintVertexShape=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(d,0);a.lineTo(0,e);a.moveTo(0,0);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlDestroy",C);mxUtils.extend(L,mxShape);
|
||||
L.prototype.getLabelBounds=function(a){return new mxRectangle(a.x,a.y+a.height/8,a.width,7*a.height/8)};L.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,0);a.end();a.stroke();a.ellipse(0,e/8,d,7*e/8);a.fillAndStroke()};L.prototype.paintForeground=function(a,b,c,d,e){a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,e/4);a.end();a.stroke()};mxCellRenderer.registerShape("umlControl",L);mxUtils.extend(K,mxRectangleShape);K.prototype.size=
|
||||
40;K.prototype.isHtmlAllowed=function(){return!1};K.prototype.getLabelBounds=function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale));return new mxRectangle(a.x,a.y,a.width,b)};K.prototype.paintBackground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))),g=mxUtils.getValue(this.style,"participant");null==g||null==this.state?mxRectangleShape.prototype.paintBackground.call(this,a,b,
|
||||
c,d,f):(g=this.state.view.graph.cellRenderer.getShape(g),null!=g&&g!=K&&(g=new g,g.apply(this.state),a.save(),g.paintVertexShape(a,b,c,d,f),a.restore()));f<e&&(a.setDashed(!0),a.begin(),a.moveTo(b+d/2,c+f),a.lineTo(b+d/2,c+e),a.end(),a.stroke())};K.prototype.paintForeground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));mxRectangleShape.prototype.paintForeground.call(this,a,b,c,d,Math.min(e,f))};mxCellRenderer.registerShape("umlLifeline",
|
||||
K);mxUtils.extend(H,mxShape);H.prototype.width=60;H.prototype.height=30;H.prototype.corner=10;H.prototype.getLabelMargins=function(a){return new mxRectangle(0,0,a.width-parseFloat(mxUtils.getValue(this.style,"width",this.width)*this.scale),a.height-parseFloat(mxUtils.getValue(this.style,"height",this.height)*this.scale))};H.prototype.paintBackground=function(a,b,c,d,e){var f=this.corner,g=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),h=Math.min(e,Math.max(1.5*
|
||||
function A(){mxEllipse.call(this)}function C(){mxShape.call(this)}function L(){mxShape.call(this)}function K(){mxRectangleShape.call(this)}function G(){mxShape.call(this)}function V(){mxShape.call(this)}function T(){mxShape.call(this)}function ca(){mxShape.call(this)}function W(){mxShape.call(this)}function v(){mxCylinder.call(this)}function R(){mxDoubleEllipse.call(this)}function H(){mxDoubleEllipse.call(this)}function I(){mxArrowConnector.call(this);this.spacing=0}function da(){mxArrowConnector.call(this);
|
||||
this.spacing=0}function N(){mxActor.call(this)}function J(){mxRectangleShape.call(this)}function M(){mxActor.call(this)}function aa(){mxActor.call(this)}function ea(){mxActor.call(this)}function U(){mxActor.call(this)}function P(){mxActor.call(this)}function S(){mxActor.call(this)}function Z(){mxActor.call(this)}function O(){mxActor.call(this)}function Q(){mxActor.call(this)}function fa(){mxActor.call(this)}function X(){mxEllipse.call(this)}function Y(){mxEllipse.call(this)}function pa(){mxEllipse.call(this)}
|
||||
function wa(){mxRhombus.call(this)}function xa(){mxEllipse.call(this)}function ya(){mxEllipse.call(this)}function za(){mxEllipse.call(this)}function qa(){mxEllipse.call(this)}function na(){mxActor.call(this)}function la(){mxActor.call(this)}function ma(){mxActor.call(this)}function ja(){mxConnector.call(this)}function Ca(a,b,c,d,e,f,g,h,k,l){g+=k;var m=d.clone();d.x-=e*(2*g+k);d.y-=f*(2*g+k);e*=g+k;f*=g+k;return function(){a.ellipse(m.x-e-g,m.y-f-g,2*g,2*g);l?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,
|
||||
mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};a.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?(a=parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))*this.scale,new mxRectangle(a,a,0,0)):null};mxCellRenderer.registerShape("cube",a);var Aa=Math.tan(mxUtils.toRadians(30)),ka=(.5-Aa)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/Aa);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ka);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ka)*b);a.lineTo(0,.25*b);a.close();a.end()};mxCellRenderer.registerShape("isoRectangle",b);mxUtils.extend(c,mxCylinder);c.prototype.size=
|
||||
20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+Aa));f?(a.moveTo(0,.25*b),a.lineTo(.5*b,(.5-ka)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ka)*b),a.lineTo(.5*b,(1-ka)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ka),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ka)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.registerShape("isoCube",c);mxUtils.extend(d,mxCylinder);d.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(e/2,Math.round(e/8)+this.strokewidth-
|
||||
1);if(f&&null!=this.fill||!f&&null==this.fill)a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,-b);f||(a.moveTo(0,b),a.curveTo(0,-b/3,d,-b/3,d,b),a.lineTo(d,e-b),a.curveTo(d,e+b/3,0,e+b/3,0,e-b),a.close())};d.prototype.getLabelMargins=function(a){return new mxRectangle(0,2.5*Math.min(a.height/2,Math.round(a.height/
|
||||
8)+this.strokewidth-1)*this.scale,0,0)};mxCellRenderer.registerShape("datastore",d);mxUtils.extend(e,mxCylinder);e.prototype.size=30;e.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(d-b,0),a.lineTo(d-b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.registerShape("note",e);mxUtils.extend(f,mxActor);f.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d/2,.5*e,d,0);a.quadTo(.5*d,e/2,d,e);a.quadTo(d/2,.5*e,0,e);a.quadTo(.5*d,e/2,0,0);a.end()};mxCellRenderer.registerShape("switch",f);mxUtils.extend(g,mxCylinder);g.prototype.tabWidth=60;g.prototype.tabHeight=20;g.prototype.tabPosition="right";g.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"tabWidth",this.tabWidth))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"tabHeight",this.tabHeight))));
|
||||
var g=mxUtils.getValue(this.style,"tabPosition",this.tabPosition);f?"left"==g?(a.moveTo(0,c),a.lineTo(b,c)):(a.moveTo(d-b,c),a.lineTo(d,c)):("left"==g?(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,c),a.lineTo(d,c)):(a.moveTo(0,c),a.lineTo(d-b,c),a.lineTo(d-b,0),a.lineTo(d,0)),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,c),a.close());a.end()};mxCellRenderer.registerShape("folder",g);mxUtils.extend(h,mxActor);h.prototype.size=30;h.prototype.isRoundable=function(){return!0};h.prototype.redrawPath=function(a,b,
|
||||
c,d,e){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("card",h);mxUtils.extend(k,mxActor);k.prototype.size=.4;k.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));a.moveTo(0,b/2);a.quadTo(d/4,1.4*b,d/2,b/2);a.quadTo(3*d/4,b*(1-1.4),d,b/2);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};k.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=mxUtils.getValue(this.style,"size",this.size),c=a.width,d=a.height;if(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)return b*=
|
||||
d,new mxRectangle(a.x,a.y+b,c,d-2*b);b*=c;return new mxRectangle(a.x+b,a.y,c-2*b,d)}return a};mxCellRenderer.registerShape("tape",k);mxUtils.extend(l,mxActor);l.prototype.size=.3;l.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*a.height):null};l.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,
|
||||
0);a.lineTo(d,0);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};mxCellRenderer.registerShape("document",l);var Ha=mxCylinder.prototype.getCylinderSize;mxCylinder.prototype.getCylinderSize=function(a,b,c,d){var e=mxUtils.getValue(this.style,"size");return null!=e?d*Math.max(0,Math.min(1,e)):Ha.apply(this,arguments)};mxCylinder.prototype.getLabelMargins=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=2*mxUtils.getValue(this.style,
|
||||
"size",.15);return new mxRectangle(0,Math.min(this.maxHeight*this.scale,a.height*b),0,0)}return null};mxUtils.extend(m,mxActor);m.prototype.size=.2;m.prototype.isRoundable=function(){return!0};m.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d-b,e)],this.isRounded,
|
||||
c,!0);a.end()};mxCellRenderer.registerShape("parallelogram",m);mxUtils.extend(n,mxActor);n.prototype.size=.2;n.prototype.isRoundable=function(){return!0};n.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("trapezoid",
|
||||
n);mxUtils.extend(p,mxActor);p.prototype.size=.5;p.prototype.redrawPath=function(a,b,c,d,e){a.setFillColor(null);b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(d,0),new mxPoint(b,0),new mxPoint(b,e/2),new mxPoint(0,e/2),new mxPoint(b,e/2),new mxPoint(b,e),new mxPoint(d,e)],this.isRounded,c,!1);a.end()};mxCellRenderer.registerShape("curlyBracket",
|
||||
p);mxUtils.extend(r,mxActor);r.prototype.redrawPath=function(a,b,c,d,e){a.setStrokeWidth(1);a.setFillColor(this.stroke);b=d/5;a.rect(0,0,b,e);a.fillAndStroke();a.rect(2*b,0,b,e);a.fillAndStroke();a.rect(4*b,0,b,e);a.fillAndStroke()};mxCellRenderer.registerShape("parallelMarker",r);q.prototype.moveTo=function(a,b){this.originalMoveTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;this.firstX=a;this.firstY=b};q.prototype.close=function(){null!=this.firstX&&null!=this.firstY&&(this.lineTo(this.firstX,
|
||||
this.firstY),this.originalClose.apply(this.canvas,arguments));this.originalClose.apply(this.canvas,arguments)};q.prototype.quadTo=function(a,b,c,d){this.originalQuadTo.apply(this.canvas,arguments);this.lastX=c;this.lastY=d};q.prototype.curveTo=function(a,b,c,d,e,f){this.originalCurveTo.apply(this.canvas,arguments);this.lastX=e;this.lastY=f};q.prototype.arcTo=function(a,b,c,d,e,f,g){this.originalArcTo.apply(this.canvas,arguments);this.lastX=f;this.lastY=g};q.prototype.lineTo=function(a,b){if(null!=
|
||||
this.lastX&&null!=this.lastY){var c=function(a){return"number"===typeof a?a?0>a?-1:1:a===a?0:NaN:NaN},d=Math.abs(a-this.lastX),e=Math.abs(b-this.lastY),f=Math.sqrt(d*d+e*e);if(2>f){this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;return}var g=Math.round(f/10),h=this.defaultVariation;5>g&&(g=5,h/=3);for(var k=c(a-this.lastX)*d/g,c=c(b-this.lastY)*e/g,d=d/f,e=e/f,f=0;f<g;f++){var l=(Math.random()-.5)*h;this.originalLineTo.call(this.canvas,k*f+this.lastX-l*e,c*f+this.lastY-
|
||||
l*d)}this.originalLineTo.call(this.canvas,a,b)}else this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b};q.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;this.canvas.curveTo=this.originalCurveTo;this.canvas.arcTo=this.originalArcTo};var Ia=mxShape.prototype.paint;mxShape.prototype.defaultJiggle=1.5;mxShape.prototype.paint=function(a){null!=
|
||||
this.style&&"0"!=mxUtils.getValue(this.style,"comic","0")&&null==a.handHiggle&&(a.handJiggle=new q(a,mxUtils.getValue(this.style,"jiggle",this.defaultJiggle)));Ia.apply(this,arguments);null!=a.handJiggle&&(a.handJiggle.destroy(),delete a.handJiggle)};mxRhombus.prototype.defaultJiggle=2;var Ja=mxRectangleShape.prototype.isHtmlAllowed;mxRectangleShape.prototype.isHtmlAllowed=function(){return(null==this.style||"0"==mxUtils.getValue(this.style,"comic","0"))&&Ja.apply(this,arguments)};var Ka=mxRectangleShape.prototype.paintBackground;
|
||||
mxRectangleShape.prototype.paintBackground=function(a,b,c,d,e){if(null==a.handJiggle)Ka.apply(this,arguments);else{var f=!0;null!=this.style&&(f="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(f||null!=this.fill&&this.fill!=mxConstants.NONE||null!=this.stroke&&this.stroke!=mxConstants.NONE)f||null!=this.fill&&this.fill!=mxConstants.NONE||(a.pointerEvents=!1),a.begin(),this.isRounded?("1"==mxUtils.getValue(this.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?f=Math.min(d/2,Math.min(e/
|
||||
2,mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2)):(f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.min(d*f,e*f)),a.moveTo(b+f,c),a.lineTo(b+d-f,c),a.quadTo(b+d,c,b+d,c+f),a.lineTo(b+d,c+e-f),a.quadTo(b+d,c+e,b+d-f,c+e),a.lineTo(b+f,c+e),a.quadTo(b,c+e,b,c+e-f),a.lineTo(b,c+f),a.quadTo(b,c,b+f,c)):(a.moveTo(b,c),a.lineTo(b+d,c),a.lineTo(b+d,c+e),a.lineTo(b,c+e),a.lineTo(b,c)),a.close(),a.end(),a.fillAndStroke()}};
|
||||
var Da=mxRectangleShape.prototype.paintForeground;mxRectangleShape.prototype.paintForeground=function(a,b,c,d,e){null==a.handJiggle&&Da.apply(this,arguments)};mxUtils.extend(t,mxRectangleShape);t.prototype.size=.1;t.prototype.isHtmlAllowed=function(){return!1};t.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,!0)==(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)){var b=a.width,c=a.height;
|
||||
a=new mxRectangle(a.x,a.y,b,c);var d=b*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var e=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,d=Math.max(d,Math.min(b*e,c*e));a.x+=Math.round(d);a.width-=Math.round(2*d)}return a};t.prototype.paintForeground=function(a,b,c,d,e){var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var g=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));f=Math.round(f);a.begin();a.moveTo(b+f,c);a.lineTo(b+f,c+e);a.moveTo(b+d-f,c);a.lineTo(b+d-f,c+e);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("process",t);mxUtils.extend(z,mxRectangleShape);z.prototype.paintBackground=function(a,b,c,d,e){a.setFillColor(mxConstants.NONE);a.rect(b,c,d,e);a.fill()};z.prototype.paintForeground=function(a,
|
||||
b,c,d,e){};mxCellRenderer.registerShape("transparent",z);mxUtils.extend(w,mxHexagon);w.prototype.size=30;w.prototype.position=.5;w.prototype.position2=.5;w.prototype.base=20;w.prototype.getLabelMargins=function(){return new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale)};w.prototype.isRoundable=function(){return!0};w.prototype.redrawPath=function(a,b,c,d,e){b=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;c=Math.max(0,Math.min(e,
|
||||
parseFloat(mxUtils.getValue(this.style,"size",this.size))));var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position",this.position)))),g=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position2",this.position2)))),h=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"base",this.base))));this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-c),new mxPoint(Math.min(d,f+h),e-c),new mxPoint(g,e),new mxPoint(Math.max(0,f),e-c),new mxPoint(0,
|
||||
e-c)],this.isRounded,b,!0,[4])};mxCellRenderer.registerShape("callout",w);mxUtils.extend(x,mxActor);x.prototype.size=.2;x.prototype.fixedSize=20;x.prototype.isRoundable=function(){return!0};x.prototype.redrawPath=function(a,b,c,d,e){b="0"!=mxUtils.getValue(this.style,"fixedSize","0")?Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.fixedSize)))):d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(0,e),new mxPoint(b,e/2)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("step",x);mxUtils.extend(y,mxHexagon);y.prototype.size=.25;y.prototype.isRoundable=function(){return!0};y.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.5*e),new mxPoint(d-b,e),new mxPoint(b,e),new mxPoint(0,.5*e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("hexagon",y);mxUtils.extend(u,mxRectangleShape);u.prototype.isHtmlAllowed=function(){return!1};u.prototype.paintForeground=function(a,b,c,d,e){var f=Math.min(d/5,e/5)+1;a.begin();a.moveTo(b+d/2,c+f);a.lineTo(b+d/2,c+e-f);a.moveTo(b+f,c+e/2);a.lineTo(b+d-f,c+e/2);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,
|
||||
arguments)};mxCellRenderer.registerShape("plus",u);var Ea=mxRhombus.prototype.paintVertexShape;mxRhombus.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};mxRhombus.prototype.paintVertexShape=function(a,b,c,d,e){Ea.apply(this,arguments);if(!this.outline&&1==this.style["double"]){var f=2*Math.max(2,this.strokewidth+
|
||||
1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&(a.setShadow(!1),Ea.apply(this,[a,b,c,d,e]))}};mxUtils.extend(D,mxRectangleShape);D.prototype.isHtmlAllowed=function(){return!1};D.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};D.prototype.paintForeground=function(a,b,c,
|
||||
d,e){if(null!=this.style){if(!this.outline&&1==this.style["double"]){var f=Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&mxRectangleShape.prototype.paintBackground.apply(this,arguments)}a.setDashed(!1);var f=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+f]];if(null!=g){var h=this.style["symbol"+f+"Align"],k=this.style["symbol"+f+"VerticalAlign"],l=this.style["symbol"+f+"Width"],m=this.style["symbol"+f+"Height"],ra=
|
||||
this.style["symbol"+f+"Spacing"]||0,n=this.style["symbol"+f+"VSpacing"]||ra,p=this.style["symbol"+f+"ArcSpacing"];null!=p&&(p*=this.getArcSize(d+this.strokewidth,e+this.strokewidth),ra+=p,n+=p);var p=b,q=c,p=h==mxConstants.ALIGN_CENTER?p+(d-l)/2:h==mxConstants.ALIGN_RIGHT?p+(d-l-ra):p+ra,q=k==mxConstants.ALIGN_MIDDLE?q+(e-m)/2:k==mxConstants.ALIGN_BOTTOM?q+(e-m-n):q+n;a.save();h=new g;h.style=this.style;g.prototype.paintVertexShape.call(h,a,p,q,l,m);a.restore()}f++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,
|
||||
arguments)};mxCellRenderer.registerShape("ext",D);mxUtils.extend(F,mxCylinder);F.prototype.redrawPath=function(a,b,c,d,e,f){f?(a.moveTo(0,0),a.lineTo(d/2,e/2),a.lineTo(d,0),a.end()):(a.moveTo(0,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(0,e),a.close())};mxCellRenderer.registerShape("message",F);mxUtils.extend(E,mxShape);E.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.ellipse(d/4,0,d/2,e/4);a.fillAndStroke();a.begin();a.moveTo(d/2,e/4);a.lineTo(d/2,2*e/3);a.moveTo(d/2,e/3);a.lineTo(0,
|
||||
e/3);a.moveTo(d/2,e/3);a.lineTo(d,e/3);a.moveTo(d/2,2*e/3);a.lineTo(0,e);a.moveTo(d/2,2*e/3);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlActor",E);mxUtils.extend(B,mxShape);B.prototype.getLabelMargins=function(a){return new mxRectangle(a.width/6,0,0,0)};B.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,e/4);a.lineTo(0,3*e/4);a.end();a.stroke();a.begin();a.moveTo(0,e/2);a.lineTo(d/6,e/2);a.end();a.stroke();a.ellipse(d/6,0,5*d/6,e);a.fillAndStroke()};
|
||||
mxCellRenderer.registerShape("umlBoundary",B);mxUtils.extend(A,mxEllipse);A.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/8,c+e);a.lineTo(b+7*d/8,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("umlEntity",A);mxUtils.extend(C,mxShape);C.prototype.paintVertexShape=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(d,0);a.lineTo(0,e);a.moveTo(0,0);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlDestroy",
|
||||
C);mxUtils.extend(L,mxShape);L.prototype.getLabelBounds=function(a){return new mxRectangle(a.x,a.y+a.height/8,a.width,7*a.height/8)};L.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,0);a.end();a.stroke();a.ellipse(0,e/8,d,7*e/8);a.fillAndStroke()};L.prototype.paintForeground=function(a,b,c,d,e){a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,e/4);a.end();a.stroke()};mxCellRenderer.registerShape("umlControl",L);mxUtils.extend(K,mxRectangleShape);
|
||||
K.prototype.size=40;K.prototype.isHtmlAllowed=function(){return!1};K.prototype.getLabelBounds=function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale));return new mxRectangle(a.x,a.y,a.width,b)};K.prototype.paintBackground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))),g=mxUtils.getValue(this.style,"participant");null==g||null==this.state?mxRectangleShape.prototype.paintBackground.call(this,
|
||||
a,b,c,d,f):(g=this.state.view.graph.cellRenderer.getShape(g),null!=g&&g!=K&&(g=new g,g.apply(this.state),a.save(),g.paintVertexShape(a,b,c,d,f),a.restore()));f<e&&(a.setDashed(!0),a.begin(),a.moveTo(b+d/2,c+f),a.lineTo(b+d/2,c+e),a.end(),a.stroke())};K.prototype.paintForeground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));mxRectangleShape.prototype.paintForeground.call(this,a,b,c,d,Math.min(e,f))};mxCellRenderer.registerShape("umlLifeline",
|
||||
K);mxUtils.extend(G,mxShape);G.prototype.width=60;G.prototype.height=30;G.prototype.corner=10;G.prototype.getLabelMargins=function(a){return new mxRectangle(0,0,a.width-parseFloat(mxUtils.getValue(this.style,"width",this.width)*this.scale),a.height-parseFloat(mxUtils.getValue(this.style,"height",this.height)*this.scale))};G.prototype.paintBackground=function(a,b,c,d,e){var f=this.corner,g=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),h=Math.min(e,Math.max(1.5*
|
||||
f,parseFloat(mxUtils.getValue(this.style,"height",this.height)))),k=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE);k!=mxConstants.NONE&&(a.setFillColor(k),a.rect(b,c,d,e),a.fill());null!=this.fill&&this.fill!=mxConstants.NONE&&this.gradient&&this.gradient!=mxConstants.NONE?(this.getGradientBounds(a,b,c,d,e),a.setGradient(this.fill,this.gradient,b,c,d,e,this.gradientDirection)):a.setFillColor(this.fill);a.begin();a.moveTo(b,c);a.lineTo(b+g,c);a.lineTo(b+g,c+Math.max(0,
|
||||
h-1.5*f));a.lineTo(b+Math.max(0,g-f),c+h);a.lineTo(b,c+h);a.close();a.fillAndStroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+h);a.stroke()};mxCellRenderer.registerShape("umlFrame",H);mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=K.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+
|
||||
h-1.5*f));a.lineTo(b+Math.max(0,g-f),c+h);a.lineTo(b,c+h);a.close();a.fillAndStroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+h);a.stroke()};mxCellRenderer.registerShape("umlFrame",G);mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=K.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+
|
||||
b,Math.min(a.y+a.height,Math.max(a.y+d,c.y)))};mxStyleRegistry.putValue("lifelinePerimeter",mxPerimeter.LifelinePerimeter);mxPerimeter.OrthogonalPerimeter=function(a,b,c,d){d=!0;return mxPerimeter.RectanglePerimeter.apply(this,arguments)};mxStyleRegistry.putValue("orthogonalPerimeter",mxPerimeter.OrthogonalPerimeter);mxPerimeter.BackbonePerimeter=function(a,b,c,d){d=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;null!=b.style.backboneSize&&(d+=parseFloat(b.style.backboneSize)*
|
||||
b.view.scale/2-1);if("south"==b.style[mxConstants.STYLE_DIRECTION]||"north"==b.style[mxConstants.STYLE_DIRECTION])return c.x<a.getCenterX()&&(d=-1*(d+1)),new mxPoint(a.getCenterX()+d,Math.min(a.y+a.height,Math.max(a.y,c.y)));c.y<a.getCenterY()&&(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxPerimeter.CalloutPerimeter=function(a,b,c,d){return mxPerimeter.RectanglePerimeter(mxUtils.getDirectedBounds(a,
|
||||
new mxRectangle(0,0,0,Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(b.style,"size",w.prototype.size))*b.view.scale))),b.style),b,c,d)};mxStyleRegistry.putValue("calloutPerimeter",mxPerimeter.CalloutPerimeter);mxPerimeter.ParallelogramPerimeter=function(a,b,c,d){var e=m.prototype.size;null!=b&&(e=mxUtils.getValue(b.style,"size",e));var f=a.x,g=a.y,h=a.width,k=a.height;b=null!=b?mxUtils.getValue(b.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;b==
|
||||
|
@ -1833,93 +1833,95 @@ b==mxConstants.DIRECTION_EAST?(e=e?Math.max(0,Math.min(k,f)):k*Math.max(0,Math.m
|
|||
Math.min(l,f)):l*Math.max(0,Math.min(1,f)),h=[new mxPoint(g,h+e),new mxPoint(m,h),new mxPoint(g+k,h+e),new mxPoint(g+k,h+l),new mxPoint(m,h+l-e),new mxPoint(g,h+l),new mxPoint(g,h+e)]):(e=e?Math.max(0,Math.min(l,f)):l*Math.max(0,Math.min(1,f)),h=[new mxPoint(g,h),new mxPoint(m,h+e),new mxPoint(g+k,h),new mxPoint(g+k,h+l-e),new mxPoint(m,h+l),new mxPoint(g,h+l-e),new mxPoint(g,h)]);m=new mxPoint(m,a);d&&(c.x<g||c.x>g+k?m.y=c.y:m.x=c.x);return mxUtils.getPerimeterPoint(h,m,c)};mxStyleRegistry.putValue("stepPerimeter",
|
||||
mxPerimeter.StepPerimeter);mxPerimeter.HexagonPerimeter2=function(a,b,c,d){var e=y.prototype.size;null!=b&&(e=mxUtils.getValue(b.style,"size",e));var f=a.x,g=a.y,h=a.width,k=a.height,l=a.getCenterX();a=a.getCenterY();b=null!=b?mxUtils.getValue(b.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;b==mxConstants.DIRECTION_NORTH||b==mxConstants.DIRECTION_SOUTH?(e=k*Math.max(0,Math.min(1,e)),g=[new mxPoint(l,g),new mxPoint(f+h,g+e),new mxPoint(f+h,g+k-e),new mxPoint(l,
|
||||
g+k),new mxPoint(f,g+k-e),new mxPoint(f,g+e),new mxPoint(l,g)]):(e=h*Math.max(0,Math.min(1,e)),g=[new mxPoint(f+e,g),new mxPoint(f+h-e,g),new mxPoint(f+h,a),new mxPoint(f+h-e,g+k),new mxPoint(f+e,g+k),new mxPoint(f,a),new mxPoint(f+e,g)]);l=new mxPoint(l,a);d&&(c.x<f||c.x>f+h?l.y=c.y:l.x=c.x);return mxUtils.getPerimeterPoint(g,l,c)};mxStyleRegistry.putValue("hexagonPerimeter2",mxPerimeter.HexagonPerimeter2);mxUtils.extend(V,mxShape);V.prototype.size=10;V.prototype.paintBackground=function(a,b,c,d,
|
||||
e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",V);mxUtils.extend(S,mxShape);S.prototype.size=10;S.prototype.inset=2;S.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),g=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,
|
||||
c);a.begin();a.moveTo(d/2,f+g);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-g,f/2);a.quadTo((d-f)/2-g,f+g,d/2,f+g);a.quadTo((d+f)/2+g,f+g,(d+f)/2+g,f/2);a.end();a.stroke()};mxCellRenderer.registerShape("requires",S);mxUtils.extend(ba,mxCylinder);ba.prototype.jettyWidth=32;ba.prototype.jettyHeight=12;ba.prototype.redrawPath=function(a,b,c,d,e,f){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));
|
||||
c=g/2;var g=c+g/2,h=.3*e-b/2,k=.7*e-b/2;f?(a.moveTo(c,h),a.lineTo(g,h),a.lineTo(g,h+b),a.lineTo(c,h+b),a.moveTo(c,k),a.lineTo(g,k),a.lineTo(g,k+b),a.lineTo(c,k+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,k+b),a.lineTo(0,k+b),a.lineTo(0,k),a.lineTo(c,k),a.lineTo(c,h+b),a.lineTo(0,h+b),a.lineTo(0,h),a.lineTo(c,h),a.close());a.end()};mxCellRenderer.registerShape("component",ba);mxUtils.extend(X,mxDoubleEllipse);X.prototype.outerStroke=!0;X.prototype.paintVertexShape=function(a,
|
||||
b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.registerShape("endState",X);mxUtils.extend(v,X);v.prototype.outerStroke=!1;mxCellRenderer.registerShape("startState",v);mxUtils.extend(Q,mxArrowConnector);Q.prototype.defaultWidth=4;Q.prototype.isOpenEnded=function(){return!0};Q.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+
|
||||
Math.max(0,this.strokewidth-1)};Q.prototype.isArrowRounded=function(){return this.isRounded};mxCellRenderer.registerShape("link",Q);mxUtils.extend(G,mxArrowConnector);G.prototype.defaultWidth=10;G.prototype.defaultArrowWidth=20;G.prototype.getStartArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"startWidth",this.defaultArrowWidth)};G.prototype.getEndArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"endWidth",this.defaultArrowWidth)};G.prototype.getEdgeWidth=
|
||||
function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};mxCellRenderer.registerShape("flexArrow",G);mxUtils.extend(I,mxActor);I.prototype.size=30;I.prototype.isRoundable=function(){return!0};I.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(0,b),new mxPoint(d,
|
||||
0),new mxPoint(d,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("manualInput",I);mxUtils.extend(ca,mxRectangleShape);ca.prototype.dx=20;ca.prototype.dy=20;ca.prototype.isHtmlAllowed=function(){return!1};ca.prototype.paintForeground=function(a,b,c,d,e){mxRectangleShape.prototype.paintForeground.apply(this,arguments);var f=0;if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));g=Math.max(f,
|
||||
Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));f=Math.max(f,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));a.begin();a.moveTo(b,c+f);a.lineTo(b+d,c+f);a.end();a.stroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+g,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("internalStorage",ca);mxUtils.extend(M,mxActor);M.prototype.dx=20;M.prototype.dy=20;M.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));
|
||||
c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint(b,c),new mxPoint(b,e),new mxPoint(0,e)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("corner",M);mxUtils.extend(J,mxActor);J.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);
|
||||
a.lineTo(0,e);a.end();a.moveTo(d,0);a.lineTo(d,e);a.end();a.moveTo(0,e/2);a.lineTo(d,e/2);a.end()};mxCellRenderer.registerShape("crossbar",J);mxUtils.extend(N,mxActor);N.prototype.dx=20;N.prototype.dy=20;N.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("tee",N);mxUtils.extend(T,mxActor);T.prototype.arrowWidth=.3;T.prototype.arrowSize=.2;T.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",this.arrowWidth))));b=d*
|
||||
Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("singleArrow",T);mxUtils.extend(ea,mxActor);ea.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",T.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",T.prototype.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,
|
||||
g,!0);a.end()};mxCellRenderer.registerShape("doubleArrow",ea);mxUtils.extend(aa,mxActor);aa.prototype.size=.1;aa.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.registerShape("dataStorage",aa);mxUtils.extend(P,mxActor);P.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,
|
||||
e,0,e);a.close();a.end()};mxCellRenderer.registerShape("or",P);mxUtils.extend(W,mxActor);W.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.registerShape("xor",W);mxUtils.extend(U,mxActor);U.prototype.size=20;U.prototype.isRoundable=function(){return!0};U.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("loopLimit",U);mxUtils.extend(O,mxActor);O.prototype.size=.375;O.prototype.isRoundable=function(){return!0};O.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("offPageConnector",O);mxUtils.extend(R,mxEllipse);R.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("tapeData",R);mxUtils.extend(fa,
|
||||
mxEllipse);fa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke();a.begin();a.moveTo(b+d/2,c);a.lineTo(b+d/2,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("orEllipse",fa);mxUtils.extend(Y,mxEllipse);Y.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b+.145*d,c+.145*
|
||||
e);a.lineTo(b+.855*d,c+.855*e);a.end();a.stroke();a.begin();a.moveTo(b+.855*d,c+.145*e);a.lineTo(b+.145*d,c+.855*e);a.end();a.stroke()};mxCellRenderer.registerShape("sumEllipse",Y);mxUtils.extend(Z,mxRhombus);Z.prototype.paintVertexShape=function(a,b,c,d,e){mxRhombus.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke()};mxCellRenderer.registerShape("sortShape",Z);mxUtils.extend(wa,mxEllipse);wa.prototype.paintVertexShape=
|
||||
function(a,b,c,d,e){a.begin();a.moveTo(b,c);a.lineTo(b+d,c);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke();a.begin();a.moveTo(b,c+e);a.lineTo(b+d,c+e);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke()};mxCellRenderer.registerShape("collate",wa);mxUtils.extend(xa,mxEllipse);xa.prototype.paintVertexShape=function(a,b,c,d,e){var f=c+e-5;a.begin();a.moveTo(b,c);a.lineTo(b,c+e);a.moveTo(b,f);a.lineTo(b+10,f-5);a.moveTo(b,f);a.lineTo(b+10,f+5);a.moveTo(b,f);a.lineTo(b+d,f);a.moveTo(b+d,c);a.lineTo(b+
|
||||
d,c+e);a.moveTo(b+d,f);a.lineTo(b+d-10,f-5);a.moveTo(b+d,f);a.lineTo(b+d-10,f+5);a.end();a.stroke()};mxCellRenderer.registerShape("dimension",xa);mxUtils.extend(ya,mxEllipse);ya.prototype.paintVertexShape=function(a,b,c,d,e){this.outline||a.setStrokeColor(null);mxRectangleShape.prototype.paintBackground.apply(this,arguments);null!=this.style&&(a.setStrokeColor(this.stroke),a.rect(b,c,d,e),a.fill(),a.begin(),a.moveTo(b,c),"1"==mxUtils.getValue(this.style,"top","1")?a.lineTo(b+d,c):a.moveTo(b+d,c),
|
||||
"1"==mxUtils.getValue(this.style,"right","1")?a.lineTo(b+d,c+e):a.moveTo(b+d,c+e),"1"==mxUtils.getValue(this.style,"bottom","1")?a.lineTo(b,c+e):a.moveTo(b,c+e),"1"==mxUtils.getValue(this.style,"left","1")&&a.lineTo(b,c-this.strokewidth/2),a.end(),a.stroke())};mxCellRenderer.registerShape("partialRectangle",ya);mxUtils.extend(pa,mxEllipse);pa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();"vertical"==mxUtils.getValue(this.style,
|
||||
"line")?(a.moveTo(b+d/2,c),a.lineTo(b+d/2,c+e)):(a.moveTo(b,c+e/2),a.lineTo(b+d,c+e/2));a.end();a.stroke()};mxCellRenderer.registerShape("lineEllipse",pa);mxUtils.extend(qa,mxActor);qa.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);a.moveTo(0,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(0,e);a.close();a.end()};mxCellRenderer.registerShape("delay",qa);mxUtils.extend(la,mxActor);la.prototype.size=.2;la.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,d);var f=
|
||||
Math.max(0,Math.min(b,b*parseFloat(mxUtils.getValue(this.style,"size",this.size))));b=(e-f)/2;c=b+f;var g=(d-f)/2,f=g+f;a.moveTo(0,b);a.lineTo(g,b);a.lineTo(g,0);a.lineTo(f,0);a.lineTo(f,b);a.lineTo(d,b);a.lineTo(d,c);a.lineTo(f,c);a.lineTo(f,e);a.lineTo(g,e);a.lineTo(g,c);a.lineTo(0,c);a.close();a.end()};mxCellRenderer.registerShape("cross",la);mxUtils.extend(ia,mxActor);ia.prototype.size=.25;ia.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);c=Math.min(d-b,Math.max(0,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size)))*d);a.moveTo(0,e/2);a.lineTo(c,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(c,e);a.close();a.end()};mxCellRenderer.registerShape("display",ia);mxUtils.extend(ja,mxConnector);ja.prototype.origPaintEdgeShape=ja.prototype.paintEdgeShape;ja.prototype.paintEdgeShape=function(a,b,c){for(var d=[],e=0;e<b.length;e++)d.push(mxUtils.clone(b[e]));var e=a.state.dashed,f=a.state.fixDash;ja.prototype.origPaintEdgeShape.apply(this,[a,d,c]);3<=a.state.strokeWidth&&(d=mxUtils.getValue(this.style,
|
||||
"fillColor",null),null!=d&&(a.setStrokeColor(d),a.setStrokeWidth(a.state.strokeWidth-2),a.setDashed(e,f),ja.prototype.origPaintEdgeShape.apply(this,[a,b,c])))};mxCellRenderer.registerShape("filledEdge",ja);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var b=this.format.getSelectionState(),c=a.apply(this,arguments);"umlFrame"==b.style.shape&&c.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",
|
||||
defaultValue:"#ffffff"});return c}}();mxMarker.addMarker("dash",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.stroke()}});mxMarker.addMarker("cross",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.moveTo(d.x-m/2+n/2,d.y-n/2-m/2);a.lineTo(d.x-n/2-3*m/2,d.y-3*n/2+m/2);a.stroke()}});
|
||||
mxMarker.addMarker("circle",Ba);mxMarker.addMarker("circlePlus",function(a,b,c,d,e,f,g,h,k,l){var m=d.clone(),n=Ba.apply(this,arguments),p=e*(g+2*k),q=f*(g+2*k);return function(){n.apply(this,arguments);a.begin();a.moveTo(m.x-e*k,m.y-f*k);a.lineTo(m.x-2*p+e*k,m.y-2*q+f*k);a.moveTo(m.x-p-q+f*k,m.y-q+p-e*k);a.lineTo(m.x+q-p-f*k,m.y-q-p+e*k);a.stroke()}});mxMarker.addMarker("async",function(a,b,c,d,e,f,g,h,k,l){b=e*k*1.118;c=f*k*1.118;e*=g+k;f*=g+k;var m=d.clone();m.x-=b;m.y-=c;d.x+=1*-e-b;d.y+=1*-f-
|
||||
c;return function(){a.begin();a.moveTo(m.x,m.y);h?a.lineTo(m.x-e-f/2,m.y-f+e/2):a.lineTo(m.x+f/2-e,m.y-f-e/2);a.lineTo(m.x-e,m.y-f);a.close();l?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(b,c,d,e,f,g,h,k,l,m){f*=h+l;g*=h+l;var n=e.clone();return function(){b.begin();b.moveTo(n.x,n.y);k?b.lineTo(n.x-f-g/a,n.y-g+f/a):b.lineTo(n.x+g/a-f,n.y-g-f/a);b.stroke()}}}(2));if("undefined"!==typeof mxVertexHandler){var Aa=function(a,b,c){return na(a,
|
||||
["width"],b,function(b,d,e,f,g){g=a.shape.getEdgeWidth()*a.view.scale+c;return new mxPoint(f.x+d*b/4+e*g/2,f.y+e*b/4-d*g/2)},function(b,d,e,f,g,h){b=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));a.style.width=Math.round(2*b)/a.view.scale-c})},na=function(a,b,c,d,e){return da(a,b,function(b){var e=a.absolutePoints,f=e.length-1;b=a.view.translate;var g=a.view.scale,h=c?e[0]:e[f],e=c?e[1]:e[f-1],f=e.x-h.x,k=e.y-h.y,l=Math.sqrt(f*f+k*k),h=d.call(this,l,f/l,k/l,h,e);return new mxPoint(h.x/g-
|
||||
b.x,h.y/g-b.y)},function(b,d,f){var g=a.absolutePoints,h=g.length-1;b=a.view.translate;var k=a.view.scale,l=c?g[0]:g[h],g=c?g[1]:g[h-1],h=g.x-l.x,m=g.y-l.y,n=Math.sqrt(h*h+m*m);d.x=(d.x+b.x)*k;d.y=(d.y+b.y)*k;e.call(this,n,h/n,m/n,l,g,d,f)})},ha=function(a){return function(b){return[da(b,["arrowWidth","arrowSize"],function(b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",T.prototype.arrowWidth))),d=Math.max(0,Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",T.prototype.arrowSize)));
|
||||
return new mxPoint(b.x+(1-d)*b.width,b.y+(1-c)*b.height/2)},function(b,c){this.state.style.arrowWidth=Math.max(0,Math.min(1,Math.abs(b.y+b.height/2-c.y)/b.height*2));this.state.style.arrowSize=Math.max(0,Math.min(a,(b.x+b.width-c.x)/b.width))})]}},ma=function(a,b,c){return function(d){var e=[da(d,["size"],function(c){var d=Math.max(0,Math.min(c.width,Math.min(c.height,parseFloat(mxUtils.getValue(this.state.style,"size",b)))))*a;return new mxPoint(c.x+d,c.y+d)},function(b,c){this.state.style.size=
|
||||
Math.round(Math.max(0,Math.min(Math.min(b.width,c.x-b.x),Math.min(b.height,c.y-b.y)))/a)})];c&&mxUtils.getValue(d.style,mxConstants.STYLE_ROUNDED,!1)&&e.push(ga(d));return e}},sa=function(a,b,c,d,e){c=null!=c?c:1;return function(f){var g=[da(f,["size"],function(b){var c=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null,d=parseFloat(mxUtils.getValue(this.state.style,"size",c?e:a));return new mxPoint(b.x+Math.max(0,Math.min(b.width,d*(c?1:b.width))),b.getCenterY())},function(a,b,
|
||||
d){var g=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null;a=g?b.x-a.x:Math.max(0,Math.min(c,(b.x-a.x)/a.width));g&&!mxEvent.isAltDown(d.getEvent())&&(a=f.view.graph.snap(a));this.state.style.size=a},null,d)];b&&mxUtils.getValue(f.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(ga(f));return g}},Da=function(a){return function(b){var c=[da(b,["size"],function(b){var c=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,"size",n.prototype.size))));return new mxPoint(b.x+
|
||||
c*b.width*.75,b.y+b.height/4)},function(b,c){this.state.style.size=Math.max(0,Math.min(a,(c.x-b.x)/(.75*b.width)))},null,!0)];mxUtils.getValue(b.style,mxConstants.STYLE_ROUNDED,!1)&&c.push(ga(b));return c}},oa=function(){return function(a){var b=[];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b}},ga=function(a,b){return da(a,[mxConstants.STYLE_ARCSIZE],function(c){var d=null!=b?b:c.height/8;if("1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)){var e=
|
||||
mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;return new mxPoint(c.x+c.width-Math.min(c.width/2,e),c.y+d)}e=Math.max(0,parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)))/100;return new mxPoint(c.x+c.width-Math.min(Math.max(c.width/2,c.height/2),Math.min(c.width,c.height)*e),c.y+d)},function(b,c,d){"1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.max(0,
|
||||
Math.min(b.width,2*(b.x+b.width-c.x)))):this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.min(50,Math.max(0,100*(b.width-c.x+b.x)/Math.min(b.width,b.height))))})},da=function(a,b,c,d,e,f){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<b.length;a++)this.copyStyle(b[a])};g.getPosition=c;g.setPosition=d;g.ignoreGrid=null!=e?e:!0;if(f){var h=g.positionChanged;g.positionChanged=function(){h.apply(this,arguments);a.view.invalidate(this.state.cell);
|
||||
a.view.validate()}}return g},ta={link:function(a){return[Aa(a,!0,10),Aa(a,!1,10)]},flexArrow:function(a){var b=a.view.graph.gridSize/a.view.scale,c=[];mxUtils.getValue(a.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(na(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+
|
||||
c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(k.getEvent())||
|
||||
Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),c.push(na(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*
|
||||
a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=
|
||||
a.style.startWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]),Math.abs(parseFloat(a.style.startWidth)-parseFloat(a.style.endWidth))<b&&(a.style.startWidth=a.style.endWidth))})));mxUtils.getValue(a.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(na(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],
|
||||
!1,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/
|
||||
3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE])})),c.push(na(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(b,
|
||||
c,d,e,f){b=(a.shape.getEndArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;
|
||||
a.style.endWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE],a.style.startWidth=a.style.endWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]),Math.abs(parseFloat(a.style.endWidth)-parseFloat(a.style.startWidth))<
|
||||
b&&(a.style.endWidth=a.style.startWidth))})));return c},swimlane:function(a){var b=[da(a,[mxConstants.STYLE_STARTSIZE],function(b){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));return 1==mxUtils.getValue(a.style,mxConstants.STYLE_HORIZONTAL,1)?new mxPoint(b.getCenterX(),b.y+Math.max(0,Math.min(b.height,c))):new mxPoint(b.x+Math.max(0,Math.min(b.width,c)),b.getCenterY())},function(b,c){a.style[mxConstants.STYLE_STARTSIZE]=1==mxUtils.getValue(this.state.style,
|
||||
mxConstants.STYLE_HORIZONTAL,1)?Math.round(Math.max(0,Math.min(b.height,c.y-b.y))):Math.round(Math.max(0,Math.min(b.width,c.x-b.x)))})];if(mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED)){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));b.push(ga(a,c/2))}return b},label:oa(),ext:oa(),rectangle:oa(),triangle:oa(),rhombus:oa(),umlLifeline:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,
|
||||
"size",K.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))},!1)]},umlFrame:function(a){return[da(a,["width","height"],function(a){var b=Math.max(H.prototype.corner,Math.min(a.width,mxUtils.getValue(this.state.style,"width",H.prototype.width))),c=Math.max(1.5*H.prototype.corner,Math.min(a.height,mxUtils.getValue(this.state.style,"height",H.prototype.height)));return new mxPoint(a.x+b,a.y+c)},function(a,
|
||||
b){this.state.style.width=Math.round(Math.max(H.prototype.corner,Math.min(a.width,b.x-a.x)));this.state.style.height=Math.round(Math.max(1.5*H.prototype.corner,Math.min(a.height,b.y-a.y)))},!1)]},process:function(a){var b=[da(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",t.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,
|
||||
mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},cross:function(a){return[da(a,["size"],function(a){var b=Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",la.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},note:function(a){return[da(a,["size"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[da(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",I.prototype.size)));return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,
|
||||
b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},dataStorage:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",aa.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},callout:function(a){var b=[da(a,["size",
|
||||
"position"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));mxUtils.getValue(this.state.style,"base",w.prototype.base);return new mxPoint(a.x+c*a.width,a.y+a.height-b)},function(a,b){mxUtils.getValue(this.state.style,"base",w.prototype.base);this.state.style.size=Math.round(Math.max(0,Math.min(a.height,a.y+a.height-b.y)));this.state.style.position=
|
||||
Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),da(a,["position2"],function(a){var b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position2",w.prototype.position2)));return new mxPoint(a.x+b*a.width,a.y+a.height)},function(a,b){this.state.style.position2=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),da(a,["base"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,
|
||||
"position",w.prototype.position))),d=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"base",w.prototype.base)));return new mxPoint(a.x+Math.min(a.width,c*a.width+d),a.y+a.height-b)},function(a,b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));this.state.style.base=Math.round(Math.max(0,Math.min(a.width,b.x-a.x-c*a.width)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},internalStorage:function(a){var b=
|
||||
[da(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",ca.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",ca.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},corner:function(a){return[da(a,
|
||||
["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",M.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",M.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[da(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,
|
||||
"dx",N.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",N.prototype.dy)));return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ha(1),doubleArrow:ha(.5),folder:function(a){return[da(a,["tabWidth","tabHeight"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,
|
||||
"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",g.prototype.tabHeight)));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(b=a.width-b);return new mxPoint(a.x+b,a.y+c)},function(a,b){var c=Math.max(0,Math.min(a.width,b.x-a.x));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(c=a.width-c);this.state.style.tabWidth=Math.round(c);this.state.style.tabHeight=
|
||||
Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},document:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",l.prototype.size))));return new mxPoint(a.x+3*a.width/4,a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},tape:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",k.prototype.size))));
|
||||
return new mxPoint(a.getCenterX(),a.y+b*a.height/2)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(b.y-a.y)/a.height*2))})]},offPageConnector:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",O.prototype.size))));return new mxPoint(a.getCenterX(),a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},step:sa(x.prototype.size,!0,null,!0,x.prototype.fixedSize),
|
||||
hexagon:sa(y.prototype.size,!0,.5,!0),curlyBracket:sa(p.prototype.size,!1),display:sa(ia.prototype.size,!1),cube:ma(1,a.prototype.size,!1),card:ma(.5,h.prototype.size,!0),loopLimit:ma(.5,U.prototype.size,!0),trapezoid:Da(.5),parallelogram:Da(1)};Graph.createHandle=da;Graph.handleFactory=ta;mxVertexHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()&&this.graph.isCellRotatable(this.state.cell)){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&
|
||||
null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_RECTANGLE);a=ta[a];null==a&&null!=this.state.shape&&this.state.shape.isRoundable()&&(a=ta[mxConstants.SHAPE_RECTANGLE]);if(null!=a)return a(this.state)}return null};mxEdgeHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_CONNECTOR);a=ta[a];if(null!=a)return a(this.state)}return null}}else Graph.createHandle=
|
||||
function(){},Graph.handleFactory={};var ua=new mxPoint(1,0),va=new mxPoint(1,0),ha=mxUtils.toRadians(-30),ua=mxUtils.getRotatedPoint(ua,Math.cos(ha),Math.sin(ha)),ha=mxUtils.toRadians(-150),va=mxUtils.getRotatedPoint(va,Math.cos(ha),Math.sin(ha));mxEdgeStyle.IsometricConnector=function(a,b,c,d,e){var f=a.view;d=null!=d&&0<d.length?d[0]:null;var g=a.absolutePoints,h=g[0],g=g[g.length-1];null!=d&&(d=f.transformControlPoint(a,d));null==h&&null!=b&&(h=new mxPoint(b.getCenterX(),b.getCenterY()));null==
|
||||
g&&null!=c&&(g=new mxPoint(c.getCenterX(),c.getCenterY()));var k=ua.x,l=ua.y,m=va.x,n=va.y,p="horizontal"==mxUtils.getValue(a.style,"elbow","horizontal");if(null!=g&&null!=h){a=function(a,b,c){a-=q.x;var d=b-q.y;b=(n*a-m*d)/(k*n-l*m);a=(l*a-k*d)/(l*m-k*n);p?(c&&(q=new mxPoint(q.x+k*b,q.y+l*b),e.push(q)),q=new mxPoint(q.x+m*a,q.y+n*a)):(c&&(q=new mxPoint(q.x+m*a,q.y+n*a),e.push(q)),q=new mxPoint(q.x+k*b,q.y+l*b));e.push(q)};var q=h;null==d&&(d=new mxPoint(h.x+(g.x-h.x)/2,h.y+(g.y-h.y)/2));a(d.x,d.y,
|
||||
!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var Ja=Graph.prototype.createEdgeHandler;Graph.prototype.createEdgeHandler=function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return Ja.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];w.prototype.constraints=[];mxRectangleShape.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,
|
||||
0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];
|
||||
mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;u.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=mxRectangleShape.prototype.constraints;h.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;ca.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;R.prototype.constraints=mxEllipse.prototype.constraints;fa.prototype.constraints=mxEllipse.prototype.constraints;Y.prototype.constraints=mxEllipse.prototype.constraints;pa.prototype.constraints=mxEllipse.prototype.constraints;I.prototype.constraints=mxRectangleShape.prototype.constraints;qa.prototype.constraints=mxRectangleShape.prototype.constraints;ia.prototype.constraints=mxRectangleShape.prototype.constraints;U.prototype.constraints=mxRectangleShape.prototype.constraints;
|
||||
O.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.3),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.7),!0),new mxConnectionConstraint(new mxPoint(.15,.95),!1),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.85,.95),!1)];E.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.1),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.75,.1),!1),new mxConnectionConstraint(new mxPoint(0,1/3),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(1,1/3),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1)];ba.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxActor.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.25,.2),!1),new mxConnectionConstraint(new mxPoint(.1,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.75,.25),!1),new mxConnectionConstraint(new mxPoint(.9,.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];f.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(.5,.75),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
1),!1)];k.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.35),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.65),!1),new mxConnectionConstraint(new mxPoint(1,.35),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,.65),!1),new mxConnectionConstraint(new mxPoint(.25,1),!1),new mxConnectionConstraint(new mxPoint(.75,0),!1)];x.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),
|
||||
!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.75),!0)];mxLine.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];mxDoubleEllipse.prototype.constraints=mxEllipse.prototype.constraints;mxRhombus.prototype.constraints=mxEllipse.prototype.constraints;mxTriangle.prototype.constraints=
|
||||
[new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0)];mxHexagon.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.375,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.625,0),!0),new mxConnectionConstraint(new mxPoint(0,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.375,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.625,1),!0)];mxCloud.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.25),!1),new mxConnectionConstraint(new mxPoint(.4,
|
||||
.1),!1),new mxConnectionConstraint(new mxPoint(.16,.55),!1),new mxConnectionConstraint(new mxPoint(.07,.4),!1),new mxConnectionConstraint(new mxPoint(.31,.8),!1),new mxConnectionConstraint(new mxPoint(.13,.77),!1),new mxConnectionConstraint(new mxPoint(.8,.8),!1),new mxConnectionConstraint(new mxPoint(.55,.95),!1),new mxConnectionConstraint(new mxPoint(.875,.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,
|
||||
.25),!1)];m.prototype.constraints=mxRectangleShape.prototype.constraints;n.prototype.constraints=mxRectangleShape.prototype.constraints;l.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),
|
||||
!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxArrow.prototype.constraints=null;N.prototype.constraints=null;M.prototype.constraints=null;J.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1),new mxConnectionConstraint(new mxPoint(.75,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];T.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];ea.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];la.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];K.prototype.constraints=null;P.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];W.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.175,
|
||||
.25),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.175,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)]})();
|
||||
e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",V);mxUtils.extend(T,mxShape);T.prototype.size=10;T.prototype.inset=2;T.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),g=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,
|
||||
c);a.begin();a.moveTo(d/2,f+g);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-g,f/2);a.quadTo((d-f)/2-g,f+g,d/2,f+g);a.quadTo((d+f)/2+g,f+g,(d+f)/2+g,f/2);a.end();a.stroke()};mxCellRenderer.registerShape("requires",T);mxUtils.extend(ca,mxShape);ca.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.end();a.stroke()};mxCellRenderer.registerShape("requiredInterface",ca);mxUtils.extend(W,mxShape);W.prototype.inset=
|
||||
2;W.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,c);a.ellipse(0,f,d-2*f,e-2*f);a.fillAndStroke();a.begin();a.moveTo(d/2,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("providedRequiredInterface",W);mxUtils.extend(v,mxCylinder);v.prototype.jettyWidth=32;v.prototype.jettyHeight=12;v.prototype.redrawPath=function(a,b,c,d,e,f){var g=parseFloat(mxUtils.getValue(this.style,
|
||||
"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));c=g/2;var g=c+g/2,h=.3*e-b/2,k=.7*e-b/2;f?(a.moveTo(c,h),a.lineTo(g,h),a.lineTo(g,h+b),a.lineTo(c,h+b),a.moveTo(c,k),a.lineTo(g,k),a.lineTo(g,k+b),a.lineTo(c,k+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,k+b),a.lineTo(0,k+b),a.lineTo(0,k),a.lineTo(c,k),a.lineTo(c,h+b),a.lineTo(0,h+b),a.lineTo(0,h),a.lineTo(c,h),a.close());a.end()};mxCellRenderer.registerShape("component",
|
||||
v);mxUtils.extend(R,mxDoubleEllipse);R.prototype.outerStroke=!0;R.prototype.paintVertexShape=function(a,b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.registerShape("endState",R);mxUtils.extend(H,R);H.prototype.outerStroke=!1;mxCellRenderer.registerShape("startState",H);mxUtils.extend(I,mxArrowConnector);I.prototype.defaultWidth=4;I.prototype.isOpenEnded=function(){return!0};
|
||||
I.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};I.prototype.isArrowRounded=function(){return this.isRounded};mxCellRenderer.registerShape("link",I);mxUtils.extend(da,mxArrowConnector);da.prototype.defaultWidth=10;da.prototype.defaultArrowWidth=20;da.prototype.getStartArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"startWidth",this.defaultArrowWidth)};da.prototype.getEndArrowWidth=function(){return this.getEdgeWidth()+
|
||||
mxUtils.getNumber(this.style,"endWidth",this.defaultArrowWidth)};da.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};mxCellRenderer.registerShape("flexArrow",da);mxUtils.extend(N,mxActor);N.prototype.size=30;N.prototype.isRoundable=function(){return!0};N.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(0,b),new mxPoint(d,0),new mxPoint(d,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("manualInput",N);mxUtils.extend(J,mxRectangleShape);J.prototype.dx=20;J.prototype.dy=20;J.prototype.isHtmlAllowed=function(){return!1};J.prototype.paintForeground=function(a,b,c,d,e){mxRectangleShape.prototype.paintForeground.apply(this,arguments);var f=0;if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));g=Math.max(f,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));f=Math.max(f,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));a.begin();a.moveTo(b,c+f);a.lineTo(b+d,c+f);a.end();a.stroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+g,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("internalStorage",J);mxUtils.extend(M,mxActor);M.prototype.dx=20;M.prototype.dy=20;M.prototype.redrawPath=
|
||||
function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint(b,c),new mxPoint(b,e),new mxPoint(0,e)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("corner",
|
||||
M);mxUtils.extend(aa,mxActor);aa.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.lineTo(0,e);a.end();a.moveTo(d,0);a.lineTo(d,e);a.end();a.moveTo(0,e/2);a.lineTo(d,e/2);a.end()};mxCellRenderer.registerShape("crossbar",aa);mxUtils.extend(ea,mxActor);ea.prototype.dx=20;ea.prototype.dy=20;ea.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("tee",ea);mxUtils.extend(U,mxActor);U.prototype.arrowWidth=.3;U.prototype.arrowSize=.2;U.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,
|
||||
parseFloat(mxUtils.getValue(this.style,"arrowWidth",this.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("singleArrow",U);mxUtils.extend(P,
|
||||
mxActor);P.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",U.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",U.prototype.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-
|
||||
b,e),new mxPoint(d-b,f),new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("doubleArrow",P);mxUtils.extend(S,mxActor);S.prototype.size=.1;S.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.registerShape("dataStorage",S);mxUtils.extend(Z,mxActor);Z.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.close();a.end()};mxCellRenderer.registerShape("or",Z);mxUtils.extend(O,mxActor);O.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.registerShape("xor",O);mxUtils.extend(Q,mxActor);Q.prototype.size=20;Q.prototype.isRoundable=function(){return!0};Q.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("loopLimit",Q);mxUtils.extend(fa,mxActor);fa.prototype.size=.375;fa.prototype.isRoundable=function(){return!0};fa.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("offPageConnector",fa);mxUtils.extend(X,mxEllipse);X.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};
|
||||
mxCellRenderer.registerShape("tapeData",X);mxUtils.extend(Y,mxEllipse);Y.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke();a.begin();a.moveTo(b+d/2,c);a.lineTo(b+d/2,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("orEllipse",Y);mxUtils.extend(pa,mxEllipse);pa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,
|
||||
arguments);a.setShadow(!1);a.begin();a.moveTo(b+.145*d,c+.145*e);a.lineTo(b+.855*d,c+.855*e);a.end();a.stroke();a.begin();a.moveTo(b+.855*d,c+.145*e);a.lineTo(b+.145*d,c+.855*e);a.end();a.stroke()};mxCellRenderer.registerShape("sumEllipse",pa);mxUtils.extend(wa,mxRhombus);wa.prototype.paintVertexShape=function(a,b,c,d,e){mxRhombus.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke()};mxCellRenderer.registerShape("sortShape",
|
||||
wa);mxUtils.extend(xa,mxEllipse);xa.prototype.paintVertexShape=function(a,b,c,d,e){a.begin();a.moveTo(b,c);a.lineTo(b+d,c);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke();a.begin();a.moveTo(b,c+e);a.lineTo(b+d,c+e);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke()};mxCellRenderer.registerShape("collate",xa);mxUtils.extend(ya,mxEllipse);ya.prototype.paintVertexShape=function(a,b,c,d,e){var f=c+e-5;a.begin();a.moveTo(b,c);a.lineTo(b,c+e);a.moveTo(b,f);a.lineTo(b+10,f-5);a.moveTo(b,f);a.lineTo(b+10,
|
||||
f+5);a.moveTo(b,f);a.lineTo(b+d,f);a.moveTo(b+d,c);a.lineTo(b+d,c+e);a.moveTo(b+d,f);a.lineTo(b+d-10,f-5);a.moveTo(b+d,f);a.lineTo(b+d-10,f+5);a.end();a.stroke()};mxCellRenderer.registerShape("dimension",ya);mxUtils.extend(za,mxEllipse);za.prototype.paintVertexShape=function(a,b,c,d,e){this.outline||a.setStrokeColor(null);mxRectangleShape.prototype.paintBackground.apply(this,arguments);null!=this.style&&(a.setStrokeColor(this.stroke),a.rect(b,c,d,e),a.fill(),a.begin(),a.moveTo(b,c),"1"==mxUtils.getValue(this.style,
|
||||
"top","1")?a.lineTo(b+d,c):a.moveTo(b+d,c),"1"==mxUtils.getValue(this.style,"right","1")?a.lineTo(b+d,c+e):a.moveTo(b+d,c+e),"1"==mxUtils.getValue(this.style,"bottom","1")?a.lineTo(b,c+e):a.moveTo(b,c+e),"1"==mxUtils.getValue(this.style,"left","1")&&a.lineTo(b,c-this.strokewidth/2),a.end(),a.stroke())};mxCellRenderer.registerShape("partialRectangle",za);mxUtils.extend(qa,mxEllipse);qa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);
|
||||
a.begin();"vertical"==mxUtils.getValue(this.style,"line")?(a.moveTo(b+d/2,c),a.lineTo(b+d/2,c+e)):(a.moveTo(b,c+e/2),a.lineTo(b+d,c+e/2));a.end();a.stroke()};mxCellRenderer.registerShape("lineEllipse",qa);mxUtils.extend(na,mxActor);na.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);a.moveTo(0,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(0,e);a.close();a.end()};mxCellRenderer.registerShape("delay",na);mxUtils.extend(la,mxActor);la.prototype.size=.2;la.prototype.redrawPath=
|
||||
function(a,b,c,d,e){b=Math.min(e,d);var f=Math.max(0,Math.min(b,b*parseFloat(mxUtils.getValue(this.style,"size",this.size))));b=(e-f)/2;c=b+f;var g=(d-f)/2,f=g+f;a.moveTo(0,b);a.lineTo(g,b);a.lineTo(g,0);a.lineTo(f,0);a.lineTo(f,b);a.lineTo(d,b);a.lineTo(d,c);a.lineTo(f,c);a.lineTo(f,e);a.lineTo(g,e);a.lineTo(g,c);a.lineTo(0,c);a.close();a.end()};mxCellRenderer.registerShape("cross",la);mxUtils.extend(ma,mxActor);ma.prototype.size=.25;ma.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);
|
||||
c=Math.min(d-b,Math.max(0,parseFloat(mxUtils.getValue(this.style,"size",this.size)))*d);a.moveTo(0,e/2);a.lineTo(c,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(c,e);a.close();a.end()};mxCellRenderer.registerShape("display",ma);mxUtils.extend(ja,mxConnector);ja.prototype.origPaintEdgeShape=ja.prototype.paintEdgeShape;ja.prototype.paintEdgeShape=function(a,b,c){for(var d=[],e=0;e<b.length;e++)d.push(mxUtils.clone(b[e]));var e=a.state.dashed,f=a.state.fixDash;ja.prototype.origPaintEdgeShape.apply(this,
|
||||
[a,d,c]);3<=a.state.strokeWidth&&(d=mxUtils.getValue(this.style,"fillColor",null),null!=d&&(a.setStrokeColor(d),a.setStrokeWidth(a.state.strokeWidth-2),a.setDashed(e,f),ja.prototype.origPaintEdgeShape.apply(this,[a,b,c])))};mxCellRenderer.registerShape("filledEdge",ja);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var b=this.format.getSelectionState(),c=a.apply(this,arguments);"umlFrame"==b.style.shape&&
|
||||
c.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",defaultValue:"#ffffff"});return c}}();mxMarker.addMarker("dash",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.stroke()}});mxMarker.addMarker("cross",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.moveTo(d.x-
|
||||
m/2+n/2,d.y-n/2-m/2);a.lineTo(d.x-n/2-3*m/2,d.y-3*n/2+m/2);a.stroke()}});mxMarker.addMarker("circle",Ca);mxMarker.addMarker("circlePlus",function(a,b,c,d,e,f,g,h,k,l){var m=d.clone(),n=Ca.apply(this,arguments),p=e*(g+2*k),q=f*(g+2*k);return function(){n.apply(this,arguments);a.begin();a.moveTo(m.x-e*k,m.y-f*k);a.lineTo(m.x-2*p+e*k,m.y-2*q+f*k);a.moveTo(m.x-p-q+f*k,m.y-q+p-e*k);a.lineTo(m.x+q-p-f*k,m.y-q-p+e*k);a.stroke()}});mxMarker.addMarker("async",function(a,b,c,d,e,f,g,h,k,l){b=e*k*1.118;c=f*
|
||||
k*1.118;e*=g+k;f*=g+k;var m=d.clone();m.x-=b;m.y-=c;d.x+=1*-e-b;d.y+=1*-f-c;return function(){a.begin();a.moveTo(m.x,m.y);h?a.lineTo(m.x-e-f/2,m.y-f+e/2):a.lineTo(m.x+f/2-e,m.y-f-e/2);a.lineTo(m.x-e,m.y-f);a.close();l?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(b,c,d,e,f,g,h,k,l,m){f*=h+l;g*=h+l;var n=e.clone();return function(){b.begin();b.moveTo(n.x,n.y);k?b.lineTo(n.x-f-g/a,n.y-g+f/a):b.lineTo(n.x+g/a-f,n.y-g-f/a);b.stroke()}}}(2));if("undefined"!==
|
||||
typeof mxVertexHandler){var Fa=function(a,b,c){return ha(a,["width"],b,function(b,d,e,f,g){g=a.shape.getEdgeWidth()*a.view.scale+c;return new mxPoint(f.x+d*b/4+e*g/2,f.y+e*b/4-d*g/2)},function(b,d,e,f,g,h){b=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));a.style.width=Math.round(2*b)/a.view.scale-c})},ha=function(a,b,c,d,e){return ba(a,b,function(b){var e=a.absolutePoints,f=e.length-1;b=a.view.translate;var g=a.view.scale,h=c?e[0]:e[f],e=c?e[1]:e[f-1],f=e.x-h.x,k=e.y-h.y,l=Math.sqrt(f*f+
|
||||
k*k),h=d.call(this,l,f/l,k/l,h,e);return new mxPoint(h.x/g-b.x,h.y/g-b.y)},function(b,d,f){var g=a.absolutePoints,h=g.length-1;b=a.view.translate;var k=a.view.scale,l=c?g[0]:g[h],g=c?g[1]:g[h-1],h=g.x-l.x,m=g.y-l.y,n=Math.sqrt(h*h+m*m);d.x=(d.x+b.x)*k;d.y=(d.y+b.y)*k;e.call(this,n,h/n,m/n,l,g,d,f)})},ia=function(a){return function(b){return[ba(b,["arrowWidth","arrowSize"],function(b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",U.prototype.arrowWidth))),d=Math.max(0,
|
||||
Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",U.prototype.arrowSize)));return new mxPoint(b.x+(1-d)*b.width,b.y+(1-c)*b.height/2)},function(b,c){this.state.style.arrowWidth=Math.max(0,Math.min(1,Math.abs(b.y+b.height/2-c.y)/b.height*2));this.state.style.arrowSize=Math.max(0,Math.min(a,(b.x+b.width-c.x)/b.width))})]}},Ba=function(a,b,c){return function(d){var e=[ba(d,["size"],function(c){var d=Math.max(0,Math.min(c.width,Math.min(c.height,parseFloat(mxUtils.getValue(this.state.style,"size",
|
||||
b)))))*a;return new mxPoint(c.x+d,c.y+d)},function(b,c){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(b.width,c.x-b.x),Math.min(b.height,c.y-b.y)))/a)})];c&&mxUtils.getValue(d.style,mxConstants.STYLE_ROUNDED,!1)&&e.push(ga(d));return e}},sa=function(a,b,c,d,e){c=null!=c?c:1;return function(f){var g=[ba(f,["size"],function(b){var c=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null,d=parseFloat(mxUtils.getValue(this.state.style,"size",c?e:a));return new mxPoint(b.x+
|
||||
Math.max(0,Math.min(b.width,d*(c?1:b.width))),b.getCenterY())},function(a,b,d){var g=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null;a=g?b.x-a.x:Math.max(0,Math.min(c,(b.x-a.x)/a.width));g&&!mxEvent.isAltDown(d.getEvent())&&(a=f.view.graph.snap(a));this.state.style.size=a},null,d)];b&&mxUtils.getValue(f.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(ga(f));return g}},Ga=function(a){return function(b){var c=[ba(b,["size"],function(b){var c=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,
|
||||
"size",n.prototype.size))));return new mxPoint(b.x+c*b.width*.75,b.y+b.height/4)},function(b,c){this.state.style.size=Math.max(0,Math.min(a,(c.x-b.x)/(.75*b.width)))},null,!0)];mxUtils.getValue(b.style,mxConstants.STYLE_ROUNDED,!1)&&c.push(ga(b));return c}},oa=function(){return function(a){var b=[];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b}},ga=function(a,b){return ba(a,[mxConstants.STYLE_ARCSIZE],function(c){var d=null!=b?b:c.height/8;if("1"==mxUtils.getValue(a.style,
|
||||
mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)){var e=mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;return new mxPoint(c.x+c.width-Math.min(c.width/2,e),c.y+d)}e=Math.max(0,parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)))/100;return new mxPoint(c.x+c.width-Math.min(Math.max(c.width/2,c.height/2),Math.min(c.width,c.height)*e),c.y+d)},function(b,c,d){"1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?
|
||||
this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.max(0,Math.min(b.width,2*(b.x+b.width-c.x)))):this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.min(50,Math.max(0,100*(b.width-c.x+b.x)/Math.min(b.width,b.height))))})},ba=function(a,b,c,d,e,f){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<b.length;a++)this.copyStyle(b[a])};g.getPosition=c;g.setPosition=d;g.ignoreGrid=null!=e?e:!0;if(f){var h=g.positionChanged;g.positionChanged=
|
||||
function(){h.apply(this,arguments);a.view.invalidate(this.state.cell);a.view.validate()}}return g},ta={link:function(a){return[Fa(a,!0,10),Fa(a,!1,10)]},flexArrow:function(a){var b=a.view.graph.gridSize/a.view.scale,c=[];mxUtils.getValue(a.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(ha(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,
|
||||
mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),c.push(ha(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/
|
||||
5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=a.style.startWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]),Math.abs(parseFloat(a.style.startWidth)-parseFloat(a.style.endWidth))<b&&(a.style.startWidth=a.style.endWidth))})));mxUtils.getValue(a.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(ha(a,
|
||||
["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE])})),c.push(ha(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],
|
||||
!1,function(b,c,d,e,f){b=(a.shape.getEndArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/
|
||||
3)/100/a.view.scale;a.style.endWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE],a.style.startWidth=a.style.endWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]),Math.abs(parseFloat(a.style.endWidth)-
|
||||
parseFloat(a.style.startWidth))<b&&(a.style.endWidth=a.style.startWidth))})));return c},swimlane:function(a){var b=[ba(a,[mxConstants.STYLE_STARTSIZE],function(b){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));return 1==mxUtils.getValue(a.style,mxConstants.STYLE_HORIZONTAL,1)?new mxPoint(b.getCenterX(),b.y+Math.max(0,Math.min(b.height,c))):new mxPoint(b.x+Math.max(0,Math.min(b.width,c)),b.getCenterY())},function(b,c){a.style[mxConstants.STYLE_STARTSIZE]=
|
||||
1==mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,1)?Math.round(Math.max(0,Math.min(b.height,c.y-b.y))):Math.round(Math.max(0,Math.min(b.width,c.x-b.x)))})];if(mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED)){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));b.push(ga(a,c/2))}return b},label:oa(),ext:oa(),rectangle:oa(),triangle:oa(),rhombus:oa(),umlLifeline:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,
|
||||
parseFloat(mxUtils.getValue(this.state.style,"size",K.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))},!1)]},umlFrame:function(a){return[ba(a,["width","height"],function(a){var b=Math.max(G.prototype.corner,Math.min(a.width,mxUtils.getValue(this.state.style,"width",G.prototype.width))),c=Math.max(1.5*G.prototype.corner,Math.min(a.height,mxUtils.getValue(this.state.style,"height",G.prototype.height)));
|
||||
return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.width=Math.round(Math.max(G.prototype.corner,Math.min(a.width,b.x-a.x)));this.state.style.height=Math.round(Math.max(1.5*G.prototype.corner,Math.min(a.height,b.y-a.y)))},!1)]},process:function(a){var b=[ba(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",t.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,
|
||||
(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},cross:function(a){return[ba(a,["size"],function(a){var b=Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",la.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},
|
||||
note:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",N.prototype.size)));
|
||||
return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},dataStorage:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",S.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-
|
||||
b.x)/a.width))})]},callout:function(a){var b=[ba(a,["size","position"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));mxUtils.getValue(this.state.style,"base",w.prototype.base);return new mxPoint(a.x+c*a.width,a.y+a.height-b)},function(a,b){mxUtils.getValue(this.state.style,"base",w.prototype.base);this.state.style.size=Math.round(Math.max(0,Math.min(a.height,
|
||||
a.y+a.height-b.y)));this.state.style.position=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),ba(a,["position2"],function(a){var b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position2",w.prototype.position2)));return new mxPoint(a.x+b*a.width,a.y+a.height)},function(a,b){this.state.style.position2=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),ba(a,["base"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),
|
||||
c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position))),d=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"base",w.prototype.base)));return new mxPoint(a.x+Math.min(a.width,c*a.width+d),a.y+a.height-b)},function(a,b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));this.state.style.base=Math.round(Math.max(0,Math.min(a.width,b.x-a.x-c*a.width)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,
|
||||
!1)&&b.push(ga(a));return b},internalStorage:function(a){var b=[ba(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",J.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",J.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,
|
||||
!1)&&b.push(ga(a));return b},corner:function(a){return[ba(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",M.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",M.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[ba(a,["dx","dy"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",ea.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",ea.prototype.dy)));return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ia(1),doubleArrow:ia(.5),folder:function(a){return[ba(a,["tabWidth","tabHeight"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",g.prototype.tabHeight)));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(b=a.width-b);return new mxPoint(a.x+b,a.y+c)},function(a,b){var c=Math.max(0,Math.min(a.width,b.x-a.x));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&
|
||||
(c=a.width-c);this.state.style.tabWidth=Math.round(c);this.state.style.tabHeight=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},document:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",l.prototype.size))));return new mxPoint(a.x+3*a.width/4,a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},tape:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",k.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b*a.height/2)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(b.y-a.y)/a.height*2))})]},offPageConnector:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",fa.prototype.size))));return new mxPoint(a.getCenterX(),a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+
|
||||
a.height-b.y)/a.height))})]},step:sa(x.prototype.size,!0,null,!0,x.prototype.fixedSize),hexagon:sa(y.prototype.size,!0,.5,!0),curlyBracket:sa(p.prototype.size,!1),display:sa(ma.prototype.size,!1),cube:Ba(1,a.prototype.size,!1),card:Ba(.5,h.prototype.size,!0),loopLimit:Ba(.5,Q.prototype.size,!0),trapezoid:Ga(.5),parallelogram:Ga(1)};Graph.createHandle=ba;Graph.handleFactory=ta;mxVertexHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()&&this.graph.isCellRotatable(this.state.cell)){var a=
|
||||
this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_RECTANGLE);a=ta[a];null==a&&null!=this.state.shape&&this.state.shape.isRoundable()&&(a=ta[mxConstants.SHAPE_RECTANGLE]);if(null!=a)return a(this.state)}return null};mxEdgeHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=
|
||||
mxConstants.SHAPE_CONNECTOR);a=ta[a];if(null!=a)return a(this.state)}return null}}else Graph.createHandle=function(){},Graph.handleFactory={};var ua=new mxPoint(1,0),va=new mxPoint(1,0),ia=mxUtils.toRadians(-30),ua=mxUtils.getRotatedPoint(ua,Math.cos(ia),Math.sin(ia)),ia=mxUtils.toRadians(-150),va=mxUtils.getRotatedPoint(va,Math.cos(ia),Math.sin(ia));mxEdgeStyle.IsometricConnector=function(a,b,c,d,e){var f=a.view;d=null!=d&&0<d.length?d[0]:null;var g=a.absolutePoints,h=g[0],g=g[g.length-1];null!=
|
||||
d&&(d=f.transformControlPoint(a,d));null==h&&null!=b&&(h=new mxPoint(b.getCenterX(),b.getCenterY()));null==g&&null!=c&&(g=new mxPoint(c.getCenterX(),c.getCenterY()));var k=ua.x,l=ua.y,m=va.x,n=va.y,p="horizontal"==mxUtils.getValue(a.style,"elbow","horizontal");if(null!=g&&null!=h){a=function(a,b,c){a-=q.x;var d=b-q.y;b=(n*a-m*d)/(k*n-l*m);a=(l*a-k*d)/(l*m-k*n);p?(c&&(q=new mxPoint(q.x+k*b,q.y+l*b),e.push(q)),q=new mxPoint(q.x+m*a,q.y+n*a)):(c&&(q=new mxPoint(q.x+m*a,q.y+n*a),e.push(q)),q=new mxPoint(q.x+
|
||||
k*b,q.y+l*b));e.push(q)};var q=h;null==d&&(d=new mxPoint(h.x+(g.x-h.x)/2,h.y+(g.y-h.y)/2));a(d.x,d.y,!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var La=Graph.prototype.createEdgeHandler;Graph.prototype.createEdgeHandler=function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return La.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];w.prototype.constraints=[];
|
||||
mxRectangleShape.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;u.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=mxRectangleShape.prototype.constraints;h.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;
|
||||
J.prototype.constraints=mxRectangleShape.prototype.constraints;S.prototype.constraints=mxRectangleShape.prototype.constraints;X.prototype.constraints=mxEllipse.prototype.constraints;Y.prototype.constraints=mxEllipse.prototype.constraints;pa.prototype.constraints=mxEllipse.prototype.constraints;qa.prototype.constraints=mxEllipse.prototype.constraints;N.prototype.constraints=mxRectangleShape.prototype.constraints;na.prototype.constraints=mxRectangleShape.prototype.constraints;ma.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;fa.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.3),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.7),!0),new mxConnectionConstraint(new mxPoint(.15,.95),!1),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.85,.95),!1)];E.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.1),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.75,.1),!1),new mxConnectionConstraint(new mxPoint(0,1/3),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(1,1/3),!1),new mxConnectionConstraint(new mxPoint(1,1),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1)];v.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxActor.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.25,.2),!1),new mxConnectionConstraint(new mxPoint(.1,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.75,.25),!1),new mxConnectionConstraint(new mxPoint(.9,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];f.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.5,.75),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];k.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.35),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.65),!1),new mxConnectionConstraint(new mxPoint(1,.35),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,.65),!1),new mxConnectionConstraint(new mxPoint(.25,1),!1),new mxConnectionConstraint(new mxPoint(.75,
|
||||
0),!1)];x.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxLine.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];mxDoubleEllipse.prototype.constraints=
|
||||
mxEllipse.prototype.constraints;mxRhombus.prototype.constraints=mxEllipse.prototype.constraints;mxTriangle.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0)];mxHexagon.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.375,
|
||||
0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.625,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.375,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),
|
||||
!0),new mxConnectionConstraint(new mxPoint(.625,1),!0)];mxCloud.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.25),!1),new mxConnectionConstraint(new mxPoint(.4,.1),!1),new mxConnectionConstraint(new mxPoint(.16,.55),!1),new mxConnectionConstraint(new mxPoint(.07,.4),!1),new mxConnectionConstraint(new mxPoint(.31,.8),!1),new mxConnectionConstraint(new mxPoint(.13,.77),!1),new mxConnectionConstraint(new mxPoint(.8,.8),!1),new mxConnectionConstraint(new mxPoint(.55,.95),!1),new mxConnectionConstraint(new mxPoint(.875,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,.25),!1)];m.prototype.constraints=mxRectangleShape.prototype.constraints;n.prototype.constraints=mxRectangleShape.prototype.constraints;l.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxArrow.prototype.constraints=null;ea.prototype.constraints=null;M.prototype.constraints=null;aa.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];U.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];P.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),
|
||||
new mxConnectionConstraint(new mxPoint(1,.5),!1)];la.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];K.prototype.constraints=null;Z.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];O.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.175,.25),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.175,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];ca.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];W.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)]})();
|
||||
(function(x,r){function N(){if(!t){t=!0;window.MathJax={skipStartupTypeset:!0,showMathMenu:!1,messageStyle:"none",AuthorInit:function(){MathJax.Hub.Config({jax:["input/TeX","input/MathML","input/AsciiMath","output/HTML-CSS"],extensions:["tex2jax.js","mml2jax.js","asciimath2jax.js"],"HTML-CSS":{imageFont:null},TeX:{extensions:["AMSmath.js","AMSsymbols.js","noErrors.js","noUndefined.js"]}});MathJax.Hub.Register.StartupHook("Begin",function(){for(var a=0;a<p.length;a++)MathJax.Hub.Queue(["Typeset",MathJax.Hub,
|
||||
p[a]])})}};var a=document.createElement("script");a.type="text/javascript";a.src="https://math.draw.io/current/MathJax.js?config=TeX-MML-AM_HTMLorMML";document.getElementsByTagName("head")[0].appendChild(a)}}function O(a){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub?MathJax.Hub.Queue(["Typeset",MathJax.Hub,a.container]):p.push(a.container);a.addListener(mxEvent.SIZE,function(e,m){"undefined"!==typeof MathJax&&"undefined"!==typeof MathJax.Hub&&MathJax.Hub.Queue(["Typeset",MathJax.Hub,
|
||||
a.container])})}mxStencilRegistry.dynamicLoading=!1;try{var e=document.createElement("style");e.type="text/css";e.innerHTML="div.mxTooltip {\n-webkit-box-shadow: 3px 3px 12px #C0C0C0;\n-moz-box-shadow: 3px 3px 12px #C0C0C0;\nbox-shadow: 3px 3px 12px #C0C0C0;\nbackground: #FFFFCC;\nborder-style: solid;\nborder-width: 1px;\nborder-color: black;\nfont-family: Arial;\nfont-size: 8pt;\nposition: absolute;\ncursor: default;\npadding: 4px;\ncolor: black;}";document.getElementsByTagName("head")[0].appendChild(e)}catch(a){}var G=
|
||||
|
|
|
@ -1750,7 +1750,7 @@
|
|||
|
||||
mxStyleRegistry.putValue('hexagonPerimeter2', mxPerimeter.HexagonPerimeter2);
|
||||
|
||||
// Lollipop Shape
|
||||
// Provided Interface Shape (aka Lollipop)
|
||||
function LollipopShape()
|
||||
{
|
||||
mxShape.call(this);
|
||||
|
@ -1774,7 +1774,7 @@
|
|||
|
||||
mxCellRenderer.registerShape('lollipop', LollipopShape);
|
||||
|
||||
// Lollipop Shape
|
||||
// Required Interface Shape
|
||||
function RequiresShape()
|
||||
{
|
||||
mxShape.call(this);
|
||||
|
@ -1803,6 +1803,52 @@
|
|||
};
|
||||
|
||||
mxCellRenderer.registerShape('requires', RequiresShape);
|
||||
|
||||
// Required Interface Shape
|
||||
function RequiredInterfaceShape()
|
||||
{
|
||||
mxShape.call(this);
|
||||
};
|
||||
mxUtils.extend(RequiredInterfaceShape, mxShape);
|
||||
|
||||
RequiredInterfaceShape.prototype.paintBackground = function(c, x, y, w, h)
|
||||
{
|
||||
c.translate(x, y);
|
||||
|
||||
c.begin();
|
||||
c.moveTo(0, 0);
|
||||
c.quadTo(w, 0, w, h / 2);
|
||||
c.quadTo(w, h, 0, h);
|
||||
c.end();
|
||||
c.stroke();
|
||||
};
|
||||
|
||||
mxCellRenderer.registerShape('requiredInterface', RequiredInterfaceShape);
|
||||
|
||||
// Provided and Required Interface Shape
|
||||
function ProvidedRequiredInterfaceShape()
|
||||
{
|
||||
mxShape.call(this);
|
||||
};
|
||||
mxUtils.extend(ProvidedRequiredInterfaceShape, mxShape);
|
||||
ProvidedRequiredInterfaceShape.prototype.inset = 2;
|
||||
ProvidedRequiredInterfaceShape.prototype.paintBackground = function(c, x, y, w, h)
|
||||
{
|
||||
var inset = parseFloat(mxUtils.getValue(this.style, 'inset', this.inset)) + this.strokewidth;
|
||||
c.translate(x, y);
|
||||
|
||||
c.ellipse(0, inset, w - 2 * inset, h - 2 * inset);
|
||||
c.fillAndStroke();
|
||||
|
||||
c.begin();
|
||||
c.moveTo(w / 2, 0);
|
||||
c.quadTo(w, 0, w, h / 2);
|
||||
c.quadTo(w, h, w / 2, h);
|
||||
c.end();
|
||||
c.stroke();
|
||||
};
|
||||
|
||||
mxCellRenderer.registerShape('providedRequiredInterface', ProvidedRequiredInterfaceShape);
|
||||
|
||||
// Component shape
|
||||
function ComponentShape()
|
||||
|
@ -3912,4 +3958,8 @@
|
|||
new mxConnectionConstraint(new mxPoint(1, 0.5), false),
|
||||
new mxConnectionConstraint(new mxPoint(0.7, 0.1), false),
|
||||
new mxConnectionConstraint(new mxPoint(0.7, 0.9), false)];
|
||||
RequiredInterfaceShape.prototype.constraints = [new mxConnectionConstraint(new mxPoint(0, 0.5), false),
|
||||
new mxConnectionConstraint(new mxPoint(1, 0.5), false)];
|
||||
ProvidedRequiredInterfaceShape.prototype.constraints = [new mxConnectionConstraint(new mxPoint(0, 0.5), false),
|
||||
new mxConnectionConstraint(new mxPoint(1, 0.5), false)];
|
||||
})();
|
||||
|
|
|
@ -1317,8 +1317,8 @@ Sidebar.prototype.addUmlPalette = function(expand)
|
|||
|
||||
return sb.createVertexTemplateFromCells([cell.clone()], cell.geometry.width, cell.geometry.height, 'Interface 2');
|
||||
}),
|
||||
this.createVertexTemplateEntry('shape=lollipop;direction=south;html=1;', 30, 10, '', 'Provided Interface', null, null, dt + 'provided interface'),
|
||||
this.createVertexTemplateEntry('shape=requires;direction=north;html=1;', 30, 20, '', 'Required Interface', null, null, dt + 'required interface'),
|
||||
this.createVertexTemplateEntry('shape=providedRequiredInterface;html=1;verticalLabelPosition=bottom;', 20, 20, '', 'Provided/Required Interface', null, null, dt + 'provided required interface'),
|
||||
this.createVertexTemplateEntry('shape=requiredInterface;html=1;verticalLabelPosition=bottom;', 10, 20, '', 'Required Interface', null, null, dt + 'required interface'),
|
||||
this.createVertexTemplateEntry('shape=umlBoundary;whiteSpace=wrap;html=1;', 100, 80, 'Boundary Object', 'Boundary Object', null, null, 'uml boundary object'),
|
||||
this.createVertexTemplateEntry('ellipse;shape=umlEntity;whiteSpace=wrap;html=1;', 80, 80, 'Entity Object', 'Entity Object', null, null, 'uml entity object'),
|
||||
this.createVertexTemplateEntry('ellipse;shape=umlControl;whiteSpace=wrap;html=1;', 70, 80, 'Control Object', 'Control Object', null, null, 'uml control object'),
|
||||
|
|
446
src/main/webapp/js/reader.min.js
vendored
446
src/main/webapp/js/reader.min.js
vendored
|
@ -36,18 +36,18 @@ function(){return null!==this.k};f.prototype.V=function(){return this.h&&decodeU
|
|||
this.l};f.prototype.ba=function(a){if("object"===typeof a&&!(a instanceof Array)&&(a instanceof Object||"[object Array]"!==Object.prototype.toString.call(a))){var b=[],c=-1,d;for(d in a){var e=a[d];"string"===typeof e&&(b[++c]=d,b[++c]=e)}a=b}for(var b=[],c="",f=0;f<a.length;)d=a[f++],e=a[f++],b.push(c,encodeURIComponent(d.toString())),c="&",e&&b.push("=",encodeURIComponent(e.toString()));this.l=b.join("")};f.prototype.fa=function(a){this.o=a?a:null};f.prototype.Z=function(){return null!==this.o};
|
||||
var l=/^(?:([^:/?#]+):)?(?:\/\/(?:([^/?#]*)@)?([^/?#:@]*)(?::([0-9]+))?)?([^?#]+)?(?:\?([^#]*))?(?:#(.*))?$/,m=/[#\/\?@]/g,n=/[\#\?]/g;f.parse=a;f.create=function(a,d,e,g,h,k,l){a=new f(b(a,m),b(d,m),"string"==typeof e?encodeURIComponent(e):null,0<g?g.toString():null,b(h,n),null,"string"==typeof l?encodeURIComponent(l):null);k&&("string"===typeof k?a.O(k.replace(/[^?&=0-9A-Za-z_\-~.%]/g,c)):a.ba(k));return a};f.N=e;f.ma=d;f.ha={ua:function(b){return/\.html$/.test(a(b).U())?"text/html":"application/javascript"},
|
||||
N:function(b,c){return b?e(a(b),a(c)).toString():""+c}};return f}();"undefined"!==typeof window&&(window.URI=f);var g=void 0,h=void 0,k=void 0,l=void 0;(function(){function a(a){return"string"===typeof a?'url("'+a.replace(x,c)+'")':'url("about:blank")'}function c(a){return y[a]}function d(a,b){return a?f.ha.N(a,b):b}function n(a,b,c){if(!c)return null;var d=(""+a).match(u);return!d||d[1]&&!D.test(d[1])?null:c(a,b)}function w(a){return a.replace(/^-(?:apple|css|epub|khtml|moz|mso?|o|rim|wap|webkit|xv)-(?=[a-z])/,
|
||||
"")}var x=/[\n\f\r\"\'()*<>]/g,y={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},u=/^(?:([^:/?# ]+):)?/,D=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function C(f,g,h,k,l){f=w(f);var m=b[f];if(m&&"object"===typeof m){for(var p=m.cssPropBits,v=p&80,q=p&1536,r=NaN,B=0,u=0;B<g.length;++B){var t=g[B].toLowerCase(),z=t.charCodeAt(0),x,L,y,D,H,E;if(32===z)t="";else if(34===z)t=16===v?h?a(n(d(k,e(g[B].substring(1,t.length-1))),f,h)):"":
|
||||
p&8&&!(v&v-1)?t:"";else if("inherit"!==t){if(H=m.cssLitGroup){var F;if(!(F=m.cssLitMap)){F={};for(var K=H.length;0<=--K;)for(var R=H[K],fa=R.length;0<=--fa;)F[R[fa]]=c;F=m.cssLitMap=F}H=F}else H=c;if(E=H,E[w(t)]!==c)if(35===z&&/^#(?:[0-9a-f]{3}){1,2}$/.test(t))t=p&2?t:"";else if(48<=z&&57>=z)t=p&1?t:"";else if(x=t.charCodeAt(1),L=t.charCodeAt(2),y=48<=x&&57>=x,D=48<=L&&57>=L,43===z&&(y||46===x&&D))t=p&1?(y?"":"0")+t.substring(1):"";else if(45===z&&(y||46===x&&D))t=p&4?(y?"-":"-0")+t.substring(1):
|
||||
p&1?"0":"";else if(46===z&&y)t=p&1?"0"+t:"";else if('url("'===t.substring(0,5))t=h&&p&16?a(n(d(k,g[B].substring(5,t.length-2)),f,h)):"";else if("("===t.charAt(t.length-1))a:{H=g;F=B;t=1;K=F+1;for(z=H.length;K<z&&t;)R=H[K++],t+=")"===R?-1:/^[^"']*\($/.test(R);if(!t)for(t=H[F].toLowerCase(),z=w(t),H=H.splice(F,K-F,""),F=m.cssFns,K=0,R=F.length;K<R;++K)if(F[K].substring(0,z.length)==z){H[0]=H[H.length-1]="";C(F[K],H,h,k);t=t+H.join(" ")+")";break a}t=""}else t=q&&/^-?[a-z_][\w\-]*$/.test(t)&&!/__$/.test(t)?
|
||||
"")}var x=/[\n\f\r\"\'()*<>]/g,y={"\n":"%0a","\f":"%0c","\r":"%0d",'"':"%22","'":"%27","(":"%28",")":"%29","*":"%2a","<":"%3c",">":"%3e"},u=/^(?:([^:/?# ]+):)?/,D=/^(?:https?|mailto|data)$/i;g=function(){var c={};return function C(f,g,h,k,l){f=w(f);var m=b[f];if(m&&"object"===typeof m){for(var p=m.cssPropBits,v=p&80,q=p&1536,r=NaN,B=0,u=0;B<g.length;++B){var t=g[B].toLowerCase(),z=t.charCodeAt(0),x,L,y,D,G,E;if(32===z)t="";else if(34===z)t=16===v?h?a(n(d(k,e(g[B].substring(1,t.length-1))),f,h)):"":
|
||||
p&8&&!(v&v-1)?t:"";else if("inherit"!==t){if(G=m.cssLitGroup){var F;if(!(F=m.cssLitMap)){F={};for(var K=G.length;0<=--K;)for(var Q=G[K],fa=Q.length;0<=--fa;)F[Q[fa]]=c;F=m.cssLitMap=F}G=F}else G=c;if(E=G,E[w(t)]!==c)if(35===z&&/^#(?:[0-9a-f]{3}){1,2}$/.test(t))t=p&2?t:"";else if(48<=z&&57>=z)t=p&1?t:"";else if(x=t.charCodeAt(1),L=t.charCodeAt(2),y=48<=x&&57>=x,D=48<=L&&57>=L,43===z&&(y||46===x&&D))t=p&1?(y?"":"0")+t.substring(1):"";else if(45===z&&(y||46===x&&D))t=p&4?(y?"-":"-0")+t.substring(1):
|
||||
p&1?"0":"";else if(46===z&&y)t=p&1?"0"+t:"";else if('url("'===t.substring(0,5))t=h&&p&16?a(n(d(k,g[B].substring(5,t.length-2)),f,h)):"";else if("("===t.charAt(t.length-1))a:{G=g;F=B;t=1;K=F+1;for(z=G.length;K<z&&t;)Q=G[K++],t+=")"===Q?-1:/^[^"']*\($/.test(Q);if(!t)for(t=G[F].toLowerCase(),z=w(t),G=G.splice(F,K-F,""),F=m.cssFns,K=0,Q=F.length;K<Q;++K)if(F[K].substring(0,z.length)==z){G[0]=G[G.length-1]="";C(F[K],G,h,k);t=t+G.join(" ")+")";break a}t=""}else t=q&&/^-?[a-z_][\w\-]*$/.test(t)&&!/__$/.test(t)?
|
||||
l&&512===q?g[B]+l:1024===q&&b[t]&&"number"===typeof b[t].oa?t:"":/^\w+$/.test(t)&&64===v&&p&8?r+1===u?(g[r]=g[r].substring(0,g[r].length-1)+" "+t+'"',""):(r=u,'"'+t+'"'):""}t&&(g[u++]=t)}1===u&&'url("about:blank")'===g[0]&&(u=0);g.length=u}else g.length=0}}();var F=/^(active|after|before|blank|checked|default|disabled|drop|empty|enabled|first|first-child|first-letter|first-line|first-of-type|fullscreen|focus|hover|in-range|indeterminate|invalid|last-child|last-of-type|left|link|only-child|only-of-type|optional|out-of-range|placeholder-shown|read-only|read-write|required|right|root|scope|user-error|valid|visited)$/,
|
||||
E={};E[">"]=E["+"]=E["~"]=E;h=function(a,b,c){function d(d,k){function l(c,d,e){var h,k,l,n,v,Z=!0;h="";c<d&&((v=a[c],"*"===v)?(++c,h=v):/^[a-zA-Z]/.test(v)&&(k=g(v.toLowerCase(),[]))&&("tagName"in k&&(v=k.tagName),++c,h=v));for(n=l=k="";Z&&c<d;++c)if(v=a[c],"#"===v.charAt(0))/^#_|__$|[^\w#:\-]/.test(v)?Z=!1:k+=v+f;else if("."===v)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(v=a[c])&&!/^_|__$/.test(v)?k+="."+v:Z=!1;else if(c+1<d&&"["===a[c]){++c;var C=a[c++].toLowerCase();v=p.m[h+"::"+C];v!==+v&&(v=p.m["*::"+
|
||||
C]);var q;b.ia?(q=b.ia(h,C),"string"!==typeof q&&(Z=!1,q=C),Z&&v!==+v&&(v=p.d.NONE)):(q=C,v!==+v&&(Z=!1));var r=C="",B=!1;/^[~^$*|]?=$/.test(a[c])&&(C=a[c++],r=a[c++],/^[0-9A-Za-z:_\-]+$/.test(r)?r='"'+r+'"':"]"===r&&(r='""',--c),/^"([^\"\\]|\\.)*"$/.test(r)||(Z=!1),(B="i"===a[c])&&++c);"]"!==a[c]&&(++c,Z=!1);switch(v){case p.d.CLASSES:case p.d.LOCAL_NAME:case p.d.NONE:break;case p.d.GLOBAL_NAME:case p.d.ID:case p.d.IDREF:"="!==C&&"~="!==C&&"$="!==C||'""'==r||B?"|="===C||""===C||(Z=!1):r='"'+r.substring(1,
|
||||
r.length-1)+f+'"';break;case p.d.URI:case p.d.URI_FRAGMENT:""!==C&&(Z=!1);break;default:Z=!1}Z&&(l+="["+q.replace(/[^\w-]/g,"\\$&")+C+r+(B?" i]":"]"))}else if(c<d&&":"===a[c])if(v=a[++c],F.test(v))n+=":"+v;else break;else break;c!==d&&(Z=!1);Z&&(c=(h+k).replace(/[^ .*#\w-]/g,"\\$&")+l+n+e)&&m.push(c);return Z}" "===a[d]&&++d;k-1!==d&&" "===a[k]&&--k;for(var m=[],n=d,v=!0,C=d;v&&C<k;++C){var q=a[C];if(E[q]===E||" "===q)l(n,C,q)?n=C+1:v=!1}l(n,k,"")||(v=!1);return v?(m.length&&(n=m.join(""),null!==
|
||||
E={};E[">"]=E["+"]=E["~"]=E;h=function(a,b,c){function d(d,k){function l(c,d,e){var h,k,l,n,v,Y=!0;h="";c<d&&((v=a[c],"*"===v)?(++c,h=v):/^[a-zA-Z]/.test(v)&&(k=g(v.toLowerCase(),[]))&&("tagName"in k&&(v=k.tagName),++c,h=v));for(n=l=k="";Y&&c<d;++c)if(v=a[c],"#"===v.charAt(0))/^#_|__$|[^\w#:\-]/.test(v)?Y=!1:k+=v+f;else if("."===v)++c<d&&/^[0-9A-Za-z:_\-]+$/.test(v=a[c])&&!/^_|__$/.test(v)?k+="."+v:Y=!1;else if(c+1<d&&"["===a[c]){++c;var C=a[c++].toLowerCase();v=p.m[h+"::"+C];v!==+v&&(v=p.m["*::"+
|
||||
C]);var q;b.ia?(q=b.ia(h,C),"string"!==typeof q&&(Y=!1,q=C),Y&&v!==+v&&(v=p.d.NONE)):(q=C,v!==+v&&(Y=!1));var r=C="",B=!1;/^[~^$*|]?=$/.test(a[c])&&(C=a[c++],r=a[c++],/^[0-9A-Za-z:_\-]+$/.test(r)?r='"'+r+'"':"]"===r&&(r='""',--c),/^"([^\"\\]|\\.)*"$/.test(r)||(Y=!1),(B="i"===a[c])&&++c);"]"!==a[c]&&(++c,Y=!1);switch(v){case p.d.CLASSES:case p.d.LOCAL_NAME:case p.d.NONE:break;case p.d.GLOBAL_NAME:case p.d.ID:case p.d.IDREF:"="!==C&&"~="!==C&&"$="!==C||'""'==r||B?"|="===C||""===C||(Y=!1):r='"'+r.substring(1,
|
||||
r.length-1)+f+'"';break;case p.d.URI:case p.d.URI_FRAGMENT:""!==C&&(Y=!1);break;default:Y=!1}Y&&(l+="["+q.replace(/[^\w-]/g,"\\$&")+C+r+(B?" i]":"]"))}else if(c<d&&":"===a[c])if(v=a[++c],F.test(v))n+=":"+v;else break;else break;c!==d&&(Y=!1);Y&&(c=(h+k).replace(/[^ .*#\w-]/g,"\\$&")+l+n+e)&&m.push(c);return Y}" "===a[d]&&++d;k-1!==d&&" "===a[k]&&--k;for(var m=[],n=d,v=!0,C=d;v&&C<k;++C){var q=a[C];if(E[q]===E||" "===q)l(n,C,q)?n=C+1:v=!1}l(n,k,"")||(v=!1);return v?(m.length&&(n=m.join(""),null!==
|
||||
e&&(n="."+e+" "+n),h.push(n)),!0):!c||c(a.slice(d,k))}var e=b.na,f=b.L,g=b.Aa,h=[],k=0,l,m=0,n;for(l=0;l<a.length;++l)(n=a[l],"("==n||"["==n?(++m,0):")"==n||"]"==n?(m&&--m,0):" "==a[l]&&(m||E[a[l-1]]===E||E[a[l+1]]===E))||(a[k++]=a[l]);a.length=k;k=a.length;for(l=m=0;l<k;++l)if(","===a[l]){if(!d(m,l))return null;m=l+1}return d(m,k)?h:null};(function(){var a=/^\w/,b=/^(?:(?:(?:(?:only|not) )?(?:all|aural|braille|embossed|handheld|print|projection|screen|speech|tty|tv)|\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))(?: and ?\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))*)(?: , (?:(?:(?:(?:only|not) )?(?:all|aural|braille|embossed|handheld|print|projection|screen|speech|tty|tv)|\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))(?: and ?\( (?:(?:min-|max-)?(?:(?:device-)?(?:aspect-ratio|height|width)|color(?:-index)?|monochrome|orientation|resolution)|grid|hover|luminosity|pointer|scan|script) (?:: -?(?:[a-z]\w+(?:-\w+)*|\d+(?: \/ \d+|(?:\.\d+)?(?:p[cxt]|[cem]m|in|dpi|dppx|dpcm|%)?)) )?\))*))*$/i;
|
||||
l=function(c){c=c.slice();for(var d=c.length,e=0,f=0;f<d;++f){var g=c[f];" "!=g&&(c[e++]=g)}c.length=e;c=c.join(" ");return c.length?b.test(c)?a.test(c)?c:"not all , "+c:"not all":""}})();(function(){function a(a){var b=/^\s*[']([^']*)[']\s*$/,c=/^\s*url\s*[(]["]([^"]*)["][)]\s*$/,d=/^\s*url\s*[(][']([^']*)['][)]\s*$/,e=/^\s*url\s*[(]([^)]*)[)]\s*$/,f;return(f=/^\s*["]([^"]*)["]\s*$/.exec(a))||(f=b.exec(a))||(f=c.exec(a))||(f=d.exec(a))||(f=e.exec(a))?f[1]:null}function b(c,e,f,k,p,q,r){function C(){t=
|
||||
G.length&&null===G[G.length-1]}var v=void 0,B=r||[0],G=[],t=!1;m(e,{startStylesheet:function(){v=[]},endStylesheet:function(){},startAtrule:function(e,g){if(t)e=null;else if("@media"===e)v.push("@media"," ",l(g));else if("@keyframes"===e||"@-webkit-keyframes"===e){var h=g[0];1!==g.length||/__$|[^\w\-]/.test(h)?e=null:(v.push(e," ",h+f.L),e="@keyframes")}else if("@import"===e&&0<g.length)if(e=null,"function"===typeof q){var m=l(g.slice(1));if("not all"!==m){++B[0];var C=[];v.push(C);var r=n(d(c,a(g[0])),
|
||||
function(a){var c=b(r,a.qa,f,k,p,q,B);--B[0];a=m?{toString:function(){return"@media "+m+" {"+c.result+"}"}}:c.result;C[0]=a;q(a,!!B[0])},p)}}else window.console&&window.console.log("@import "+g.join(" ")+" elided");t=!e;G.push(e)},endAtrule:function(){G.pop();t||v.push(";");C()},startBlock:function(){t||v.push("{")},endBlock:function(){t||(v.push("}"),t=!0)},startRuleset:function(a){if(!t){var b=void 0;"@keyframes"===G[G.length-1]?(b=a.join(" ").match(/^ *(?:from|to|\d+(?:\.\d+)?%) *(?:, *(?:from|to|\d+(?:\.\d+)?%) *)*$/i),
|
||||
t=!b,b&&(b=b[0].replace(/ +/g,""))):(a=h(a,f),a&&a.length?b=a.join(", "):t=!0);t||v.push(b,"{")}G.push(null)},endRuleset:function(){G.pop();t||v.push("}");C()},declaration:function(a,b){if(!t){var d=!1,e=b.length;2<=e&&"!"===b[e-2]&&"important"===b[e-1].toLowerCase()&&(d=!0,b.length-=2);g(a,b,k,c,f.L);b.length&&v.push(a,":",b.join(" "),d?" !important;":";")}}});return{result:{toString:function(){return v.join("")}},va:!!B[0]}}k=function(a,c,d,e){return b(a,c,d,e,void 0,void 0).result.toString()}})()})();
|
||||
H.length&&null===H[H.length-1]}var v=void 0,B=r||[0],H=[],t=!1;m(e,{startStylesheet:function(){v=[]},endStylesheet:function(){},startAtrule:function(e,g){if(t)e=null;else if("@media"===e)v.push("@media"," ",l(g));else if("@keyframes"===e||"@-webkit-keyframes"===e){var h=g[0];1!==g.length||/__$|[^\w\-]/.test(h)?e=null:(v.push(e," ",h+f.L),e="@keyframes")}else if("@import"===e&&0<g.length)if(e=null,"function"===typeof q){var m=l(g.slice(1));if("not all"!==m){++B[0];var C=[];v.push(C);var r=n(d(c,a(g[0])),
|
||||
function(a){var c=b(r,a.qa,f,k,p,q,B);--B[0];a=m?{toString:function(){return"@media "+m+" {"+c.result+"}"}}:c.result;C[0]=a;q(a,!!B[0])},p)}}else window.console&&window.console.log("@import "+g.join(" ")+" elided");t=!e;H.push(e)},endAtrule:function(){H.pop();t||v.push(";");C()},startBlock:function(){t||v.push("{")},endBlock:function(){t||(v.push("}"),t=!0)},startRuleset:function(a){if(!t){var b=void 0;"@keyframes"===H[H.length-1]?(b=a.join(" ").match(/^ *(?:from|to|\d+(?:\.\d+)?%) *(?:, *(?:from|to|\d+(?:\.\d+)?%) *)*$/i),
|
||||
t=!b,b&&(b=b[0].replace(/ +/g,""))):(a=h(a,f),a&&a.length?b=a.join(", "):t=!0);t||v.push(b,"{")}H.push(null)},endRuleset:function(){H.pop();t||v.push("}");C()},declaration:function(a,b){if(!t){var d=!1,e=b.length;2<=e&&"!"===b[e-2]&&"important"===b[e-1].toLowerCase()&&(d=!0,b.length-=2);g(a,b,k,c,f.L);b.length&&v.push(a,":",b.join(" "),d?" !important;":";")}}});return{result:{toString:function(){return v.join("")}},va:!!B[0]}}k=function(a,c,d,e){return b(a,c,d,e,void 0,void 0).result.toString()}})()})();
|
||||
"undefined"!==typeof window&&(window.sanitizeCssProperty=g,window.sanitizeCssSelectorList=h,window.sanitizeStylesheet=k,window.sanitizeMediaQuery=l);var m,n;(function(){function a(a,c,d,e,f){for(var g=c++;c<d&&"{"!==a[c]&&";"!==a[c];)++c;if(c<d&&(f||";"===a[c])){f=g+1;var h=c;f<d&&" "===a[f]&&++f;h>f&&" "===a[h-1]&&--h;e.startAtrule&&e.startAtrule(a[g].toLowerCase(),a.slice(f,h));c="{"===a[c]?b(a,c,d,e):c+1;e.endAtrule&&e.endAtrule()}return c}function b(d,e,f,g){++e;for(g.startBlock&&g.startBlock();e<
|
||||
f;){var h=d[e].charAt(0);if("}"==h){++e;break}e=" "===h||";"===h?e+1:"@"===h?a(d,e,f,g,!1):"{"===h?b(d,e,f,g):c(d,e,f,g)}g.endBlock&&g.endBlock();return e}function c(a,b,c,d){var f=b,h=e(a,b,c,!0);if(0>h)return h=~h,h===f?h+1:h;var k=a[h];if("{"!==k)return h===f?h+1:h;b=h+1;h>f&&" "===a[h-1]&&--h;for(d.startRuleset&&d.startRuleset(a.slice(f,h));b<c;){k=a[b];if("}"===k){++b;break}b=" "===k?b+1:g(a,b,c,d)}d.endRuleset&&d.endRuleset();return b}function e(a,b,c,d){for(var e,f=[],g=-1;b<c;++b)if(e=a[b].charAt(0),
|
||||
"["===e||"("===e)f[++g]=e;else if("]"===e&&"["===f[g]||")"===e&&"("===f[g])--g;else if("{"===e||"}"===e||";"===e||"@"===e||":"===e&&!d)break;0<=g&&(b=~(b+1));return b}function f(a,b,c){for(;b<c&&";"!==a[b]&&"}"!==a[b];)++b;return b<c&&";"===a[b]?b+1:b}function g(a,b,c,d){var g=a[b++];if(!h.test(g))return f(a,b,c);b<c&&" "===a[b]&&++b;if(b==c||":"!==a[b])return f(a,b,c);++b;b<c&&" "===a[b]&&++b;var k=e(a,b,c,!1);if(0>k)k=~k;else{for(var l=[],m=0,n=b;n<k;++n)b=a[n]," "!==b&&(l[m++]=b);if(k<c){do{b=
|
||||
|
@ -71,21 +71,21 @@ frameset:"HTMLFrameSetElement",h1:"HTMLHeadingElement",h2:"HTMLHeadingElement",h
|
|||
li:"HTMLLIElement",link:"HTMLLinkElement",map:"HTMLMapElement",mark:"HTMLElement",menu:"HTMLMenuElement",meta:"HTMLMetaElement",meter:"HTMLMeterElement",nav:"HTMLElement",nobr:"HTMLElement",noembed:"HTMLElement",noframes:"HTMLElement",noscript:"HTMLElement",object:"HTMLObjectElement",ol:"HTMLOListElement",optgroup:"HTMLOptGroupElement",option:"HTMLOptionElement",output:"HTMLOutputElement",p:"HTMLParagraphElement",param:"HTMLParamElement",pre:"HTMLPreElement",progress:"HTMLProgressElement",q:"HTMLQuoteElement",
|
||||
s:"HTMLElement",samp:"HTMLElement",script:"HTMLScriptElement",section:"HTMLElement",select:"HTMLSelectElement",small:"HTMLElement",source:"HTMLSourceElement",span:"HTMLSpanElement",strike:"HTMLElement",strong:"HTMLElement",style:"HTMLStyleElement",sub:"HTMLElement",summary:"HTMLElement",sup:"HTMLElement",table:"HTMLTableElement",tbody:"HTMLTableSectionElement",td:"HTMLTableDataCellElement",textarea:"HTMLTextAreaElement",tfoot:"HTMLTableSectionElement",th:"HTMLTableHeaderCellElement",thead:"HTMLTableSectionElement",
|
||||
time:"HTMLTimeElement",title:"HTMLTitleElement",tr:"HTMLTableRowElement",track:"HTMLTrackElement",tt:"HTMLElement",u:"HTMLElement",ul:"HTMLUListElement","var":"HTMLElement",video:"HTMLVideoElement",wbr:"HTMLElement"};p.ELEMENT_DOM_INTERFACES=p.Q;p.P={NOT_LOADED:0,SAME_DOCUMENT:1,NEW_DOCUMENT:2};p.ueffects=p.P;p.J={"a::href":2,"area::href":2,"audio::src":1,"blockquote::cite":0,"command::icon":1,"del::cite":0,"form::action":2,"img::src":1,"input::src":1,"ins::cite":0,"q::cite":0,"video::poster":1,"video::src":1};
|
||||
p.URIEFFECTS=p.J;p.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};p.ltypes=p.M;p.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};p.LOADERTYPES=p.I;"undefined"!==typeof window&&(window.html4=p);a=function(a){function b(a,b){var c;if(ba.hasOwnProperty(b))c=ba[b];else{var d=b.match(X);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(v))?String.fromCharCode(parseInt(d[1],
|
||||
16)):G&&Q.test(b)?(G.innerHTML="&"+b+";",d=G.textContent,ba[b]=d):"&"+b+";"}return c}function c(a){return a.replace(ca,b)}function d(a){return(""+a).replace(J,"&").replace(T,"<").replace(ea,">").replace(aa,""")}function e(a){return a.replace(N,"&$1").replace(T,"<").replace(ea,">")}function g(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
|
||||
d=a+"";if(W)d=d.split(e);else{for(var f=[],g=0,h;null!==(h=e.exec(d));)f.push(d.substring(g,h.index)),f.push(h[0]),g=h.index+h[0].length;f.push(d.substring(g));d=f}k(b,d,0,{r:!1,C:!1},c)}}function h(a,b,c,d,e){return function(){k(a,b,c,d,e)}}function k(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var g,k,n,v=c.length;d<v;){var p=c[d++],C=c[d];switch(p){case "&":M.test(C)?(b.e&&b.e("&"+C,f,O,h(b,c,d,e,f)),d++):b.e&&b.e("&",f,O,h(b,c,d,e,f));break;case "</":if(g=/^([-\w:]+)[^\'\"]*/.exec(C))if(g[0].length===
|
||||
C.length&&">"===c[d+1])d+=2,n=g[1].toLowerCase(),b.t&&b.t(n,f,O,h(b,c,d,e,f));else{var Z=c,R=d,q=b,r=f,Y=O,G=e,Q=m(Z,R);Q?(q.t&&q.t(Q.name,r,Y,h(q,Z,R,G,r)),d=Q.next):d=Z.length}else b.e&&b.e("</",f,O,h(b,c,d,e,f));break;case "<":if(g=/^([-\w:]+)\s*\/?/.exec(C))if(g[0].length===C.length&&">"===c[d+1]){d+=2;n=g[1].toLowerCase();b.w&&b.w(n,[],f,O,h(b,c,d,e,f));var t=a.f[n];t&U&&(d=l(c,{name:n,next:d,c:t},b,f,O,e))}else{var Z=c,R=b,q=f,r=O,Y=e,B=m(Z,d);B?(R.w&&R.w(B.name,B.R,q,r,h(R,Z,B.next,Y,q)),
|
||||
d=B.c&U?l(Z,B,R,q,r,Y):B.next):d=Z.length}else b.e&&b.e("<",f,O,h(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(k=d+1;k<v&&(">"!==c[k]||!/--$/.test(c[k-1]));k++);if(k<v){if(b.A){var u=c.slice(d,k).join("");b.A(u.substr(0,u.length-2),f,O,h(b,c,k+1,e,f))}d=k+1}else e.C=!0}e.C&&b.e&&b.e("<!--",f,O,h(b,c,d,e,f));break;case "<!":if(/^\w/.test(C)){if(!e.r){for(k=d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<!",f,O,h(b,c,d,e,f))}else b.e&&b.e("<!",f,O,h(b,c,d,e,f));break;case "<?":if(!e.r){for(k=
|
||||
d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<?",f,O,h(b,c,d,e,f));break;case ">":b.e&&b.e(">",f,O,h(b,c,d,e,f));break;case "":break;default:b.e&&b.e(p,f,O,h(b,c,d,e,f))}}b.B&&b.B(f)}catch(ma){if(ma!==O)throw ma;}}function l(b,c,d,f,g,k){var l=b.length;R.hasOwnProperty(c.name)||(R[c.name]=RegExp("^"+c.name+"(?:[\\s\\/]|$)","i"));for(var m=R[c.name],n=c.next,v=c.next+1;v<l&&("</"!==b[v-1]||!m.test(b[v]));v++);v<l&&--v;l=b.slice(n,v).join("");if(c.c&a.c.CDATA)d.z&&d.z(l,f,g,h(d,b,
|
||||
p.URIEFFECTS=p.J;p.M={UNSANDBOXED:2,SANDBOXED:1,DATA:0};p.ltypes=p.M;p.I={"a::href":2,"area::href":2,"audio::src":2,"blockquote::cite":2,"command::icon":1,"del::cite":2,"form::action":2,"img::src":1,"input::src":1,"ins::cite":2,"q::cite":2,"video::poster":1,"video::src":2};p.LOADERTYPES=p.I;"undefined"!==typeof window&&(window.html4=p);a=function(a){function b(a,b){var c;if(ca.hasOwnProperty(b))c=ca[b];else{var d=b.match(W);c=d?String.fromCharCode(parseInt(d[1],10)):(d=b.match(v))?String.fromCharCode(parseInt(d[1],
|
||||
16)):H&&R.test(b)?(H.innerHTML="&"+b+";",d=H.textContent,ca[b]=d):"&"+b+";"}return c}function c(a){return a.replace(da,b)}function d(a){return(""+a).replace(J,"&").replace(aa,"<").replace(ea,">").replace(U,""")}function e(a){return a.replace(M,"&$1").replace(aa,"<").replace(ea,">")}function g(a){var b={z:a.z||a.cdata,A:a.A||a.comment,B:a.B||a.endDoc,t:a.t||a.endTag,e:a.e||a.pcdata,F:a.F||a.rcdata,H:a.H||a.startDoc,w:a.w||a.startTag};return function(a,c){var d,e=/(<\/|<\!--|<[!?]|[&<>])/g;
|
||||
d=a+"";if(S)d=d.split(e);else{for(var f=[],g=0,h;null!==(h=e.exec(d));)f.push(d.substring(g,h.index)),f.push(h[0]),g=h.index+h[0].length;f.push(d.substring(g));d=f}k(b,d,0,{r:!1,C:!1},c)}}function h(a,b,c,d,e){return function(){k(a,b,c,d,e)}}function k(b,c,d,e,f){try{b.H&&0==d&&b.H(f);for(var g,k,n,v=c.length;d<v;){var p=c[d++],C=c[d];switch(p){case "&":N.test(C)?(b.e&&b.e("&"+C,f,O,h(b,c,d,e,f)),d++):b.e&&b.e("&",f,O,h(b,c,d,e,f));break;case "</":if(g=/^([-\w:]+)[^\'\"]*/.exec(C))if(g[0].length===
|
||||
C.length&&">"===c[d+1])d+=2,n=g[1].toLowerCase(),b.t&&b.t(n,f,O,h(b,c,d,e,f));else{var Y=c,Q=d,q=b,r=f,X=O,R=e,H=m(Y,Q);H?(q.t&&q.t(H.name,r,X,h(q,Y,Q,R,r)),d=H.next):d=Y.length}else b.e&&b.e("</",f,O,h(b,c,d,e,f));break;case "<":if(g=/^([-\w:]+)\s*\/?/.exec(C))if(g[0].length===C.length&&">"===c[d+1]){d+=2;n=g[1].toLowerCase();b.w&&b.w(n,[],f,O,h(b,c,d,e,f));var t=a.f[n];t&Z&&(d=l(c,{name:n,next:d,c:t},b,f,O,e))}else{var Y=c,Q=b,q=f,r=O,X=e,B=m(Y,d);B?(Q.w&&Q.w(B.name,B.R,q,r,h(Q,Y,B.next,X,q)),
|
||||
d=B.c&Z?l(Y,B,Q,q,r,X):B.next):d=Y.length}else b.e&&b.e("<",f,O,h(b,c,d,e,f));break;case "\x3c!--":if(!e.C){for(k=d+1;k<v&&(">"!==c[k]||!/--$/.test(c[k-1]));k++);if(k<v){if(b.A){var u=c.slice(d,k).join("");b.A(u.substr(0,u.length-2),f,O,h(b,c,k+1,e,f))}d=k+1}else e.C=!0}e.C&&b.e&&b.e("<!--",f,O,h(b,c,d,e,f));break;case "<!":if(/^\w/.test(C)){if(!e.r){for(k=d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<!",f,O,h(b,c,d,e,f))}else b.e&&b.e("<!",f,O,h(b,c,d,e,f));break;case "<?":if(!e.r){for(k=
|
||||
d+1;k<v&&">"!==c[k];k++);k<v?d=k+1:e.r=!0}e.r&&b.e&&b.e("<?",f,O,h(b,c,d,e,f));break;case ">":b.e&&b.e(">",f,O,h(b,c,d,e,f));break;case "":break;default:b.e&&b.e(p,f,O,h(b,c,d,e,f))}}b.B&&b.B(f)}catch(ha){if(ha!==O)throw ha;}}function l(b,c,d,f,g,k){var l=b.length;Q.hasOwnProperty(c.name)||(Q[c.name]=RegExp("^"+c.name+"(?:[\\s\\/]|$)","i"));for(var m=Q[c.name],n=c.next,v=c.next+1;v<l&&("</"!==b[v-1]||!m.test(b[v]));v++);v<l&&--v;l=b.slice(n,v).join("");if(c.c&a.c.CDATA)d.z&&d.z(l,f,g,h(d,b,
|
||||
v,k,f));else if(c.c&a.c.RCDATA)d.F&&d.F(e(l),f,g,h(d,b,v,k,f));else throw Error("bug");return v}function m(b,d){var e=/^([-\w:]+)/.exec(b[d]),f={};f.name=e[1].toLowerCase();f.c=a.f[f.name];for(var g=b[d].substr(e[0].length),h=d+1,k=b.length;h<k&&">"!==b[h];h++)g+=b[h];if(!(k<=h)){for(var l=[];""!==g;)if(e=P.exec(g))if(e[4]&&!e[5]||e[6]&&!e[7]){for(var e=e[4]||e[6],m=!1,g=[g,b[h++]];h<k;h++){if(m){if(">"===b[h])break}else 0<=b[h].indexOf(e)&&(m=!0);g.push(b[h])}if(k<=h)break;g=g.join("")}else{var m=
|
||||
e[1].toLowerCase(),n;if(e[2]){n=e[3];var v=n.charCodeAt(0);if(34===v||39===v)n=n.substr(1,n.length-2);n=c(n.replace(I,""))}else n="";l.push(m,n);g=g.substr(e[0].length)}else g=g.replace(/^[\s\S][^a-z\s]*/,"");f.R=l;f.next=h+1;return f}}function n(b){function c(a,b){f||b.push(a)}var e,f;return g({startDoc:function(){e=[];f=!1},startTag:function(c,g,h){if(!f&&a.f.hasOwnProperty(c)){var k=a.f[c];if(!(k&a.c.FOLDABLE)){var l=b(c,g);if(l){if("object"!==typeof l)throw Error("tagPolicy did not return object (old API?)");
|
||||
if("attribs"in l)g=l.attribs;else throw Error("tagPolicy gave no attribs");var m;"tagName"in l?(m=l.tagName,l=a.f[m]):(m=c,l=k);if(k&a.c.OPTIONAL_ENDTAG){var n=e[e.length-1];n&&n.D===c&&(n.v!==m||c!==m)&&h.push("</",n.v,">")}k&a.c.EMPTY||e.push({D:c,v:m});h.push("<",m);c=0;for(n=g.length;c<n;c+=2){var v=g[c],C=g[c+1];null!==C&&void 0!==C&&h.push(" ",v,'="',d(C),'"')}h.push(">");k&a.c.EMPTY&&!(l&a.c.EMPTY)&&h.push("</",m,">")}else f=!(k&a.c.EMPTY)}}},endTag:function(b,c){if(f)f=!1;else if(a.f.hasOwnProperty(b)){var d=
|
||||
a.f[b];if(!(d&(a.c.EMPTY|a.c.FOLDABLE))){if(d&a.c.OPTIONAL_ENDTAG)for(d=e.length;0<=--d;){var g=e[d].D;if(g===b)break;if(!(a.f[g]&a.c.OPTIONAL_ENDTAG))return}else for(d=e.length;0<=--d&&e[d].D!==b;);if(!(0>d)){for(g=e.length;--g>d;){var h=e[g].v;a.f[h]&a.c.OPTIONAL_ENDTAG||c.push("</",h,">")}d<e.length&&(b=e[d].v);e.length=d;c.push("</",b,">")}}}},pcdata:c,rcdata:c,cdata:c,endDoc:function(a){for(;e.length;e.length--)a.push("</",e[e.length-1].v,">")}})}function p(a,b,c,d,e){if(!e)return null;try{var g=
|
||||
f.parse(""+a);if(g&&(!g.K()||fa.test(g.W()))){var h=e(g,b,c,d);return h?h.toString():null}}catch(ia){}return null}function r(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function C(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function L(b,c,d,e,f){for(var g=0;g<c.length;g+=2){var h=c[g],k=c[g+1],l=k,m=null,n;if((n=
|
||||
b+"::"+h,a.m.hasOwnProperty(n))||(n="*::"+h,a.m.hasOwnProperty(n)))m=a.m[n];if(null!==m)switch(m){case a.d.NONE:break;case a.d.SCRIPT:k=null;f&&r(f,b,h,l,k);break;case a.d.STYLE:if("undefined"===typeof V){k=null;f&&r(f,b,h,l,k);break}var v=[];V(k,{declaration:function(b,c){var e=b.toLowerCase();S(e,c,d?function(b){return p(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&v.push(e+": "+c.join(" "))}});k=0<v.length?v.join(" ; "):null;f&&r(f,b,h,l,k);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:k=
|
||||
e?e(k):k;f&&r(f,b,h,l,k);break;case a.d.URI:k=p(k,C(a.J,b,h),C(a.I,b,h),{TYPE:"MARKUP",XML_ATTR:h,XML_TAG:b},d);f&&r(f,b,h,l,k);break;case a.d.URI_FRAGMENT:k&&"#"===k.charAt(0)?(k=k.substring(1),k=e?e(k):k,null!==k&&void 0!==k&&(k="#"+k)):k=null;f&&r(f,b,h,l,k);break;default:k=null,f&&r(f,b,h,l,k)}else k=null,f&&r(f,b,h,l,k);c[g+1]=k}return c}function K(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&r(d,e,void 0,void 0,void 0);else return{attribs:L(e,f,b,c,d)}}}function H(a,b){var c=[];n(b)(a,
|
||||
c);return c.join("")}var V,S;"undefined"!==typeof window&&(V=window.parseCssDeclarations,S=window.sanitizeCssProperty);var ba={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},X=/^#(\d+)$/,v=/^#x([0-9A-Fa-f]+)$/,Q=/^[A-Za-z][A-za-z0-9]+$/,G="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,I=/\0/g,ca=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,M=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,J=/&/g,N=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,T=
|
||||
/[<]/g,ea=/>/g,aa=/\"/g,P=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,W=3==="a,b".split(/(,)/).length,U=a.c.CDATA|a.c.RCDATA,O={},R={},fa=/^(?:https?|mailto|data)$/i,Y={};Y.pa=Y.escapeAttrib=d;Y.ra=Y.makeHtmlSanitizer=n;Y.sa=Y.makeSaxParser=g;Y.ta=Y.makeTagPolicy=K;Y.wa=Y.normalizeRCData=e;Y.xa=Y.sanitize=function(a,b,c,d){return H(a,K(b,c,d))};Y.ya=Y.sanitizeAttribs=L;Y.za=Y.sanitizeWithPolicy=H;Y.Ba=Y.unescapeEntities=c;return Y}(p);c=a.sanitize;"undefined"!==
|
||||
f.parse(""+a);if(g&&(!g.K()||fa.test(g.W()))){var h=e(g,b,c,d);return h?h.toString():null}}catch(na){}return null}function r(a,b,c,d,e){c||a(b+" removed",{S:"removed",tagName:b});if(d!==e){var f="changed";d&&!e?f="removed":!d&&e&&(f="added");a(b+"."+c+" "+f,{S:f,tagName:b,la:c,oldValue:d,newValue:e})}}function C(a,b,c){b=b+"::"+c;if(a.hasOwnProperty(b))return a[b];b="*::"+c;if(a.hasOwnProperty(b))return a[b]}function L(b,c,d,e,f){for(var g=0;g<c.length;g+=2){var h=c[g],k=c[g+1],l=k,m=null,n;if((n=
|
||||
b+"::"+h,a.m.hasOwnProperty(n))||(n="*::"+h,a.m.hasOwnProperty(n)))m=a.m[n];if(null!==m)switch(m){case a.d.NONE:break;case a.d.SCRIPT:k=null;f&&r(f,b,h,l,k);break;case a.d.STYLE:if("undefined"===typeof V){k=null;f&&r(f,b,h,l,k);break}var v=[];V(k,{declaration:function(b,c){var e=b.toLowerCase();T(e,c,d?function(b){return p(b,a.P.ja,a.M.ka,{TYPE:"CSS",CSS_PROP:e},d)}:null);c.length&&v.push(e+": "+c.join(" "))}});k=0<v.length?v.join(" ; "):null;f&&r(f,b,h,l,k);break;case a.d.ID:case a.d.IDREF:case a.d.IDREFS:case a.d.GLOBAL_NAME:case a.d.LOCAL_NAME:case a.d.CLASSES:k=
|
||||
e?e(k):k;f&&r(f,b,h,l,k);break;case a.d.URI:k=p(k,C(a.J,b,h),C(a.I,b,h),{TYPE:"MARKUP",XML_ATTR:h,XML_TAG:b},d);f&&r(f,b,h,l,k);break;case a.d.URI_FRAGMENT:k&&"#"===k.charAt(0)?(k=k.substring(1),k=e?e(k):k,null!==k&&void 0!==k&&(k="#"+k)):k=null;f&&r(f,b,h,l,k);break;default:k=null,f&&r(f,b,h,l,k)}else k=null,f&&r(f,b,h,l,k);c[g+1]=k}return c}function K(b,c,d){return function(e,f){if(a.f[e]&a.c.UNSAFE)d&&r(d,e,void 0,void 0,void 0);else return{attribs:L(e,f,b,c,d)}}}function G(a,b){var c=[];n(b)(a,
|
||||
c);return c.join("")}var V,T;"undefined"!==typeof window&&(V=window.parseCssDeclarations,T=window.sanitizeCssProperty);var ca={lt:"<",LT:"<",gt:">",GT:">",amp:"&",AMP:"&",quot:'"',apos:"'",nbsp:" "},W=/^#(\d+)$/,v=/^#x([0-9A-Fa-f]+)$/,R=/^[A-Za-z][A-za-z0-9]+$/,H="undefined"!==typeof window&&window.document?window.document.createElement("textarea"):null,I=/\0/g,da=/&(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/g,N=/^(#[0-9]+|#[xX][0-9A-Fa-f]+|\w+);/,J=/&/g,M=/&([^a-z#]|#(?:[^0-9x]|x(?:[^0-9a-f]|$)|$)|$)/gi,aa=
|
||||
/[<]/g,ea=/>/g,U=/\"/g,P=/^\s*([-.:\w]+)(?:\s*(=)\s*((")[^"]*("|$)|(')[^']*('|$)|(?=[a-z][-\w]*\s*=)|[^"'\s]*))?/i,S=3==="a,b".split(/(,)/).length,Z=a.c.CDATA|a.c.RCDATA,O={},Q={},fa=/^(?:https?|mailto|data)$/i,X={};X.pa=X.escapeAttrib=d;X.ra=X.makeHtmlSanitizer=n;X.sa=X.makeSaxParser=g;X.ta=X.makeTagPolicy=K;X.wa=X.normalizeRCData=e;X.xa=X.sanitize=function(a,b,c,d){return G(a,K(b,c,d))};X.ya=X.sanitizeAttribs=L;X.za=X.sanitizeWithPolicy=G;X.Ba=X.unescapeEntities=c;return X}(p);c=a.sanitize;"undefined"!==
|
||||
typeof window&&(window.html=a,window.html_sanitize=c)})();var Base64={_keyStr:"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",encode:function(a,b){var c="",d,e,f,g,h,k,l=0;for(null!=b&&b||(a=Base64._utf8_encode(a));l<a.length;)d=a.charCodeAt(l++),e=a.charCodeAt(l++),f=a.charCodeAt(l++),g=d>>2,d=(d&3)<<4|e>>4,h=(e&15)<<2|f>>6,k=f&63,isNaN(e)?h=k=64:isNaN(f)&&(k=64),c=c+this._keyStr.charAt(g)+this._keyStr.charAt(d)+this._keyStr.charAt(h)+this._keyStr.charAt(k);return c},decode:function(a,b){b=null!=b?b:!1;var c="",d,e,f,g,h,k=0;for(a=a.replace(/[^A-Za-z0-9\+\/\=]/g,
|
||||
"");k<a.length;)d=this._keyStr.indexOf(a.charAt(k++)),e=this._keyStr.indexOf(a.charAt(k++)),g=this._keyStr.indexOf(a.charAt(k++)),h=this._keyStr.indexOf(a.charAt(k++)),d=d<<2|e>>4,e=(e&15)<<4|g>>2,f=(g&3)<<6|h,c+=String.fromCharCode(d),64!=g&&(c+=String.fromCharCode(e)),64!=h&&(c+=String.fromCharCode(f));b||(c=Base64._utf8_decode(c));return c},_utf8_encode:function(a){a=a.replace(/\r\n/g,"\n");for(var b="",c=0;c<a.length;c++){var d=a.charCodeAt(c);128>d?b+=String.fromCharCode(d):(127<d&&2048>d?b+=
|
||||
String.fromCharCode(d>>6|192):(b+=String.fromCharCode(d>>12|224),b+=String.fromCharCode(d>>6&63|128)),b+=String.fromCharCode(d&63|128))}return b},_utf8_decode:function(a){var b="",c=0,d;for(c1=c2=0;c<a.length;)d=a.charCodeAt(c),128>d?(b+=String.fromCharCode(d),c++):191<d&&224>d?(c2=a.charCodeAt(c+1),b+=String.fromCharCode((d&31)<<6|c2&63),c+=2):(c2=a.charCodeAt(c+1),c3=a.charCodeAt(c+2),b+=String.fromCharCode((d&15)<<12|(c2&63)<<6|c3&63),c+=3);return b}};!function(a){"object"==typeof exports&&"undefined"!=typeof module?module.exports=a():"function"==typeof define&&define.amd?define([],a):("undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:this).pako=a()}(function(){return function b(c,d,e){function f(h,l){if(!d[h]){if(!c[h]){var k="function"==typeof require&&require;if(!l&&k)return k(h,!0);if(g)return g(h,!0);k=Error("Cannot find module '"+h+"'");throw k.code="MODULE_NOT_FOUND",k;}k=d[h]={exports:{}};
|
||||
|
@ -107,76 +107,76 @@ d?(c[h++]=192|d>>>6,c[h++]=128|63&d):65536>d?(c[h++]=224|d>>>12,c[h++]=128|d>>>6
|
|||
2===h?31:3===h?15:7;1<h&&d<l;)g=g<<6|63&b[d++],h--;1<h?m[f++]=65533:65536>g?m[f++]=g:(g-=65536,m[f++]=55296|g>>10&1023,m[f++]=56320|1023&g)}return e(m,f)};d.utf8border=function(b,c){var d;c=c||b.length;c>b.length&&(c=b.length);for(d=c-1;0<=d&&128===(192&b[d]);)d--;return 0>d?c:0===d?c:d+k[b[d]]>c?d:c}},{"./common":3}],5:[function(b,c,d){c.exports=function(b,c,d,h){var e=65535&b|0;b=b>>>16&65535|0;for(var f;0!==d;){f=2E3<d?2E3:d;d-=f;do e=e+c[h++]|0,b=b+e|0;while(--f);e%=65521;b%=65521}return e|b<<
|
||||
16|0}},{}],6:[function(b,c,d){c.exports={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}},{}],7:[function(b,c,d){var e=function(){for(var b,c=[],d=0;256>d;d++){b=d;for(var e=
|
||||
0;8>e;e++)b=1&b?3988292384^b>>>1:b>>>1;c[d]=b}return c}();c.exports=function(b,c,d,k){d=k+d;for(b^=-1;k<d;k++)b=b>>>8^e[255&(b^c[k])];return b^-1}},{}],8:[function(b,c,d){function e(b,c){return b.msg=B[c],c}function f(b){for(var c=b.length;0<=--c;)b[c]=0}function g(b){var c=b.state,d=c.pending;d>b.avail_out&&(d=b.avail_out);0!==d&&(u.arraySet(b.output,c.pending_buf,c.pending_out,d,b.next_out),b.next_out+=d,c.pending_out+=d,b.total_out+=d,b.avail_out-=d,c.pending-=d,0===c.pending&&(c.pending_out=0))}
|
||||
function h(b,c){D._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function k(b,c){b.pending_buf[b.pending++]=c}function l(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function m(b,c){var d,e,f=b.max_chain_length,g=b.strstart,h=b.prev_length,k=b.nice_match,l=b.strstart>b.w_size-T?b.strstart-(b.w_size-T):0,m=b.window,v=b.w_mask,n=b.prev,C=b.strstart+N,p=m[g+h-1],q=m[g+h];b.prev_length>=b.good_match&&(f>>=
|
||||
2);k>b.lookahead&&(k=b.lookahead);do if(d=c,m[d+h]===q&&m[d+h-1]===p&&m[d]===m[g]&&m[++d]===m[g+1]){g+=2;for(d++;m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&g<C;);if(e=N-(C-g),g=C-N,e>h){if(b.match_start=c,h=e,e>=k)break;p=m[g+h-1];q=m[g+h]}}while((c=n[c&v])>l&&0!==--f);return h<=b.lookahead?h:b.lookahead}function n(b){var c,d,e,f,g=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=g+(g-T)){u.arraySet(b.window,
|
||||
function h(b,c){D._tr_flush_block(b,0<=b.block_start?b.block_start:-1,b.strstart-b.block_start,c);b.block_start=b.strstart;g(b.strm)}function k(b,c){b.pending_buf[b.pending++]=c}function l(b,c){b.pending_buf[b.pending++]=c>>>8&255;b.pending_buf[b.pending++]=255&c}function m(b,c){var d,e,f=b.max_chain_length,g=b.strstart,h=b.prev_length,k=b.nice_match,l=b.strstart>b.w_size-aa?b.strstart-(b.w_size-aa):0,m=b.window,v=b.w_mask,n=b.prev,C=b.strstart+M,p=m[g+h-1],q=m[g+h];b.prev_length>=b.good_match&&(f>>=
|
||||
2);k>b.lookahead&&(k=b.lookahead);do if(d=c,m[d+h]===q&&m[d+h-1]===p&&m[d]===m[g]&&m[++d]===m[g+1]){g+=2;for(d++;m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&m[++g]===m[++d]&&g<C;);if(e=M-(C-g),g=C-M,e>h){if(b.match_start=c,h=e,e>=k)break;p=m[g+h-1];q=m[g+h]}}while((c=n[c&v])>l&&0!==--f);return h<=b.lookahead?h:b.lookahead}function n(b){var c,d,e,f,g=b.w_size;do{if(f=b.window_size-b.lookahead-b.strstart,b.strstart>=g+(g-aa)){u.arraySet(b.window,
|
||||
b.window,g,g,0);b.match_start-=g;b.strstart-=g;b.block_start-=g;c=d=b.hash_size;do e=b.head[--c],b.head[c]=e>=g?e-g:0;while(--d);c=d=g;do e=b.prev[--c],b.prev[c]=e>=g?e-g:0;while(--d);f+=g}if(0===b.strm.avail_in)break;c=b.strm;e=b.window;var h=b.strstart+b.lookahead,k=c.avail_in;if(d=(k>f&&(k=f),0===k?0:(c.avail_in-=k,u.arraySet(e,c.input,c.next_in,k,h),1===c.state.wrap?c.adler=F(c.adler,e,k,h):2===c.state.wrap&&(c.adler=E(c.adler,e,k,h)),c.next_in+=k,c.total_in+=k,k)),b.lookahead+=d,b.lookahead+
|
||||
b.insert>=J)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+J-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<J)););}while(b.lookahead<T&&0!==b.strm.avail_in)}function p(b,c){for(var d,e;;){if(b.lookahead<T){if(n(b),b.lookahead<T&&c===A)return P;if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
|
||||
J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-T&&(b.match_length=m(b,d)),b.match_length>=J)if(e=D._tr_tally(b,b.strstart-b.match_start,b.match_length-J),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=J){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
|
||||
b.strstart++}else b.strstart+=b.match_length,b.match_length=0,b.ins_h=b.window[b.strstart],b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+1])&b.hash_mask;else e=D._tr_tally(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++;if(e&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?U:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:W}function r(b,c){for(var d,e,f;;){if(b.lookahead<T){if(n(b),b.lookahead<T&&c===A)return P;if(0===
|
||||
b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),b.prev_length=b.match_length,b.prev_match=b.match_start,b.match_length=J-1,0!==d&&b.prev_length<b.max_lazy_match&&b.strstart-d<=b.w_size-T&&(b.match_length=m(b,d),5>=b.match_length&&(b.strategy===V||b.match_length===J&&4096<b.strstart-b.match_start)&&(b.match_length=J-1)),b.prev_length>=J&&b.match_length<=b.prev_length){f=
|
||||
b.insert>=J)for(f=b.strstart-b.insert,b.ins_h=b.window[f],b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+1])&b.hash_mask;b.insert&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[f+J-1])&b.hash_mask,b.prev[f&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=f,f++,b.insert--,!(b.lookahead+b.insert<J)););}while(b.lookahead<aa&&0!==b.strm.avail_in)}function p(b,c){for(var d,e;;){if(b.lookahead<aa){if(n(b),b.lookahead<aa&&c===A)return P;if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+
|
||||
J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),0!==d&&b.strstart-d<=b.w_size-aa&&(b.match_length=m(b,d)),b.match_length>=J)if(e=D._tr_tally(b,b.strstart-b.match_start,b.match_length-J),b.lookahead-=b.match_length,b.match_length<=b.max_lazy_match&&b.lookahead>=J){b.match_length--;do b.strstart++,b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart;while(0!==--b.match_length);
|
||||
b.strstart++}else b.strstart+=b.match_length,b.match_length=0,b.ins_h=b.window[b.strstart],b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+1])&b.hash_mask;else e=D._tr_tally(b,0,b.window[b.strstart]),b.lookahead--,b.strstart++;if(e&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:S}function r(b,c){for(var d,e,f;;){if(b.lookahead<aa){if(n(b),b.lookahead<aa&&c===A)return P;
|
||||
if(0===b.lookahead)break}if(d=0,b.lookahead>=J&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart),b.prev_length=b.match_length,b.prev_match=b.match_start,b.match_length=J-1,0!==d&&b.prev_length<b.max_lazy_match&&b.strstart-d<=b.w_size-aa&&(b.match_length=m(b,d),5>=b.match_length&&(b.strategy===V||b.match_length===J&&4096<b.strstart-b.match_start)&&(b.match_length=J-1)),b.prev_length>=J&&b.match_length<=b.prev_length){f=
|
||||
b.strstart+b.lookahead-J;e=D._tr_tally(b,b.strstart-1-b.prev_match,b.prev_length-J);b.lookahead-=b.prev_length-1;b.prev_length-=2;do++b.strstart<=f&&(b.ins_h=(b.ins_h<<b.hash_shift^b.window[b.strstart+J-1])&b.hash_mask,d=b.prev[b.strstart&b.w_mask]=b.head[b.ins_h],b.head[b.ins_h]=b.strstart);while(0!==--b.prev_length);if(b.match_available=0,b.match_length=J-1,b.strstart++,e&&(h(b,!1),0===b.strm.avail_out))return P}else if(b.match_available){if(e=D._tr_tally(b,0,b.window[b.strstart-1]),e&&h(b,!1),
|
||||
b.strstart++,b.lookahead--,0===b.strm.avail_out)return P}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(D._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?U:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:W}function q(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function t(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
|
||||
this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=X;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
|
||||
this.ins_h=0;this.dyn_ltree=new u.Buf16(2*ca);this.dyn_dtree=new u.Buf16(2*(2*G+1));this.bl_tree=new u.Buf16(2*(2*I+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new u.Buf16(M+1);this.heap=new u.Buf16(2*Q+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new u.Buf16(2*Q+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function z(b){var c;
|
||||
return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ba,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ea:aa,b.adler=2===c.wrap?0:1,c.last_flush=A,D._tr_init(c),L):e(b,K)}function w(b){var c=z(b);c===L&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=y[b.level].max_lazy,b.good_match=y[b.level].good_length,b.nice_match=y[b.level].nice_length,b.max_chain_length=y[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
|
||||
b.prev_length=J-1,b.match_available=0,b.ins_h=0);return c}function x(b,c,d,f,g,h){if(!b)return K;var k=1;if(c===H&&(c=6),0>f?(k=0,f=-f):15<f&&(k=2,f-=16),1>g||g>v||d!==X||8>f||15<f||0>c||9<c||0>h||h>S)return e(b,K);8===f&&(f=9);var l=new t;return b.state=l,l.strm=b,l.wrap=k,l.gzhead=null,l.w_bits=f,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=g+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+J-1)/J),l.window=new u.Buf8(2*l.w_size),l.head=new u.Buf16(l.hash_size),
|
||||
l.prev=new u.Buf16(l.w_size),l.lit_bufsize=1<<g+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new u.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=c,l.strategy=h,l.method=d,w(b)}var y,u=b("../utils/common"),D=b("./trees"),F=b("./adler32"),E=b("./crc32"),B=b("./messages"),A=0,C=4,L=0,K=-2,H=-1,V=1,S=4,ba=2,X=8,v=9,Q=286,G=30,I=19,ca=2*Q+1,M=15,J=3,N=258,T=N+J+1,ea=42,aa=113,P=1,W=2,U=3,O=4;y=[new q(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
|
||||
(d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(n(b),0===b.lookahead&&c===A)return P;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,h(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-T&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=0,c===C?(h(b,!0),0===b.strm.avail_out?U:O):(b.strstart>b.block_start&&h(b,!1),P)}),new q(4,4,8,4,p),new q(4,5,16,8,p),new q(4,6,32,
|
||||
32,p),new q(4,4,16,16,r),new q(8,16,32,32,r),new q(8,16,128,128,r),new q(8,32,128,256,r),new q(32,128,258,1024,r),new q(32,258,258,4096,r)];d.deflateInit=function(b,c){return x(b,c,X,15,8,0)};d.deflateInit2=x;d.deflateReset=w;d.deflateResetKeep=z;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?K:(b.state.gzhead=c,L):K};d.deflate=function(b,c){var d,m,v,p;if(!b||!b.state||5<c||0>c)return b?e(b,K):K;if(m=b.state,!b.output||!b.input&&0!==b.avail_in||666===m.status&&c!==C)return e(b,
|
||||
b.strstart++,b.lookahead--,0===b.strm.avail_out)return P}else b.match_available=1,b.strstart++,b.lookahead--}return b.match_available&&(D._tr_tally(b,0,b.window[b.strstart-1]),b.match_available=0),b.insert=b.strstart<J-1?b.strstart:J-1,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):b.last_lit&&(h(b,!1),0===b.strm.avail_out)?P:S}function q(b,c,d,e,f){this.good_length=b;this.max_lazy=c;this.nice_length=d;this.max_chain=e;this.func=f}function t(){this.strm=null;this.status=0;this.pending_buf=null;this.wrap=
|
||||
this.pending=this.pending_out=this.pending_buf_size=0;this.gzhead=null;this.gzindex=0;this.method=W;this.last_flush=-1;this.w_mask=this.w_bits=this.w_size=0;this.window=null;this.window_size=0;this.head=this.prev=null;this.nice_match=this.good_match=this.strategy=this.level=this.max_lazy_match=this.max_chain_length=this.prev_length=this.lookahead=this.match_start=this.strstart=this.match_available=this.prev_match=this.match_length=this.block_start=this.hash_shift=this.hash_mask=this.hash_bits=this.hash_size=
|
||||
this.ins_h=0;this.dyn_ltree=new u.Buf16(2*da);this.dyn_dtree=new u.Buf16(2*(2*H+1));this.bl_tree=new u.Buf16(2*(2*I+1));f(this.dyn_ltree);f(this.dyn_dtree);f(this.bl_tree);this.bl_desc=this.d_desc=this.l_desc=null;this.bl_count=new u.Buf16(N+1);this.heap=new u.Buf16(2*R+1);f(this.heap);this.heap_max=this.heap_len=0;this.depth=new u.Buf16(2*R+1);f(this.depth);this.bi_valid=this.bi_buf=this.insert=this.matches=this.static_len=this.opt_len=this.d_buf=this.last_lit=this.lit_bufsize=this.l_buf=0}function z(b){var c;
|
||||
return b&&b.state?(b.total_in=b.total_out=0,b.data_type=ca,c=b.state,c.pending=0,c.pending_out=0,0>c.wrap&&(c.wrap=-c.wrap),c.status=c.wrap?ea:U,b.adler=2===c.wrap?0:1,c.last_flush=A,D._tr_init(c),L):e(b,K)}function w(b){var c=z(b);c===L&&(b=b.state,b.window_size=2*b.w_size,f(b.head),b.max_lazy_match=y[b.level].max_lazy,b.good_match=y[b.level].good_length,b.nice_match=y[b.level].nice_length,b.max_chain_length=y[b.level].max_chain,b.strstart=0,b.block_start=0,b.lookahead=0,b.insert=0,b.match_length=
|
||||
b.prev_length=J-1,b.match_available=0,b.ins_h=0);return c}function x(b,c,d,f,g,h){if(!b)return K;var k=1;if(c===G&&(c=6),0>f?(k=0,f=-f):15<f&&(k=2,f-=16),1>g||g>v||d!==W||8>f||15<f||0>c||9<c||0>h||h>T)return e(b,K);8===f&&(f=9);var l=new t;return b.state=l,l.strm=b,l.wrap=k,l.gzhead=null,l.w_bits=f,l.w_size=1<<l.w_bits,l.w_mask=l.w_size-1,l.hash_bits=g+7,l.hash_size=1<<l.hash_bits,l.hash_mask=l.hash_size-1,l.hash_shift=~~((l.hash_bits+J-1)/J),l.window=new u.Buf8(2*l.w_size),l.head=new u.Buf16(l.hash_size),
|
||||
l.prev=new u.Buf16(l.w_size),l.lit_bufsize=1<<g+6,l.pending_buf_size=4*l.lit_bufsize,l.pending_buf=new u.Buf8(l.pending_buf_size),l.d_buf=1*l.lit_bufsize,l.l_buf=3*l.lit_bufsize,l.level=c,l.strategy=h,l.method=d,w(b)}var y,u=b("../utils/common"),D=b("./trees"),F=b("./adler32"),E=b("./crc32"),B=b("./messages"),A=0,C=4,L=0,K=-2,G=-1,V=1,T=4,ca=2,W=8,v=9,R=286,H=30,I=19,da=2*R+1,N=15,J=3,M=258,aa=M+J+1,ea=42,U=113,P=1,S=2,Z=3,O=4;y=[new q(0,0,0,0,function(b,c){var d=65535;for(d>b.pending_buf_size-5&&
|
||||
(d=b.pending_buf_size-5);;){if(1>=b.lookahead){if(n(b),0===b.lookahead&&c===A)return P;if(0===b.lookahead)break}b.strstart+=b.lookahead;b.lookahead=0;var e=b.block_start+d;if((0===b.strstart||b.strstart>=e)&&(b.lookahead=b.strstart-e,b.strstart=e,h(b,!1),0===b.strm.avail_out)||b.strstart-b.block_start>=b.w_size-aa&&(h(b,!1),0===b.strm.avail_out))return P}return b.insert=0,c===C?(h(b,!0),0===b.strm.avail_out?Z:O):(b.strstart>b.block_start&&h(b,!1),P)}),new q(4,4,8,4,p),new q(4,5,16,8,p),new q(4,6,
|
||||
32,32,p),new q(4,4,16,16,r),new q(8,16,32,32,r),new q(8,16,128,128,r),new q(8,32,128,256,r),new q(32,128,258,1024,r),new q(32,258,258,4096,r)];d.deflateInit=function(b,c){return x(b,c,W,15,8,0)};d.deflateInit2=x;d.deflateReset=w;d.deflateResetKeep=z;d.deflateSetHeader=function(b,c){return b&&b.state?2!==b.state.wrap?K:(b.state.gzhead=c,L):K};d.deflate=function(b,c){var d,m,v,p;if(!b||!b.state||5<c||0>c)return b?e(b,K):K;if(m=b.state,!b.output||!b.input&&0!==b.avail_in||666===m.status&&c!==C)return e(b,
|
||||
0===b.avail_out?-5:K);if(m.strm=b,d=m.last_flush,m.last_flush=c,m.status===ea)2===m.wrap?(b.adler=0,k(m,31),k(m,139),k(m,8),m.gzhead?(k(m,(m.gzhead.text?1:0)+(m.gzhead.hcrc?2:0)+(m.gzhead.extra?4:0)+(m.gzhead.name?8:0)+(m.gzhead.comment?16:0)),k(m,255&m.gzhead.time),k(m,m.gzhead.time>>8&255),k(m,m.gzhead.time>>16&255),k(m,m.gzhead.time>>24&255),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,255&m.gzhead.os),m.gzhead.extra&&m.gzhead.extra.length&&(k(m,255&m.gzhead.extra.length),k(m,m.gzhead.extra.length>>
|
||||
8&255)),m.gzhead.hcrc&&(b.adler=E(b.adler,m.pending_buf,m.pending,0)),m.gzindex=0,m.status=69):(k(m,0),k(m,0),k(m,0),k(m,0),k(m,0),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,3),m.status=aa)):(v=X+(m.w_bits-8<<4)<<8,v|=(2<=m.strategy||2>m.level?0:6>m.level?1:6===m.level?2:3)<<6,0!==m.strstart&&(v|=32),m.status=aa,l(m,v+(31-v%31)),0!==m.strstart&&(l(m,b.adler>>>16),l(m,65535&b.adler)),b.adler=1);if(69===m.status)if(m.gzhead.extra){for(v=m.pending;m.gzindex<(65535&m.gzhead.extra.length)&&(m.pending!==
|
||||
8&255)),m.gzhead.hcrc&&(b.adler=E(b.adler,m.pending_buf,m.pending,0)),m.gzindex=0,m.status=69):(k(m,0),k(m,0),k(m,0),k(m,0),k(m,0),k(m,9===m.level?2:2<=m.strategy||2>m.level?4:0),k(m,3),m.status=U)):(v=W+(m.w_bits-8<<4)<<8,v|=(2<=m.strategy||2>m.level?0:6>m.level?1:6===m.level?2:3)<<6,0!==m.strstart&&(v|=32),m.status=U,l(m,v+(31-v%31)),0!==m.strstart&&(l(m,b.adler>>>16),l(m,65535&b.adler)),b.adler=1);if(69===m.status)if(m.gzhead.extra){for(v=m.pending;m.gzindex<(65535&m.gzhead.extra.length)&&(m.pending!==
|
||||
m.pending_buf_size||(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v)),g(b),v=m.pending,m.pending!==m.pending_buf_size));)k(m,255&m.gzhead.extra[m.gzindex]),m.gzindex++;m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));m.gzindex===m.gzhead.extra.length&&(m.gzindex=0,m.status=73)}else m.status=73;if(73===m.status)if(m.gzhead.name){v=m.pending;do{if(m.pending===m.pending_buf_size&&(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-
|
||||
v,v)),g(b),v=m.pending,m.pending===m.pending_buf_size)){p=1;break}p=m.gzindex<m.gzhead.name.length?255&m.gzhead.name.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.gzindex=0,m.status=91)}else m.status=91;if(91===m.status)if(m.gzhead.comment){v=m.pending;do{if(m.pending===m.pending_buf_size&&(m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v)),g(b),v=m.pending,m.pending===m.pending_buf_size)){p=
|
||||
1;break}p=m.gzindex<m.gzhead.comment.length?255&m.gzhead.comment.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.status=103)}else m.status=103;if(103===m.status&&(m.gzhead.hcrc?(m.pending+2>m.pending_buf_size&&g(b),m.pending+2<=m.pending_buf_size&&(k(m,255&b.adler),k(m,b.adler>>8&255),b.adler=0,m.status=aa)):m.status=aa),0!==m.pending){if(g(b),0===b.avail_out)return m.last_flush=-1,L}else if(0===b.avail_in&&(c<<1)-
|
||||
(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==C)return e(b,-5);if(666===m.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==m.lookahead||c!==A&&666!==m.status){var q;if(2===m.strategy)a:{for(var r;;){if(0===m.lookahead&&(n(m),0===m.lookahead)){if(c===A){q=P;break a}break}if(m.match_length=0,r=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++,r&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?U:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?
|
||||
P:W)}else if(3===m.strategy)a:{var Q,G;for(r=m.window;;){if(m.lookahead<=N){if(n(m),m.lookahead<=N&&c===A){q=P;break a}if(0===m.lookahead)break}if(m.match_length=0,m.lookahead>=J&&0<m.strstart&&(G=m.strstart-1,Q=r[G],Q===r[++G]&&Q===r[++G]&&Q===r[++G])){for(d=m.strstart+N;Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&Q===r[++G]&&G<d;);m.match_length=N-(d-G);m.match_length>m.lookahead&&(m.match_length=m.lookahead)}if(m.match_length>=J?(q=D._tr_tally(m,1,m.match_length-
|
||||
J),m.lookahead-=m.match_length,m.strstart+=m.match_length,m.match_length=0):(q=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++),q&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?U:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?P:W)}else q=y[m.level].func(m,c);if(q!==U&&q!==O||(m.status=666),q===P||q===U)return 0===b.avail_out&&(m.last_flush=-1),L;if(q===W&&(1===c?D._tr_align(m):5!==c&&(D._tr_stored_block(m,0,0,!1),3===c&&(f(m.head),0===
|
||||
1;break}p=m.gzindex<m.gzhead.comment.length?255&m.gzhead.comment.charCodeAt(m.gzindex++):0;k(m,p)}while(0!==p);m.gzhead.hcrc&&m.pending>v&&(b.adler=E(b.adler,m.pending_buf,m.pending-v,v));0===p&&(m.status=103)}else m.status=103;if(103===m.status&&(m.gzhead.hcrc?(m.pending+2>m.pending_buf_size&&g(b),m.pending+2<=m.pending_buf_size&&(k(m,255&b.adler),k(m,b.adler>>8&255),b.adler=0,m.status=U)):m.status=U),0!==m.pending){if(g(b),0===b.avail_out)return m.last_flush=-1,L}else if(0===b.avail_in&&(c<<1)-
|
||||
(4<c?9:0)<=(d<<1)-(4<d?9:0)&&c!==C)return e(b,-5);if(666===m.status&&0!==b.avail_in)return e(b,-5);if(0!==b.avail_in||0!==m.lookahead||c!==A&&666!==m.status){var q;if(2===m.strategy)a:{for(var r;;){if(0===m.lookahead&&(n(m),0===m.lookahead)){if(c===A){q=P;break a}break}if(m.match_length=0,r=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++,r&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?Z:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?
|
||||
P:S)}else if(3===m.strategy)a:{var H,R;for(r=m.window;;){if(m.lookahead<=M){if(n(m),m.lookahead<=M&&c===A){q=P;break a}if(0===m.lookahead)break}if(m.match_length=0,m.lookahead>=J&&0<m.strstart&&(R=m.strstart-1,H=r[R],H===r[++R]&&H===r[++R]&&H===r[++R])){for(d=m.strstart+M;H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&H===r[++R]&&R<d;);m.match_length=M-(d-R);m.match_length>m.lookahead&&(m.match_length=m.lookahead)}if(m.match_length>=J?(q=D._tr_tally(m,1,m.match_length-
|
||||
J),m.lookahead-=m.match_length,m.strstart+=m.match_length,m.match_length=0):(q=D._tr_tally(m,0,m.window[m.strstart]),m.lookahead--,m.strstart++),q&&(h(m,!1),0===m.strm.avail_out)){q=P;break a}}q=(m.insert=0,c===C?(h(m,!0),0===m.strm.avail_out?Z:O):m.last_lit&&(h(m,!1),0===m.strm.avail_out)?P:S)}else q=y[m.level].func(m,c);if(q!==Z&&q!==O||(m.status=666),q===P||q===Z)return 0===b.avail_out&&(m.last_flush=-1),L;if(q===S&&(1===c?D._tr_align(m):5!==c&&(D._tr_stored_block(m,0,0,!1),3===c&&(f(m.head),0===
|
||||
m.lookahead&&(m.strstart=0,m.block_start=0,m.insert=0))),g(b),0===b.avail_out))return m.last_flush=-1,L}return c!==C?L:0>=m.wrap?1:(2===m.wrap?(k(m,255&b.adler),k(m,b.adler>>8&255),k(m,b.adler>>16&255),k(m,b.adler>>24&255),k(m,255&b.total_in),k(m,b.total_in>>8&255),k(m,b.total_in>>16&255),k(m,b.total_in>>24&255)):(l(m,b.adler>>>16),l(m,65535&b.adler)),g(b),0<m.wrap&&(m.wrap=-m.wrap),0!==m.pending?L:1)};d.deflateEnd=function(b){var c;return b&&b.state?(c=b.state.status,c!==ea&&69!==c&&73!==c&&91!==
|
||||
c&&103!==c&&c!==aa&&666!==c?e(b,K):(b.state=null,c===aa?e(b,-3):L)):K};d.deflateSetDictionary=function(b,c){var d,e,g,h,k,m,l;e=c.length;if(!b||!b.state||(d=b.state,h=d.wrap,2===h||1===h&&d.status!==ea||d.lookahead))return K;1===h&&(b.adler=F(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===h&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),k=new u.Buf8(d.w_size),u.arraySet(k,c,e-d.w_size,d.w_size,0),c=k,e=d.w_size);k=b.avail_in;m=b.next_in;l=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(n(d);d.lookahead>=
|
||||
c&&103!==c&&c!==U&&666!==c?e(b,K):(b.state=null,c===U?e(b,-3):L)):K};d.deflateSetDictionary=function(b,c){var d,e,g,h,k,m,l;e=c.length;if(!b||!b.state||(d=b.state,h=d.wrap,2===h||1===h&&d.status!==ea||d.lookahead))return K;1===h&&(b.adler=F(b.adler,c,e,0));d.wrap=0;e>=d.w_size&&(0===h&&(f(d.head),d.strstart=0,d.block_start=0,d.insert=0),k=new u.Buf8(d.w_size),u.arraySet(k,c,e-d.w_size,d.w_size,0),c=k,e=d.w_size);k=b.avail_in;m=b.next_in;l=b.input;b.avail_in=e;b.next_in=0;b.input=c;for(n(d);d.lookahead>=
|
||||
J;){e=d.strstart;g=d.lookahead-(J-1);do d.ins_h=(d.ins_h<<d.hash_shift^d.window[e+J-1])&d.hash_mask,d.prev[e&d.w_mask]=d.head[d.ins_h],d.head[d.ins_h]=e,e++;while(--g);d.strstart=e;d.lookahead=J-1;n(d)}return d.strstart+=d.lookahead,d.block_start=d.strstart,d.insert=d.lookahead,d.lookahead=0,d.match_length=d.prev_length=J-1,d.match_available=0,b.next_in=m,b.input=l,b.avail_in=k,d.wrap=h,L};d.deflateInfo="pako deflate (from Nodeca project)"},{"../utils/common":3,"./adler32":5,"./crc32":7,"./messages":13,
|
||||
"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,l,m,n,p,r,q,t,z,w,x,y,u,D,F,E,B,A,C,L,K,H;d=b.state;e=b.next_in;K=b.input;f=e+(b.avail_in-5);l=b.next_out;H=b.output;m=l-(c-b.avail_out);n=l+(b.avail_out-257);p=d.dmax;r=d.wsize;q=d.whave;t=d.wnext;z=d.window;w=d.hold;x=d.bits;y=d.lencode;u=d.distcode;D=(1<<d.lenbits)-
|
||||
1;F=(1<<d.distbits)-1;a:do b:for(15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8),E=y[w&D];;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,0===B)H[l++]=65535&E;else{if(!(16&B)){if(0===(64&B)){E=y[(65535&E)+(w&(1<<B)-1)];continue b}if(32&B){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}A=65535&E;(B&=15)&&(x<B&&(w+=K[e++]<<x,x+=8),A+=w&(1<<B)-1,w>>>=B,x-=B);15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8);E=u[w&F];c:for(;;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,!(16&B)){if(0===(64&B)){E=u[(65535&
|
||||
E)+(w&(1<<B)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(C=65535&E,B&=15,x<B&&(w+=K[e++]<<x,x+=8,x<B&&(w+=K[e++]<<x,x+=8)),C+=w&(1<<B)-1,C>p){b.msg="invalid distance too far back";d.mode=30;break a}if(w>>>=B,x-=B,B=l-m,C>B){if(B=C-B,B>q&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(E=0,L=z,0===t){if(E+=r-B,B<A){A-=B;do H[l++]=z[E++];while(--B);E=l-C;L=H}}else if(t<B){if(E+=r+t-B,B-=t,B<A){A-=B;do H[l++]=z[E++];while(--B);if(E=0,t<A){B=t;A-=B;do H[l++]=z[E++];
|
||||
while(--B);E=l-C;L=H}}}else if(E+=t-B,B<A){A-=B;do H[l++]=z[E++];while(--B);E=l-C;L=H}for(;2<A;)H[l++]=L[E++],H[l++]=L[E++],H[l++]=L[E++],A-=3;A&&(H[l++]=L[E++],1<A&&(H[l++]=L[E++]))}else{E=l-C;do H[l++]=H[E++],H[l++]=H[E++],H[l++]=H[E++],A-=3;while(2<A);A&&(H[l++]=H[E++],1<A&&(H[l++]=H[E++]))}break}}break}while(e<f&&l<n);A=x>>3;e-=A;x-=A<<3;b.next_in=e;b.next_out=l;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=l<n?257+(n-l):257-(l-n);d.hold=w&(1<<x)-1;d.bits=x}},{}],11:[function(b,c,d){function e(b){return(b>>>
|
||||
"./trees":14}],9:[function(b,c,d){c.exports=function(){this.os=this.xflags=this.time=this.text=0;this.extra=null;this.extra_len=0;this.comment=this.name="";this.hcrc=0;this.done=!1}},{}],10:[function(b,c,d){c.exports=function(b,c){var d,e,f,l,m,n,p,r,q,t,z,w,x,y,u,D,F,E,B,A,C,L,K,G;d=b.state;e=b.next_in;K=b.input;f=e+(b.avail_in-5);l=b.next_out;G=b.output;m=l-(c-b.avail_out);n=l+(b.avail_out-257);p=d.dmax;r=d.wsize;q=d.whave;t=d.wnext;z=d.window;w=d.hold;x=d.bits;y=d.lencode;u=d.distcode;D=(1<<d.lenbits)-
|
||||
1;F=(1<<d.distbits)-1;a:do b:for(15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8),E=y[w&D];;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,0===B)G[l++]=65535&E;else{if(!(16&B)){if(0===(64&B)){E=y[(65535&E)+(w&(1<<B)-1)];continue b}if(32&B){d.mode=12;break a}b.msg="invalid literal/length code";d.mode=30;break a}A=65535&E;(B&=15)&&(x<B&&(w+=K[e++]<<x,x+=8),A+=w&(1<<B)-1,w>>>=B,x-=B);15>x&&(w+=K[e++]<<x,x+=8,w+=K[e++]<<x,x+=8);E=u[w&F];c:for(;;){if(B=E>>>24,w>>>=B,x-=B,B=E>>>16&255,!(16&B)){if(0===(64&B)){E=u[(65535&
|
||||
E)+(w&(1<<B)-1)];continue c}b.msg="invalid distance code";d.mode=30;break a}if(C=65535&E,B&=15,x<B&&(w+=K[e++]<<x,x+=8,x<B&&(w+=K[e++]<<x,x+=8)),C+=w&(1<<B)-1,C>p){b.msg="invalid distance too far back";d.mode=30;break a}if(w>>>=B,x-=B,B=l-m,C>B){if(B=C-B,B>q&&d.sane){b.msg="invalid distance too far back";d.mode=30;break a}if(E=0,L=z,0===t){if(E+=r-B,B<A){A-=B;do G[l++]=z[E++];while(--B);E=l-C;L=G}}else if(t<B){if(E+=r+t-B,B-=t,B<A){A-=B;do G[l++]=z[E++];while(--B);if(E=0,t<A){B=t;A-=B;do G[l++]=z[E++];
|
||||
while(--B);E=l-C;L=G}}}else if(E+=t-B,B<A){A-=B;do G[l++]=z[E++];while(--B);E=l-C;L=G}for(;2<A;)G[l++]=L[E++],G[l++]=L[E++],G[l++]=L[E++],A-=3;A&&(G[l++]=L[E++],1<A&&(G[l++]=L[E++]))}else{E=l-C;do G[l++]=G[E++],G[l++]=G[E++],G[l++]=G[E++],A-=3;while(2<A);A&&(G[l++]=G[E++],1<A&&(G[l++]=G[E++]))}break}}break}while(e<f&&l<n);A=x>>3;e-=A;x-=A<<3;b.next_in=e;b.next_out=l;b.avail_in=e<f?5+(f-e):5-(e-f);b.avail_out=l<n?257+(n-l):257-(l-n);d.hold=w&(1<<x)-1;d.bits=x}},{}],11:[function(b,c,d){function e(b){return(b>>>
|
||||
24&255)+(b>>>8&65280)+((65280&b)<<8)+((255&b)<<24)}function f(){this.mode=0;this.last=!1;this.wrap=0;this.havedict=!1;this.total=this.check=this.dmax=this.flags=0;this.head=null;this.wnext=this.whave=this.wsize=this.wbits=0;this.window=null;this.extra=this.offset=this.length=this.bits=this.hold=0;this.distcode=this.lencode=null;this.have=this.ndist=this.nlen=this.ncode=this.distbits=this.lenbits=0;this.next=null;this.lens=new r.Buf16(320);this.work=new r.Buf16(288);this.distdyn=this.lendyn=null;this.was=
|
||||
this.back=this.sane=0}function g(b){var c;return b&&b.state?(c=b.state,b.total_in=b.total_out=c.total=0,b.msg="",c.wrap&&(b.adler=1&c.wrap),c.mode=u,c.last=0,c.havedict=0,c.dmax=32768,c.head=null,c.hold=0,c.bits=0,c.lencode=c.lendyn=new r.Buf32(D),c.distcode=c.distdyn=new r.Buf32(F),c.sane=1,c.back=-1,x):y}function h(b){var c;return b&&b.state?(c=b.state,c.wsize=0,c.whave=0,c.wnext=0,g(b)):y}function k(b,c){var d,e;return b&&b.state?(e=b.state,0>c?(d=0,c=-c):(d=(c>>4)+1,48>c&&(c&=15)),c&&(8>c||15<
|
||||
c)?y:(null!==e.window&&e.wbits!==c&&(e.window=null),e.wrap=d,e.wbits=c,h(b))):y}function l(b,c){var d,e;return b?(e=new f,b.state=e,e.window=null,d=k(b,c),d!==x&&(b.state=null),d):y}function m(b,c,d,e){var f;b=b.state;return null===b.window&&(b.wsize=1<<b.wbits,b.wnext=0,b.whave=0,b.window=new r.Buf8(b.wsize)),e>=b.wsize?(r.arraySet(b.window,c,d-b.wsize,b.wsize,0),b.wnext=0,b.whave=b.wsize):(f=b.wsize-b.wnext,f>e&&(f=e),r.arraySet(b.window,c,d-e,f,b.wnext),e-=f,e?(r.arraySet(b.window,c,d-e,e,0),b.wnext=
|
||||
e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var n,p,r=b("../utils/common"),q=b("./adler32"),t=b("./crc32"),z=b("./inffast"),w=b("./inftrees"),x=0,y=-2,u=1,D=852,F=592,E=!0;d.inflateReset=h;d.inflateReset2=k;d.inflateResetKeep=g;d.inflateInit=function(b){return l(b,15)};d.inflateInit2=l;d.inflate=function(b,c){var d,f,g,h,k,l,B,A,v,Q,G,I,ca,M,J,N,D,F,aa,P,W,U,O=0,R=new r.Buf8(4),fa=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
|
||||
!b.output||!b.input&&0!==b.avail_in)return y;d=b.state;12===d.mode&&(d.mode=13);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;Q=l;G=B;W=x;a:for(;;)switch(d.mode){case u:if(0===d.wrap){d.mode=13;break}for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(2&d.wrap&&35615===A){d.check=0;R[0]=255&A;R[1]=A>>>8&255;d.check=t(d.check,R,2,0);v=A=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&A)<<8)+(A>>8))%31){b.msg="incorrect header check";
|
||||
e,b.whave=b.wsize):(b.wnext+=f,b.wnext===b.wsize&&(b.wnext=0),b.whave<b.wsize&&(b.whave+=f))),0}var n,p,r=b("../utils/common"),q=b("./adler32"),t=b("./crc32"),z=b("./inffast"),w=b("./inftrees"),x=0,y=-2,u=1,D=852,F=592,E=!0;d.inflateReset=h;d.inflateReset2=k;d.inflateResetKeep=g;d.inflateInit=function(b){return l(b,15)};d.inflateInit2=l;d.inflate=function(b,c){var d,f,g,h,k,l,B,A,v,R,H,I,da,N,J,M,D,F,U,P,S,Z,O=0,Q=new r.Buf8(4),fa=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!b||!b.state||
|
||||
!b.output||!b.input&&0!==b.avail_in)return y;d=b.state;12===d.mode&&(d.mode=13);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;R=l;H=B;S=x;a:for(;;)switch(d.mode){case u:if(0===d.wrap){d.mode=13;break}for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(2&d.wrap&&35615===A){d.check=0;Q[0]=255&A;Q[1]=A>>>8&255;d.check=t(d.check,Q,2,0);v=A=0;d.mode=2;break}if(d.flags=0,d.head&&(d.head.done=!1),!(1&d.wrap)||(((255&A)<<8)+(A>>8))%31){b.msg="incorrect header check";
|
||||
d.mode=30;break}if(8!==(15&A)){b.msg="unknown compression method";d.mode=30;break}if(A>>>=4,v-=4,P=(15&A)+8,0===d.wbits)d.wbits=P;else if(P>d.wbits){b.msg="invalid window size";d.mode=30;break}d.dmax=1<<P;b.adler=d.check=1;d.mode=512&A?10:12;v=A=0;break;case 2:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(d.flags=A,8!==(255&d.flags)){b.msg="unknown compression method";d.mode=30;break}if(57344&d.flags){b.msg="unknown header flags set";d.mode=30;break}d.head&&(d.head.text=A>>8&1);512&d.flags&&
|
||||
(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0;d.mode=3;case 3:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.time=A);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,R[2]=A>>>16&255,R[3]=A>>>24&255,d.check=t(d.check,R,4,0));v=A=0;d.mode=4;case 4:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.xflags=255&A,d.head.os=A>>8);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0;d.mode=5;case 5:if(1024&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}d.length=A;d.head&&(d.head.extra_len=A);512&d.flags&&(R[0]=255&A,R[1]=A>>>8&255,d.check=t(d.check,R,2,0));v=A=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(I=d.length,I>l&&(I=l),I&&(d.head&&(P=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),r.arraySet(d.head.extra,f,h,I,P)),512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,d.length-=I),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===l)break a;I=0;do P=f[h+
|
||||
(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0;d.mode=3;case 3:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.time=A);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,Q[2]=A>>>16&255,Q[3]=A>>>24&255,d.check=t(d.check,Q,4,0));v=A=0;d.mode=4;case 4:for(;16>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.head&&(d.head.xflags=255&A,d.head.os=A>>8);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0;d.mode=5;case 5:if(1024&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}d.length=A;d.head&&(d.head.extra_len=A);512&d.flags&&(Q[0]=255&A,Q[1]=A>>>8&255,d.check=t(d.check,Q,2,0));v=A=0}else d.head&&(d.head.extra=null);d.mode=6;case 6:if(1024&d.flags&&(I=d.length,I>l&&(I=l),I&&(d.head&&(P=d.head.extra_len-d.length,d.head.extra||(d.head.extra=Array(d.head.extra_len)),r.arraySet(d.head.extra,f,h,I,P)),512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,d.length-=I),d.length))break a;d.length=0;d.mode=7;case 7:if(2048&d.flags){if(0===l)break a;I=0;do P=f[h+
|
||||
I++],d.head&&P&&65536>d.length&&(d.head.name+=String.fromCharCode(P));while(P&&I<l);if(512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,P)break a}else d.head&&(d.head.name=null);d.length=0;d.mode=8;case 8:if(4096&d.flags){if(0===l)break a;I=0;do P=f[h+I++],d.head&&P&&65536>d.length&&(d.head.comment+=String.fromCharCode(P));while(P&&I<l);if(512&d.flags&&(d.check=t(d.check,f,I,h)),l-=I,h+=I,P)break a}else d.head&&(d.head.comment=null);d.mode=9;case 9:if(512&d.flags){for(;16>v;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}if(A!==(65535&d.check)){b.msg="header crc mismatch";d.mode=30;break}v=A=0}d.head&&(d.head.hcrc=d.flags>>9&1,d.head.done=!0);b.adler=d.check=0;d.mode=12;break;case 10:for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}b.adler=d.check=e(A);v=A=0;d.mode=11;case 11:if(0===d.havedict)return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,2;b.adler=d.check=1;d.mode=12;case 12:if(5===c||6===c)break a;case 13:if(d.last){A>>>=7&v;v-=7&v;d.mode=27;break}for(;3>v;){if(0===
|
||||
l)break a;l--;A+=f[h++]<<v;v+=8}switch(d.last=1&A,A>>>=1,--v,3&A){case 0:d.mode=14;break;case 1:N=d;if(E){n=new r.Buf32(512);p=new r.Buf32(32);for(M=0;144>M;)N.lens[M++]=8;for(;256>M;)N.lens[M++]=9;for(;280>M;)N.lens[M++]=7;for(;288>M;)N.lens[M++]=8;w(1,N.lens,0,288,n,0,N.work,{bits:9});for(M=0;32>M;)N.lens[M++]=5;w(2,N.lens,0,32,p,0,N.work,{bits:5});E=!1}N.lencode=n;N.lenbits=9;N.distcode=p;N.distbits=5;if(d.mode=20,6===c){A>>>=2;v-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
|
||||
l)break a;l--;A+=f[h++]<<v;v+=8}switch(d.last=1&A,A>>>=1,--v,3&A){case 0:d.mode=14;break;case 1:M=d;if(E){n=new r.Buf32(512);p=new r.Buf32(32);for(N=0;144>N;)M.lens[N++]=8;for(;256>N;)M.lens[N++]=9;for(;280>N;)M.lens[N++]=7;for(;288>N;)M.lens[N++]=8;w(1,M.lens,0,288,n,0,M.work,{bits:9});for(N=0;32>N;)M.lens[N++]=5;w(2,M.lens,0,32,p,0,M.work,{bits:5});E=!1}M.lencode=n;M.lenbits=9;M.distcode=p;M.distbits=5;if(d.mode=20,6===c){A>>>=2;v-=2;break a}break;case 2:d.mode=17;break;case 3:b.msg="invalid block type",
|
||||
d.mode=30}A>>>=2;v-=2;break;case 14:A>>>=7&v;for(v-=7&v;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if((65535&A)!==(A>>>16^65535)){b.msg="invalid stored block lengths";d.mode=30;break}if(d.length=65535&A,A=0,v=0,d.mode=15,6===c)break a;case 15:d.mode=16;case 16:if(I=d.length){if(I>l&&(I=l),I>B&&(I=B),0===I)break a;r.arraySet(g,f,h,I,k);l-=I;h+=I;B-=I;k+=I;d.length-=I;break}d.mode=12;break;case 17:for(;14>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(d.nlen=(31&A)+257,A>>>=5,v-=5,d.ndist=(31&A)+
|
||||
1,A>>>=5,v-=5,d.ncode=(15&A)+4,A>>>=4,v-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.lens[fa[d.have++]]=7&A;A>>>=3;v-=3}for(;19>d.have;)d.lens[fa[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,U={bits:d.lenbits},W=w(0,d.lens,0,19,d.lencode,0,d.work,U),d.lenbits=U.bits,W){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
|
||||
d.nlen+d.ndist;){for(;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(16>N)A>>>=J,v-=J,d.lens[d.have++]=N;else{if(16===N){for(M=J+2;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A>>>=J,v-=J,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}P=d.lens[d.have-1];I=3+(3&A);A>>>=2;v-=2}else if(17===N){for(M=J+3;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=3+(7&A);A>>>=3;v-=3}else{for(M=J+7;v<M;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=11+(127&A);A>>>=7;v-=7}if(d.have+I>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;I--;)d.lens[d.have++]=P}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,U={bits:d.lenbits},W=w(1,d.lens,0,d.nlen,d.lencode,0,d.work,U),d.lenbits=U.bits,W){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,U={bits:d.distbits},W=w(2,d.lens,d.nlen,d.ndist,
|
||||
d.distcode,0,d.work,U),d.distbits=U.bits,W){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=l&&258<=B){b.next_out=k;b.avail_out=B;b.next_in=h;b.avail_in=l;d.hold=A;d.bits=v;z(b,G);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,M=O>>>16&255,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(M&&0===(240&M)){D=
|
||||
J;F=M;for(aa=N;O=d.lencode[aa+((A&(1<<D+F)-1)>>D)],J=O>>>24,M=O>>>16&255,N=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,d.length=N,0===M){d.mode=26;break}if(32&M){d.back=-1;d.mode=12;break}if(64&M){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&M;d.mode=22;case 22:if(d.extra){for(M=d.extra;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.length+=A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}d.was=d.length;d.mode=
|
||||
23;case 23:for(;O=d.distcode[A&(1<<d.distbits)-1],J=O>>>24,M=O>>>16&255,N=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(0===(240&M)){D=J;F=M;for(aa=N;O=d.distcode[aa+((A&(1<<D+F)-1)>>D)],J=O>>>24,M=O>>>16&255,N=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,64&M){b.msg="invalid distance code";d.mode=30;break}d.offset=N;d.extra=15&M;d.mode=24;case 24:if(d.extra){for(M=d.extra;v<M;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.offset+=
|
||||
A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===B)break a;if(I=G-B,d.offset>I){if(I=d.offset-I,I>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}I>d.wnext?(I-=d.wnext,ca=d.wsize-I):ca=d.wnext-I;I>d.length&&(I=d.length);M=d.window}else M=g,ca=k-d.offset,I=d.length;I>B&&(I=B);B-=I;d.length-=I;do g[k++]=M[ca++];while(--I);0===d.length&&(d.mode=21);break;case 26:if(0===B)break a;
|
||||
g[k++]=d.length;B--;d.mode=21;break;case 27:if(d.wrap){for(;32>v;){if(0===l)break a;l--;A|=f[h++]<<v;v+=8}if(G-=B,b.total_out+=G,d.total+=G,G&&(b.adler=d.check=d.flags?t(d.check,g,G,k-G):q(d.check,g,G,k-G)),G=B,(d.flags?A:e(A))!==d.check){b.msg="incorrect data check";d.mode=30;break}v=A=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}v=A=0}d.mode=29;case 29:W=1;break a;case 30:W=
|
||||
-3;break a;case 31:return-4;default:return y}return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,(d.wsize||G!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&m(b,b.output,b.next_out,G-b.avail_out)?(d.mode=31,-4):(Q-=b.avail_in,G-=b.avail_out,b.total_in+=Q,b.total_out+=G,d.total+=G,d.wrap&&G&&(b.adler=d.check=d.flags?t(d.check,g,G,b.next_out-G):q(d.check,g,G,b.next_out-G)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===Q&&0===G||4===
|
||||
c)&&W===x&&(W=-5),W)};d.inflateEnd=function(b){if(!b||!b.state)return y;var c=b.state;return c.window&&(c.window=null),b.state=null,x};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?y:(d.head=c,c.done=!1,x)):y};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?y:11===d.mode&&(e=1,e=q(e,c,f,0),e!==d.check)?-3:m(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,x)):y};d.inflateInfo="pako inflate (from Nodeca project)"},
|
||||
1,A>>>=5,v-=5,d.ncode=(15&A)+4,A>>>=4,v-=4,286<d.nlen||30<d.ndist){b.msg="too many length or distance symbols";d.mode=30;break}d.have=0;d.mode=18;case 18:for(;d.have<d.ncode;){for(;3>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.lens[fa[d.have++]]=7&A;A>>>=3;v-=3}for(;19>d.have;)d.lens[fa[d.have++]]=0;if(d.lencode=d.lendyn,d.lenbits=7,Z={bits:d.lenbits},S=w(0,d.lens,0,19,d.lencode,0,d.work,Z),d.lenbits=Z.bits,S){b.msg="invalid code lengths set";d.mode=30;break}d.have=0;d.mode=19;case 19:for(;d.have<
|
||||
d.nlen+d.ndist;){for(;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(16>M)A>>>=J,v-=J,d.lens[d.have++]=M;else{if(16===M){for(N=J+2;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A>>>=J,v-=J,0===d.have){b.msg="invalid bit length repeat";d.mode=30;break}P=d.lens[d.have-1];I=3+(3&A);A>>>=2;v-=2}else if(17===M){for(N=J+3;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=3+(7&A);A>>>=3;v-=3}else{for(N=J+7;v<N;){if(0===l)break a;l--;
|
||||
A+=f[h++]<<v;v+=8}A>>>=J;v-=J;P=0;I=11+(127&A);A>>>=7;v-=7}if(d.have+I>d.nlen+d.ndist){b.msg="invalid bit length repeat";d.mode=30;break}for(;I--;)d.lens[d.have++]=P}}if(30===d.mode)break;if(0===d.lens[256]){b.msg="invalid code -- missing end-of-block";d.mode=30;break}if(d.lenbits=9,Z={bits:d.lenbits},S=w(1,d.lens,0,d.nlen,d.lencode,0,d.work,Z),d.lenbits=Z.bits,S){b.msg="invalid literal/lengths set";d.mode=30;break}if(d.distbits=6,d.distcode=d.distdyn,Z={bits:d.distbits},S=w(2,d.lens,d.nlen,d.ndist,
|
||||
d.distcode,0,d.work,Z),d.distbits=Z.bits,S){b.msg="invalid distances set";d.mode=30;break}if(d.mode=20,6===c)break a;case 20:d.mode=21;case 21:if(6<=l&&258<=B){b.next_out=k;b.avail_out=B;b.next_in=h;b.avail_in=l;d.hold=A;d.bits=v;z(b,H);k=b.next_out;g=b.output;B=b.avail_out;h=b.next_in;f=b.input;l=b.avail_in;A=d.hold;v=d.bits;12===d.mode&&(d.back=-1);break}for(d.back=0;O=d.lencode[A&(1<<d.lenbits)-1],J=O>>>24,N=O>>>16&255,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(N&&0===(240&N)){D=
|
||||
J;F=N;for(U=M;O=d.lencode[U+((A&(1<<D+F)-1)>>D)],J=O>>>24,N=O>>>16&255,M=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,d.length=M,0===N){d.mode=26;break}if(32&N){d.back=-1;d.mode=12;break}if(64&N){b.msg="invalid literal/length code";d.mode=30;break}d.extra=15&N;d.mode=22;case 22:if(d.extra){for(N=d.extra;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.length+=A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}d.was=d.length;d.mode=23;
|
||||
case 23:for(;O=d.distcode[A&(1<<d.distbits)-1],J=O>>>24,N=O>>>16&255,M=65535&O,!(J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(0===(240&N)){D=J;F=N;for(U=M;O=d.distcode[U+((A&(1<<D+F)-1)>>D)],J=O>>>24,N=O>>>16&255,M=65535&O,!(D+J<=v);){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}A>>>=D;v-=D;d.back+=D}if(A>>>=J,v-=J,d.back+=J,64&N){b.msg="invalid distance code";d.mode=30;break}d.offset=M;d.extra=15&N;d.mode=24;case 24:if(d.extra){for(N=d.extra;v<N;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}d.offset+=
|
||||
A&(1<<d.extra)-1;A>>>=d.extra;v-=d.extra;d.back+=d.extra}if(d.offset>d.dmax){b.msg="invalid distance too far back";d.mode=30;break}d.mode=25;case 25:if(0===B)break a;if(I=H-B,d.offset>I){if(I=d.offset-I,I>d.whave&&d.sane){b.msg="invalid distance too far back";d.mode=30;break}I>d.wnext?(I-=d.wnext,da=d.wsize-I):da=d.wnext-I;I>d.length&&(I=d.length);N=d.window}else N=g,da=k-d.offset,I=d.length;I>B&&(I=B);B-=I;d.length-=I;do g[k++]=N[da++];while(--I);0===d.length&&(d.mode=21);break;case 26:if(0===B)break a;
|
||||
g[k++]=d.length;B--;d.mode=21;break;case 27:if(d.wrap){for(;32>v;){if(0===l)break a;l--;A|=f[h++]<<v;v+=8}if(H-=B,b.total_out+=H,d.total+=H,H&&(b.adler=d.check=d.flags?t(d.check,g,H,k-H):q(d.check,g,H,k-H)),H=B,(d.flags?A:e(A))!==d.check){b.msg="incorrect data check";d.mode=30;break}v=A=0}d.mode=28;case 28:if(d.wrap&&d.flags){for(;32>v;){if(0===l)break a;l--;A+=f[h++]<<v;v+=8}if(A!==(4294967295&d.total)){b.msg="incorrect length check";d.mode=30;break}v=A=0}d.mode=29;case 29:S=1;break a;case 30:S=
|
||||
-3;break a;case 31:return-4;default:return y}return b.next_out=k,b.avail_out=B,b.next_in=h,b.avail_in=l,d.hold=A,d.bits=v,(d.wsize||H!==b.avail_out&&30>d.mode&&(27>d.mode||4!==c))&&m(b,b.output,b.next_out,H-b.avail_out)?(d.mode=31,-4):(R-=b.avail_in,H-=b.avail_out,b.total_in+=R,b.total_out+=H,d.total+=H,d.wrap&&H&&(b.adler=d.check=d.flags?t(d.check,g,H,b.next_out-H):q(d.check,g,H,b.next_out-H)),b.data_type=d.bits+(d.last?64:0)+(12===d.mode?128:0)+(20===d.mode||15===d.mode?256:0),(0===R&&0===H||4===
|
||||
c)&&S===x&&(S=-5),S)};d.inflateEnd=function(b){if(!b||!b.state)return y;var c=b.state;return c.window&&(c.window=null),b.state=null,x};d.inflateGetHeader=function(b,c){var d;return b&&b.state?(d=b.state,0===(2&d.wrap)?y:(d.head=c,c.done=!1,x)):y};d.inflateSetDictionary=function(b,c){var d,e,f=c.length;return b&&b.state?(d=b.state,0!==d.wrap&&11!==d.mode?y:11===d.mode&&(e=1,e=q(e,c,f,0),e!==d.check)?-3:m(b,c,f,f)?(d.mode=31,-4):(d.havedict=1,x)):y};d.inflateInfo="pako inflate (from Nodeca project)"},
|
||||
{"../utils/common":3,"./adler32":5,"./crc32":7,"./inffast":10,"./inftrees":12}],12:[function(b,c,d){var e=b("../utils/common"),f=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],g=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],h=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],k=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,
|
||||
25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,p,r,q,t,z){var l,m,n,u,D,F,E,B,A=z.bits,C,L,K,H,V,S,ba=0,X,v=null,Q=0,G=new e.Buf16(16);u=new e.Buf16(16);var I=null,ca=0;for(C=0;15>=C;C++)G[C]=0;for(L=0;L<p;L++)G[c[d+L]]++;H=A;for(K=15;1<=K&&0===G[K];K--);if(H>K&&(H=K),0===K)return r[q++]=20971520,r[q++]=20971520,z.bits=1,0;for(A=1;A<K&&0===G[A];A++);H<A&&(H=A);for(C=l=1;15>=C;C++)if(l<<=1,l-=G[C],0>l)return-1;if(0<l&&(0===b||1!==K))return-1;u[1]=0;for(C=1;15>C;C++)u[C+1]=u[C]+G[C];
|
||||
for(L=0;L<p;L++)0!==c[d+L]&&(t[u[c[d+L]]++]=L);if(0===b?(v=I=t,D=19):1===b?(v=f,Q-=257,I=g,ca-=257,D=256):(v=h,I=k,D=-1),X=0,L=0,C=A,u=q,V=H,S=0,n=-1,ba=1<<H,p=ba-1,1===b&&852<ba||2===b&&592<ba)return 1;for(var M=0;;){M++;F=C-S;t[L]<D?(E=0,B=t[L]):t[L]>D?(E=I[ca+t[L]],B=v[Q+t[L]]):(E=96,B=0);l=1<<C-S;A=m=1<<V;do m-=l,r[u+(X>>S)+m]=F<<24|E<<16|B|0;while(0!==m);for(l=1<<C-1;X&l;)l>>=1;if(0!==l?(X&=l-1,X+=l):X=0,L++,0===--G[C]){if(C===K)break;C=c[d+t[L]]}if(C>H&&(X&p)!==n){0===S&&(S=H);u+=A;V=C-S;for(l=
|
||||
1<<V;V+S<K&&(l-=G[V+S],!(0>=l));)V++,l<<=1;if(ba+=1<<V,1===b&&852<ba||2===b&&592<ba)return 1;n=X&p;r[n]=H<<24|V<<16|u-q|0}}return 0!==X&&(r[u+X]=C-S<<24|4194304),z.bits=H,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
|
||||
b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function h(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function k(b,c,d){b.bi_valid>ba-d?(b.bi_buf|=c<<b.bi_valid&65535,h(b,b.bi_buf),b.bi_buf=c>>ba-b.bi_valid,b.bi_valid+=d-ba):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function l(b,c,d){k(b,d[2*c],d[2*c+1])}function m(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
|
||||
while(0<--c);return d>>>1}function n(b,c,d){var e,f=Array(S+1),g=0;for(e=1;e<=S;e++)f[e]=g=g+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=m(f[e]++,e))}function p(b){var c;for(c=0;c<L;c++)b.dyn_ltree[2*c]=0;for(c=0;c<K;c++)b.dyn_dtree[2*c]=0;for(c=0;c<H;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*X]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function r(b){8<b.bi_valid?h(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function q(b,c,d,e){var f=2*c,g=2*d;
|
||||
return b[f]<b[g]||b[f]===b[g]&&e[c]<=e[d]}function t(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&q(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!q(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function z(b,c,d){var e,f,g,h,m=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*m]<<8|b.pending_buf[b.d_buf+2*m+1],f=b.pending_buf[b.l_buf+m],m++,0===e?l(b,f,c):(g=aa[f],l(b,g+C+1,c),h=I[g],0!==h&&(f-=P[g],k(b,f,h)),e--,g=256>e?ea[e]:ea[256+(e>>>7)],l(b,g,d),h=ca[g],0!==h&&
|
||||
(e-=W[g],k(b,e,h)));while(m<b.last_lit)}l(b,X,c)}function w(b,c){var d,e,f,g=c.dyn_tree;e=c.stat_desc.static_tree;var h=c.stat_desc.has_stree,k=c.stat_desc.elems,l=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<k;d++)0!==g[2*d]?(b.heap[++b.heap_len]=l=d,b.depth[d]=0):g[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>l?++l:0,g[2*f]=1,b.depth[f]=0,b.opt_len--,h&&(b.static_len-=e[2*f+1]);c.max_code=l;for(d=b.heap_len>>1;1<=d;d--)t(b,g,d);f=k;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],t(b,g,1),e=b.heap[1],
|
||||
b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,g[2*f]=g[2*d]+g[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,g[2*d+1]=g[2*e+1]=f,b.heap[1]=f++,t(b,g,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var m,v,h=c.dyn_tree,k=c.max_code,p=c.stat_desc.static_tree,q=c.stat_desc.has_stree,r=c.stat_desc.extra_bits,G=c.stat_desc.extra_base,Q=c.stat_desc.max_length,I=0;for(e=0;e<=S;e++)b.bl_count[e]=0;h[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=h[2*h[2*f+1]+1]+
|
||||
1,e>Q&&(e=Q,I++),h[2*f+1]=e,f>k||(b.bl_count[e]++,m=0,f>=G&&(m=r[f-G]),v=h[2*f],b.opt_len+=v*(e+m),q&&(b.static_len+=v*(p[2*f+1]+m)));if(0!==I){do{for(e=Q-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[Q]--;I-=2}while(0<I);for(e=Q;0!==e;e--)for(f=b.bl_count[e];0!==f;)m=b.heap[--d],m>k||(h[2*m+1]!==e&&(b.opt_len+=(e-h[2*m+1])*h[2*m],h[2*m+1]=e),f--)}n(g,l,b.bl_count)}function x(b,c,d){var e,f,g=-1,h=c[1],k=0,l=7,m=4;0===h&&(l=138,m=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=h,
|
||||
h=c[2*(e+1)+1],++k<l&&f===h||(k<m?b.bl_tree[2*f]+=k:0!==f?(f!==g&&b.bl_tree[2*f]++,b.bl_tree[2*v]++):10>=k?b.bl_tree[2*Q]++:b.bl_tree[2*G]++,k=0,g=f,0===h?(l=138,m=3):f===h?(l=6,m=3):(l=7,m=4))}function y(b,c,d){var e,f,g=-1,h=c[1],m=0,n=7,p=4;0===h&&(n=138,p=3);for(e=0;e<=d;e++)if(f=h,h=c[2*(e+1)+1],!(++m<n&&f===h)){if(m<p){do l(b,f,b.bl_tree);while(0!==--m)}else 0!==f?(f!==g&&(l(b,f,b.bl_tree),m--),l(b,v,b.bl_tree),k(b,m-3,2)):10>=m?(l(b,Q,b.bl_tree),k(b,m-3,3)):(l(b,G,b.bl_tree),k(b,m-11,7));m=
|
||||
0;g=f;0===h?(n=138,p=3):f===h?(n=6,p=3):(n=7,p=4)}}function u(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return E;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return B;for(c=32;c<C;c++)if(0!==b.dyn_ltree[2*c])return B;return E}function D(b,c,d,e){k(b,(A<<1)+(e?1:0),3);r(b);h(b,d);h(b,~d);F.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var F=b("../utils/common"),E=0,B=1,A=0,C=256,L=C+1+29,K=30,H=19,V=2*L+1,S=15,ba=16,X=256,v=16,Q=17,
|
||||
G=18,I=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],ca=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],M=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],J=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],N=Array(2*(L+2));e(N);var T=Array(2*K);e(T);var ea=Array(512);e(ea);var aa=Array(256);e(aa);var P=Array(29);e(P);var W=Array(K);e(W);var U,O,R,fa=!1;d._tr_init=function(b){if(!fa){var c,d,e,h=Array(S+1);for(e=d=0;28>e;e++)for(P[e]=d,c=0;c<1<<I[e];c++)aa[d++]=e;aa[d-1]=
|
||||
e;for(e=d=0;16>e;e++)for(W[e]=d,c=0;c<1<<ca[e];c++)ea[d++]=e;for(d>>=7;e<K;e++)for(W[e]=d<<7,c=0;c<1<<ca[e]-7;c++)ea[256+d++]=e;for(c=0;c<=S;c++)h[c]=0;for(c=0;143>=c;)N[2*c+1]=8,c++,h[8]++;for(;255>=c;)N[2*c+1]=9,c++,h[9]++;for(;279>=c;)N[2*c+1]=7,c++,h[7]++;for(;287>=c;)N[2*c+1]=8,c++,h[8]++;n(N,L+1,h);for(c=0;c<K;c++)T[2*c+1]=5,T[2*c]=m(c,5);U=new f(N,I,C+1,L,S);O=new f(T,ca,0,K,S);R=new f([],M,0,H,7);fa=!0}b.l_desc=new g(b.dyn_ltree,U);b.d_desc=new g(b.dyn_dtree,O);b.bl_desc=new g(b.bl_tree,R);
|
||||
b.bi_buf=0;b.bi_valid=0;p(b)};d._tr_stored_block=D;d._tr_flush_block=function(b,c,d,e){var f,g,h=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=u(b));w(b,b.l_desc);w(b,b.d_desc);x(b,b.dyn_ltree,b.l_desc.max_code);x(b,b.dyn_dtree,b.d_desc.max_code);w(b,b.bl_desc);for(h=H-1;3<=h&&0===b.bl_tree[2*J[h]+1];h--);h=(b.opt_len+=3*(h+1)+14,h);f=b.opt_len+3+7>>>3;g=b.static_len+3+7>>>3;g<=f&&(f=g)}else f=g=d+5;if(d+4<=f&&-1!==c)D(b,c,d,e);else if(4===b.strategy||g===f)k(b,2+(e?1:0),3),z(b,N,T);else{k(b,
|
||||
4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;h+=1;k(b,c-257,5);k(b,d-1,5);k(b,h-4,4);for(f=0;f<h;f++)k(b,b.bl_tree[2*J[f]+1],3);y(b,b.dyn_ltree,c-1);y(b,b.dyn_dtree,d-1);z(b,b.dyn_ltree,b.dyn_dtree)}p(b);e&&r(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(aa[d]+C+1)]++,b.dyn_dtree[2*(256>c?ea[c]:
|
||||
ea[256+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){k(b,2,3);l(b,X,N);16===b.bi_valid?(h(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,
|
||||
25,25,26,26,27,27,28,28,29,29,64,64];c.exports=function(b,c,d,p,r,q,t,z){var l,m,n,u,D,F,E,B,A=z.bits,C,L,K,G,V,T,ca=0,W,v=null,R=0,H=new e.Buf16(16);u=new e.Buf16(16);var I=null,da=0;for(C=0;15>=C;C++)H[C]=0;for(L=0;L<p;L++)H[c[d+L]]++;G=A;for(K=15;1<=K&&0===H[K];K--);if(G>K&&(G=K),0===K)return r[q++]=20971520,r[q++]=20971520,z.bits=1,0;for(A=1;A<K&&0===H[A];A++);G<A&&(G=A);for(C=l=1;15>=C;C++)if(l<<=1,l-=H[C],0>l)return-1;if(0<l&&(0===b||1!==K))return-1;u[1]=0;for(C=1;15>C;C++)u[C+1]=u[C]+H[C];
|
||||
for(L=0;L<p;L++)0!==c[d+L]&&(t[u[c[d+L]]++]=L);if(0===b?(v=I=t,D=19):1===b?(v=f,R-=257,I=g,da-=257,D=256):(v=h,I=k,D=-1),W=0,L=0,C=A,u=q,V=G,T=0,n=-1,ca=1<<G,p=ca-1,1===b&&852<ca||2===b&&592<ca)return 1;for(var N=0;;){N++;F=C-T;t[L]<D?(E=0,B=t[L]):t[L]>D?(E=I[da+t[L]],B=v[R+t[L]]):(E=96,B=0);l=1<<C-T;A=m=1<<V;do m-=l,r[u+(W>>T)+m]=F<<24|E<<16|B|0;while(0!==m);for(l=1<<C-1;W&l;)l>>=1;if(0!==l?(W&=l-1,W+=l):W=0,L++,0===--H[C]){if(C===K)break;C=c[d+t[L]]}if(C>G&&(W&p)!==n){0===T&&(T=G);u+=A;V=C-T;for(l=
|
||||
1<<V;V+T<K&&(l-=H[V+T],!(0>=l));)V++,l<<=1;if(ca+=1<<V,1===b&&852<ca||2===b&&592<ca)return 1;n=W&p;r[n]=G<<24|V<<16|u-q|0}}return 0!==W&&(r[u+W]=C-T<<24|4194304),z.bits=G,0}},{"../utils/common":3}],13:[function(b,c,d){c.exports={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}},{}],14:[function(b,c,d){function e(b){for(var c=b.length;0<=--c;)b[c]=0}function f(b,c,d,e,f){this.static_tree=
|
||||
b;this.extra_bits=c;this.extra_base=d;this.elems=e;this.max_length=f;this.has_stree=b&&b.length}function g(b,c){this.dyn_tree=b;this.max_code=0;this.stat_desc=c}function h(b,c){b.pending_buf[b.pending++]=255&c;b.pending_buf[b.pending++]=c>>>8&255}function k(b,c,d){b.bi_valid>ca-d?(b.bi_buf|=c<<b.bi_valid&65535,h(b,b.bi_buf),b.bi_buf=c>>ca-b.bi_valid,b.bi_valid+=d-ca):(b.bi_buf|=c<<b.bi_valid&65535,b.bi_valid+=d)}function l(b,c,d){k(b,d[2*c],d[2*c+1])}function m(b,c){var d=0;do d|=1&b,b>>>=1,d<<=1;
|
||||
while(0<--c);return d>>>1}function n(b,c,d){var e,f=Array(T+1),g=0;for(e=1;e<=T;e++)f[e]=g=g+d[e-1]<<1;for(d=0;d<=c;d++)e=b[2*d+1],0!==e&&(b[2*d]=m(f[e]++,e))}function p(b){var c;for(c=0;c<L;c++)b.dyn_ltree[2*c]=0;for(c=0;c<K;c++)b.dyn_dtree[2*c]=0;for(c=0;c<G;c++)b.bl_tree[2*c]=0;b.dyn_ltree[2*W]=1;b.opt_len=b.static_len=0;b.last_lit=b.matches=0}function r(b){8<b.bi_valid?h(b,b.bi_buf):0<b.bi_valid&&(b.pending_buf[b.pending++]=b.bi_buf);b.bi_buf=0;b.bi_valid=0}function q(b,c,d,e){var f=2*c,g=2*d;
|
||||
return b[f]<b[g]||b[f]===b[g]&&e[c]<=e[d]}function t(b,c,d){for(var e=b.heap[d],f=d<<1;f<=b.heap_len&&(f<b.heap_len&&q(c,b.heap[f+1],b.heap[f],b.depth)&&f++,!q(c,e,b.heap[f],b.depth));)b.heap[d]=b.heap[f],d=f,f<<=1;b.heap[d]=e}function z(b,c,d){var e,f,g,h,m=0;if(0!==b.last_lit){do e=b.pending_buf[b.d_buf+2*m]<<8|b.pending_buf[b.d_buf+2*m+1],f=b.pending_buf[b.l_buf+m],m++,0===e?l(b,f,c):(g=U[f],l(b,g+C+1,c),h=I[g],0!==h&&(f-=P[g],k(b,f,h)),e--,g=256>e?ea[e]:ea[256+(e>>>7)],l(b,g,d),h=da[g],0!==h&&
|
||||
(e-=S[g],k(b,e,h)));while(m<b.last_lit)}l(b,W,c)}function w(b,c){var d,e,f,g=c.dyn_tree;e=c.stat_desc.static_tree;var h=c.stat_desc.has_stree,k=c.stat_desc.elems,l=-1;b.heap_len=0;b.heap_max=V;for(d=0;d<k;d++)0!==g[2*d]?(b.heap[++b.heap_len]=l=d,b.depth[d]=0):g[2*d+1]=0;for(;2>b.heap_len;)f=b.heap[++b.heap_len]=2>l?++l:0,g[2*f]=1,b.depth[f]=0,b.opt_len--,h&&(b.static_len-=e[2*f+1]);c.max_code=l;for(d=b.heap_len>>1;1<=d;d--)t(b,g,d);f=k;do d=b.heap[1],b.heap[1]=b.heap[b.heap_len--],t(b,g,1),e=b.heap[1],
|
||||
b.heap[--b.heap_max]=d,b.heap[--b.heap_max]=e,g[2*f]=g[2*d]+g[2*e],b.depth[f]=(b.depth[d]>=b.depth[e]?b.depth[d]:b.depth[e])+1,g[2*d+1]=g[2*e+1]=f,b.heap[1]=f++,t(b,g,1);while(2<=b.heap_len);b.heap[--b.heap_max]=b.heap[1];var m,v,h=c.dyn_tree,k=c.max_code,p=c.stat_desc.static_tree,q=c.stat_desc.has_stree,r=c.stat_desc.extra_bits,R=c.stat_desc.extra_base,H=c.stat_desc.max_length,I=0;for(e=0;e<=T;e++)b.bl_count[e]=0;h[2*b.heap[b.heap_max]+1]=0;for(d=b.heap_max+1;d<V;d++)f=b.heap[d],e=h[2*h[2*f+1]+1]+
|
||||
1,e>H&&(e=H,I++),h[2*f+1]=e,f>k||(b.bl_count[e]++,m=0,f>=R&&(m=r[f-R]),v=h[2*f],b.opt_len+=v*(e+m),q&&(b.static_len+=v*(p[2*f+1]+m)));if(0!==I){do{for(e=H-1;0===b.bl_count[e];)e--;b.bl_count[e]--;b.bl_count[e+1]+=2;b.bl_count[H]--;I-=2}while(0<I);for(e=H;0!==e;e--)for(f=b.bl_count[e];0!==f;)m=b.heap[--d],m>k||(h[2*m+1]!==e&&(b.opt_len+=(e-h[2*m+1])*h[2*m],h[2*m+1]=e),f--)}n(g,l,b.bl_count)}function x(b,c,d){var e,f,g=-1,h=c[1],k=0,l=7,m=4;0===h&&(l=138,m=3);c[2*(d+1)+1]=65535;for(e=0;e<=d;e++)f=h,
|
||||
h=c[2*(e+1)+1],++k<l&&f===h||(k<m?b.bl_tree[2*f]+=k:0!==f?(f!==g&&b.bl_tree[2*f]++,b.bl_tree[2*v]++):10>=k?b.bl_tree[2*R]++:b.bl_tree[2*H]++,k=0,g=f,0===h?(l=138,m=3):f===h?(l=6,m=3):(l=7,m=4))}function y(b,c,d){var e,f,g=-1,h=c[1],m=0,n=7,p=4;0===h&&(n=138,p=3);for(e=0;e<=d;e++)if(f=h,h=c[2*(e+1)+1],!(++m<n&&f===h)){if(m<p){do l(b,f,b.bl_tree);while(0!==--m)}else 0!==f?(f!==g&&(l(b,f,b.bl_tree),m--),l(b,v,b.bl_tree),k(b,m-3,2)):10>=m?(l(b,R,b.bl_tree),k(b,m-3,3)):(l(b,H,b.bl_tree),k(b,m-11,7));m=
|
||||
0;g=f;0===h?(n=138,p=3):f===h?(n=6,p=3):(n=7,p=4)}}function u(b){var c,d=4093624447;for(c=0;31>=c;c++,d>>>=1)if(1&d&&0!==b.dyn_ltree[2*c])return E;if(0!==b.dyn_ltree[18]||0!==b.dyn_ltree[20]||0!==b.dyn_ltree[26])return B;for(c=32;c<C;c++)if(0!==b.dyn_ltree[2*c])return B;return E}function D(b,c,d,e){k(b,(A<<1)+(e?1:0),3);r(b);h(b,d);h(b,~d);F.arraySet(b.pending_buf,b.window,c,d,b.pending);b.pending+=d}var F=b("../utils/common"),E=0,B=1,A=0,C=256,L=C+1+29,K=30,G=19,V=2*L+1,T=15,ca=16,W=256,v=16,R=17,
|
||||
H=18,I=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],da=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],N=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],J=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],M=Array(2*(L+2));e(M);var aa=Array(2*K);e(aa);var ea=Array(512);e(ea);var U=Array(256);e(U);var P=Array(29);e(P);var S=Array(K);e(S);var Z,O,Q,fa=!1;d._tr_init=function(b){if(!fa){var c,d,e,h=Array(T+1);for(e=d=0;28>e;e++)for(P[e]=d,c=0;c<1<<I[e];c++)U[d++]=e;U[d-1]=e;
|
||||
for(e=d=0;16>e;e++)for(S[e]=d,c=0;c<1<<da[e];c++)ea[d++]=e;for(d>>=7;e<K;e++)for(S[e]=d<<7,c=0;c<1<<da[e]-7;c++)ea[256+d++]=e;for(c=0;c<=T;c++)h[c]=0;for(c=0;143>=c;)M[2*c+1]=8,c++,h[8]++;for(;255>=c;)M[2*c+1]=9,c++,h[9]++;for(;279>=c;)M[2*c+1]=7,c++,h[7]++;for(;287>=c;)M[2*c+1]=8,c++,h[8]++;n(M,L+1,h);for(c=0;c<K;c++)aa[2*c+1]=5,aa[2*c]=m(c,5);Z=new f(M,I,C+1,L,T);O=new f(aa,da,0,K,T);Q=new f([],N,0,G,7);fa=!0}b.l_desc=new g(b.dyn_ltree,Z);b.d_desc=new g(b.dyn_dtree,O);b.bl_desc=new g(b.bl_tree,
|
||||
Q);b.bi_buf=0;b.bi_valid=0;p(b)};d._tr_stored_block=D;d._tr_flush_block=function(b,c,d,e){var f,g,h=0;if(0<b.level){2===b.strm.data_type&&(b.strm.data_type=u(b));w(b,b.l_desc);w(b,b.d_desc);x(b,b.dyn_ltree,b.l_desc.max_code);x(b,b.dyn_dtree,b.d_desc.max_code);w(b,b.bl_desc);for(h=G-1;3<=h&&0===b.bl_tree[2*J[h]+1];h--);h=(b.opt_len+=3*(h+1)+14,h);f=b.opt_len+3+7>>>3;g=b.static_len+3+7>>>3;g<=f&&(f=g)}else f=g=d+5;if(d+4<=f&&-1!==c)D(b,c,d,e);else if(4===b.strategy||g===f)k(b,2+(e?1:0),3),z(b,M,aa);
|
||||
else{k(b,4+(e?1:0),3);c=b.l_desc.max_code+1;d=b.d_desc.max_code+1;h+=1;k(b,c-257,5);k(b,d-1,5);k(b,h-4,4);for(f=0;f<h;f++)k(b,b.bl_tree[2*J[f]+1],3);y(b,b.dyn_ltree,c-1);y(b,b.dyn_dtree,d-1);z(b,b.dyn_ltree,b.dyn_dtree)}p(b);e&&r(b)};d._tr_tally=function(b,c,d){return b.pending_buf[b.d_buf+2*b.last_lit]=c>>>8&255,b.pending_buf[b.d_buf+2*b.last_lit+1]=255&c,b.pending_buf[b.l_buf+b.last_lit]=255&d,b.last_lit++,0===c?b.dyn_ltree[2*d]++:(b.matches++,c--,b.dyn_ltree[2*(U[d]+C+1)]++,b.dyn_dtree[2*(256>
|
||||
c?ea[c]:ea[256+(c>>>7)])]++),b.last_lit===b.lit_bufsize-1};d._tr_align=function(b){k(b,2,3);l(b,W,M);16===b.bi_valid?(h(b,b.bi_buf),b.bi_buf=0,b.bi_valid=0):8<=b.bi_valid&&(b.pending_buf[b.pending++]=255&b.bi_buf,b.bi_buf>>=8,b.bi_valid-=8)}},{"../utils/common":3}],15:[function(b,c,d){c.exports=function(){this.input=null;this.total_in=this.avail_in=this.next_in=0;this.output=null;this.total_out=this.avail_out=this.next_out=0;this.msg="";this.state=null;this.data_type=2;this.adler=0}},{}],"/":[function(b,
|
||||
c,d){d=b("./lib/utils/common").assign;var e=b("./lib/deflate"),f=b("./lib/inflate");b=b("./lib/zlib/constants");var g={};d(g,e,f,b);c.exports=g},{"./lib/deflate":1,"./lib/inflate":2,"./lib/utils/common":3,"./lib/zlib/constants":6}]},{},[])("/")});var JSON;JSON||(JSON={});
|
||||
(function(){function a(a){return 10>a?"0"+a:a}function b(a){e.lastIndex=0;return e.test(a)?'"'+a.replace(e,function(a){var b=h[a];return"string"===typeof b?b:"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)})+'"':'"'+a+'"'}function c(a,d){var e,h,l,m,t=f,z,w=d[a];w&&"object"===typeof w&&"function"===typeof w.toJSON&&(w=w.toJSON(a));"function"===typeof k&&(w=k.call(d,a,w));switch(typeof w){case "string":return b(w);case "number":return isFinite(w)?""+w:"null";case "boolean":case "null":return""+w;
|
||||
case "object":if(!w)return"null";f+=g;z=[];if("[object Array]"===Object.prototype.toString.apply(w)){m=w.length;for(e=0;e<m;e+=1)z[e]=c(e,w)||"null";l=0===z.length?"[]":f?"[\n"+f+z.join(",\n"+f)+"\n"+t+"]":"["+z.join(",")+"]";f=t;return l}if(k&&"object"===typeof k)for(m=k.length,e=0;e<m;e+=1)"string"===typeof k[e]&&(h=k[e],(l=c(h,w))&&z.push(b(h)+(f?": ":":")+l));else for(h in w)Object.prototype.hasOwnProperty.call(w,h)&&(l=c(h,w))&&z.push(b(h)+(f?": ":":")+l);l=0===z.length?"{}":f?"{\n"+f+z.join(",\n"+
|
||||
|
@ -184,7 +184,7 @@ f)+"\n"+t+"}":"{"+z.join(",")+"}";f=t;return l}}"function"!==typeof Date.prototy
|
|||
e=/[\\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,f,g,h={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"},k;"function"!==typeof JSON.stringify&&(JSON.stringify=function(a,b,d){var e;g=f="";if("number"===typeof d)for(e=0;e<d;e+=1)g+=" ";else"string"===typeof d&&(g=d);if((k=b)&&"function"!==typeof b&&("object"!==typeof b||"number"!==typeof b.length))throw Error("JSON.stringify");return c("",{"":a})});
|
||||
"function"!==typeof JSON.parse&&(JSON.parse=function(a,b){function c(a,d){var e,f,g=a[d];if(g&&"object"===typeof g)for(e in g)Object.prototype.hasOwnProperty.call(g,e)&&(f=c(g,e),void 0!==f?g[e]=f:delete g[e]);return b.call(a,d,g)}var e;a=""+a;d.lastIndex=0;d.test(a)&&(a=a.replace(d,function(a){return"\\u"+("0000"+a.charCodeAt(0).toString(16)).slice(-4)}));if(/^[\],:{}\s]*$/.test(a.replace(/\\(?:["\\\/bfnrt]|u[0-9a-fA-F]{4})/g,"@").replace(/"[^"\\\n\r]*"|true|false|null|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?/g,
|
||||
"]").replace(/(?:^|:|,)(?:\s*\[)+/g,"")))return e=eval("("+a+")"),"function"===typeof b?c({"":e},""):e;throw new SyntaxError("JSON.parse");})})();"undefined"===typeof window.mxBasePath&&(window.mxBasePath="https://www.draw.io/mxgraph/");window.mxLoadStylesheets=window.mxLoadStylesheets||!1;window.mxLoadResources=window.mxLoadResources||!1;window.mxLanguage=window.mxLanguage||"en";window.urlParams=window.urlParams||{};window.MAX_REQUEST_SIZE=window.MAX_REQUEST_SIZE||10485760;window.MAX_AREA=window.MAX_AREA||225E6;window.EXPORT_URL=window.EXPORT_URL||"/export";window.SAVE_URL=window.SAVE_URL||"/save";window.OPEN_URL=window.OPEN_URL||"/open";window.RESOURCES_PATH=window.RESOURCES_PATH||"resources";window.RESOURCE_BASE=window.RESOURCE_BASE||window.RESOURCES_PATH+"/grapheditor";window.STENCIL_PATH=window.STENCIL_PATH||"stencils";window.IMAGE_PATH=window.IMAGE_PATH||"images";
|
||||
window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"9.1.0",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
|
||||
window.STYLE_PATH=window.STYLE_PATH||"styles";window.CSS_PATH=window.CSS_PATH||"styles";window.OPEN_FORM=window.OPEN_FORM||"open.html";window.mxBasePath=window.mxBasePath||"../../../src";window.mxLanguage=window.mxLanguage||urlParams.lang;window.mxLanguages=window.mxLanguages||["de"];var mxClient={VERSION:"9.1.1",IS_IE:0<=navigator.userAgent.indexOf("MSIE"),IS_IE6:0<=navigator.userAgent.indexOf("MSIE 6"),IS_IE11:!!navigator.userAgent.match(/Trident\/7\./),IS_EDGE:!!navigator.userAgent.match(/Edge\//),IS_QUIRKS:0<=navigator.userAgent.indexOf("MSIE")&&(null==document.documentMode||5==document.documentMode),IS_EM:"spellcheck"in document.createElement("textarea")&&8==document.documentMode,VML_PREFIX:"v",OFFICE_PREFIX:"o",IS_NS:0<=navigator.userAgent.indexOf("Mozilla/")&&0>navigator.userAgent.indexOf("MSIE")&&
|
||||
0>navigator.userAgent.indexOf("Edge/"),IS_OP:0<=navigator.userAgent.indexOf("Opera/")||0<=navigator.userAgent.indexOf("OPR/"),IS_OT:0<=navigator.userAgent.indexOf("Presto/")&&0>navigator.userAgent.indexOf("Presto/2.4.")&&0>navigator.userAgent.indexOf("Presto/2.3.")&&0>navigator.userAgent.indexOf("Presto/2.2.")&&0>navigator.userAgent.indexOf("Presto/2.1.")&&0>navigator.userAgent.indexOf("Presto/2.0.")&&0>navigator.userAgent.indexOf("Presto/1."),IS_SF:0<=navigator.userAgent.indexOf("AppleWebKit/")&&
|
||||
0>navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_IOS:navigator.userAgent.match(/(iPad|iPhone|iPod)/g)?!0:!1,IS_GC:0<=navigator.userAgent.indexOf("Chrome/")&&0>navigator.userAgent.indexOf("Edge/"),IS_CHROMEAPP:null!=window.chrome&&null!=chrome.app&&null!=chrome.app.runtime,IS_FF:0<=navigator.userAgent.indexOf("Firefox/"),IS_MT:0<=navigator.userAgent.indexOf("Firefox/")&&0>navigator.userAgent.indexOf("Firefox/1.")&&0>navigator.userAgent.indexOf("Firefox/2.")||0<=navigator.userAgent.indexOf("Iceweasel/")&&
|
||||
0>navigator.userAgent.indexOf("Iceweasel/1.")&&0>navigator.userAgent.indexOf("Iceweasel/2.")||0<=navigator.userAgent.indexOf("SeaMonkey/")&&0>navigator.userAgent.indexOf("SeaMonkey/1.")||0<=navigator.userAgent.indexOf("Iceape/")&&0>navigator.userAgent.indexOf("Iceape/1."),IS_SVG:0<=navigator.userAgent.indexOf("Firefox/")||0<=navigator.userAgent.indexOf("Iceweasel/")||0<=navigator.userAgent.indexOf("Seamonkey/")||0<=navigator.userAgent.indexOf("Iceape/")||0<=navigator.userAgent.indexOf("Galeon/")||
|
||||
|
@ -531,7 +531,7 @@ mxArrowConnector.prototype.augmentBoundingBox=function(a){mxShape.prototype.augm
|
|||
mxArrowConnector.prototype.paintEdgeShape=function(a,b){var c=this.strokewidth;this.outline&&(c=Math.max(1,mxUtils.getNumber(this.style,mxConstants.STYLE_STROKEWIDTH,this.strokewidth)));for(var d=this.getStartArrowWidth()+c,e=this.getEndArrowWidth()+c,f=this.outline?this.getEdgeWidth()+c:this.getEdgeWidth(),g=this.isOpenEnded(),h=this.isMarkerStart(),k=this.isMarkerEnd(),l=g?0:this.arrowSpacing+c/2,m=this.startSize+c,c=this.endSize+c,n=this.isArrowRounded(),p=b[b.length-1],r=1;r<b.length-1&&b[r].x==
|
||||
b[0].x&&b[r].y==b[0].y;)r++;var q=b[r].x-b[0].x,r=b[r].y-b[0].y,t=Math.sqrt(q*q+r*r);if(0!=t){var z=q/t,w,x=z,y=r/t,u,D=y,t=f*y,F=-f*z,E=[];n?a.setLineJoin("round"):2<b.length&&a.setMiterLimit(1.42);a.begin();q=z;r=y;if(h&&!g)this.paintMarker(a,b[0].x,b[0].y,z,y,m,d,f,l,!0);else{w=b[0].x+t/2+l*z;u=b[0].y+F/2+l*y;var B=b[0].x-t/2+l*z,A=b[0].y-F/2+l*y;g?(a.moveTo(w,u),E.push(function(){a.lineTo(B,A)})):(a.moveTo(B,A),a.lineTo(w,u))}for(var C=u=w=0,t=0;t<b.length-2;t++)if(F=mxUtils.relativeCcw(b[t].x,
|
||||
b[t].y,b[t+1].x,b[t+1].y,b[t+2].x,b[t+2].y),w=b[t+2].x-b[t+1].x,u=b[t+2].y-b[t+1].y,C=Math.sqrt(w*w+u*u),0!=C&&(x=w/C,D=u/C,tmp=Math.max(Math.sqrt((z*x+y*D+1)/2),.04),w=z+x,u=y+D,C=Math.sqrt(w*w+u*u),0!=C)){w/=C;u/=C;var C=Math.max(tmp,Math.min(this.strokewidth/200+.04,.35)),C=0!=F&&n?Math.max(.1,C):Math.max(tmp,.06),L=b[t+1].x+u*f/2/C,K=b[t+1].y-w*f/2/C;u=b[t+1].x-u*f/2/C;w=b[t+1].y+w*f/2/C;0!=F&&n?-1==F?(F=u+D*f,C=w-x*f,a.lineTo(u+y*f,w-z*f),a.quadTo(L,K,F,C),function(b,c){E.push(function(){a.lineTo(b,
|
||||
c)})}(u,w)):(a.lineTo(L,K),function(b,c){var d=L-y*f,e=K+z*f,g=L-D*f,h=K+x*f;E.push(function(){a.quadTo(b,c,d,e)});E.push(function(){a.lineTo(g,h)})}(u,w)):(a.lineTo(L,K),function(b,c){E.push(function(){a.lineTo(b,c)})}(u,w));z=x;y=D}t=f*D;F=-f*x;if(k&&!g)this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!1);else{a.lineTo(p.x-l*x+t/2,p.y-l*D+F/2);var H=p.x-l*x-t/2,V=p.y-l*D-F/2;g?(a.moveTo(H,V),E.splice(0,0,function(){a.moveTo(H,V)})):a.lineTo(H,V)}for(t=E.length-1;0<=t;t--)E[t]();g?(a.end(),a.stroke()):(a.close(),
|
||||
c)})}(u,w)):(a.lineTo(L,K),function(b,c){var d=L-y*f,e=K+z*f,g=L-D*f,h=K+x*f;E.push(function(){a.quadTo(b,c,d,e)});E.push(function(){a.lineTo(g,h)})}(u,w)):(a.lineTo(L,K),function(b,c){E.push(function(){a.lineTo(b,c)})}(u,w));z=x;y=D}t=f*D;F=-f*x;if(k&&!g)this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!1);else{a.lineTo(p.x-l*x+t/2,p.y-l*D+F/2);var G=p.x-l*x-t/2,V=p.y-l*D-F/2;g?(a.moveTo(G,V),E.splice(0,0,function(){a.moveTo(G,V)})):a.lineTo(G,V)}for(t=E.length-1;0<=t;t--)E[t]();g?(a.end(),a.stroke()):(a.close(),
|
||||
a.fillAndStroke());a.setShadow(!1);a.setMiterLimit(4);n&&a.setLineJoin("flat");2<b.length&&(a.setMiterLimit(4),h&&!g&&(a.begin(),this.paintMarker(a,b[0].x,b[0].y,q,r,m,d,f,l,!0),a.stroke(),a.end()),k&&!g&&(a.begin(),this.paintMarker(a,p.x,p.y,-z,-y,c,e,f,l,!0),a.stroke(),a.end()))}};
|
||||
mxArrowConnector.prototype.paintMarker=function(a,b,c,d,e,f,g,h,k,l){g=h/g;var m=h*e/2;h=-h*d/2;var n=(k+f)*d;f=(k+f)*e;l?a.moveTo(b-m+n,c-h+f):a.lineTo(b-m+n,c-h+f);a.lineTo(b-m/g+n,c-h/g+f);a.lineTo(b+k*d,c+k*e);a.lineTo(b+m/g+n,c+h/g+f);a.lineTo(b+m+n,c+h+f)};mxArrowConnector.prototype.isArrowRounded=function(){return this.isRounded};mxArrowConnector.prototype.getStartArrowWidth=function(){return mxConstants.ARROW_WIDTH};mxArrowConnector.prototype.getEndArrowWidth=function(){return mxConstants.ARROW_WIDTH};
|
||||
mxArrowConnector.prototype.getEdgeWidth=function(){return mxConstants.ARROW_WIDTH/3};mxArrowConnector.prototype.isOpenEnded=function(){return!1};mxArrowConnector.prototype.isMarkerStart=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE};mxArrowConnector.prototype.isMarkerEnd=function(){return mxUtils.getValue(this.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE};
|
||||
|
@ -607,10 +607,10 @@ this.direction==mxConstants.DIRECTION_WEST);if(f){b=Math.min(a.width,b*this.scal
|
|||
mxSwimlane.prototype.getArcSize=function(a,b,c){a=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100;return c*a*3};mxSwimlane.prototype.isHorizontal=function(){return 1==mxUtils.getValue(this.style,mxConstants.STYLE_HORIZONTAL,1)};
|
||||
mxSwimlane.prototype.paintVertexShape=function(a,b,c,d,e){var f=this.getTitleSize(),g=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE),h=1==mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_LINE,1),k=0,f=this.isHorizontal()?Math.min(f,e):Math.min(f,d);a.translate(b,c);this.isRounded?(k=this.getArcSize(d,e,f),this.paintRoundedSwimlane(a,b,c,d,e,f,k,g,h)):this.paintSwimlane(a,b,c,d,e,f,g,h);g=mxUtils.getValue(this.style,mxConstants.STYLE_SEPARATORCOLOR,mxConstants.NONE);
|
||||
this.paintSeparator(a,b,c,d,e,f,g);null!=this.image&&(e=this.getImageBounds(b,c,d,e),a.image(e.x-b,e.y-c,e.width,e.height,this.image,!1,!1,!1));this.glass&&(a.setShadow(!1),this.paintGlassEffect(a,0,0,d,f,k))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,h){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),a.rect(0,0,d,e),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(h||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,e),a.lineTo(f,e),(h||f>=d)&&
|
||||
a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,h,k){g=Math.min(e-f,Math.min(f,g));h!=mxConstants.NONE&&(a.save(),a.setFillColor(h),a.roundrect(0,0,d,e,g,g),a.fillAndStroke(),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e-g),a.quadTo(0,
|
||||
e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(k||f>=d)&&a.close(),a.fillAndStroke(),f<d&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSwimlane=function(a,b,c,d,e,f,g,h){g!=mxConstants.NONE&&(a.save(),a.setFillColor(g),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();0==f&&(f=e);this.isHorizontal()?(a.moveTo(0,f),a.lineTo(0,0),a.lineTo(d,0),a.lineTo(d,f),(h||f>=e)&&a.close(),a.fillAndStroke(),f<e&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,f),a.lineTo(0,e),a.lineTo(d,e),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(0,0),a.lineTo(0,
|
||||
e),a.lineTo(f,e),(h||f>=d)&&a.close(),a.fillAndStroke(),f<d&&g==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(f,e),a.stroke()))};
|
||||
mxSwimlane.prototype.paintRoundedSwimlane=function(a,b,c,d,e,f,g,h,k){g=Math.min(e-f,Math.min(f,g));h!=mxConstants.NONE&&(a.save(),a.setFillColor(h),mxRectangleShape.prototype.paintBackground.call(this,a,0,0,d,e),a.restore(),a.setShadow(!1));a.begin();this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,g),a.quadTo(d,0,d-Math.min(d/2,g),0),a.lineTo(Math.min(d/2,g),0),a.quadTo(0,0,0,g),a.lineTo(0,f),(k||f>=e)&&a.close(),a.fillAndStroke(),f<e&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(0,
|
||||
f),a.lineTo(0,e-g),a.quadTo(0,e,Math.min(d/2,g),e),a.lineTo(d-Math.min(d/2,g),e),a.quadTo(d,e,d,e-g),a.lineTo(d,f),a.stroke())):(a.moveTo(f,0),a.lineTo(g,0),a.quadTo(0,0,0,Math.min(e/2,g)),a.lineTo(0,e-Math.min(e/2,g)),a.quadTo(0,e,g,e),a.lineTo(f,e),(k||f>=d)&&a.close(),a.fillAndStroke(),f<d&&h==mxConstants.NONE&&(a.pointerEvents=!1,a.begin(),a.moveTo(f,e),a.lineTo(d-g,e),a.quadTo(d,e,d,e-Math.min(e/2,g)),a.lineTo(d,Math.min(e/2,g)),a.quadTo(d,0,d-g,0),a.lineTo(f,0),a.stroke()))};
|
||||
mxSwimlane.prototype.paintSeparator=function(a,b,c,d,e,f,g){g!=mxConstants.NONE&&(a.setStrokeColor(g),a.setDashed(!0),a.begin(),this.isHorizontal()?(a.moveTo(d,f),a.lineTo(d,e)):(a.moveTo(f,0),a.lineTo(d,0)),a.stroke(),a.setDashed(!1))};mxSwimlane.prototype.getImageBounds=function(a,b,c,d){return this.isHorizontal()?new mxRectangle(a+c-this.imageSize,b,this.imageSize,this.imageSize):new mxRectangle(a,b,this.imageSize,this.imageSize)};function mxGraphLayout(a){this.graph=a}
|
||||
mxGraphLayout.prototype.graph=null;mxGraphLayout.prototype.useBoundingBox=!0;mxGraphLayout.prototype.parent=null;mxGraphLayout.prototype.moveCell=function(a,b,c){};mxGraphLayout.prototype.execute=function(a){};mxGraphLayout.prototype.getGraph=function(){return this.graph};mxGraphLayout.prototype.getConstraint=function(a,b,c,d){c=this.graph.view.getState(b);b=null!=c?c.style:this.graph.getCellStyle(b);return null!=b?b[a]:null};
|
||||
mxGraphLayout.traverse=function(a,b,c,d,e){if(null!=c&&null!=a&&(b=null!=b?b:!0,e=e||new mxDictionary,!e.get(a)&&(e.put(a,!0),d=c(a,d),null==d||d))&&(d=this.graph.model.getEdgeCount(a),0<d))for(var f=0;f<d;f++){var g=this.graph.model.getEdgeAt(a,f),h=this.graph.model.getTerminal(g,!0)==a;if(!b||h)h=this.graph.view.getVisibleTerminal(g,!h),this.traverse(h,b,c,g,e)}};
|
||||
|
@ -1698,12 +1698,12 @@ return b||"0"!=mxUtils.getValue(c,mxConstants.STYLE_RESIZABLE,"1")&&"wrap"==c[mx
|
|||
g=this.view.translate;h=this.view.scale;e=e/h-(a?g.x:g.y);d=d/h-(a?g.x:g.y);this.getModel().beginUpdate();try{for(var k=(d-e)/(c.length-1),d=e,f=1;f<c.length-1;f++){var l=this.view.getState(this.model.getParent(c[f].cell)),m=this.getCellGeometry(c[f].cell),d=d+k;null!=m&&null!=l&&(m=m.clone(),a?m.x=Math.round(d-m.width/2)-l.origin.x:m.y=Math.round(d-m.height/2)-l.origin.y,this.getModel().setGeometry(c[f].cell,m))}}finally{this.getModel().endUpdate()}}}return b};Graph.prototype.isCloneEvent=function(a){return mxClient.IS_MAC&&
|
||||
mxEvent.isMetaDown(a)||mxEvent.isControlDown(a)};Graph.prototype.encodeCells=function(a){for(var b=this.cloneCells(a),c=new mxDictionary,d=0;d<a.length;d++)c.put(a[d],!0);for(d=0;d<b.length;d++){var e=this.view.getState(a[d]);if(null!=e){var f=this.getCellGeometry(b[d]);null==f||!f.relative||this.model.isEdge(a[d])||c.get(this.model.getParent(a[d]))||(f.relative=!1,f.x=e.x/e.view.scale-e.view.translate.x,f.y=e.y/e.view.scale-e.view.translate.y)}}c=new mxCodec;e=new mxGraphModel;f=e.getChildAt(e.getRoot(),
|
||||
0);for(d=0;d<a.length;d++)e.add(f,b[d]);return c.encode(e)};Graph.prototype.createSvgImageExport=function(){var a=new mxImageExport;a.getLinkForCellState=mxUtils.bind(this,function(a,b){return this.getLinkForCell(a.cell)});return a};Graph.prototype.getSvg=function(a,b,c,d,e,f,g,h){var k=this.useCssTransforms;k&&(this.useCssTransforms=!1,this.view.revalidate(),this.sizeDidChange());try{b=null!=b?b:1;c=null!=c?c:0;e=null!=e?e:!0;f=null!=f?f:!0;g=null!=g?g:!0;var l=f||d?this.getGraphBounds():this.getBoundingBox(this.getSelectionCells());
|
||||
if(null==l)throw Error(mxResources.get("drawingEmpty"));var m=this.view.scale,n=mxUtils.createXmlDocument(),p=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"svg"):n.createElement("svg");null!=a&&(null!=p.style?p.style.backgroundColor=a:p.setAttribute("style","background-color:"+a));null==n.createElementNS?(p.setAttribute("xmlns",mxConstants.NS_SVG),p.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):p.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink",mxConstants.NS_XLINK);
|
||||
a=b/m;p.setAttribute("width",Math.max(1,Math.ceil(l.width*a)+2*c)+"px");p.setAttribute("height",Math.max(1,Math.ceil(l.height*a)+2*c)+"px");p.setAttribute("version","1.1");d=p;if(e){var v=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"g"):n.createElement("g");v.setAttribute("transform","translate(0.5,0.5)");p.appendChild(v);n.appendChild(p);d=v}else n.appendChild(p);var q=this.createSvgCanvas(d);q.foOffset=e?-.5:0;q.textOffset=e?-.5:0;q.imageOffset=e?-.5:0;q.translate(Math.floor((c/
|
||||
b-l.x)/m),Math.floor((c/b-l.y)/m));var r=document.createElement("textarea"),t=q.createAlternateContent;q.createAlternateContent=function(a,b,c,d,e,f,g,h,k,l,m,n,p){var v=this.state;if(null!=this.foAltText&&(0==d||0!=v.fontSize&&f.length<5*d/v.fontSize)){var q=this.createElement("text");q.setAttribute("x",Math.round(d/2));q.setAttribute("y",Math.round((e+v.fontSize)/2));q.setAttribute("fill",v.fontColor||"black");q.setAttribute("text-anchor","middle");q.setAttribute("font-size",Math.round(v.fontSize)+
|
||||
"px");q.setAttribute("font-family",v.fontFamily);(v.fontStyle&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD&&q.setAttribute("font-weight","bold");(v.fontStyle&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC&&q.setAttribute("font-style","italic");(v.fontStyle&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&q.setAttribute("text-decoration","underline");try{return r.innerHTML=f,q.textContent=r.value,q}catch(Aa){return t.apply(this,arguments)}}else return t.apply(this,arguments)};var u=this.backgroundImage;
|
||||
if(null!=u){b=m/b;var G=this.view.translate,Q=new mxRectangle(G.x*b,G.y*b,u.width*b,u.height*b);mxUtils.intersects(l,Q)&&q.image(G.x,G.y,u.width,u.height,u.src,!0)}q.scale(a);q.textEnabled=g;h=null!=h?h:this.createSvgImageExport();var w=h.drawCellState;h.drawCellState=function(a,b){for(var c=a.view.graph,d=c.isCellSelected(a.cell),e=c.model.getParent(a.cell);!f&&!d&&null!=e;)d=c.isCellSelected(e),e=c.model.getParent(e);(f||d)&&w.apply(this,arguments)};h.drawState(this.getView().getState(this.model.root),
|
||||
q);return p}finally{k&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.createSvgCanvas=function(a){return new mxSvgCanvas2D(a)};Graph.prototype.getSelectedElement=function(){var a=null;if(window.getSelection){var b=window.getSelection();b.getRangeAt&&b.rangeCount&&(a=b.getRangeAt(0).commonAncestorContainer)}else document.selection&&(a=document.selection.createRange().parentElement());return a};Graph.prototype.getParentByName=function(a,b,c){for(;null!=a&&a.nodeName!=
|
||||
if(null==l)throw Error(mxResources.get("drawingEmpty"));var m=this.view.scale,n=mxUtils.createXmlDocument(),v=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"svg"):n.createElement("svg");null!=a&&(null!=v.style?v.style.backgroundColor=a:v.setAttribute("style","background-color:"+a));null==n.createElementNS?(v.setAttribute("xmlns",mxConstants.NS_SVG),v.setAttribute("xmlns:xlink",mxConstants.NS_XLINK)):v.setAttributeNS("http://www.w3.org/2000/xmlns/","xmlns:xlink",mxConstants.NS_XLINK);
|
||||
a=b/m;v.setAttribute("width",Math.max(1,Math.ceil(l.width*a)+2*c)+"px");v.setAttribute("height",Math.max(1,Math.ceil(l.height*a)+2*c)+"px");v.setAttribute("version","1.1");d=v;if(e){var p=null!=n.createElementNS?n.createElementNS(mxConstants.NS_SVG,"g"):n.createElement("g");p.setAttribute("transform","translate(0.5,0.5)");v.appendChild(p);n.appendChild(v);d=p}else n.appendChild(v);var q=this.createSvgCanvas(d);q.foOffset=e?-.5:0;q.textOffset=e?-.5:0;q.imageOffset=e?-.5:0;q.translate(Math.floor((c/
|
||||
b-l.x)/m),Math.floor((c/b-l.y)/m));var r=document.createElement("textarea"),t=q.createAlternateContent;q.createAlternateContent=function(a,b,c,d,e,f,g,h,k,l,m,n,v){var p=this.state;if(null!=this.foAltText&&(0==d||0!=p.fontSize&&f.length<5*d/p.fontSize)){var q=this.createElement("text");q.setAttribute("x",Math.round(d/2));q.setAttribute("y",Math.round((e+p.fontSize)/2));q.setAttribute("fill",p.fontColor||"black");q.setAttribute("text-anchor","middle");q.setAttribute("font-size",Math.round(p.fontSize)+
|
||||
"px");q.setAttribute("font-family",p.fontFamily);(p.fontStyle&mxConstants.FONT_BOLD)==mxConstants.FONT_BOLD&&q.setAttribute("font-weight","bold");(p.fontStyle&mxConstants.FONT_ITALIC)==mxConstants.FONT_ITALIC&&q.setAttribute("font-style","italic");(p.fontStyle&mxConstants.FONT_UNDERLINE)==mxConstants.FONT_UNDERLINE&&q.setAttribute("text-decoration","underline");try{return r.innerHTML=f,q.textContent=r.value,q}catch(Da){return t.apply(this,arguments)}}else return t.apply(this,arguments)};var u=this.backgroundImage;
|
||||
if(null!=u){b=m/b;var H=this.view.translate,w=new mxRectangle(H.x*b,H.y*b,u.width*b,u.height*b);mxUtils.intersects(l,w)&&q.image(H.x,H.y,u.width,u.height,u.src,!0)}q.scale(a);q.textEnabled=g;h=null!=h?h:this.createSvgImageExport();var R=h.drawCellState;h.drawCellState=function(a,b){for(var c=a.view.graph,d=c.isCellSelected(a.cell),e=c.model.getParent(a.cell);!f&&!d&&null!=e;)d=c.isCellSelected(e),e=c.model.getParent(e);(f||d)&&R.apply(this,arguments)};h.drawState(this.getView().getState(this.model.root),
|
||||
q);return v}finally{k&&(this.useCssTransforms=!0,this.view.revalidate(),this.sizeDidChange())}};Graph.prototype.createSvgCanvas=function(a){return new mxSvgCanvas2D(a)};Graph.prototype.getSelectedElement=function(){var a=null;if(window.getSelection){var b=window.getSelection();b.getRangeAt&&b.rangeCount&&(a=b.getRangeAt(0).commonAncestorContainer)}else document.selection&&(a=document.selection.createRange().parentElement());return a};Graph.prototype.getParentByName=function(a,b,c){for(;null!=a&&a.nodeName!=
|
||||
b;){if(a==c)return null;a=a.parentNode}return a};Graph.prototype.selectNode=function(a){var b=null;if(window.getSelection){if(b=window.getSelection(),b.getRangeAt&&b.rangeCount){var c=document.createRange();c.selectNode(a);b.removeAllRanges();b.addRange(c)}}else(b=document.selection)&&"Control"!=b.type&&(a=b.createRange(),a.collapse(!0),c=b.createRange(),c.setEndPoint("StartToStart",a),c.select())};Graph.prototype.insertRow=function(a,b){for(var c=a.tBodies[0],d=c.rows[0].cells,e=0,f=0;f<d.length;f++)var g=
|
||||
d[f].getAttribute("colspan"),e=e+(null!=g?parseInt(g):1);c=c.insertRow(b);for(f=0;f<e;f++)mxUtils.br(c.insertCell(-1));return c.cells[0]};Graph.prototype.deleteRow=function(a,b){a.tBodies[0].deleteRow(b)};Graph.prototype.insertColumn=function(a,b){var c=a.tHead;if(null!=c)for(var d=0;d<c.rows.length;d++){var e=document.createElement("th");c.rows[d].appendChild(e);mxUtils.br(e)}c=a.tBodies[0];for(d=0;d<c.rows.length;d++)e=c.rows[d].insertCell(b),mxUtils.br(e);return c.rows[0].cells[0<=b?b:c.rows[0].cells.length-
|
||||
1]};Graph.prototype.deleteColumn=function(a,b){if(0<=b)for(var c=a.tBodies[0].rows,d=0;d<c.length;d++)c[d].cells.length>b&&c[d].deleteCell(b)};Graph.prototype.pasteHtmlAtCaret=function(a){var b;if(window.getSelection){if(b=window.getSelection(),b.getRangeAt&&b.rangeCount){b=b.getRangeAt(0);b.deleteContents();var c=document.createElement("div");c.innerHTML=a;a=document.createDocumentFragment();for(var d;d=c.firstChild;)lastNode=a.appendChild(d);b.insertNode(a)}}else(b=document.selection)&&"Control"!=
|
||||
|
@ -1770,58 +1770,58 @@ mxUtils.getTextContent(c[d])));this.linkHint.appendChild(e)}}};mxEdgeHandler.pro
|
|||
this.labelShape&&(this.labelShape.node.style.display=this.graph.isEnabled()&&this.graph.getSelectionCount()<this.graph.graphHandler.maxCells?"":"none")});this.selectionHandler=mxUtils.bind(this,function(b,c){a()});this.graph.getSelectionModel().addListener(mxEvent.CHANGE,this.selectionHandler);this.changeHandler=mxUtils.bind(this,function(b,c){this.updateLinkHint(this.graph.getLinkForCell(this.state.cell),this.graph.getLinksForState(this.state));a();this.redrawHandles()});this.graph.getModel().addListener(mxEvent.CHANGE,
|
||||
this.changeHandler);var b=this.graph.getLinkForCell(this.state.cell),c=this.graph.getLinksForState(this.state);if(null!=b||null!=c&&0<c.length)this.updateLinkHint(b,c),this.redrawHandles()};var L=mxConnectionHandler.prototype.init;mxConnectionHandler.prototype.init=function(){L.apply(this,arguments);this.constraintHandler.isEnabled=mxUtils.bind(this,function(){return this.graph.connectionHandler.isEnabled()})};var K=mxVertexHandler.prototype.redrawHandles;mxVertexHandler.prototype.redrawHandles=function(){K.apply(this);
|
||||
if(null!=this.state&&null!=this.linkHint){var a=new mxPoint(this.state.getCenterX(),this.state.getCenterY()),b=new mxRectangle(this.state.x,this.state.y-22,this.state.width+24,this.state.height+22),c=mxUtils.getBoundingBox(b,this.state.style[mxConstants.STYLE_ROTATION]||"0",a),a=null!=c?mxUtils.getBoundingBox(this.state,this.state.style[mxConstants.STYLE_ROTATION]||"0"):this.state,b=null!=this.state.text?this.state.text.boundingBox:null;null==c&&(c=this.state);c=c.y+c.height;null!=b&&(c=Math.max(c,
|
||||
b.y+b.height));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(c+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var H=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){H.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=
|
||||
function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var S=mxEdgeHandler.prototype.redrawHandles;
|
||||
mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(S.apply(this),null!=this.state&&null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.text.bounds&&(a=new mxRectangle(a.x,a.y,a.width,a.height),a.add(this.state.text.bounds));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(a.y+a.height+6+this.state.view.graph.tolerance)+"px"}};var ba=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=
|
||||
function(){ba.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var X=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){X.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),
|
||||
b.y+b.height));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(c+this.verticalOffset/2+6+this.state.view.graph.tolerance)+"px"}};var G=mxVertexHandler.prototype.reset;mxVertexHandler.prototype.reset=function(){G.apply(this,arguments);null!=this.rotationShape&&null!=this.rotationShape.node&&(this.rotationShape.node.style.display=1==this.graph.getSelectionCount()?"":"none")};var V=mxVertexHandler.prototype.destroy;mxVertexHandler.prototype.destroy=
|
||||
function(){V.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),this.changeHandler=null);null!=this.editingHandler&&(this.graph.removeListener(this.editingHandler),this.editingHandler=null)};var T=mxEdgeHandler.prototype.redrawHandles;
|
||||
mxEdgeHandler.prototype.redrawHandles=function(){if(null!=this.marker&&(T.apply(this),null!=this.state&&null!=this.linkHint)){var a=this.state;null!=this.state.text&&null!=this.state.text.bounds&&(a=new mxRectangle(a.x,a.y,a.width,a.height),a.add(this.state.text.bounds));this.linkHint.style.left=Math.max(0,Math.round(a.x+(a.width-this.linkHint.clientWidth)/2))+"px";this.linkHint.style.top=Math.round(a.y+a.height+6+this.state.view.graph.tolerance)+"px"}};var ca=mxEdgeHandler.prototype.reset;mxEdgeHandler.prototype.reset=
|
||||
function(){ca.apply(this,arguments);null!=this.linkHint&&(this.linkHint.style.visibility="")};var W=mxEdgeHandler.prototype.destroy;mxEdgeHandler.prototype.destroy=function(){W.apply(this,arguments);null!=this.linkHint&&(this.linkHint.parentNode.removeChild(this.linkHint),this.linkHint=null);null!=this.selectionHandler&&(this.graph.getSelectionModel().removeListener(this.selectionHandler),this.selectionHandler=null);null!=this.changeHandler&&(this.graph.getModel().removeListener(this.changeHandler),
|
||||
this.changeHandler=null)}}();(function(){function a(){mxCylinder.call(this)}function b(){mxActor.call(this)}function c(){mxCylinder.call(this)}function d(){mxCylinder.call(this)}function e(){mxCylinder.call(this)}function f(){mxActor.call(this)}function g(){mxCylinder.call(this)}function h(){mxActor.call(this)}function k(){mxActor.call(this)}function l(){mxActor.call(this)}function m(){mxActor.call(this)}function n(){mxActor.call(this)}function p(){mxActor.call(this)}function r(){mxActor.call(this)}function q(a,b){this.canvas=
|
||||
a;this.canvas.setLineJoin("round");this.canvas.setLineCap("round");this.defaultVariation=b;this.originalLineTo=this.canvas.lineTo;this.canvas.lineTo=mxUtils.bind(this,q.prototype.lineTo);this.originalMoveTo=this.canvas.moveTo;this.canvas.moveTo=mxUtils.bind(this,q.prototype.moveTo);this.originalClose=this.canvas.close;this.canvas.close=mxUtils.bind(this,q.prototype.close);this.originalQuadTo=this.canvas.quadTo;this.canvas.quadTo=mxUtils.bind(this,q.prototype.quadTo);this.originalCurveTo=this.canvas.curveTo;
|
||||
this.canvas.curveTo=mxUtils.bind(this,q.prototype.curveTo);this.originalArcTo=this.canvas.arcTo;this.canvas.arcTo=mxUtils.bind(this,q.prototype.arcTo)}function t(){mxRectangleShape.call(this)}function z(){mxRectangleShape.call(this)}function w(){mxActor.call(this)}function x(){mxActor.call(this)}function y(){mxActor.call(this)}function u(){mxRectangleShape.call(this)}function D(){mxRectangleShape.call(this)}function F(){mxCylinder.call(this)}function E(){mxShape.call(this)}function B(){mxShape.call(this)}
|
||||
function A(){mxEllipse.call(this)}function C(){mxShape.call(this)}function L(){mxShape.call(this)}function K(){mxRectangleShape.call(this)}function H(){mxShape.call(this)}function V(){mxShape.call(this)}function S(){mxShape.call(this)}function ba(){mxCylinder.call(this)}function X(){mxDoubleEllipse.call(this)}function v(){mxDoubleEllipse.call(this)}function Q(){mxArrowConnector.call(this);this.spacing=0}function G(){mxArrowConnector.call(this);this.spacing=0}function I(){mxActor.call(this)}function ca(){mxRectangleShape.call(this)}
|
||||
function M(){mxActor.call(this)}function J(){mxActor.call(this)}function N(){mxActor.call(this)}function T(){mxActor.call(this)}function ea(){mxActor.call(this)}function aa(){mxActor.call(this)}function P(){mxActor.call(this)}function W(){mxActor.call(this)}function U(){mxActor.call(this)}function O(){mxActor.call(this)}function R(){mxEllipse.call(this)}function fa(){mxEllipse.call(this)}function Y(){mxEllipse.call(this)}function Z(){mxRhombus.call(this)}function wa(){mxEllipse.call(this)}function xa(){mxEllipse.call(this)}
|
||||
function ya(){mxEllipse.call(this)}function pa(){mxEllipse.call(this)}function qa(){mxActor.call(this)}function la(){mxActor.call(this)}function ia(){mxActor.call(this)}function ja(){mxConnector.call(this)}function Ba(a,b,c,d,e,f,g,h,k,l){g+=k;var m=d.clone();d.x-=e*(2*g+k);d.y-=f*(2*g+k);e*=g+k;f*=g+k;return function(){a.ellipse(m.x-e-g,m.y-f-g,2*g,2*g);l?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,
|
||||
Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};a.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?(a=parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale,new mxRectangle(a,a,0,0)):null};mxCellRenderer.registerShape("cube",
|
||||
a);var za=Math.tan(mxUtils.toRadians(30)),ka=(.5-za)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/za);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ka);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ka)*b);a.lineTo(0,.25*b);a.close();a.end()};mxCellRenderer.registerShape("isoRectangle",b);mxUtils.extend(c,mxCylinder);c.prototype.size=20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+za));f?(a.moveTo(0,.25*b),a.lineTo(.5*
|
||||
b,(.5-ka)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ka)*b),a.lineTo(.5*b,(1-ka)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ka),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ka)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.registerShape("isoCube",c);mxUtils.extend(d,mxCylinder);d.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(e/2,Math.round(e/8)+this.strokewidth-1);if(f&&null!=this.fill||!f&&null==this.fill)a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||
|
||||
(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,-b);f||(a.moveTo(0,b),a.curveTo(0,-b/3,d,-b/3,d,b),a.lineTo(d,e-b),a.curveTo(d,e+b/3,0,e+b/3,0,e-b),a.close())};d.prototype.getLabelMargins=function(a){return new mxRectangle(0,2.5*Math.min(a.height/2,Math.round(a.height/8)+this.strokewidth-1)*this.scale,0,0)};mxCellRenderer.registerShape("datastore",
|
||||
d);mxUtils.extend(e,mxCylinder);e.prototype.size=30;e.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(d-b,0),a.lineTo(d-b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.registerShape("note",e);mxUtils.extend(f,mxActor);f.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d/2,.5*e,d,0);a.quadTo(.5*
|
||||
d,e/2,d,e);a.quadTo(d/2,.5*e,0,e);a.quadTo(.5*d,e/2,0,0);a.end()};mxCellRenderer.registerShape("switch",f);mxUtils.extend(g,mxCylinder);g.prototype.tabWidth=60;g.prototype.tabHeight=20;g.prototype.tabPosition="right";g.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"tabWidth",this.tabWidth))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"tabHeight",this.tabHeight))));var g=mxUtils.getValue(this.style,"tabPosition",this.tabPosition);
|
||||
f?"left"==g?(a.moveTo(0,c),a.lineTo(b,c)):(a.moveTo(d-b,c),a.lineTo(d,c)):("left"==g?(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,c),a.lineTo(d,c)):(a.moveTo(0,c),a.lineTo(d-b,c),a.lineTo(d-b,0),a.lineTo(d,0)),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,c),a.close());a.end()};mxCellRenderer.registerShape("folder",g);mxUtils.extend(h,mxActor);h.prototype.size=30;h.prototype.isRoundable=function(){return!0};h.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size)))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("card",h);mxUtils.extend(k,mxActor);k.prototype.size=.4;k.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,b/2);a.quadTo(d/4,1.4*b,d/2,b/2);a.quadTo(3*
|
||||
d/4,b*(1-1.4),d,b/2);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};k.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=mxUtils.getValue(this.style,"size",this.size),c=a.width,d=a.height;if(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)return b*=d,new mxRectangle(a.x,a.y+b,c,d-2*b);b*=c;return new mxRectangle(a.x+b,a.y,c-
|
||||
2*b,d)}return a};mxCellRenderer.registerShape("tape",k);mxUtils.extend(l,mxActor);l.prototype.size=.3;l.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*a.height):null};l.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,0);a.lineTo(d,0);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/
|
||||
4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};mxCellRenderer.registerShape("document",l);var Ea=mxCylinder.prototype.getCylinderSize;mxCylinder.prototype.getCylinderSize=function(a,b,c,d){var e=mxUtils.getValue(this.style,"size");return null!=e?d*Math.max(0,Math.min(1,e)):Ea.apply(this,arguments)};mxCylinder.prototype.getLabelMargins=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=2*mxUtils.getValue(this.style,"size",.15);return new mxRectangle(0,Math.min(this.maxHeight*
|
||||
this.scale,a.height*b),0,0)}return null};mxUtils.extend(m,mxActor);m.prototype.size=.2;m.prototype.isRoundable=function(){return!0};m.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d-b,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("parallelogram",
|
||||
m);mxUtils.extend(n,mxActor);n.prototype.size=.2;n.prototype.isRoundable=function(){return!0};n.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("trapezoid",n);mxUtils.extend(p,mxActor);p.prototype.size=
|
||||
.5;p.prototype.redrawPath=function(a,b,c,d,e){a.setFillColor(null);b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(d,0),new mxPoint(b,0),new mxPoint(b,e/2),new mxPoint(0,e/2),new mxPoint(b,e/2),new mxPoint(b,e),new mxPoint(d,e)],this.isRounded,c,!1);a.end()};mxCellRenderer.registerShape("curlyBracket",p);mxUtils.extend(r,mxActor);r.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.setStrokeWidth(1);a.setFillColor(this.stroke);b=d/5;a.rect(0,0,b,e);a.fillAndStroke();a.rect(2*b,0,b,e);a.fillAndStroke();a.rect(4*b,0,b,e);a.fillAndStroke()};mxCellRenderer.registerShape("parallelMarker",r);q.prototype.moveTo=function(a,b){this.originalMoveTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;this.firstX=a;this.firstY=b};q.prototype.close=function(){null!=this.firstX&&null!=this.firstY&&(this.lineTo(this.firstX,this.firstY),this.originalClose.apply(this.canvas,
|
||||
arguments));this.originalClose.apply(this.canvas,arguments)};q.prototype.quadTo=function(a,b,c,d){this.originalQuadTo.apply(this.canvas,arguments);this.lastX=c;this.lastY=d};q.prototype.curveTo=function(a,b,c,d,e,f){this.originalCurveTo.apply(this.canvas,arguments);this.lastX=e;this.lastY=f};q.prototype.arcTo=function(a,b,c,d,e,f,g){this.originalArcTo.apply(this.canvas,arguments);this.lastX=f;this.lastY=g};q.prototype.lineTo=function(a,b){if(null!=this.lastX&&null!=this.lastY){var c=function(a){return"number"===
|
||||
typeof a?a?0>a?-1:1:a===a?0:NaN:NaN},d=Math.abs(a-this.lastX),e=Math.abs(b-this.lastY),f=Math.sqrt(d*d+e*e);if(2>f){this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;return}var g=Math.round(f/10),h=this.defaultVariation;5>g&&(g=5,h/=3);for(var k=c(a-this.lastX)*d/g,c=c(b-this.lastY)*e/g,d=d/f,e=e/f,f=0;f<g;f++){var l=(Math.random()-.5)*h;this.originalLineTo.call(this.canvas,k*f+this.lastX-l*e,c*f+this.lastY-l*d)}this.originalLineTo.call(this.canvas,a,b)}else this.originalLineTo.apply(this.canvas,
|
||||
arguments);this.lastX=a;this.lastY=b};q.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;this.canvas.curveTo=this.originalCurveTo;this.canvas.arcTo=this.originalArcTo};var Fa=mxShape.prototype.paint;mxShape.prototype.defaultJiggle=1.5;mxShape.prototype.paint=function(a){null!=this.style&&"0"!=mxUtils.getValue(this.style,"comic","0")&&null==a.handHiggle&&(a.handJiggle=
|
||||
new q(a,mxUtils.getValue(this.style,"jiggle",this.defaultJiggle)));Fa.apply(this,arguments);null!=a.handJiggle&&(a.handJiggle.destroy(),delete a.handJiggle)};mxRhombus.prototype.defaultJiggle=2;var Ga=mxRectangleShape.prototype.isHtmlAllowed;mxRectangleShape.prototype.isHtmlAllowed=function(){return(null==this.style||"0"==mxUtils.getValue(this.style,"comic","0"))&&Ga.apply(this,arguments)};var Ha=mxRectangleShape.prototype.paintBackground;mxRectangleShape.prototype.paintBackground=function(a,b,c,
|
||||
d,e){if(null==a.handJiggle)Ha.apply(this,arguments);else{var f=!0;null!=this.style&&(f="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(f||null!=this.fill&&this.fill!=mxConstants.NONE||null!=this.stroke&&this.stroke!=mxConstants.NONE)f||null!=this.fill&&this.fill!=mxConstants.NONE||(a.pointerEvents=!1),a.begin(),this.isRounded?("1"==mxUtils.getValue(this.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?f=Math.min(d/2,Math.min(e/2,mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2)):(f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.min(d*f,e*f)),a.moveTo(b+f,c),a.lineTo(b+d-f,c),a.quadTo(b+d,c,b+d,c+f),a.lineTo(b+d,c+e-f),a.quadTo(b+d,c+e,b+d-f,c+e),a.lineTo(b+f,c+e),a.quadTo(b,c+e,b,c+e-f),a.lineTo(b,c+f),a.quadTo(b,c,b+f,c)):(a.moveTo(b,c),a.lineTo(b+d,c),a.lineTo(b+d,c+e),a.lineTo(b,c+e),a.lineTo(b,c)),a.close(),a.end(),a.fillAndStroke()}};var Ia=mxRectangleShape.prototype.paintForeground;
|
||||
mxRectangleShape.prototype.paintForeground=function(a,b,c,d,e){null==a.handJiggle&&Ia.apply(this,arguments)};mxUtils.extend(t,mxRectangleShape);t.prototype.size=.1;t.prototype.isHtmlAllowed=function(){return!1};t.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,!0)==(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)){var b=a.width,c=a.height;a=new mxRectangle(a.x,a.y,b,c);var d=b*Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var e=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,d=Math.max(d,Math.min(b*e,c*e));a.x+=Math.round(d);a.width-=Math.round(2*d)}return a};t.prototype.paintForeground=function(a,b,c,d,e){var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*
|
||||
mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));f=Math.round(f);a.begin();a.moveTo(b+f,c);a.lineTo(b+f,c+e);a.moveTo(b+d-f,c);a.lineTo(b+d-f,c+e);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("process",t);mxUtils.extend(z,mxRectangleShape);z.prototype.paintBackground=function(a,b,c,d,e){a.setFillColor(mxConstants.NONE);a.rect(b,c,d,e);a.fill()};z.prototype.paintForeground=function(a,b,c,d,e){};mxCellRenderer.registerShape("transparent",
|
||||
z);mxUtils.extend(w,mxHexagon);w.prototype.size=30;w.prototype.position=.5;w.prototype.position2=.5;w.prototype.base=20;w.prototype.getLabelMargins=function(){return new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale)};w.prototype.isRoundable=function(){return!0};w.prototype.redrawPath=function(a,b,c,d,e){b=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",
|
||||
this.size))));var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position",this.position)))),g=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position2",this.position2)))),h=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"base",this.base))));this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-c),new mxPoint(Math.min(d,f+h),e-c),new mxPoint(g,e),new mxPoint(Math.max(0,f),e-c),new mxPoint(0,e-c)],this.isRounded,b,!0,[4])};mxCellRenderer.registerShape("callout",
|
||||
w);mxUtils.extend(x,mxActor);x.prototype.size=.2;x.prototype.fixedSize=20;x.prototype.isRoundable=function(){return!0};x.prototype.redrawPath=function(a,b,c,d,e){b="0"!=mxUtils.getValue(this.style,"fixedSize","0")?Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.fixedSize)))):d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,
|
||||
0),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(0,e),new mxPoint(b,e/2)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("step",x);mxUtils.extend(y,mxHexagon);y.prototype.size=.25;y.prototype.isRoundable=function(){return!0};y.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,
|
||||
0),new mxPoint(d-b,0),new mxPoint(d,.5*e),new mxPoint(d-b,e),new mxPoint(b,e),new mxPoint(0,.5*e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("hexagon",y);mxUtils.extend(u,mxRectangleShape);u.prototype.isHtmlAllowed=function(){return!1};u.prototype.paintForeground=function(a,b,c,d,e){var f=Math.min(d/5,e/5)+1;a.begin();a.moveTo(b+d/2,c+f);a.lineTo(b+d/2,c+e-f);a.moveTo(b+f,c+e/2);a.lineTo(b+d-f,c+e/2);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("plus",
|
||||
u);var Ca=mxRhombus.prototype.paintVertexShape;mxRhombus.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};mxRhombus.prototype.paintVertexShape=function(a,b,c,d,e){Ca.apply(this,arguments);if(!this.outline&&1==this.style["double"]){var f=2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||
|
||||
0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&(a.setShadow(!1),Ca.apply(this,[a,b,c,d,e]))}};mxUtils.extend(D,mxRectangleShape);D.prototype.isHtmlAllowed=function(){return!1};D.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};D.prototype.paintForeground=function(a,b,c,d,e){if(null!=this.style){if(!this.outline&&1==this.style["double"]){var f=
|
||||
Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&mxRectangleShape.prototype.paintBackground.apply(this,arguments)}a.setDashed(!1);var f=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+f]];if(null!=g){var h=this.style["symbol"+f+"Align"],k=this.style["symbol"+f+"VerticalAlign"],l=this.style["symbol"+f+"Width"],m=this.style["symbol"+f+"Height"],ra=this.style["symbol"+f+"Spacing"]||0,n=this.style["symbol"+f+"VSpacing"]||ra,
|
||||
p=this.style["symbol"+f+"ArcSpacing"];null!=p&&(p*=this.getArcSize(d+this.strokewidth,e+this.strokewidth),ra+=p,n+=p);var p=b,q=c,p=h==mxConstants.ALIGN_CENTER?p+(d-l)/2:h==mxConstants.ALIGN_RIGHT?p+(d-l-ra):p+ra,q=k==mxConstants.ALIGN_MIDDLE?q+(e-m)/2:k==mxConstants.ALIGN_BOTTOM?q+(e-m-n):q+n;a.save();h=new g;h.style=this.style;g.prototype.paintVertexShape.call(h,a,p,q,l,m);a.restore()}f++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("ext",
|
||||
D);mxUtils.extend(F,mxCylinder);F.prototype.redrawPath=function(a,b,c,d,e,f){f?(a.moveTo(0,0),a.lineTo(d/2,e/2),a.lineTo(d,0),a.end()):(a.moveTo(0,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(0,e),a.close())};mxCellRenderer.registerShape("message",F);mxUtils.extend(E,mxShape);E.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.ellipse(d/4,0,d/2,e/4);a.fillAndStroke();a.begin();a.moveTo(d/2,e/4);a.lineTo(d/2,2*e/3);a.moveTo(d/2,e/3);a.lineTo(0,e/3);a.moveTo(d/2,e/3);a.lineTo(d,e/3);a.moveTo(d/
|
||||
2,2*e/3);a.lineTo(0,e);a.moveTo(d/2,2*e/3);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlActor",E);mxUtils.extend(B,mxShape);B.prototype.getLabelMargins=function(a){return new mxRectangle(a.width/6,0,0,0)};B.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,e/4);a.lineTo(0,3*e/4);a.end();a.stroke();a.begin();a.moveTo(0,e/2);a.lineTo(d/6,e/2);a.end();a.stroke();a.ellipse(d/6,0,5*d/6,e);a.fillAndStroke()};mxCellRenderer.registerShape("umlBoundary",
|
||||
B);mxUtils.extend(A,mxEllipse);A.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/8,c+e);a.lineTo(b+7*d/8,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("umlEntity",A);mxUtils.extend(C,mxShape);C.prototype.paintVertexShape=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(d,0);a.lineTo(0,e);a.moveTo(0,0);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlDestroy",C);mxUtils.extend(L,mxShape);
|
||||
L.prototype.getLabelBounds=function(a){return new mxRectangle(a.x,a.y+a.height/8,a.width,7*a.height/8)};L.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,0);a.end();a.stroke();a.ellipse(0,e/8,d,7*e/8);a.fillAndStroke()};L.prototype.paintForeground=function(a,b,c,d,e){a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,e/4);a.end();a.stroke()};mxCellRenderer.registerShape("umlControl",L);mxUtils.extend(K,mxRectangleShape);K.prototype.size=
|
||||
40;K.prototype.isHtmlAllowed=function(){return!1};K.prototype.getLabelBounds=function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale));return new mxRectangle(a.x,a.y,a.width,b)};K.prototype.paintBackground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))),g=mxUtils.getValue(this.style,"participant");null==g||null==this.state?mxRectangleShape.prototype.paintBackground.call(this,a,b,
|
||||
c,d,f):(g=this.state.view.graph.cellRenderer.getShape(g),null!=g&&g!=K&&(g=new g,g.apply(this.state),a.save(),g.paintVertexShape(a,b,c,d,f),a.restore()));f<e&&(a.setDashed(!0),a.begin(),a.moveTo(b+d/2,c+f),a.lineTo(b+d/2,c+e),a.end(),a.stroke())};K.prototype.paintForeground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));mxRectangleShape.prototype.paintForeground.call(this,a,b,c,d,Math.min(e,f))};mxCellRenderer.registerShape("umlLifeline",
|
||||
K);mxUtils.extend(H,mxShape);H.prototype.width=60;H.prototype.height=30;H.prototype.corner=10;H.prototype.getLabelMargins=function(a){return new mxRectangle(0,0,a.width-parseFloat(mxUtils.getValue(this.style,"width",this.width)*this.scale),a.height-parseFloat(mxUtils.getValue(this.style,"height",this.height)*this.scale))};H.prototype.paintBackground=function(a,b,c,d,e){var f=this.corner,g=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),h=Math.min(e,Math.max(1.5*
|
||||
function A(){mxEllipse.call(this)}function C(){mxShape.call(this)}function L(){mxShape.call(this)}function K(){mxRectangleShape.call(this)}function G(){mxShape.call(this)}function V(){mxShape.call(this)}function T(){mxShape.call(this)}function ca(){mxShape.call(this)}function W(){mxShape.call(this)}function v(){mxCylinder.call(this)}function R(){mxDoubleEllipse.call(this)}function H(){mxDoubleEllipse.call(this)}function I(){mxArrowConnector.call(this);this.spacing=0}function da(){mxArrowConnector.call(this);
|
||||
this.spacing=0}function N(){mxActor.call(this)}function J(){mxRectangleShape.call(this)}function M(){mxActor.call(this)}function aa(){mxActor.call(this)}function ea(){mxActor.call(this)}function U(){mxActor.call(this)}function P(){mxActor.call(this)}function S(){mxActor.call(this)}function Z(){mxActor.call(this)}function O(){mxActor.call(this)}function Q(){mxActor.call(this)}function fa(){mxActor.call(this)}function X(){mxEllipse.call(this)}function Y(){mxEllipse.call(this)}function pa(){mxEllipse.call(this)}
|
||||
function wa(){mxRhombus.call(this)}function xa(){mxEllipse.call(this)}function ya(){mxEllipse.call(this)}function za(){mxEllipse.call(this)}function qa(){mxEllipse.call(this)}function na(){mxActor.call(this)}function la(){mxActor.call(this)}function ma(){mxActor.call(this)}function ja(){mxConnector.call(this)}function Ca(a,b,c,d,e,f,g,h,k,l){g+=k;var m=d.clone();d.x-=e*(2*g+k);d.y-=f*(2*g+k);e*=g+k;f*=g+k;return function(){a.ellipse(m.x-e-g,m.y-f-g,2*g,2*g);l?a.fillAndStroke():a.stroke()}}mxUtils.extend(a,
|
||||
mxCylinder);a.prototype.size=20;a.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(b,e),a.lineTo(b,b),a.lineTo(0,0),a.moveTo(b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(b,e),a.lineTo(0,e-b),a.lineTo(0,0),a.close());a.end()};a.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?(a=parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))*this.scale,new mxRectangle(a,a,0,0)):null};mxCellRenderer.registerShape("cube",a);var Aa=Math.tan(mxUtils.toRadians(30)),ka=(.5-Aa)/2;mxUtils.extend(b,mxActor);b.prototype.size=20;b.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/Aa);a.translate((d-b)/2,(e-b)/2+b/4);a.moveTo(0,.25*b);a.lineTo(.5*b,b*ka);a.lineTo(b,.25*b);a.lineTo(.5*b,(.5-ka)*b);a.lineTo(0,.25*b);a.close();a.end()};mxCellRenderer.registerShape("isoRectangle",b);mxUtils.extend(c,mxCylinder);c.prototype.size=
|
||||
20;c.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(d,e/(.5+Aa));f?(a.moveTo(0,.25*b),a.lineTo(.5*b,(.5-ka)*b),a.lineTo(b,.25*b),a.moveTo(.5*b,(.5-ka)*b),a.lineTo(.5*b,(1-ka)*b)):(a.translate((d-b)/2,(e-b)/2),a.moveTo(0,.25*b),a.lineTo(.5*b,b*ka),a.lineTo(b,.25*b),a.lineTo(b,.75*b),a.lineTo(.5*b,(1-ka)*b),a.lineTo(0,.75*b),a.close());a.end()};mxCellRenderer.registerShape("isoCube",c);mxUtils.extend(d,mxCylinder);d.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.min(e/2,Math.round(e/8)+this.strokewidth-
|
||||
1);if(f&&null!=this.fill||!f&&null==this.fill)a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,b/2),a.moveTo(0,b),a.curveTo(0,2*b,d,2*b,d,b),f||(a.stroke(),a.begin()),a.translate(0,-b);f||(a.moveTo(0,b),a.curveTo(0,-b/3,d,-b/3,d,b),a.lineTo(d,e-b),a.curveTo(d,e+b/3,0,e+b/3,0,e-b),a.close())};d.prototype.getLabelMargins=function(a){return new mxRectangle(0,2.5*Math.min(a.height/2,Math.round(a.height/
|
||||
8)+this.strokewidth-1)*this.scale,0,0)};mxCellRenderer.registerShape("datastore",d);mxUtils.extend(e,mxCylinder);e.prototype.size=30;e.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));f?(a.moveTo(d-b,0),a.lineTo(d-b,b),a.lineTo(d,b)):(a.moveTo(0,0),a.lineTo(d-b,0),a.lineTo(d,b),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,0),a.close());a.end()};mxCellRenderer.registerShape("note",e);mxUtils.extend(f,mxActor);f.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d/2,.5*e,d,0);a.quadTo(.5*d,e/2,d,e);a.quadTo(d/2,.5*e,0,e);a.quadTo(.5*d,e/2,0,0);a.end()};mxCellRenderer.registerShape("switch",f);mxUtils.extend(g,mxCylinder);g.prototype.tabWidth=60;g.prototype.tabHeight=20;g.prototype.tabPosition="right";g.prototype.redrawPath=function(a,b,c,d,e,f){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"tabWidth",this.tabWidth))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"tabHeight",this.tabHeight))));
|
||||
var g=mxUtils.getValue(this.style,"tabPosition",this.tabPosition);f?"left"==g?(a.moveTo(0,c),a.lineTo(b,c)):(a.moveTo(d-b,c),a.lineTo(d,c)):("left"==g?(a.moveTo(0,0),a.lineTo(b,0),a.lineTo(b,c),a.lineTo(d,c)):(a.moveTo(0,c),a.lineTo(d-b,c),a.lineTo(d-b,0),a.lineTo(d,0)),a.lineTo(d,e),a.lineTo(0,e),a.lineTo(0,c),a.close());a.end()};mxCellRenderer.registerShape("folder",g);mxUtils.extend(h,mxActor);h.prototype.size=30;h.prototype.isRoundable=function(){return!0};h.prototype.redrawPath=function(a,b,
|
||||
c,d,e){b=Math.max(0,Math.min(d,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("card",h);mxUtils.extend(k,mxActor);k.prototype.size=.4;k.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));a.moveTo(0,b/2);a.quadTo(d/4,1.4*b,d/2,b/2);a.quadTo(3*d/4,b*(1-1.4),d,b/2);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};k.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=mxUtils.getValue(this.style,"size",this.size),c=a.width,d=a.height;if(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)return b*=
|
||||
d,new mxRectangle(a.x,a.y+b,c,d-2*b);b*=c;return new mxRectangle(a.x+b,a.y,c-2*b,d)}return a};mxCellRenderer.registerShape("tape",k);mxUtils.extend(l,mxActor);l.prototype.size=.3;l.prototype.getLabelMargins=function(a){return mxUtils.getValue(this.style,"boundedLbl",!1)?new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*a.height):null};l.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(0,
|
||||
0);a.lineTo(d,0);a.lineTo(d,e-b/2);a.quadTo(3*d/4,e-1.4*b,d/2,e-b/2);a.quadTo(d/4,e-b*(1-1.4),0,e-b/2);a.lineTo(0,b/2);a.close();a.end()};mxCellRenderer.registerShape("document",l);var Ha=mxCylinder.prototype.getCylinderSize;mxCylinder.prototype.getCylinderSize=function(a,b,c,d){var e=mxUtils.getValue(this.style,"size");return null!=e?d*Math.max(0,Math.min(1,e)):Ha.apply(this,arguments)};mxCylinder.prototype.getLabelMargins=function(a){if(mxUtils.getValue(this.style,"boundedLbl",!1)){var b=2*mxUtils.getValue(this.style,
|
||||
"size",.15);return new mxRectangle(0,Math.min(this.maxHeight*this.scale,a.height*b),0,0)}return null};mxUtils.extend(m,mxActor);m.prototype.size=.2;m.prototype.isRoundable=function(){return!0};m.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d,0),new mxPoint(d-b,e)],this.isRounded,
|
||||
c,!0);a.end()};mxCellRenderer.registerShape("parallelogram",m);mxUtils.extend(n,mxActor);n.prototype.size=.2;n.prototype.isRoundable=function(){return!0};n.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("trapezoid",
|
||||
n);mxUtils.extend(p,mxActor);p.prototype.size=.5;p.prototype.redrawPath=function(a,b,c,d,e){a.setFillColor(null);b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(d,0),new mxPoint(b,0),new mxPoint(b,e/2),new mxPoint(0,e/2),new mxPoint(b,e/2),new mxPoint(b,e),new mxPoint(d,e)],this.isRounded,c,!1);a.end()};mxCellRenderer.registerShape("curlyBracket",
|
||||
p);mxUtils.extend(r,mxActor);r.prototype.redrawPath=function(a,b,c,d,e){a.setStrokeWidth(1);a.setFillColor(this.stroke);b=d/5;a.rect(0,0,b,e);a.fillAndStroke();a.rect(2*b,0,b,e);a.fillAndStroke();a.rect(4*b,0,b,e);a.fillAndStroke()};mxCellRenderer.registerShape("parallelMarker",r);q.prototype.moveTo=function(a,b){this.originalMoveTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;this.firstX=a;this.firstY=b};q.prototype.close=function(){null!=this.firstX&&null!=this.firstY&&(this.lineTo(this.firstX,
|
||||
this.firstY),this.originalClose.apply(this.canvas,arguments));this.originalClose.apply(this.canvas,arguments)};q.prototype.quadTo=function(a,b,c,d){this.originalQuadTo.apply(this.canvas,arguments);this.lastX=c;this.lastY=d};q.prototype.curveTo=function(a,b,c,d,e,f){this.originalCurveTo.apply(this.canvas,arguments);this.lastX=e;this.lastY=f};q.prototype.arcTo=function(a,b,c,d,e,f,g){this.originalArcTo.apply(this.canvas,arguments);this.lastX=f;this.lastY=g};q.prototype.lineTo=function(a,b){if(null!=
|
||||
this.lastX&&null!=this.lastY){var c=function(a){return"number"===typeof a?a?0>a?-1:1:a===a?0:NaN:NaN},d=Math.abs(a-this.lastX),e=Math.abs(b-this.lastY),f=Math.sqrt(d*d+e*e);if(2>f){this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b;return}var g=Math.round(f/10),h=this.defaultVariation;5>g&&(g=5,h/=3);for(var k=c(a-this.lastX)*d/g,c=c(b-this.lastY)*e/g,d=d/f,e=e/f,f=0;f<g;f++){var l=(Math.random()-.5)*h;this.originalLineTo.call(this.canvas,k*f+this.lastX-l*e,c*f+this.lastY-
|
||||
l*d)}this.originalLineTo.call(this.canvas,a,b)}else this.originalLineTo.apply(this.canvas,arguments);this.lastX=a;this.lastY=b};q.prototype.destroy=function(){this.canvas.lineTo=this.originalLineTo;this.canvas.moveTo=this.originalMoveTo;this.canvas.close=this.originalClose;this.canvas.quadTo=this.originalQuadTo;this.canvas.curveTo=this.originalCurveTo;this.canvas.arcTo=this.originalArcTo};var Ia=mxShape.prototype.paint;mxShape.prototype.defaultJiggle=1.5;mxShape.prototype.paint=function(a){null!=
|
||||
this.style&&"0"!=mxUtils.getValue(this.style,"comic","0")&&null==a.handHiggle&&(a.handJiggle=new q(a,mxUtils.getValue(this.style,"jiggle",this.defaultJiggle)));Ia.apply(this,arguments);null!=a.handJiggle&&(a.handJiggle.destroy(),delete a.handJiggle)};mxRhombus.prototype.defaultJiggle=2;var Ja=mxRectangleShape.prototype.isHtmlAllowed;mxRectangleShape.prototype.isHtmlAllowed=function(){return(null==this.style||"0"==mxUtils.getValue(this.style,"comic","0"))&&Ja.apply(this,arguments)};var Ka=mxRectangleShape.prototype.paintBackground;
|
||||
mxRectangleShape.prototype.paintBackground=function(a,b,c,d,e){if(null==a.handJiggle)Ka.apply(this,arguments);else{var f=!0;null!=this.style&&(f="1"==mxUtils.getValue(this.style,mxConstants.STYLE_POINTER_EVENTS,"1"));if(f||null!=this.fill&&this.fill!=mxConstants.NONE||null!=this.stroke&&this.stroke!=mxConstants.NONE)f||null!=this.fill&&this.fill!=mxConstants.NONE||(a.pointerEvents=!1),a.begin(),this.isRounded?("1"==mxUtils.getValue(this.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?f=Math.min(d/2,Math.min(e/
|
||||
2,mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2)):(f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.min(d*f,e*f)),a.moveTo(b+f,c),a.lineTo(b+d-f,c),a.quadTo(b+d,c,b+d,c+f),a.lineTo(b+d,c+e-f),a.quadTo(b+d,c+e,b+d-f,c+e),a.lineTo(b+f,c+e),a.quadTo(b,c+e,b,c+e-f),a.lineTo(b,c+f),a.quadTo(b,c,b+f,c)):(a.moveTo(b,c),a.lineTo(b+d,c),a.lineTo(b+d,c+e),a.lineTo(b,c+e),a.lineTo(b,c)),a.close(),a.end(),a.fillAndStroke()}};
|
||||
var Da=mxRectangleShape.prototype.paintForeground;mxRectangleShape.prototype.paintForeground=function(a,b,c,d,e){null==a.handJiggle&&Da.apply(this,arguments)};mxUtils.extend(t,mxRectangleShape);t.prototype.size=.1;t.prototype.isHtmlAllowed=function(){return!1};t.prototype.getLabelBounds=function(a){if(mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,!0)==(null==this.direction||this.direction==mxConstants.DIRECTION_EAST||this.direction==mxConstants.DIRECTION_WEST)){var b=a.width,c=a.height;
|
||||
a=new mxRectangle(a.x,a.y,b,c);var d=b*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var e=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,d=Math.max(d,Math.min(b*e,c*e));a.x+=Math.round(d);a.width-=Math.round(2*d)}return a};t.prototype.paintForeground=function(a,b,c,d,e){var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));if(this.isRounded)var g=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));f=Math.round(f);a.begin();a.moveTo(b+f,c);a.lineTo(b+f,c+e);a.moveTo(b+d-f,c);a.lineTo(b+d-f,c+e);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,arguments)};mxCellRenderer.registerShape("process",t);mxUtils.extend(z,mxRectangleShape);z.prototype.paintBackground=function(a,b,c,d,e){a.setFillColor(mxConstants.NONE);a.rect(b,c,d,e);a.fill()};z.prototype.paintForeground=function(a,
|
||||
b,c,d,e){};mxCellRenderer.registerShape("transparent",z);mxUtils.extend(w,mxHexagon);w.prototype.size=30;w.prototype.position=.5;w.prototype.position2=.5;w.prototype.base=20;w.prototype.getLabelMargins=function(){return new mxRectangle(0,0,0,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale)};w.prototype.isRoundable=function(){return!0};w.prototype.redrawPath=function(a,b,c,d,e){b=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;c=Math.max(0,Math.min(e,
|
||||
parseFloat(mxUtils.getValue(this.style,"size",this.size))));var f=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position",this.position)))),g=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"position2",this.position2)))),h=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"base",this.base))));this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-c),new mxPoint(Math.min(d,f+h),e-c),new mxPoint(g,e),new mxPoint(Math.max(0,f),e-c),new mxPoint(0,
|
||||
e-c)],this.isRounded,b,!0,[4])};mxCellRenderer.registerShape("callout",w);mxUtils.extend(x,mxActor);x.prototype.size=.2;x.prototype.fixedSize=20;x.prototype.isRoundable=function(){return!0};x.prototype.redrawPath=function(a,b,c,d,e){b="0"!=mxUtils.getValue(this.style,"fixedSize","0")?Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"size",this.fixedSize)))):d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(0,e),new mxPoint(b,e/2)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("step",x);mxUtils.extend(y,mxHexagon);y.prototype.size=.25;y.prototype.isRoundable=function(){return!0};y.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.5*e),new mxPoint(d-b,e),new mxPoint(b,e),new mxPoint(0,.5*e)],this.isRounded,c,!0)};mxCellRenderer.registerShape("hexagon",y);mxUtils.extend(u,mxRectangleShape);u.prototype.isHtmlAllowed=function(){return!1};u.prototype.paintForeground=function(a,b,c,d,e){var f=Math.min(d/5,e/5)+1;a.begin();a.moveTo(b+d/2,c+f);a.lineTo(b+d/2,c+e-f);a.moveTo(b+f,c+e/2);a.lineTo(b+d-f,c+e/2);a.end();a.stroke();mxRectangleShape.prototype.paintForeground.apply(this,
|
||||
arguments)};mxCellRenderer.registerShape("plus",u);var Ea=mxRhombus.prototype.paintVertexShape;mxRhombus.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(2*Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};mxRhombus.prototype.paintVertexShape=function(a,b,c,d,e){Ea.apply(this,arguments);if(!this.outline&&1==this.style["double"]){var f=2*Math.max(2,this.strokewidth+
|
||||
1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&(a.setShadow(!1),Ea.apply(this,[a,b,c,d,e]))}};mxUtils.extend(D,mxRectangleShape);D.prototype.isHtmlAllowed=function(){return!1};D.prototype.getLabelBounds=function(a){if(1==this.style["double"]){var b=(Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0))*this.scale;return new mxRectangle(a.x+b,a.y+b,a.width-2*b,a.height-2*b)}return a};D.prototype.paintForeground=function(a,b,c,
|
||||
d,e){if(null!=this.style){if(!this.outline&&1==this.style["double"]){var f=Math.max(2,this.strokewidth+1)+parseFloat(this.style[mxConstants.STYLE_MARGIN]||0);b+=f;c+=f;d-=2*f;e-=2*f;0<d&&0<e&&mxRectangleShape.prototype.paintBackground.apply(this,arguments)}a.setDashed(!1);var f=0,g;do{g=mxCellRenderer.defaultShapes[this.style["symbol"+f]];if(null!=g){var h=this.style["symbol"+f+"Align"],k=this.style["symbol"+f+"VerticalAlign"],l=this.style["symbol"+f+"Width"],m=this.style["symbol"+f+"Height"],ra=
|
||||
this.style["symbol"+f+"Spacing"]||0,n=this.style["symbol"+f+"VSpacing"]||ra,p=this.style["symbol"+f+"ArcSpacing"];null!=p&&(p*=this.getArcSize(d+this.strokewidth,e+this.strokewidth),ra+=p,n+=p);var p=b,q=c,p=h==mxConstants.ALIGN_CENTER?p+(d-l)/2:h==mxConstants.ALIGN_RIGHT?p+(d-l-ra):p+ra,q=k==mxConstants.ALIGN_MIDDLE?q+(e-m)/2:k==mxConstants.ALIGN_BOTTOM?q+(e-m-n):q+n;a.save();h=new g;h.style=this.style;g.prototype.paintVertexShape.call(h,a,p,q,l,m);a.restore()}f++}while(null!=g)}mxRectangleShape.prototype.paintForeground.apply(this,
|
||||
arguments)};mxCellRenderer.registerShape("ext",D);mxUtils.extend(F,mxCylinder);F.prototype.redrawPath=function(a,b,c,d,e,f){f?(a.moveTo(0,0),a.lineTo(d/2,e/2),a.lineTo(d,0),a.end()):(a.moveTo(0,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(0,e),a.close())};mxCellRenderer.registerShape("message",F);mxUtils.extend(E,mxShape);E.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.ellipse(d/4,0,d/2,e/4);a.fillAndStroke();a.begin();a.moveTo(d/2,e/4);a.lineTo(d/2,2*e/3);a.moveTo(d/2,e/3);a.lineTo(0,
|
||||
e/3);a.moveTo(d/2,e/3);a.lineTo(d,e/3);a.moveTo(d/2,2*e/3);a.lineTo(0,e);a.moveTo(d/2,2*e/3);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlActor",E);mxUtils.extend(B,mxShape);B.prototype.getLabelMargins=function(a){return new mxRectangle(a.width/6,0,0,0)};B.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,e/4);a.lineTo(0,3*e/4);a.end();a.stroke();a.begin();a.moveTo(0,e/2);a.lineTo(d/6,e/2);a.end();a.stroke();a.ellipse(d/6,0,5*d/6,e);a.fillAndStroke()};
|
||||
mxCellRenderer.registerShape("umlBoundary",B);mxUtils.extend(A,mxEllipse);A.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/8,c+e);a.lineTo(b+7*d/8,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("umlEntity",A);mxUtils.extend(C,mxShape);C.prototype.paintVertexShape=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(d,0);a.lineTo(0,e);a.moveTo(0,0);a.lineTo(d,e);a.end();a.stroke()};mxCellRenderer.registerShape("umlDestroy",
|
||||
C);mxUtils.extend(L,mxShape);L.prototype.getLabelBounds=function(a){return new mxRectangle(a.x,a.y+a.height/8,a.width,7*a.height/8)};L.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,0);a.end();a.stroke();a.ellipse(0,e/8,d,7*e/8);a.fillAndStroke()};L.prototype.paintForeground=function(a,b,c,d,e){a.begin();a.moveTo(3*d/8,e/8*1.1);a.lineTo(5*d/8,e/4);a.end();a.stroke()};mxCellRenderer.registerShape("umlControl",L);mxUtils.extend(K,mxRectangleShape);
|
||||
K.prototype.size=40;K.prototype.isHtmlAllowed=function(){return!1};K.prototype.getLabelBounds=function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.style,"size",this.size))*this.scale));return new mxRectangle(a.x,a.y,a.width,b)};K.prototype.paintBackground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)))),g=mxUtils.getValue(this.style,"participant");null==g||null==this.state?mxRectangleShape.prototype.paintBackground.call(this,
|
||||
a,b,c,d,f):(g=this.state.view.graph.cellRenderer.getShape(g),null!=g&&g!=K&&(g=new g,g.apply(this.state),a.save(),g.paintVertexShape(a,b,c,d,f),a.restore()));f<e&&(a.setDashed(!0),a.begin(),a.moveTo(b+d/2,c+f),a.lineTo(b+d/2,c+e),a.end(),a.stroke())};K.prototype.paintForeground=function(a,b,c,d,e){var f=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));mxRectangleShape.prototype.paintForeground.call(this,a,b,c,d,Math.min(e,f))};mxCellRenderer.registerShape("umlLifeline",
|
||||
K);mxUtils.extend(G,mxShape);G.prototype.width=60;G.prototype.height=30;G.prototype.corner=10;G.prototype.getLabelMargins=function(a){return new mxRectangle(0,0,a.width-parseFloat(mxUtils.getValue(this.style,"width",this.width)*this.scale),a.height-parseFloat(mxUtils.getValue(this.style,"height",this.height)*this.scale))};G.prototype.paintBackground=function(a,b,c,d,e){var f=this.corner,g=Math.min(d,Math.max(f,parseFloat(mxUtils.getValue(this.style,"width",this.width)))),h=Math.min(e,Math.max(1.5*
|
||||
f,parseFloat(mxUtils.getValue(this.style,"height",this.height)))),k=mxUtils.getValue(this.style,mxConstants.STYLE_SWIMLANE_FILLCOLOR,mxConstants.NONE);k!=mxConstants.NONE&&(a.setFillColor(k),a.rect(b,c,d,e),a.fill());null!=this.fill&&this.fill!=mxConstants.NONE&&this.gradient&&this.gradient!=mxConstants.NONE?(this.getGradientBounds(a,b,c,d,e),a.setGradient(this.fill,this.gradient,b,c,d,e,this.gradientDirection)):a.setFillColor(this.fill);a.begin();a.moveTo(b,c);a.lineTo(b+g,c);a.lineTo(b+g,c+Math.max(0,
|
||||
h-1.5*f));a.lineTo(b+Math.max(0,g-f),c+h);a.lineTo(b,c+h);a.close();a.fillAndStroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+h);a.stroke()};mxCellRenderer.registerShape("umlFrame",H);mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=K.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+
|
||||
h-1.5*f));a.lineTo(b+Math.max(0,g-f),c+h);a.lineTo(b,c+h);a.close();a.fillAndStroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+d,c);a.lineTo(b+d,c+e);a.lineTo(b,c+e);a.lineTo(b,c+h);a.stroke()};mxCellRenderer.registerShape("umlFrame",G);mxPerimeter.LifelinePerimeter=function(a,b,c,d){d=K.prototype.size;null!=b&&(d=mxUtils.getValue(b.style,"size",d)*b.view.scale);b=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;c.x<a.getCenterX()&&(b=-1*(b+1));return new mxPoint(a.getCenterX()+
|
||||
b,Math.min(a.y+a.height,Math.max(a.y+d,c.y)))};mxStyleRegistry.putValue("lifelinePerimeter",mxPerimeter.LifelinePerimeter);mxPerimeter.OrthogonalPerimeter=function(a,b,c,d){d=!0;return mxPerimeter.RectanglePerimeter.apply(this,arguments)};mxStyleRegistry.putValue("orthogonalPerimeter",mxPerimeter.OrthogonalPerimeter);mxPerimeter.BackbonePerimeter=function(a,b,c,d){d=parseFloat(b.style[mxConstants.STYLE_STROKEWIDTH]||1)*b.view.scale/2-1;null!=b.style.backboneSize&&(d+=parseFloat(b.style.backboneSize)*
|
||||
b.view.scale/2-1);if("south"==b.style[mxConstants.STYLE_DIRECTION]||"north"==b.style[mxConstants.STYLE_DIRECTION])return c.x<a.getCenterX()&&(d=-1*(d+1)),new mxPoint(a.getCenterX()+d,Math.min(a.y+a.height,Math.max(a.y,c.y)));c.y<a.getCenterY()&&(d=-1*(d+1));return new mxPoint(Math.min(a.x+a.width,Math.max(a.x,c.x)),a.getCenterY()+d)};mxStyleRegistry.putValue("backbonePerimeter",mxPerimeter.BackbonePerimeter);mxPerimeter.CalloutPerimeter=function(a,b,c,d){return mxPerimeter.RectanglePerimeter(mxUtils.getDirectedBounds(a,
|
||||
new mxRectangle(0,0,0,Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(b.style,"size",w.prototype.size))*b.view.scale))),b.style),b,c,d)};mxStyleRegistry.putValue("calloutPerimeter",mxPerimeter.CalloutPerimeter);mxPerimeter.ParallelogramPerimeter=function(a,b,c,d){var e=m.prototype.size;null!=b&&(e=mxUtils.getValue(b.style,"size",e));var f=a.x,g=a.y,h=a.width,k=a.height;b=null!=b?mxUtils.getValue(b.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;b==
|
||||
|
@ -1833,90 +1833,92 @@ b==mxConstants.DIRECTION_EAST?(e=e?Math.max(0,Math.min(k,f)):k*Math.max(0,Math.m
|
|||
Math.min(l,f)):l*Math.max(0,Math.min(1,f)),h=[new mxPoint(g,h+e),new mxPoint(m,h),new mxPoint(g+k,h+e),new mxPoint(g+k,h+l),new mxPoint(m,h+l-e),new mxPoint(g,h+l),new mxPoint(g,h+e)]):(e=e?Math.max(0,Math.min(l,f)):l*Math.max(0,Math.min(1,f)),h=[new mxPoint(g,h),new mxPoint(m,h+e),new mxPoint(g+k,h),new mxPoint(g+k,h+l-e),new mxPoint(m,h+l),new mxPoint(g,h+l-e),new mxPoint(g,h)]);m=new mxPoint(m,a);d&&(c.x<g||c.x>g+k?m.y=c.y:m.x=c.x);return mxUtils.getPerimeterPoint(h,m,c)};mxStyleRegistry.putValue("stepPerimeter",
|
||||
mxPerimeter.StepPerimeter);mxPerimeter.HexagonPerimeter2=function(a,b,c,d){var e=y.prototype.size;null!=b&&(e=mxUtils.getValue(b.style,"size",e));var f=a.x,g=a.y,h=a.width,k=a.height,l=a.getCenterX();a=a.getCenterY();b=null!=b?mxUtils.getValue(b.style,mxConstants.STYLE_DIRECTION,mxConstants.DIRECTION_EAST):mxConstants.DIRECTION_EAST;b==mxConstants.DIRECTION_NORTH||b==mxConstants.DIRECTION_SOUTH?(e=k*Math.max(0,Math.min(1,e)),g=[new mxPoint(l,g),new mxPoint(f+h,g+e),new mxPoint(f+h,g+k-e),new mxPoint(l,
|
||||
g+k),new mxPoint(f,g+k-e),new mxPoint(f,g+e),new mxPoint(l,g)]):(e=h*Math.max(0,Math.min(1,e)),g=[new mxPoint(f+e,g),new mxPoint(f+h-e,g),new mxPoint(f+h,a),new mxPoint(f+h-e,g+k),new mxPoint(f+e,g+k),new mxPoint(f,a),new mxPoint(f+e,g)]);l=new mxPoint(l,a);d&&(c.x<f||c.x>f+h?l.y=c.y:l.x=c.x);return mxUtils.getPerimeterPoint(g,l,c)};mxStyleRegistry.putValue("hexagonPerimeter2",mxPerimeter.HexagonPerimeter2);mxUtils.extend(V,mxShape);V.prototype.size=10;V.prototype.paintBackground=function(a,b,c,d,
|
||||
e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",V);mxUtils.extend(S,mxShape);S.prototype.size=10;S.prototype.inset=2;S.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),g=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,
|
||||
c);a.begin();a.moveTo(d/2,f+g);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-g,f/2);a.quadTo((d-f)/2-g,f+g,d/2,f+g);a.quadTo((d+f)/2+g,f+g,(d+f)/2+g,f/2);a.end();a.stroke()};mxCellRenderer.registerShape("requires",S);mxUtils.extend(ba,mxCylinder);ba.prototype.jettyWidth=32;ba.prototype.jettyHeight=12;ba.prototype.redrawPath=function(a,b,c,d,e,f){var g=parseFloat(mxUtils.getValue(this.style,"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));
|
||||
c=g/2;var g=c+g/2,h=.3*e-b/2,k=.7*e-b/2;f?(a.moveTo(c,h),a.lineTo(g,h),a.lineTo(g,h+b),a.lineTo(c,h+b),a.moveTo(c,k),a.lineTo(g,k),a.lineTo(g,k+b),a.lineTo(c,k+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,k+b),a.lineTo(0,k+b),a.lineTo(0,k),a.lineTo(c,k),a.lineTo(c,h+b),a.lineTo(0,h+b),a.lineTo(0,h),a.lineTo(c,h),a.close());a.end()};mxCellRenderer.registerShape("component",ba);mxUtils.extend(X,mxDoubleEllipse);X.prototype.outerStroke=!0;X.prototype.paintVertexShape=function(a,
|
||||
b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.registerShape("endState",X);mxUtils.extend(v,X);v.prototype.outerStroke=!1;mxCellRenderer.registerShape("startState",v);mxUtils.extend(Q,mxArrowConnector);Q.prototype.defaultWidth=4;Q.prototype.isOpenEnded=function(){return!0};Q.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+
|
||||
Math.max(0,this.strokewidth-1)};Q.prototype.isArrowRounded=function(){return this.isRounded};mxCellRenderer.registerShape("link",Q);mxUtils.extend(G,mxArrowConnector);G.prototype.defaultWidth=10;G.prototype.defaultArrowWidth=20;G.prototype.getStartArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"startWidth",this.defaultArrowWidth)};G.prototype.getEndArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"endWidth",this.defaultArrowWidth)};G.prototype.getEdgeWidth=
|
||||
function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};mxCellRenderer.registerShape("flexArrow",G);mxUtils.extend(I,mxActor);I.prototype.size=30;I.prototype.isRoundable=function(){return!0};I.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(0,b),new mxPoint(d,
|
||||
0),new mxPoint(d,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("manualInput",I);mxUtils.extend(ca,mxRectangleShape);ca.prototype.dx=20;ca.prototype.dy=20;ca.prototype.isHtmlAllowed=function(){return!1};ca.prototype.paintForeground=function(a,b,c,d,e){mxRectangleShape.prototype.paintForeground.apply(this,arguments);var f=0;if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));g=Math.max(f,
|
||||
Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));f=Math.max(f,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));a.begin();a.moveTo(b,c+f);a.lineTo(b+d,c+f);a.end();a.stroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+g,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("internalStorage",ca);mxUtils.extend(M,mxActor);M.prototype.dx=20;M.prototype.dy=20;M.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));
|
||||
c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint(b,c),new mxPoint(b,e),new mxPoint(0,e)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("corner",M);mxUtils.extend(J,mxActor);J.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);
|
||||
a.lineTo(0,e);a.end();a.moveTo(d,0);a.lineTo(d,e);a.end();a.moveTo(0,e/2);a.lineTo(d,e/2);a.end()};mxCellRenderer.registerShape("crossbar",J);mxUtils.extend(N,mxActor);N.prototype.dx=20;N.prototype.dy=20;N.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("tee",N);mxUtils.extend(T,mxActor);T.prototype.arrowWidth=.3;T.prototype.arrowSize=.2;T.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",this.arrowWidth))));b=d*
|
||||
Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("singleArrow",T);mxUtils.extend(ea,mxActor);ea.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",T.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",T.prototype.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,
|
||||
g,!0);a.end()};mxCellRenderer.registerShape("doubleArrow",ea);mxUtils.extend(aa,mxActor);aa.prototype.size=.1;aa.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.registerShape("dataStorage",aa);mxUtils.extend(P,mxActor);P.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,
|
||||
e,0,e);a.close();a.end()};mxCellRenderer.registerShape("or",P);mxUtils.extend(W,mxActor);W.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.registerShape("xor",W);mxUtils.extend(U,mxActor);U.prototype.size=20;U.prototype.isRoundable=function(){return!0};U.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("loopLimit",U);mxUtils.extend(O,mxActor);O.prototype.size=.375;O.prototype.isRoundable=function(){return!0};O.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));c=mxUtils.getValue(this.style,
|
||||
mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("offPageConnector",O);mxUtils.extend(R,mxEllipse);R.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("tapeData",R);mxUtils.extend(fa,
|
||||
mxEllipse);fa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke();a.begin();a.moveTo(b+d/2,c);a.lineTo(b+d/2,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("orEllipse",fa);mxUtils.extend(Y,mxEllipse);Y.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b+.145*d,c+.145*
|
||||
e);a.lineTo(b+.855*d,c+.855*e);a.end();a.stroke();a.begin();a.moveTo(b+.855*d,c+.145*e);a.lineTo(b+.145*d,c+.855*e);a.end();a.stroke()};mxCellRenderer.registerShape("sumEllipse",Y);mxUtils.extend(Z,mxRhombus);Z.prototype.paintVertexShape=function(a,b,c,d,e){mxRhombus.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke()};mxCellRenderer.registerShape("sortShape",Z);mxUtils.extend(wa,mxEllipse);wa.prototype.paintVertexShape=
|
||||
function(a,b,c,d,e){a.begin();a.moveTo(b,c);a.lineTo(b+d,c);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke();a.begin();a.moveTo(b,c+e);a.lineTo(b+d,c+e);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke()};mxCellRenderer.registerShape("collate",wa);mxUtils.extend(xa,mxEllipse);xa.prototype.paintVertexShape=function(a,b,c,d,e){var f=c+e-5;a.begin();a.moveTo(b,c);a.lineTo(b,c+e);a.moveTo(b,f);a.lineTo(b+10,f-5);a.moveTo(b,f);a.lineTo(b+10,f+5);a.moveTo(b,f);a.lineTo(b+d,f);a.moveTo(b+d,c);a.lineTo(b+
|
||||
d,c+e);a.moveTo(b+d,f);a.lineTo(b+d-10,f-5);a.moveTo(b+d,f);a.lineTo(b+d-10,f+5);a.end();a.stroke()};mxCellRenderer.registerShape("dimension",xa);mxUtils.extend(ya,mxEllipse);ya.prototype.paintVertexShape=function(a,b,c,d,e){this.outline||a.setStrokeColor(null);mxRectangleShape.prototype.paintBackground.apply(this,arguments);null!=this.style&&(a.setStrokeColor(this.stroke),a.rect(b,c,d,e),a.fill(),a.begin(),a.moveTo(b,c),"1"==mxUtils.getValue(this.style,"top","1")?a.lineTo(b+d,c):a.moveTo(b+d,c),
|
||||
"1"==mxUtils.getValue(this.style,"right","1")?a.lineTo(b+d,c+e):a.moveTo(b+d,c+e),"1"==mxUtils.getValue(this.style,"bottom","1")?a.lineTo(b,c+e):a.moveTo(b,c+e),"1"==mxUtils.getValue(this.style,"left","1")&&a.lineTo(b,c-this.strokewidth/2),a.end(),a.stroke())};mxCellRenderer.registerShape("partialRectangle",ya);mxUtils.extend(pa,mxEllipse);pa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();"vertical"==mxUtils.getValue(this.style,
|
||||
"line")?(a.moveTo(b+d/2,c),a.lineTo(b+d/2,c+e)):(a.moveTo(b,c+e/2),a.lineTo(b+d,c+e/2));a.end();a.stroke()};mxCellRenderer.registerShape("lineEllipse",pa);mxUtils.extend(qa,mxActor);qa.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);a.moveTo(0,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(0,e);a.close();a.end()};mxCellRenderer.registerShape("delay",qa);mxUtils.extend(la,mxActor);la.prototype.size=.2;la.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,d);var f=
|
||||
Math.max(0,Math.min(b,b*parseFloat(mxUtils.getValue(this.style,"size",this.size))));b=(e-f)/2;c=b+f;var g=(d-f)/2,f=g+f;a.moveTo(0,b);a.lineTo(g,b);a.lineTo(g,0);a.lineTo(f,0);a.lineTo(f,b);a.lineTo(d,b);a.lineTo(d,c);a.lineTo(f,c);a.lineTo(f,e);a.lineTo(g,e);a.lineTo(g,c);a.lineTo(0,c);a.close();a.end()};mxCellRenderer.registerShape("cross",la);mxUtils.extend(ia,mxActor);ia.prototype.size=.25;ia.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);c=Math.min(d-b,Math.max(0,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size)))*d);a.moveTo(0,e/2);a.lineTo(c,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(c,e);a.close();a.end()};mxCellRenderer.registerShape("display",ia);mxUtils.extend(ja,mxConnector);ja.prototype.origPaintEdgeShape=ja.prototype.paintEdgeShape;ja.prototype.paintEdgeShape=function(a,b,c){for(var d=[],e=0;e<b.length;e++)d.push(mxUtils.clone(b[e]));var e=a.state.dashed,f=a.state.fixDash;ja.prototype.origPaintEdgeShape.apply(this,[a,d,c]);3<=a.state.strokeWidth&&(d=mxUtils.getValue(this.style,
|
||||
"fillColor",null),null!=d&&(a.setStrokeColor(d),a.setStrokeWidth(a.state.strokeWidth-2),a.setDashed(e,f),ja.prototype.origPaintEdgeShape.apply(this,[a,b,c])))};mxCellRenderer.registerShape("filledEdge",ja);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var b=this.format.getSelectionState(),c=a.apply(this,arguments);"umlFrame"==b.style.shape&&c.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",
|
||||
defaultValue:"#ffffff"});return c}}();mxMarker.addMarker("dash",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.stroke()}});mxMarker.addMarker("cross",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.moveTo(d.x-m/2+n/2,d.y-n/2-m/2);a.lineTo(d.x-n/2-3*m/2,d.y-3*n/2+m/2);a.stroke()}});
|
||||
mxMarker.addMarker("circle",Ba);mxMarker.addMarker("circlePlus",function(a,b,c,d,e,f,g,h,k,l){var m=d.clone(),n=Ba.apply(this,arguments),p=e*(g+2*k),q=f*(g+2*k);return function(){n.apply(this,arguments);a.begin();a.moveTo(m.x-e*k,m.y-f*k);a.lineTo(m.x-2*p+e*k,m.y-2*q+f*k);a.moveTo(m.x-p-q+f*k,m.y-q+p-e*k);a.lineTo(m.x+q-p-f*k,m.y-q-p+e*k);a.stroke()}});mxMarker.addMarker("async",function(a,b,c,d,e,f,g,h,k,l){b=e*k*1.118;c=f*k*1.118;e*=g+k;f*=g+k;var m=d.clone();m.x-=b;m.y-=c;d.x+=1*-e-b;d.y+=1*-f-
|
||||
c;return function(){a.begin();a.moveTo(m.x,m.y);h?a.lineTo(m.x-e-f/2,m.y-f+e/2):a.lineTo(m.x+f/2-e,m.y-f-e/2);a.lineTo(m.x-e,m.y-f);a.close();l?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(b,c,d,e,f,g,h,k,l,m){f*=h+l;g*=h+l;var n=e.clone();return function(){b.begin();b.moveTo(n.x,n.y);k?b.lineTo(n.x-f-g/a,n.y-g+f/a):b.lineTo(n.x+g/a-f,n.y-g-f/a);b.stroke()}}}(2));if("undefined"!==typeof mxVertexHandler){var Aa=function(a,b,c){return na(a,
|
||||
["width"],b,function(b,d,e,f,g){g=a.shape.getEdgeWidth()*a.view.scale+c;return new mxPoint(f.x+d*b/4+e*g/2,f.y+e*b/4-d*g/2)},function(b,d,e,f,g,h){b=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));a.style.width=Math.round(2*b)/a.view.scale-c})},na=function(a,b,c,d,e){return da(a,b,function(b){var e=a.absolutePoints,f=e.length-1;b=a.view.translate;var g=a.view.scale,h=c?e[0]:e[f],e=c?e[1]:e[f-1],f=e.x-h.x,k=e.y-h.y,l=Math.sqrt(f*f+k*k),h=d.call(this,l,f/l,k/l,h,e);return new mxPoint(h.x/g-
|
||||
b.x,h.y/g-b.y)},function(b,d,f){var g=a.absolutePoints,h=g.length-1;b=a.view.translate;var k=a.view.scale,l=c?g[0]:g[h],g=c?g[1]:g[h-1],h=g.x-l.x,m=g.y-l.y,n=Math.sqrt(h*h+m*m);d.x=(d.x+b.x)*k;d.y=(d.y+b.y)*k;e.call(this,n,h/n,m/n,l,g,d,f)})},ha=function(a){return function(b){return[da(b,["arrowWidth","arrowSize"],function(b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",T.prototype.arrowWidth))),d=Math.max(0,Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",T.prototype.arrowSize)));
|
||||
return new mxPoint(b.x+(1-d)*b.width,b.y+(1-c)*b.height/2)},function(b,c){this.state.style.arrowWidth=Math.max(0,Math.min(1,Math.abs(b.y+b.height/2-c.y)/b.height*2));this.state.style.arrowSize=Math.max(0,Math.min(a,(b.x+b.width-c.x)/b.width))})]}},ma=function(a,b,c){return function(d){var e=[da(d,["size"],function(c){var d=Math.max(0,Math.min(c.width,Math.min(c.height,parseFloat(mxUtils.getValue(this.state.style,"size",b)))))*a;return new mxPoint(c.x+d,c.y+d)},function(b,c){this.state.style.size=
|
||||
Math.round(Math.max(0,Math.min(Math.min(b.width,c.x-b.x),Math.min(b.height,c.y-b.y)))/a)})];c&&mxUtils.getValue(d.style,mxConstants.STYLE_ROUNDED,!1)&&e.push(ga(d));return e}},sa=function(a,b,c,d,e){c=null!=c?c:1;return function(f){var g=[da(f,["size"],function(b){var c=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null,d=parseFloat(mxUtils.getValue(this.state.style,"size",c?e:a));return new mxPoint(b.x+Math.max(0,Math.min(b.width,d*(c?1:b.width))),b.getCenterY())},function(a,b,
|
||||
d){var g=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null;a=g?b.x-a.x:Math.max(0,Math.min(c,(b.x-a.x)/a.width));g&&!mxEvent.isAltDown(d.getEvent())&&(a=f.view.graph.snap(a));this.state.style.size=a},null,d)];b&&mxUtils.getValue(f.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(ga(f));return g}},Da=function(a){return function(b){var c=[da(b,["size"],function(b){var c=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,"size",n.prototype.size))));return new mxPoint(b.x+
|
||||
c*b.width*.75,b.y+b.height/4)},function(b,c){this.state.style.size=Math.max(0,Math.min(a,(c.x-b.x)/(.75*b.width)))},null,!0)];mxUtils.getValue(b.style,mxConstants.STYLE_ROUNDED,!1)&&c.push(ga(b));return c}},oa=function(){return function(a){var b=[];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b}},ga=function(a,b){return da(a,[mxConstants.STYLE_ARCSIZE],function(c){var d=null!=b?b:c.height/8;if("1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)){var e=
|
||||
mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;return new mxPoint(c.x+c.width-Math.min(c.width/2,e),c.y+d)}e=Math.max(0,parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)))/100;return new mxPoint(c.x+c.width-Math.min(Math.max(c.width/2,c.height/2),Math.min(c.width,c.height)*e),c.y+d)},function(b,c,d){"1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.max(0,
|
||||
Math.min(b.width,2*(b.x+b.width-c.x)))):this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.min(50,Math.max(0,100*(b.width-c.x+b.x)/Math.min(b.width,b.height))))})},da=function(a,b,c,d,e,f){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<b.length;a++)this.copyStyle(b[a])};g.getPosition=c;g.setPosition=d;g.ignoreGrid=null!=e?e:!0;if(f){var h=g.positionChanged;g.positionChanged=function(){h.apply(this,arguments);a.view.invalidate(this.state.cell);
|
||||
a.view.validate()}}return g},ta={link:function(a){return[Aa(a,!0,10),Aa(a,!1,10)]},flexArrow:function(a){var b=a.view.graph.gridSize/a.view.scale,c=[];mxUtils.getValue(a.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(na(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+
|
||||
c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(k.getEvent())||
|
||||
Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),c.push(na(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*
|
||||
a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=
|
||||
a.style.startWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]),Math.abs(parseFloat(a.style.startWidth)-parseFloat(a.style.endWidth))<b&&(a.style.startWidth=a.style.endWidth))})));mxUtils.getValue(a.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(na(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],
|
||||
!1,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/
|
||||
3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE])})),c.push(na(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(b,
|
||||
c,d,e,f){b=(a.shape.getEndArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;
|
||||
a.style.endWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE],a.style.startWidth=a.style.endWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]),Math.abs(parseFloat(a.style.endWidth)-parseFloat(a.style.startWidth))<
|
||||
b&&(a.style.endWidth=a.style.startWidth))})));return c},swimlane:function(a){var b=[da(a,[mxConstants.STYLE_STARTSIZE],function(b){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));return 1==mxUtils.getValue(a.style,mxConstants.STYLE_HORIZONTAL,1)?new mxPoint(b.getCenterX(),b.y+Math.max(0,Math.min(b.height,c))):new mxPoint(b.x+Math.max(0,Math.min(b.width,c)),b.getCenterY())},function(b,c){a.style[mxConstants.STYLE_STARTSIZE]=1==mxUtils.getValue(this.state.style,
|
||||
mxConstants.STYLE_HORIZONTAL,1)?Math.round(Math.max(0,Math.min(b.height,c.y-b.y))):Math.round(Math.max(0,Math.min(b.width,c.x-b.x)))})];if(mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED)){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));b.push(ga(a,c/2))}return b},label:oa(),ext:oa(),rectangle:oa(),triangle:oa(),rhombus:oa(),umlLifeline:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,
|
||||
"size",K.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))},!1)]},umlFrame:function(a){return[da(a,["width","height"],function(a){var b=Math.max(H.prototype.corner,Math.min(a.width,mxUtils.getValue(this.state.style,"width",H.prototype.width))),c=Math.max(1.5*H.prototype.corner,Math.min(a.height,mxUtils.getValue(this.state.style,"height",H.prototype.height)));return new mxPoint(a.x+b,a.y+c)},function(a,
|
||||
b){this.state.style.width=Math.round(Math.max(H.prototype.corner,Math.min(a.width,b.x-a.x)));this.state.style.height=Math.round(Math.max(1.5*H.prototype.corner,Math.min(a.height,b.y-a.y)))},!1)]},process:function(a){var b=[da(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",t.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,
|
||||
mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},cross:function(a){return[da(a,["size"],function(a){var b=Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",la.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},note:function(a){return[da(a,["size"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[da(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",I.prototype.size)));return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,
|
||||
b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},dataStorage:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",aa.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-b.x)/a.width))})]},callout:function(a){var b=[da(a,["size",
|
||||
"position"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));mxUtils.getValue(this.state.style,"base",w.prototype.base);return new mxPoint(a.x+c*a.width,a.y+a.height-b)},function(a,b){mxUtils.getValue(this.state.style,"base",w.prototype.base);this.state.style.size=Math.round(Math.max(0,Math.min(a.height,a.y+a.height-b.y)));this.state.style.position=
|
||||
Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),da(a,["position2"],function(a){var b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position2",w.prototype.position2)));return new mxPoint(a.x+b*a.width,a.y+a.height)},function(a,b){this.state.style.position2=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),da(a,["base"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,
|
||||
"position",w.prototype.position))),d=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"base",w.prototype.base)));return new mxPoint(a.x+Math.min(a.width,c*a.width+d),a.y+a.height-b)},function(a,b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));this.state.style.base=Math.round(Math.max(0,Math.min(a.width,b.x-a.x-c*a.width)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},internalStorage:function(a){var b=
|
||||
[da(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",ca.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",ca.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},corner:function(a){return[da(a,
|
||||
["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",M.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",M.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[da(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,
|
||||
"dx",N.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",N.prototype.dy)));return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ha(1),doubleArrow:ha(.5),folder:function(a){return[da(a,["tabWidth","tabHeight"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,
|
||||
"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",g.prototype.tabHeight)));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(b=a.width-b);return new mxPoint(a.x+b,a.y+c)},function(a,b){var c=Math.max(0,Math.min(a.width,b.x-a.x));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(c=a.width-c);this.state.style.tabWidth=Math.round(c);this.state.style.tabHeight=
|
||||
Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},document:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",l.prototype.size))));return new mxPoint(a.x+3*a.width/4,a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},tape:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",k.prototype.size))));
|
||||
return new mxPoint(a.getCenterX(),a.y+b*a.height/2)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(b.y-a.y)/a.height*2))})]},offPageConnector:function(a){return[da(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",O.prototype.size))));return new mxPoint(a.getCenterX(),a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},step:sa(x.prototype.size,!0,null,!0,x.prototype.fixedSize),
|
||||
hexagon:sa(y.prototype.size,!0,.5,!0),curlyBracket:sa(p.prototype.size,!1),display:sa(ia.prototype.size,!1),cube:ma(1,a.prototype.size,!1),card:ma(.5,h.prototype.size,!0),loopLimit:ma(.5,U.prototype.size,!0),trapezoid:Da(.5),parallelogram:Da(1)};Graph.createHandle=da;Graph.handleFactory=ta;mxVertexHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()&&this.graph.isCellRotatable(this.state.cell)){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&
|
||||
null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_RECTANGLE);a=ta[a];null==a&&null!=this.state.shape&&this.state.shape.isRoundable()&&(a=ta[mxConstants.SHAPE_RECTANGLE]);if(null!=a)return a(this.state)}return null};mxEdgeHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_CONNECTOR);a=ta[a];if(null!=a)return a(this.state)}return null}}else Graph.createHandle=
|
||||
function(){},Graph.handleFactory={};var ua=new mxPoint(1,0),va=new mxPoint(1,0),ha=mxUtils.toRadians(-30),ua=mxUtils.getRotatedPoint(ua,Math.cos(ha),Math.sin(ha)),ha=mxUtils.toRadians(-150),va=mxUtils.getRotatedPoint(va,Math.cos(ha),Math.sin(ha));mxEdgeStyle.IsometricConnector=function(a,b,c,d,e){var f=a.view;d=null!=d&&0<d.length?d[0]:null;var g=a.absolutePoints,h=g[0],g=g[g.length-1];null!=d&&(d=f.transformControlPoint(a,d));null==h&&null!=b&&(h=new mxPoint(b.getCenterX(),b.getCenterY()));null==
|
||||
g&&null!=c&&(g=new mxPoint(c.getCenterX(),c.getCenterY()));var k=ua.x,l=ua.y,m=va.x,n=va.y,p="horizontal"==mxUtils.getValue(a.style,"elbow","horizontal");if(null!=g&&null!=h){a=function(a,b,c){a-=q.x;var d=b-q.y;b=(n*a-m*d)/(k*n-l*m);a=(l*a-k*d)/(l*m-k*n);p?(c&&(q=new mxPoint(q.x+k*b,q.y+l*b),e.push(q)),q=new mxPoint(q.x+m*a,q.y+n*a)):(c&&(q=new mxPoint(q.x+m*a,q.y+n*a),e.push(q)),q=new mxPoint(q.x+k*b,q.y+l*b));e.push(q)};var q=h;null==d&&(d=new mxPoint(h.x+(g.x-h.x)/2,h.y+(g.y-h.y)/2));a(d.x,d.y,
|
||||
!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var Ja=Graph.prototype.createEdgeHandler;Graph.prototype.createEdgeHandler=function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return Ja.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];w.prototype.constraints=[];mxRectangleShape.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,
|
||||
0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];
|
||||
mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;u.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=mxRectangleShape.prototype.constraints;h.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;ca.prototype.constraints=mxRectangleShape.prototype.constraints;aa.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;R.prototype.constraints=mxEllipse.prototype.constraints;fa.prototype.constraints=mxEllipse.prototype.constraints;Y.prototype.constraints=mxEllipse.prototype.constraints;pa.prototype.constraints=mxEllipse.prototype.constraints;I.prototype.constraints=mxRectangleShape.prototype.constraints;qa.prototype.constraints=mxRectangleShape.prototype.constraints;ia.prototype.constraints=mxRectangleShape.prototype.constraints;U.prototype.constraints=mxRectangleShape.prototype.constraints;
|
||||
O.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.3),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.7),!0),new mxConnectionConstraint(new mxPoint(.15,.95),!1),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.85,.95),!1)];E.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.1),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.75,.1),!1),new mxConnectionConstraint(new mxPoint(0,1/3),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(1,1/3),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1)];ba.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxActor.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.25,.2),!1),new mxConnectionConstraint(new mxPoint(.1,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.75,.25),!1),new mxConnectionConstraint(new mxPoint(.9,.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];f.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(.5,.75),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
1),!1)];k.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.35),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.65),!1),new mxConnectionConstraint(new mxPoint(1,.35),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,.65),!1),new mxConnectionConstraint(new mxPoint(.25,1),!1),new mxConnectionConstraint(new mxPoint(.75,0),!1)];x.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),
|
||||
!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.75),!0)];mxLine.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];mxDoubleEllipse.prototype.constraints=mxEllipse.prototype.constraints;mxRhombus.prototype.constraints=mxEllipse.prototype.constraints;mxTriangle.prototype.constraints=
|
||||
[new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0)];mxHexagon.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.375,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.625,0),!0),new mxConnectionConstraint(new mxPoint(0,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.375,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.625,1),!0)];mxCloud.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.25),!1),new mxConnectionConstraint(new mxPoint(.4,
|
||||
.1),!1),new mxConnectionConstraint(new mxPoint(.16,.55),!1),new mxConnectionConstraint(new mxPoint(.07,.4),!1),new mxConnectionConstraint(new mxPoint(.31,.8),!1),new mxConnectionConstraint(new mxPoint(.13,.77),!1),new mxConnectionConstraint(new mxPoint(.8,.8),!1),new mxConnectionConstraint(new mxPoint(.55,.95),!1),new mxConnectionConstraint(new mxPoint(.875,.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,
|
||||
.25),!1)];m.prototype.constraints=mxRectangleShape.prototype.constraints;n.prototype.constraints=mxRectangleShape.prototype.constraints;l.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),
|
||||
!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxArrow.prototype.constraints=null;N.prototype.constraints=null;M.prototype.constraints=null;J.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,1),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1),new mxConnectionConstraint(new mxPoint(.75,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];T.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];ea.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];la.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];K.prototype.constraints=null;P.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];W.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.175,
|
||||
.25),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.175,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)]})();
|
||||
e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size));a.translate(b,c);a.ellipse((d-f)/2,0,f,f);a.fillAndStroke();a.begin();a.moveTo(d/2,f);a.lineTo(d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("lollipop",V);mxUtils.extend(T,mxShape);T.prototype.size=10;T.prototype.inset=2;T.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"size",this.size)),g=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,
|
||||
c);a.begin();a.moveTo(d/2,f+g);a.lineTo(d/2,e);a.end();a.stroke();a.begin();a.moveTo((d-f)/2-g,f/2);a.quadTo((d-f)/2-g,f+g,d/2,f+g);a.quadTo((d+f)/2+g,f+g,(d+f)/2+g,f/2);a.end();a.stroke()};mxCellRenderer.registerShape("requires",T);mxUtils.extend(ca,mxShape);ca.prototype.paintBackground=function(a,b,c,d,e){a.translate(b,c);a.begin();a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.end();a.stroke()};mxCellRenderer.registerShape("requiredInterface",ca);mxUtils.extend(W,mxShape);W.prototype.inset=
|
||||
2;W.prototype.paintBackground=function(a,b,c,d,e){var f=parseFloat(mxUtils.getValue(this.style,"inset",this.inset))+this.strokewidth;a.translate(b,c);a.ellipse(0,f,d-2*f,e-2*f);a.fillAndStroke();a.begin();a.moveTo(d/2,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d/2,e);a.end();a.stroke()};mxCellRenderer.registerShape("providedRequiredInterface",W);mxUtils.extend(v,mxCylinder);v.prototype.jettyWidth=32;v.prototype.jettyHeight=12;v.prototype.redrawPath=function(a,b,c,d,e,f){var g=parseFloat(mxUtils.getValue(this.style,
|
||||
"jettyWidth",this.jettyWidth));b=parseFloat(mxUtils.getValue(this.style,"jettyHeight",this.jettyHeight));c=g/2;var g=c+g/2,h=.3*e-b/2,k=.7*e-b/2;f?(a.moveTo(c,h),a.lineTo(g,h),a.lineTo(g,h+b),a.lineTo(c,h+b),a.moveTo(c,k),a.lineTo(g,k),a.lineTo(g,k+b),a.lineTo(c,k+b)):(a.moveTo(c,0),a.lineTo(d,0),a.lineTo(d,e),a.lineTo(c,e),a.lineTo(c,k+b),a.lineTo(0,k+b),a.lineTo(0,k),a.lineTo(c,k),a.lineTo(c,h+b),a.lineTo(0,h+b),a.lineTo(0,h),a.lineTo(c,h),a.close());a.end()};mxCellRenderer.registerShape("component",
|
||||
v);mxUtils.extend(R,mxDoubleEllipse);R.prototype.outerStroke=!0;R.prototype.paintVertexShape=function(a,b,c,d,e){var f=Math.min(4,Math.min(d/5,e/5));0<d&&0<e&&(a.ellipse(b+f,c+f,d-2*f,e-2*f),a.fillAndStroke());a.setShadow(!1);this.outerStroke&&(a.ellipse(b,c,d,e),a.stroke())};mxCellRenderer.registerShape("endState",R);mxUtils.extend(H,R);H.prototype.outerStroke=!1;mxCellRenderer.registerShape("startState",H);mxUtils.extend(I,mxArrowConnector);I.prototype.defaultWidth=4;I.prototype.isOpenEnded=function(){return!0};
|
||||
I.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};I.prototype.isArrowRounded=function(){return this.isRounded};mxCellRenderer.registerShape("link",I);mxUtils.extend(da,mxArrowConnector);da.prototype.defaultWidth=10;da.prototype.defaultArrowWidth=20;da.prototype.getStartArrowWidth=function(){return this.getEdgeWidth()+mxUtils.getNumber(this.style,"startWidth",this.defaultArrowWidth)};da.prototype.getEndArrowWidth=function(){return this.getEdgeWidth()+
|
||||
mxUtils.getNumber(this.style,"endWidth",this.defaultArrowWidth)};da.prototype.getEdgeWidth=function(){return mxUtils.getNumber(this.style,"width",this.defaultWidth)+Math.max(0,this.strokewidth-1)};mxCellRenderer.registerShape("flexArrow",da);mxUtils.extend(N,mxActor);N.prototype.size=30;N.prototype.isRoundable=function(){return!0};N.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(e,parseFloat(mxUtils.getValue(this.style,"size",this.size)));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e),new mxPoint(0,b),new mxPoint(d,0),new mxPoint(d,e)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("manualInput",N);mxUtils.extend(J,mxRectangleShape);J.prototype.dx=20;J.prototype.dy=20;J.prototype.isHtmlAllowed=function(){return!1};J.prototype.paintForeground=function(a,b,c,d,e){mxRectangleShape.prototype.paintForeground.apply(this,arguments);var f=0;if(this.isRounded)var g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,
|
||||
100*mxConstants.RECTANGLE_ROUNDING_FACTOR)/100,f=Math.max(f,Math.min(d*g,e*g));g=Math.max(f,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));f=Math.max(f,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));a.begin();a.moveTo(b,c+f);a.lineTo(b+d,c+f);a.end();a.stroke();a.begin();a.moveTo(b+g,c);a.lineTo(b+g,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("internalStorage",J);mxUtils.extend(M,mxActor);M.prototype.dx=20;M.prototype.dy=20;M.prototype.redrawPath=
|
||||
function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint(b,c),new mxPoint(b,e),new mxPoint(0,e)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("corner",
|
||||
M);mxUtils.extend(aa,mxActor);aa.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.lineTo(0,e);a.end();a.moveTo(d,0);a.lineTo(d,e);a.end();a.moveTo(0,e/2);a.lineTo(d,e/2);a.end()};mxCellRenderer.registerShape("crossbar",aa);mxUtils.extend(ea,mxActor);ea.prototype.dx=20;ea.prototype.dy=20;ea.prototype.redrawPath=function(a,b,c,d,e){b=Math.max(0,Math.min(d,parseFloat(mxUtils.getValue(this.style,"dx",this.dx))));c=Math.max(0,Math.min(e,parseFloat(mxUtils.getValue(this.style,"dy",this.dy))));parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size));var f=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,c),new mxPoint((d+b)/2,c),new mxPoint((d+b)/2,e),new mxPoint((d-b)/2,e),new mxPoint((d-b)/2,c),new mxPoint(0,c)],this.isRounded,f,!0);a.end()};mxCellRenderer.registerShape("tee",ea);mxUtils.extend(U,mxActor);U.prototype.arrowWidth=.3;U.prototype.arrowSize=.2;U.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,
|
||||
parseFloat(mxUtils.getValue(this.style,"arrowWidth",this.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",this.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-b,e),new mxPoint(d-b,f),new mxPoint(0,f)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("singleArrow",U);mxUtils.extend(P,
|
||||
mxActor);P.prototype.redrawPath=function(a,b,c,d,e){var f=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowWidth",U.prototype.arrowWidth))));b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"arrowSize",U.prototype.arrowSize))));c=(e-f)/2;var f=c+f,g=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,e/2),new mxPoint(b,0),new mxPoint(b,c),new mxPoint(d-b,c),new mxPoint(d-b,0),new mxPoint(d,e/2),new mxPoint(d-
|
||||
b,e),new mxPoint(d-b,f),new mxPoint(b,f),new mxPoint(b,e)],this.isRounded,g,!0);a.end()};mxCellRenderer.registerShape("doubleArrow",P);mxUtils.extend(S,mxActor);S.prototype.size=.1;S.prototype.redrawPath=function(a,b,c,d,e){b=d*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,"size",this.size))));a.moveTo(b,0);a.lineTo(d,0);a.quadTo(d-2*b,e/2,d,e);a.lineTo(b,e);a.quadTo(b-2*b,e/2,b,0);a.close();a.end()};mxCellRenderer.registerShape("dataStorage",S);mxUtils.extend(Z,mxActor);Z.prototype.redrawPath=
|
||||
function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.close();a.end()};mxCellRenderer.registerShape("or",Z);mxUtils.extend(O,mxActor);O.prototype.redrawPath=function(a,b,c,d,e){a.moveTo(0,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,0,e);a.quadTo(d/2,e/2,0,0);a.close();a.end()};mxCellRenderer.registerShape("xor",O);mxUtils.extend(Q,mxActor);Q.prototype.size=20;Q.prototype.isRoundable=function(){return!0};Q.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d/2,Math.min(e,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(b,0),new mxPoint(d-b,0),new mxPoint(d,.8*b),new mxPoint(d,e),new mxPoint(0,e),new mxPoint(0,.8*b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("loopLimit",Q);mxUtils.extend(fa,mxActor);fa.prototype.size=.375;fa.prototype.isRoundable=function(){return!0};fa.prototype.redrawPath=function(a,b,c,d,e){b=e*Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.style,
|
||||
"size",this.size))));c=mxUtils.getValue(this.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;this.addPoints(a,[new mxPoint(0,0),new mxPoint(d,0),new mxPoint(d,e-b),new mxPoint(d/2,e),new mxPoint(0,e-b)],this.isRounded,c,!0);a.end()};mxCellRenderer.registerShape("offPageConnector",fa);mxUtils.extend(X,mxEllipse);X.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.begin();a.moveTo(b+d/2,c+e);a.lineTo(b+d,c+e);a.end();a.stroke()};
|
||||
mxCellRenderer.registerShape("tapeData",X);mxUtils.extend(Y,mxEllipse);Y.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke();a.begin();a.moveTo(b+d/2,c);a.lineTo(b+d/2,c+e);a.end();a.stroke()};mxCellRenderer.registerShape("orEllipse",Y);mxUtils.extend(pa,mxEllipse);pa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,
|
||||
arguments);a.setShadow(!1);a.begin();a.moveTo(b+.145*d,c+.145*e);a.lineTo(b+.855*d,c+.855*e);a.end();a.stroke();a.begin();a.moveTo(b+.855*d,c+.145*e);a.lineTo(b+.145*d,c+.855*e);a.end();a.stroke()};mxCellRenderer.registerShape("sumEllipse",pa);mxUtils.extend(wa,mxRhombus);wa.prototype.paintVertexShape=function(a,b,c,d,e){mxRhombus.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);a.begin();a.moveTo(b,c+e/2);a.lineTo(b+d,c+e/2);a.end();a.stroke()};mxCellRenderer.registerShape("sortShape",
|
||||
wa);mxUtils.extend(xa,mxEllipse);xa.prototype.paintVertexShape=function(a,b,c,d,e){a.begin();a.moveTo(b,c);a.lineTo(b+d,c);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke();a.begin();a.moveTo(b,c+e);a.lineTo(b+d,c+e);a.lineTo(b+d/2,c+e/2);a.close();a.fillAndStroke()};mxCellRenderer.registerShape("collate",xa);mxUtils.extend(ya,mxEllipse);ya.prototype.paintVertexShape=function(a,b,c,d,e){var f=c+e-5;a.begin();a.moveTo(b,c);a.lineTo(b,c+e);a.moveTo(b,f);a.lineTo(b+10,f-5);a.moveTo(b,f);a.lineTo(b+10,
|
||||
f+5);a.moveTo(b,f);a.lineTo(b+d,f);a.moveTo(b+d,c);a.lineTo(b+d,c+e);a.moveTo(b+d,f);a.lineTo(b+d-10,f-5);a.moveTo(b+d,f);a.lineTo(b+d-10,f+5);a.end();a.stroke()};mxCellRenderer.registerShape("dimension",ya);mxUtils.extend(za,mxEllipse);za.prototype.paintVertexShape=function(a,b,c,d,e){this.outline||a.setStrokeColor(null);mxRectangleShape.prototype.paintBackground.apply(this,arguments);null!=this.style&&(a.setStrokeColor(this.stroke),a.rect(b,c,d,e),a.fill(),a.begin(),a.moveTo(b,c),"1"==mxUtils.getValue(this.style,
|
||||
"top","1")?a.lineTo(b+d,c):a.moveTo(b+d,c),"1"==mxUtils.getValue(this.style,"right","1")?a.lineTo(b+d,c+e):a.moveTo(b+d,c+e),"1"==mxUtils.getValue(this.style,"bottom","1")?a.lineTo(b,c+e):a.moveTo(b,c+e),"1"==mxUtils.getValue(this.style,"left","1")&&a.lineTo(b,c-this.strokewidth/2),a.end(),a.stroke())};mxCellRenderer.registerShape("partialRectangle",za);mxUtils.extend(qa,mxEllipse);qa.prototype.paintVertexShape=function(a,b,c,d,e){mxEllipse.prototype.paintVertexShape.apply(this,arguments);a.setShadow(!1);
|
||||
a.begin();"vertical"==mxUtils.getValue(this.style,"line")?(a.moveTo(b+d/2,c),a.lineTo(b+d/2,c+e)):(a.moveTo(b,c+e/2),a.lineTo(b+d,c+e/2));a.end();a.stroke()};mxCellRenderer.registerShape("lineEllipse",qa);mxUtils.extend(na,mxActor);na.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);a.moveTo(0,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(0,e);a.close();a.end()};mxCellRenderer.registerShape("delay",na);mxUtils.extend(la,mxActor);la.prototype.size=.2;la.prototype.redrawPath=
|
||||
function(a,b,c,d,e){b=Math.min(e,d);var f=Math.max(0,Math.min(b,b*parseFloat(mxUtils.getValue(this.style,"size",this.size))));b=(e-f)/2;c=b+f;var g=(d-f)/2,f=g+f;a.moveTo(0,b);a.lineTo(g,b);a.lineTo(g,0);a.lineTo(f,0);a.lineTo(f,b);a.lineTo(d,b);a.lineTo(d,c);a.lineTo(f,c);a.lineTo(f,e);a.lineTo(g,e);a.lineTo(g,c);a.lineTo(0,c);a.close();a.end()};mxCellRenderer.registerShape("cross",la);mxUtils.extend(ma,mxActor);ma.prototype.size=.25;ma.prototype.redrawPath=function(a,b,c,d,e){b=Math.min(d,e/2);
|
||||
c=Math.min(d-b,Math.max(0,parseFloat(mxUtils.getValue(this.style,"size",this.size)))*d);a.moveTo(0,e/2);a.lineTo(c,0);a.lineTo(d-b,0);a.quadTo(d,0,d,e/2);a.quadTo(d,e,d-b,e);a.lineTo(c,e);a.close();a.end()};mxCellRenderer.registerShape("display",ma);mxUtils.extend(ja,mxConnector);ja.prototype.origPaintEdgeShape=ja.prototype.paintEdgeShape;ja.prototype.paintEdgeShape=function(a,b,c){for(var d=[],e=0;e<b.length;e++)d.push(mxUtils.clone(b[e]));var e=a.state.dashed,f=a.state.fixDash;ja.prototype.origPaintEdgeShape.apply(this,
|
||||
[a,d,c]);3<=a.state.strokeWidth&&(d=mxUtils.getValue(this.style,"fillColor",null),null!=d&&(a.setStrokeColor(d),a.setStrokeWidth(a.state.strokeWidth-2),a.setDashed(e,f),ja.prototype.origPaintEdgeShape.apply(this,[a,b,c])))};mxCellRenderer.registerShape("filledEdge",ja);"undefined"!==typeof StyleFormatPanel&&function(){var a=StyleFormatPanel.prototype.getCustomColors;StyleFormatPanel.prototype.getCustomColors=function(){var b=this.format.getSelectionState(),c=a.apply(this,arguments);"umlFrame"==b.style.shape&&
|
||||
c.push({title:mxResources.get("laneColor"),key:"swimlaneFillColor",defaultValue:"#ffffff"});return c}}();mxMarker.addMarker("dash",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.stroke()}});mxMarker.addMarker("cross",function(a,b,c,d,e,f,g,h,k,l){var m=e*(g+k+1),n=f*(g+k+1);return function(){a.begin();a.moveTo(d.x-m/2-n/2,d.y-n/2+m/2);a.lineTo(d.x+n/2-3*m/2,d.y-3*n/2-m/2);a.moveTo(d.x-
|
||||
m/2+n/2,d.y-n/2-m/2);a.lineTo(d.x-n/2-3*m/2,d.y-3*n/2+m/2);a.stroke()}});mxMarker.addMarker("circle",Ca);mxMarker.addMarker("circlePlus",function(a,b,c,d,e,f,g,h,k,l){var m=d.clone(),n=Ca.apply(this,arguments),p=e*(g+2*k),q=f*(g+2*k);return function(){n.apply(this,arguments);a.begin();a.moveTo(m.x-e*k,m.y-f*k);a.lineTo(m.x-2*p+e*k,m.y-2*q+f*k);a.moveTo(m.x-p-q+f*k,m.y-q+p-e*k);a.lineTo(m.x+q-p-f*k,m.y-q-p+e*k);a.stroke()}});mxMarker.addMarker("async",function(a,b,c,d,e,f,g,h,k,l){b=e*k*1.118;c=f*
|
||||
k*1.118;e*=g+k;f*=g+k;var m=d.clone();m.x-=b;m.y-=c;d.x+=1*-e-b;d.y+=1*-f-c;return function(){a.begin();a.moveTo(m.x,m.y);h?a.lineTo(m.x-e-f/2,m.y-f+e/2):a.lineTo(m.x+f/2-e,m.y-f-e/2);a.lineTo(m.x-e,m.y-f);a.close();l?a.fillAndStroke():a.stroke()}});mxMarker.addMarker("openAsync",function(a){a=null!=a?a:2;return function(b,c,d,e,f,g,h,k,l,m){f*=h+l;g*=h+l;var n=e.clone();return function(){b.begin();b.moveTo(n.x,n.y);k?b.lineTo(n.x-f-g/a,n.y-g+f/a):b.lineTo(n.x+g/a-f,n.y-g-f/a);b.stroke()}}}(2));if("undefined"!==
|
||||
typeof mxVertexHandler){var Fa=function(a,b,c){return ha(a,["width"],b,function(b,d,e,f,g){g=a.shape.getEdgeWidth()*a.view.scale+c;return new mxPoint(f.x+d*b/4+e*g/2,f.y+e*b/4-d*g/2)},function(b,d,e,f,g,h){b=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));a.style.width=Math.round(2*b)/a.view.scale-c})},ha=function(a,b,c,d,e){return ba(a,b,function(b){var e=a.absolutePoints,f=e.length-1;b=a.view.translate;var g=a.view.scale,h=c?e[0]:e[f],e=c?e[1]:e[f-1],f=e.x-h.x,k=e.y-h.y,l=Math.sqrt(f*f+
|
||||
k*k),h=d.call(this,l,f/l,k/l,h,e);return new mxPoint(h.x/g-b.x,h.y/g-b.y)},function(b,d,f){var g=a.absolutePoints,h=g.length-1;b=a.view.translate;var k=a.view.scale,l=c?g[0]:g[h],g=c?g[1]:g[h-1],h=g.x-l.x,m=g.y-l.y,n=Math.sqrt(h*h+m*m);d.x=(d.x+b.x)*k;d.y=(d.y+b.y)*k;e.call(this,n,h/n,m/n,l,g,d,f)})},ia=function(a){return function(b){return[ba(b,["arrowWidth","arrowSize"],function(b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"arrowWidth",U.prototype.arrowWidth))),d=Math.max(0,
|
||||
Math.min(a,mxUtils.getValue(this.state.style,"arrowSize",U.prototype.arrowSize)));return new mxPoint(b.x+(1-d)*b.width,b.y+(1-c)*b.height/2)},function(b,c){this.state.style.arrowWidth=Math.max(0,Math.min(1,Math.abs(b.y+b.height/2-c.y)/b.height*2));this.state.style.arrowSize=Math.max(0,Math.min(a,(b.x+b.width-c.x)/b.width))})]}},Ba=function(a,b,c){return function(d){var e=[ba(d,["size"],function(c){var d=Math.max(0,Math.min(c.width,Math.min(c.height,parseFloat(mxUtils.getValue(this.state.style,"size",
|
||||
b)))))*a;return new mxPoint(c.x+d,c.y+d)},function(b,c){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(b.width,c.x-b.x),Math.min(b.height,c.y-b.y)))/a)})];c&&mxUtils.getValue(d.style,mxConstants.STYLE_ROUNDED,!1)&&e.push(ga(d));return e}},sa=function(a,b,c,d,e){c=null!=c?c:1;return function(f){var g=[ba(f,["size"],function(b){var c=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null,d=parseFloat(mxUtils.getValue(this.state.style,"size",c?e:a));return new mxPoint(b.x+
|
||||
Math.max(0,Math.min(b.width,d*(c?1:b.width))),b.getCenterY())},function(a,b,d){var g=null!=e?"0"!=mxUtils.getValue(this.state.style,"fixedSize","0"):null;a=g?b.x-a.x:Math.max(0,Math.min(c,(b.x-a.x)/a.width));g&&!mxEvent.isAltDown(d.getEvent())&&(a=f.view.graph.snap(a));this.state.style.size=a},null,d)];b&&mxUtils.getValue(f.style,mxConstants.STYLE_ROUNDED,!1)&&g.push(ga(f));return g}},Ga=function(a){return function(b){var c=[ba(b,["size"],function(b){var c=Math.max(0,Math.min(a,parseFloat(mxUtils.getValue(this.state.style,
|
||||
"size",n.prototype.size))));return new mxPoint(b.x+c*b.width*.75,b.y+b.height/4)},function(b,c){this.state.style.size=Math.max(0,Math.min(a,(c.x-b.x)/(.75*b.width)))},null,!0)];mxUtils.getValue(b.style,mxConstants.STYLE_ROUNDED,!1)&&c.push(ga(b));return c}},oa=function(){return function(a){var b=[];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b}},ga=function(a,b){return ba(a,[mxConstants.STYLE_ARCSIZE],function(c){var d=null!=b?b:c.height/8;if("1"==mxUtils.getValue(a.style,
|
||||
mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)){var e=mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,mxConstants.LINE_ARCSIZE)/2;return new mxPoint(c.x+c.width-Math.min(c.width/2,e),c.y+d)}e=Math.max(0,parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_ARCSIZE,100*mxConstants.RECTANGLE_ROUNDING_FACTOR)))/100;return new mxPoint(c.x+c.width-Math.min(Math.max(c.width/2,c.height/2),Math.min(c.width,c.height)*e),c.y+d)},function(b,c,d){"1"==mxUtils.getValue(a.style,mxConstants.STYLE_ABSOLUTE_ARCSIZE,0)?
|
||||
this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.max(0,Math.min(b.width,2*(b.x+b.width-c.x)))):this.state.style[mxConstants.STYLE_ARCSIZE]=Math.round(Math.min(50,Math.max(0,100*(b.width-c.x+b.x)/Math.min(b.width,b.height))))})},ba=function(a,b,c,d,e,f){var g=new mxHandle(a,null,mxVertexHandler.prototype.secondaryHandleImage);g.execute=function(){for(var a=0;a<b.length;a++)this.copyStyle(b[a])};g.getPosition=c;g.setPosition=d;g.ignoreGrid=null!=e?e:!0;if(f){var h=g.positionChanged;g.positionChanged=
|
||||
function(){h.apply(this,arguments);a.view.invalidate(this.state.cell);a.view.validate()}}return g},ta={link:function(a){return[Fa(a,!0,10),Fa(a,!1,10)]},flexArrow:function(a){var b=a.view.graph.gridSize/a.view.scale,c=[];mxUtils.getValue(a.style,mxConstants.STYLE_STARTARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(ha(a,["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,
|
||||
mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
a.style[mxConstants.STYLE_STARTSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE])})),c.push(ha(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!0,function(b,c,d,e,f){b=(a.shape.getStartArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.ARROW_SIZE/
|
||||
5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)+d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)-c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_STARTSIZE]=Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.startWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
a.style[mxConstants.STYLE_STARTSIZE],a.style.endWidth=a.style.startWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_STARTSIZE])-parseFloat(a.style[mxConstants.STYLE_ENDSIZE]))<b/6&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]),Math.abs(parseFloat(a.style.startWidth)-parseFloat(a.style.endWidth))<b&&(a.style.startWidth=a.style.endWidth))})));mxUtils.getValue(a.style,mxConstants.STYLE_ENDARROW,mxConstants.NONE)!=mxConstants.NONE&&(c.push(ha(a,
|
||||
["width",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],!1,function(b,c,d,e,f){b=(a.shape.getEdgeWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=
|
||||
Math.round(100*(d-a.shape.strokewidth)/3)/100/a.view.scale;a.style.width=Math.round(2*c)/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE]);mxEvent.isAltDown(k.getEvent())||Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE])})),c.push(ha(a,["startWidth","endWidth",mxConstants.STYLE_STARTSIZE,mxConstants.STYLE_ENDSIZE],
|
||||
!1,function(b,c,d,e,f){b=(a.shape.getEndArrowWidth()-a.shape.strokewidth)*a.view.scale;f=3*mxUtils.getNumber(a.style,mxConstants.STYLE_ENDSIZE,mxConstants.ARROW_SIZE/5)*a.view.scale;return new mxPoint(e.x+c*(f+a.shape.strokewidth*a.view.scale)-d*b/2,e.y+d*(f+a.shape.strokewidth*a.view.scale)+c*b/2)},function(c,d,e,f,g,h,k){c=Math.sqrt(mxUtils.ptSegDistSq(f.x,f.y,g.x,g.y,h.x,h.y));d=mxUtils.ptLineDist(f.x,f.y,f.x+e,f.y-d,h.x,h.y);a.style[mxConstants.STYLE_ENDSIZE]=Math.round(100*(d-a.shape.strokewidth)/
|
||||
3)/100/a.view.scale;a.style.endWidth=Math.max(0,Math.round(2*c)-a.shape.getEdgeWidth())/a.view.scale;mxEvent.isControlDown(k.getEvent())&&(a.style[mxConstants.STYLE_STARTSIZE]=a.style[mxConstants.STYLE_ENDSIZE],a.style.startWidth=a.style.endWidth);mxEvent.isAltDown(k.getEvent())||(Math.abs(parseFloat(a.style[mxConstants.STYLE_ENDSIZE])-parseFloat(a.style[mxConstants.STYLE_STARTSIZE]))<b/6&&(a.style[mxConstants.STYLE_ENDSIZE]=a.style[mxConstants.STYLE_STARTSIZE]),Math.abs(parseFloat(a.style.endWidth)-
|
||||
parseFloat(a.style.startWidth))<b&&(a.style.endWidth=a.style.startWidth))})));return c},swimlane:function(a){var b=[ba(a,[mxConstants.STYLE_STARTSIZE],function(b){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));return 1==mxUtils.getValue(a.style,mxConstants.STYLE_HORIZONTAL,1)?new mxPoint(b.getCenterX(),b.y+Math.max(0,Math.min(b.height,c))):new mxPoint(b.x+Math.max(0,Math.min(b.width,c)),b.getCenterY())},function(b,c){a.style[mxConstants.STYLE_STARTSIZE]=
|
||||
1==mxUtils.getValue(this.state.style,mxConstants.STYLE_HORIZONTAL,1)?Math.round(Math.max(0,Math.min(b.height,c.y-b.y))):Math.round(Math.max(0,Math.min(b.width,c.x-b.x)))})];if(mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED)){var c=parseFloat(mxUtils.getValue(a.style,mxConstants.STYLE_STARTSIZE,mxConstants.DEFAULT_STARTSIZE));b.push(ga(a,c/2))}return b},label:oa(),ext:oa(),rectangle:oa(),triangle:oa(),rhombus:oa(),umlLifeline:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,
|
||||
parseFloat(mxUtils.getValue(this.state.style,"size",K.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))},!1)]},umlFrame:function(a){return[ba(a,["width","height"],function(a){var b=Math.max(G.prototype.corner,Math.min(a.width,mxUtils.getValue(this.state.style,"width",G.prototype.width))),c=Math.max(1.5*G.prototype.corner,Math.min(a.height,mxUtils.getValue(this.state.style,"height",G.prototype.height)));
|
||||
return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.width=Math.round(Math.max(G.prototype.corner,Math.min(a.width,b.x-a.x)));this.state.style.height=Math.round(Math.max(1.5*G.prototype.corner,Math.min(a.height,b.y-a.y)))},!1)]},process:function(a){var b=[ba(a,["size"],function(a){var b=Math.max(0,Math.min(.5,parseFloat(mxUtils.getValue(this.state.style,"size",t.prototype.size))));return new mxPoint(a.x+a.width*b,a.y+a.height/4)},function(a,b){this.state.style.size=Math.max(0,Math.min(.5,
|
||||
(b.x-a.x)/a.width))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},cross:function(a){return[ba(a,["size"],function(a){var b=Math.min(a.width,a.height),b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"size",la.prototype.size)))*b/2;return new mxPoint(a.getCenterX()-b,a.getCenterY()-b)},function(a,b){var c=Math.min(a.width,a.height);this.state.style.size=Math.max(0,Math.min(1,Math.min(Math.max(0,a.getCenterY()-b.y)/c*2,Math.max(0,a.getCenterX()-b.x)/c*2)))})]},
|
||||
note:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.width,Math.min(a.height,parseFloat(mxUtils.getValue(this.state.style,"size",e.prototype.size)))));return new mxPoint(a.x+a.width-b,a.y+b)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(Math.min(a.width,a.x+a.width-b.x),Math.min(a.height,b.y-a.y))))})]},manualInput:function(a){var b=[ba(a,["size"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",N.prototype.size)));
|
||||
return new mxPoint(a.x+a.width/4,a.y+3*b/4)},function(a,b){this.state.style.size=Math.round(Math.max(0,Math.min(a.height,4*(b.y-a.y)/3)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,!1)&&b.push(ga(a));return b},dataStorage:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",S.prototype.size))));return new mxPoint(a.x+(1-b)*a.width,a.getCenterY())},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.x+a.width-
|
||||
b.x)/a.width))})]},callout:function(a){var b=[ba(a,["size","position"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));mxUtils.getValue(this.state.style,"base",w.prototype.base);return new mxPoint(a.x+c*a.width,a.y+a.height-b)},function(a,b){mxUtils.getValue(this.state.style,"base",w.prototype.base);this.state.style.size=Math.round(Math.max(0,Math.min(a.height,
|
||||
a.y+a.height-b.y)));this.state.style.position=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),ba(a,["position2"],function(a){var b=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position2",w.prototype.position2)));return new mxPoint(a.x+b*a.width,a.y+a.height)},function(a,b){this.state.style.position2=Math.round(100*Math.max(0,Math.min(1,(b.x-a.x)/a.width)))/100}),ba(a,["base"],function(a){var b=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"size",w.prototype.size))),
|
||||
c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position))),d=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"base",w.prototype.base)));return new mxPoint(a.x+Math.min(a.width,c*a.width+d),a.y+a.height-b)},function(a,b){var c=Math.max(0,Math.min(1,mxUtils.getValue(this.state.style,"position",w.prototype.position)));this.state.style.base=Math.round(Math.max(0,Math.min(a.width,b.x-a.x-c*a.width)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,
|
||||
!1)&&b.push(ga(a));return b},internalStorage:function(a){var b=[ba(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",J.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",J.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})];mxUtils.getValue(a.style,mxConstants.STYLE_ROUNDED,
|
||||
!1)&&b.push(ga(a));return b},corner:function(a){return[ba(a,["dx","dy"],function(a){var b=Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",M.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",M.prototype.dy)));return new mxPoint(a.x+b,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,Math.min(a.width,b.x-a.x)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},tee:function(a){return[ba(a,["dx","dy"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"dx",ea.prototype.dx))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"dy",ea.prototype.dy)));return new mxPoint(a.x+(a.width+b)/2,a.y+c)},function(a,b){this.state.style.dx=Math.round(Math.max(0,2*Math.min(a.width/2,b.x-a.x-a.width/2)));this.state.style.dy=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},singleArrow:ia(1),doubleArrow:ia(.5),folder:function(a){return[ba(a,["tabWidth","tabHeight"],function(a){var b=
|
||||
Math.max(0,Math.min(a.width,mxUtils.getValue(this.state.style,"tabWidth",g.prototype.tabWidth))),c=Math.max(0,Math.min(a.height,mxUtils.getValue(this.state.style,"tabHeight",g.prototype.tabHeight)));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&(b=a.width-b);return new mxPoint(a.x+b,a.y+c)},function(a,b){var c=Math.max(0,Math.min(a.width,b.x-a.x));mxUtils.getValue(this.state.style,"tabPosition",g.prototype.tabPosition)==mxConstants.ALIGN_RIGHT&&
|
||||
(c=a.width-c);this.state.style.tabWidth=Math.round(c);this.state.style.tabHeight=Math.round(Math.max(0,Math.min(a.height,b.y-a.y)))})]},document:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",l.prototype.size))));return new mxPoint(a.x+3*a.width/4,a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+a.height-b.y)/a.height))})]},tape:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,
|
||||
Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",k.prototype.size))));return new mxPoint(a.getCenterX(),a.y+b*a.height/2)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(b.y-a.y)/a.height*2))})]},offPageConnector:function(a){return[ba(a,["size"],function(a){var b=Math.max(0,Math.min(1,parseFloat(mxUtils.getValue(this.state.style,"size",fa.prototype.size))));return new mxPoint(a.getCenterX(),a.y+(1-b)*a.height)},function(a,b){this.state.style.size=Math.max(0,Math.min(1,(a.y+
|
||||
a.height-b.y)/a.height))})]},step:sa(x.prototype.size,!0,null,!0,x.prototype.fixedSize),hexagon:sa(y.prototype.size,!0,.5,!0),curlyBracket:sa(p.prototype.size,!1),display:sa(ma.prototype.size,!1),cube:Ba(1,a.prototype.size,!1),card:Ba(.5,h.prototype.size,!0),loopLimit:Ba(.5,Q.prototype.size,!0),trapezoid:Ga(.5),parallelogram:Ga(1)};Graph.createHandle=ba;Graph.handleFactory=ta;mxVertexHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()&&this.graph.isCellRotatable(this.state.cell)){var a=
|
||||
this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=mxConstants.SHAPE_RECTANGLE);a=ta[a];null==a&&null!=this.state.shape&&this.state.shape.isRoundable()&&(a=ta[mxConstants.SHAPE_RECTANGLE]);if(null!=a)return a(this.state)}return null};mxEdgeHandler.prototype.createCustomHandles=function(){if(1==this.state.view.graph.getSelectionCount()){var a=this.state.style.shape;null==mxCellRenderer.defaultShapes[a]&&null==mxStencilRegistry.getStencil(a)&&(a=
|
||||
mxConstants.SHAPE_CONNECTOR);a=ta[a];if(null!=a)return a(this.state)}return null}}else Graph.createHandle=function(){},Graph.handleFactory={};var ua=new mxPoint(1,0),va=new mxPoint(1,0),ia=mxUtils.toRadians(-30),ua=mxUtils.getRotatedPoint(ua,Math.cos(ia),Math.sin(ia)),ia=mxUtils.toRadians(-150),va=mxUtils.getRotatedPoint(va,Math.cos(ia),Math.sin(ia));mxEdgeStyle.IsometricConnector=function(a,b,c,d,e){var f=a.view;d=null!=d&&0<d.length?d[0]:null;var g=a.absolutePoints,h=g[0],g=g[g.length-1];null!=
|
||||
d&&(d=f.transformControlPoint(a,d));null==h&&null!=b&&(h=new mxPoint(b.getCenterX(),b.getCenterY()));null==g&&null!=c&&(g=new mxPoint(c.getCenterX(),c.getCenterY()));var k=ua.x,l=ua.y,m=va.x,n=va.y,p="horizontal"==mxUtils.getValue(a.style,"elbow","horizontal");if(null!=g&&null!=h){a=function(a,b,c){a-=q.x;var d=b-q.y;b=(n*a-m*d)/(k*n-l*m);a=(l*a-k*d)/(l*m-k*n);p?(c&&(q=new mxPoint(q.x+k*b,q.y+l*b),e.push(q)),q=new mxPoint(q.x+m*a,q.y+n*a)):(c&&(q=new mxPoint(q.x+m*a,q.y+n*a),e.push(q)),q=new mxPoint(q.x+
|
||||
k*b,q.y+l*b));e.push(q)};var q=h;null==d&&(d=new mxPoint(h.x+(g.x-h.x)/2,h.y+(g.y-h.y)/2));a(d.x,d.y,!0);a(g.x,g.y,!1)}};mxStyleRegistry.putValue("isometricEdgeStyle",mxEdgeStyle.IsometricConnector);var La=Graph.prototype.createEdgeHandler;Graph.prototype.createEdgeHandler=function(a,b){if(b==mxEdgeStyle.IsometricConnector){var c=new mxElbowEdgeHandler(a);c.snapToTerminals=!1;return c}return La.apply(this,arguments)};b.prototype.constraints=[];c.prototype.constraints=[];w.prototype.constraints=[];
|
||||
mxRectangleShape.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,
|
||||
1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxEllipse.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!0),new mxConnectionConstraint(new mxPoint(1,0),!0),new mxConnectionConstraint(new mxPoint(0,1),!0),new mxConnectionConstraint(new mxPoint(1,1),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5))];mxLabel.prototype.constraints=mxRectangleShape.prototype.constraints;mxImageShape.prototype.constraints=mxRectangleShape.prototype.constraints;mxSwimlane.prototype.constraints=mxRectangleShape.prototype.constraints;u.prototype.constraints=mxRectangleShape.prototype.constraints;e.prototype.constraints=mxRectangleShape.prototype.constraints;h.prototype.constraints=mxRectangleShape.prototype.constraints;a.prototype.constraints=mxRectangleShape.prototype.constraints;g.prototype.constraints=mxRectangleShape.prototype.constraints;
|
||||
J.prototype.constraints=mxRectangleShape.prototype.constraints;S.prototype.constraints=mxRectangleShape.prototype.constraints;X.prototype.constraints=mxEllipse.prototype.constraints;Y.prototype.constraints=mxEllipse.prototype.constraints;pa.prototype.constraints=mxEllipse.prototype.constraints;qa.prototype.constraints=mxEllipse.prototype.constraints;N.prototype.constraints=mxRectangleShape.prototype.constraints;na.prototype.constraints=mxRectangleShape.prototype.constraints;ma.prototype.constraints=
|
||||
mxRectangleShape.prototype.constraints;Q.prototype.constraints=mxRectangleShape.prototype.constraints;fa.prototype.constraints=mxRectangleShape.prototype.constraints;mxCylinder.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.15,.05),!1),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.85,.05),!1),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.3),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.7),!0),new mxConnectionConstraint(new mxPoint(.15,.95),!1),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.85,.95),!1)];E.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.1),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.75,.1),!1),new mxConnectionConstraint(new mxPoint(0,1/3),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(1,1/3),!1),new mxConnectionConstraint(new mxPoint(1,1),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1)];v.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,.3),!0),new mxConnectionConstraint(new mxPoint(0,.7),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];mxActor.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.25,.2),!1),new mxConnectionConstraint(new mxPoint(.1,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.75,.25),!1),new mxConnectionConstraint(new mxPoint(.9,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0)];f.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(.5,.25),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.5,.75),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];k.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.35),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.65),!1),new mxConnectionConstraint(new mxPoint(1,.35),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,.65),!1),new mxConnectionConstraint(new mxPoint(.25,1),!1),new mxConnectionConstraint(new mxPoint(.75,
|
||||
0),!1)];x.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(.25,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(.75,1),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxLine.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];V.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];mxDoubleEllipse.prototype.constraints=
|
||||
mxEllipse.prototype.constraints;mxRhombus.prototype.constraints=mxEllipse.prototype.constraints;mxTriangle.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.5,1),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0)];mxHexagon.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.375,
|
||||
0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.625,0),!0),new mxConnectionConstraint(new mxPoint(0,.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0),new mxConnectionConstraint(new mxPoint(.375,1),!0),new mxConnectionConstraint(new mxPoint(.5,1),
|
||||
!0),new mxConnectionConstraint(new mxPoint(.625,1),!0)];mxCloud.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,.25),!1),new mxConnectionConstraint(new mxPoint(.4,.1),!1),new mxConnectionConstraint(new mxPoint(.16,.55),!1),new mxConnectionConstraint(new mxPoint(.07,.4),!1),new mxConnectionConstraint(new mxPoint(.31,.8),!1),new mxConnectionConstraint(new mxPoint(.13,.77),!1),new mxConnectionConstraint(new mxPoint(.8,.8),!1),new mxConnectionConstraint(new mxPoint(.55,.95),!1),new mxConnectionConstraint(new mxPoint(.875,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.96,.7),!1),new mxConnectionConstraint(new mxPoint(.625,.2),!1),new mxConnectionConstraint(new mxPoint(.88,.25),!1)];m.prototype.constraints=mxRectangleShape.prototype.constraints;n.prototype.constraints=mxRectangleShape.prototype.constraints;l.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.25,0),!0),new mxConnectionConstraint(new mxPoint(.5,0),!0),new mxConnectionConstraint(new mxPoint(.75,0),!0),new mxConnectionConstraint(new mxPoint(0,
|
||||
.25),!0),new mxConnectionConstraint(new mxPoint(0,.5),!0),new mxConnectionConstraint(new mxPoint(0,.75),!0),new mxConnectionConstraint(new mxPoint(1,.25),!0),new mxConnectionConstraint(new mxPoint(1,.5),!0),new mxConnectionConstraint(new mxPoint(1,.75),!0)];mxArrow.prototype.constraints=null;ea.prototype.constraints=null;M.prototype.constraints=null;aa.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,0),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,
|
||||
1),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.5,.5),!1),new mxConnectionConstraint(new mxPoint(.75,.5),!1),new mxConnectionConstraint(new mxPoint(1,0),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(1,1),!1)];U.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];P.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),
|
||||
new mxConnectionConstraint(new mxPoint(1,.5),!1)];la.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.5,0),!1),new mxConnectionConstraint(new mxPoint(.5,1),!1)];K.prototype.constraints=null;Z.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.25),!1),new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(0,.75),!1),new mxConnectionConstraint(new mxPoint(1,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];O.prototype.constraints=[new mxConnectionConstraint(new mxPoint(.175,.25),!1),new mxConnectionConstraint(new mxPoint(.25,.5),!1),new mxConnectionConstraint(new mxPoint(.175,.75),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1),new mxConnectionConstraint(new mxPoint(.7,.1),!1),new mxConnectionConstraint(new mxPoint(.7,.9),!1)];ca.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,
|
||||
.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)];W.prototype.constraints=[new mxConnectionConstraint(new mxPoint(0,.5),!1),new mxConnectionConstraint(new mxPoint(1,.5),!1)]})();
|
4
src/main/webapp/js/shapes.min.js
vendored
4
src/main/webapp/js/shapes.min.js
vendored
|
@ -1,4 +1,6 @@
|
|||
function mxBpmnShape(a,d,e,b){mxShape.call(this);this.bounds=a;this.fill=d;this.stroke=e;this.strokewidth=null!=b?b:1}mxUtils.extend(mxBpmnShape,mxShape);mxBpmnShape.prototype.eventTypeEnum={START_STANDARD:"standard",EVENT_SP_INT:"eventInt",EVENT_SP_NONINT:"eventNonint",CATCHING:"catching",BOUND_INT:"boundInt",BOUND_NONINT:"boundNonint",THROWING:"throwing",END:"end",NONE:"none",GATEWAY:"gateway"};
|
||||
function mxBpmnShape(a,d,e,b){mxShape.call(this);this.bounds=a;this.fill=d;this.stroke=e;this.strokewidth=null!=b?b:1}mxUtils.extend(mxBpmnShape,mxShape);
|
||||
mxBpmnShape.prototype.customProperties=[{name:"fillColor",dispName:"Fill Color",type:"color"},{name:"rounded",dispName:"Rounded",type:"bool"},{name:"strokeWidth",dispName:"Stroke Width",type:"int"},{name:"floatVal",dispName:"Float Value",type:"float"},{name:"fontFamily",dispName:"Font Family",type:"string"},{name:"verticalAlign",dispName:"Vertical Align",type:"enum",enumList:[{val:"middle",dispName:"Middle"},{val:"bottom",dispName:"Bottom"},{val:"top",dispName:"Top"}]}];
|
||||
mxBpmnShape.prototype.eventTypeEnum={START_STANDARD:"standard",EVENT_SP_INT:"eventInt",EVENT_SP_NONINT:"eventNonint",CATCHING:"catching",BOUND_INT:"boundInt",BOUND_NONINT:"boundNonint",THROWING:"throwing",END:"end",NONE:"none",GATEWAY:"gateway"};
|
||||
mxBpmnShape.prototype.eventEnum={GENERAL:"general",MESSAGE:"message",TIMER:"timer",ESCALATION:"escalation",CONDITIONAL:"conditional",LINK:"link",ERROR:"error",CANCEL:"cancel",COMPENSATION:"compensation",SIGNAL:"signal",MULTIPLE:"multiple",PAR_MULTI:"parallelMultiple",TERMINATE:"terminate",GW_EXCLUSIVE:"exclusiveGw",GW_PARALLEL:"parallelGw",GW_COMPLEX:"complexGw"};mxBpmnShape.prototype.miscEnum={OUTLINE:"outline",BACKGROUND:"background",SYMBOL:"symbol",GATEWAY:"gateway"};
|
||||
mxBpmnShape.prototype.paintVertexShape=function(a,d,e,b,c){this.redrawPath(a,d,e,b,c,mxBpmnShape.prototype.miscEnum.BACKGROUND);mxUtils.getValue(this.style,mxBpmnShape.prototype.miscEnum.BACKGROUND,mxBpmnShape.prototype.eventTypeEnum.NONE)===mxBpmnShape.prototype.eventTypeEnum.GATEWAY&&a.setShadow(!1);this.redrawPath(a,d,e,b,c,mxBpmnShape.prototype.miscEnum.OUTLINE);this.redrawPath(a,d,e,b,c,mxBpmnShape.prototype.miscEnum.SYMBOL)};
|
||||
mxBpmnShape.prototype.redrawPath=function(a,d,e,b,c,f){var g=mxUtils.getValue(this.style,mxBpmnShape.prototype.miscEnum.BACKGROUND,mxBpmnShape.prototype.eventTypeEnum.NONE);if(f==mxBpmnShape.prototype.miscEnum.BACKGROUND){if(null!=g){var h=this.backgrounds[g];null!=h&&(a.translate(d,e),h.call(this,a,d,e,b,c,f))}}else if(f==mxBpmnShape.prototype.miscEnum.OUTLINE){g===mxBpmnShape.prototype.eventTypeEnum.GATEWAY?(a.translate(b/4,c/4),c/=2,b/=2,this.constraints=[new mxConnectionConstraint(new mxPoint(.5,
|
||||
|
|
1834
src/main/webapp/js/viewer.min.js
vendored
1834
src/main/webapp/js/viewer.min.js
vendored
File diff suppressed because one or more lines are too long
|
@ -38,6 +38,17 @@ function mxBpmnShape(bounds, fill, stroke, strokewidth)
|
|||
*/
|
||||
mxUtils.extend(mxBpmnShape, mxShape);
|
||||
|
||||
mxBpmnShape.prototype.customProperties = [
|
||||
{name: 'fillColor', dispName: 'Fill Color', type: 'color'},
|
||||
{name: 'rounded', dispName: 'Rounded', type: 'bool'},
|
||||
{name: 'strokeWidth', dispName: 'Stroke Width', type: 'int'},
|
||||
{name: 'floatVal', dispName: 'Float Value', type: 'float'},
|
||||
{name: 'fontFamily', dispName: 'Font Family', type: 'string'},
|
||||
{name: 'verticalAlign', dispName: 'Vertical Align', type: 'enum',
|
||||
enumList: [{val: 'middle', dispName: 'Middle'}, {val: 'bottom', dispName: 'Bottom'}, {val: 'top', dispName: 'Top'}]
|
||||
},
|
||||
];
|
||||
|
||||
mxBpmnShape.prototype.eventTypeEnum = {
|
||||
START_STANDARD : 'standard',
|
||||
EVENT_SP_INT : 'eventInt',
|
||||
|
|
Loading…
Reference in a new issue