feat:when cancel Animation,sync the properties from native

This commit is contained in:
pengfei.zhou
2021-04-22 14:54:25 +08:00
committed by osborn
parent 819feb1617
commit cdd25caa7d
12 changed files with 377 additions and 324 deletions

View File

@@ -410,7 +410,13 @@ var View = /** @class */ (function () {
});
};
View.prototype.cancelAnimation = function (context, animation) {
return this.nativeChannel(context, "cancelAnimation")(animation.id);
var _this = this;
return this.nativeChannel(context, "cancelAnimation")(animation.id).then(function (args) {
for (var key in args) {
Reflect.set(_this, key, Reflect.get(args, key, args), _this);
Reflect.deleteProperty(_this.__dirty_props__, key);
}
});
};
__decorate$d([
Property,