新人充值优惠转场动画
This commit is contained in:
@@ -23,6 +23,7 @@
|
||||
#import "MainProtocol.h"
|
||||
///VC
|
||||
#import "XPMineRechargeViewController.h"
|
||||
#import "XPNewUserRechargePresentTrasition.h"
|
||||
|
||||
@interface XPNewUserRechargeViewController ()<MainProtocol, UICollectionViewDelegate, UICollectionViewDataSource>
|
||||
///顶部的View
|
||||
@@ -53,6 +54,9 @@
|
||||
@property (nonatomic,strong) NSArray<FirstRechargeModel *> *originArray;
|
||||
///当前的导航栏
|
||||
@property (nonatomic,weak) UINavigationController * currentNav;
|
||||
///转场动画
|
||||
@property (nonatomic, strong) XPNewUserRechargePresentTrasition *animatedTransition;
|
||||
|
||||
@end
|
||||
|
||||
@implementation XPNewUserRechargeViewController
|
||||
@@ -74,6 +78,9 @@
|
||||
[self.presenter getNewUserRechargeList];
|
||||
[self initSubViews];
|
||||
[self initSubViewConstraints];
|
||||
if (self.hadAnimate) {
|
||||
self.transitioningDelegate = self;
|
||||
}
|
||||
}
|
||||
|
||||
#pragma mark - Private Method
|
||||
@@ -276,6 +283,10 @@
|
||||
sender.selected = !sender.selected;
|
||||
}
|
||||
|
||||
- (nullable id <UIViewControllerAnimatedTransitioning>)animationControllerForDismissedController:(UIViewController *)dismissed{
|
||||
return self.animatedTransition;
|
||||
}
|
||||
|
||||
#pragma mark - Getters And Setters
|
||||
- (UICollectionView *)collectionView{
|
||||
if (!_collectionView) {
|
||||
@@ -375,4 +386,11 @@
|
||||
return _segmentView;
|
||||
}
|
||||
|
||||
- (XPNewUserRechargePresentTrasition *)animatedTransition {
|
||||
if (!_animatedTransition) {
|
||||
_animatedTransition = [[XPNewUserRechargePresentTrasition alloc] init];
|
||||
}
|
||||
return _animatedTransition;
|
||||
}
|
||||
|
||||
@end
|
||||
|
Reference in New Issue
Block a user