@eva/plugin-renderer-dragonbone 1.2.6 → 1.2.7-editor.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -43,6 +43,10 @@ function __decorate(decorators, target, key, desc) {
43
43
  return c > 3 && r && Object.defineProperty(target, key, r), r;
44
44
  }
45
45
 
46
+ function __metadata(metadataKey, metadataValue) {
47
+ if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(metadataKey, metadataValue);
48
+ }
49
+
46
50
  function __awaiter(thisArg, _arguments, P, generator) {
47
51
  return new (P || (P = Promise))(function (resolve, reject) {
48
52
  function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
@@ -149,16 +153,20 @@ var DragonBone$3 = (function (_super) {
149
153
  };
150
154
  DragonBone.componentName = 'DragonBone';
151
155
  __decorate([
152
- inspectorDecorator.type('string')
156
+ inspectorDecorator.Field(),
157
+ __metadata("design:type", String)
153
158
  ], DragonBone.prototype, "resource", void 0);
154
159
  __decorate([
155
- inspectorDecorator.type('string')
160
+ inspectorDecorator.Field(),
161
+ __metadata("design:type", String)
156
162
  ], DragonBone.prototype, "armatureName", void 0);
157
163
  __decorate([
158
- inspectorDecorator.type('string')
164
+ inspectorDecorator.Field(),
165
+ __metadata("design:type", String)
159
166
  ], DragonBone.prototype, "animationName", void 0);
160
167
  __decorate([
161
- inspectorDecorator.type('boolean')
168
+ inspectorDecorator.Field(),
169
+ __metadata("design:type", Boolean)
162
170
  ], DragonBone.prototype, "autoPlay", void 0);
163
171
  return DragonBone;
164
172
  }(eva_js.Component));
@@ -17034,15 +17042,18 @@ var DragonBone = (function (_super) {
17034
17042
  };
17035
17043
  DragonBone.prototype.add = function (changed) {
17036
17044
  return __awaiter(this, void 0, void 0, function () {
17037
- var component, armature, _loop_1, key;
17045
+ var component, asyncId, armature, _loop_1, key;
17038
17046
  return __generator(this, function (_a) {
17039
17047
  switch (_a.label) {
17040
17048
  case 0:
17041
17049
  component = changed.component;
17042
17050
  this.isRemovedMap.delete(component);
17051
+ asyncId = this.increaseAsyncId(changed.gameObject.id);
17043
17052
  return [4, eva_js.resource.getResource(component.resource)];
17044
17053
  case 1:
17045
17054
  _a.sent();
17055
+ if (!this.validateAsyncId(changed.gameObject.id, asyncId))
17056
+ return [2];
17046
17057
  if (this.isRemovedMap.get(component)) {
17047
17058
  this.isRemovedMap.delete(component);
17048
17059
  return [2];