1 line
6.1 KiB
JSON
1 line
6.1 KiB
JSON
{"ast":null,"code":"import { __extends } from \"tslib\";\nimport Path from './Path.js';\n\nvar CompoundPath = function (_super) {\n __extends(CompoundPath, _super);\n\n function CompoundPath() {\n var _this = _super !== null && _super.apply(this, arguments) || this;\n\n _this.type = 'compound';\n return _this;\n }\n\n CompoundPath.prototype._updatePathDirty = function () {\n var paths = this.shape.paths;\n var dirtyPath = this.shapeChanged();\n\n for (var i = 0; i < paths.length; i++) {\n dirtyPath = dirtyPath || paths[i].shapeChanged();\n }\n\n if (dirtyPath) {\n this.dirtyShape();\n }\n };\n\n CompoundPath.prototype.beforeBrush = function () {\n this._updatePathDirty();\n\n var paths = this.shape.paths || [];\n var scale = this.getGlobalScale();\n\n for (var i = 0; i < paths.length; i++) {\n if (!paths[i].path) {\n paths[i].createPathProxy();\n }\n\n paths[i].path.setScale(scale[0], scale[1], paths[i].segmentIgnoreThreshold);\n }\n };\n\n CompoundPath.prototype.buildPath = function (ctx, shape) {\n var paths = shape.paths || [];\n\n for (var i = 0; i < paths.length; i++) {\n paths[i].buildPath(ctx, paths[i].shape, true);\n }\n };\n\n CompoundPath.prototype.afterBrush = function () {\n var paths = this.shape.paths || [];\n\n for (var i = 0; i < paths.length; i++) {\n paths[i].pathUpdated();\n }\n };\n\n CompoundPath.prototype.getBoundingRect = function () {\n this._updatePathDirty.call(this);\n\n return Path.prototype.getBoundingRect.call(this);\n };\n\n return CompoundPath;\n}(Path);\n\nexport default CompoundPath;","map":{"version":3,"sources":["D:/Work/WorkSpace/GitWorkSpace/TenShop/resource/ElectronicMall/src/qingge-Market/qingge-vue/node_modules/zrender/lib/graphic/CompoundPath.js"],"names":["__extends","Path","CompoundPath","_super","_this","apply","arguments","type","prototype","_updatePathDirty","paths","shape","dirtyPath","shapeChanged","i","length","dirtyShape","beforeBrush","scale","getGlobalScale","path","createPathProxy","setScale","segmentIgnoreThreshold","buildPath","ctx","afterBrush","pathUpdated","getBoundingRect","call"],"mappings":"A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function (_super) {\r\n __extends(CompoundPath, _super);\r\n function CompoundPath() {\r\n var _this = _super !== null && _super.apply(this, arguments) || this;\r\n _this.type = 'compound';\r\n return _this;\r\n }\r\n CompoundPath.prototype._updatePathDirty = function () {\r\n var paths = this.shape.paths;\r\n var dirtyPath = this.shapeChanged();\r\n for (var i = 0; i < paths.length; i++) {\r\n dirtyPath = dirtyPath || paths[i].shapeChanged();\r\n }\r\n if (dirtyPath) {\r\n this.dirtyShape();\r\n }\r\n };\r\n CompoundPath.prototype.beforeBrush = function () {\r\n this._updatePathDirty();\r\n var paths = this.shape.paths || [];\r\n var scale = this.getGlobalScale();\r\n for (var i = 0; i < paths.length; i++) {\r\n if (!paths[i].path) {\r\n paths[i].createPathProxy();\r\n }\r\n paths[i].path.setScale(scale[0], scale[1], paths[i].segmentIgnoreThreshold);\r\n }\r\n };\r\n CompoundPath.prototype.buildPath = function (ctx, shape) {\r\n var paths = shape.paths || [];\r\n for (var i = 0; i < paths.length; i++) {\r\n paths[i].buildPath(ctx, paths[i].shape, true);\r\n }\r\n };\r\n CompoundPath.prototype.afterBrush = function () {\r\n var paths = this.shape.paths || [];\r\n for (var i = 0; i < paths.length; i++) {\r\n paths[i].pathUpdated();\r\n }\r\n };\r\n CompoundPath.prototype.getBoundingRect = function () {\r\n this._updatePathDirty.call(this);\r\n return Path.prototype.getBoundingRect.call(this);\r\n };\r\n return CompoundPath;\r\n}(Path));\r\nexport default CompoundPath;\r\n"]},"metadata":{},"sourceType":"module"} |