iOS:refact requestLayout logic
This commit is contained in:
@@ -31,7 +31,6 @@ @implementation DoricRefreshableNode
|
||||
- (DoricSwipeRefreshLayout *)build {
|
||||
return [[DoricSwipeRefreshLayout new] also:^(DoricSwipeRefreshLayout *it) {
|
||||
it.swipePullingDelegate = self;
|
||||
|
||||
}];
|
||||
}
|
||||
|
||||
@@ -62,8 +61,7 @@ - (DoricViewNode *)subNodeWithViewId:(NSString *)viewId {
|
||||
}
|
||||
}
|
||||
|
||||
- (void)blend:(NSDictionary *)props {
|
||||
[super blend:props];
|
||||
- (void)afterBlended:(NSDictionary *)props {
|
||||
[self blendContent];
|
||||
[self blendHeader];
|
||||
}
|
||||
@@ -102,6 +100,7 @@ - (void)blendContent {
|
||||
self.view.contentView = it.view;
|
||||
}];
|
||||
}
|
||||
[self.view.contentView.doricLayout apply:self.view.frame.size];
|
||||
}
|
||||
|
||||
- (void)blendHeader {
|
||||
@@ -138,6 +137,7 @@ - (void)blendHeader {
|
||||
self.view.headerView = it.view;
|
||||
}];
|
||||
}
|
||||
[self.view.headerView.doricLayout apply:self.view.frame.size];
|
||||
}
|
||||
|
||||
- (void)blendSubNode:(NSDictionary *)subModel {
|
||||
|
||||
Reference in New Issue
Block a user