feat:scroller add onScroll and onScrollEnd property

This commit is contained in:
pengfei.zhou
2020-03-03 15:51:20 +08:00
committed by osborn
parent 0fa121e54f
commit 021fdab35f
16 changed files with 141 additions and 3 deletions

View File

@@ -2029,6 +2029,14 @@ var Scroller = /** @class */ (function (_super) {
Property,
__metadata$7("design:type", Object)
], Scroller.prototype, "contentOffset", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScroll", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScrollEnd", void 0);
return Scroller;
}(Superview));
@@ -3040,6 +3048,9 @@ var ViewModel = /** @class */ (function () {
ViewModel.prototype.getState = function () {
return this.state;
};
ViewModel.prototype.getViewHolder = function () {
return this.viewHolder;
};
ViewModel.prototype.updateState = function (setter) {
setter(this.state);
this.onBind(this.state, this.viewHolder);

View File

@@ -1510,6 +1510,14 @@ __decorate$7([
Property,
__metadata$7("design:type", Object)
], Scroller.prototype, "contentOffset", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScroll", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScrollEnd", void 0);
var __decorate$8 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -2258,6 +2266,9 @@ class ViewModel {
getState() {
return this.state;
}
getViewHolder() {
return this.viewHolder;
}
updateState(setter) {
setter(this.state);
this.onBind(this.state, this.viewHolder);

View File

@@ -2969,6 +2969,14 @@ __decorate$7([
Property,
__metadata$7("design:type", Object)
], Scroller.prototype, "contentOffset", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScroll", void 0);
__decorate$7([
Property,
__metadata$7("design:type", Function)
], Scroller.prototype, "onScrollEnd", void 0);
var __decorate$8 = (undefined && undefined.__decorate) || function (decorators, target, key, desc) {
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
@@ -3717,6 +3725,9 @@ class ViewModel {
getState() {
return this.state;
}
getViewHolder() {
return this.viewHolder;
}
updateState(setter) {
setter(this.state);
this.onBind(this.state, this.viewHolder);