You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
121 lines
3.8 KiB
121 lines
3.8 KiB
// |
|
// TFBasicViewController.h |
|
// WXReader |
|
// |
|
// Created by 谢腾飞 on 2020/11/21. |
|
// Copyright © 2020 xtfei_2011@126.com. All rights reserved. |
|
// |
|
|
|
#import <UIKit/UIKit.h> |
|
#import "TFBasicNavBarView.h" |
|
#import "TFEmptyView.h" |
|
#import "SGPagingView.h" |
|
|
|
NS_ASSUME_NONNULL_BEGIN |
|
|
|
#define TFPageView_H 44 |
|
|
|
typedef NS_ENUM(NSUInteger, TFProductionType) { |
|
|
|
TFProductionTypeNovel = 0, |
|
TFProductionTypeComic = 1, |
|
TFProductionTypeAudio = 2, |
|
TFProductionTypeAi = 3 |
|
}; |
|
|
|
@interface TFBasicViewController : UIViewController |
|
#pragma mark - 属性 |
|
@property (nonatomic ,strong) NSMutableArray *dataSourceArray; |
|
@property (nonatomic ,strong) NSMutableDictionary *advertDict; |
|
@property (nonatomic ,assign) int currentPageNumber; |
|
@property (nonatomic ,assign) TFProductionType productionType; |
|
@property (nonatomic ,assign) CGFloat pageViewHeight; |
|
|
|
#pragma mark - 控件 |
|
@property (nonatomic ,strong) TFBasicNavBarView *navigationBar; |
|
@property (nonatomic ,strong) UITableView *mainTableView; |
|
@property (nonatomic ,strong) UITableView *mainTableViewGroup; |
|
@property (nonatomic ,strong) UICollectionViewFlowLayout *mainCollectionViewFlowLayout; |
|
@property (nonatomic ,strong) UICollectionView *mainCollectionView; |
|
@property (nonatomic ,strong) SGPageTitleViewConfigure *pageConfigure; |
|
@property (nonatomic ,strong) TFEmptyView *emptyView; |
|
@property (nonatomic ,copy) NSString *navTitle; |
|
@property (nonatomic ,assign) BOOL isPresentState; |
|
|
|
#pragma mark - 公共方法 |
|
// 返回上一页 |
|
- (void)popViewController; |
|
|
|
// 是否可右滑返回 |
|
- (void)navigationCanSlidingBack:(BOOL)canSlidingBack; |
|
|
|
// 空白占位图 |
|
- (void)setEmptyOnView:(UIScrollView *)scrollView title:(NSString *_Nullable)title tapBlock:(void(^)(void))tapBlock; |
|
|
|
// 空白占位图,自定义Y值 |
|
- (void)setEmptyOnView:(UIScrollView *)scrollView title:(NSString *_Nullable)title centerY:(CGFloat)centerY tapBlock:(void(^)(void))tapBlock; |
|
|
|
// 空白占位图 |
|
- (void)setEmptyOnView:(UIScrollView *)scrollView title:(NSString * _Nullable)title buttonTitle:(NSString * _Nullable)buttonTitle tapBlock:(void(^)(void))tapBlock; |
|
|
|
// 空白占位图 |
|
- (void)setEmptyOnView:(UIScrollView *)scrollView title:(NSString * _Nullable)title detailTitle:(NSString * _Nullable)detailTitle buttonTitle:(NSString * _Nullable)buttonTitle tapBlock:(void(^)(void))tapBlock; |
|
|
|
// 空白占位图 |
|
- (void)setEmptyOnView:(UIScrollView *)scrollView imageName:(NSString * _Nullable)imageName title:(NSString *)title detailTitle:(NSString * _Nullable)detailTitle buttonTitle:(NSString * _Nullable)buttonTitle centerY:(CGFloat)centerY tapBlock:(void(^)(void))tapBlock; |
|
|
|
// 取消cell左滑删除状态 |
|
- (void)cancleTableViewCellEditingState; |
|
|
|
#pragma mark - 导航栏设置 |
|
// 隐藏导航条 |
|
- (void)hiddenNavigationBar:(BOOL)hidden; |
|
|
|
// 设置导航条背景色 |
|
- (void)setNavigationBarBackgroundColor:(UIColor *)color; |
|
|
|
// 设置导航条标题 |
|
- (void)setNavigationBarTitle:(NSString *)title; |
|
|
|
// 设置导航条标题颜色 |
|
- (void)setNavigationBarTintColor:(UIColor *)tintColor; |
|
|
|
// 隐藏返回按钮 |
|
- (void)hiddenNavigationBarLeftButton; |
|
|
|
// 设置导航栏右侧按钮 |
|
- (void)setNavigationBarRightButton:(UIButton *)rightButton; |
|
|
|
// 设置导航栏左侧按钮 |
|
- (void)setNavigationBarLeftButton:(UIButton *)leftButton; |
|
|
|
// 设置导航栏线条 - 无 |
|
- (void)hiddenSeparator; |
|
|
|
// 设置导航栏线条 - 细 |
|
- (void)setNavSmallSeparator; |
|
|
|
// 设置导航栏线条 - 粗 |
|
- (void)setNavLargeSeparator; |
|
|
|
// 隐藏home条 |
|
- (void)hiddenHomeIndicator; |
|
|
|
// 显示home条 |
|
- (void)showHomeIndicator; |
|
|
|
#pragma mark - 状态栏设置 |
|
// 状态条白色 |
|
- (void)setStatusBarLightContentStyle; |
|
|
|
// 设置状态条黑色 |
|
- (void)setStatusBarDefaultStyle; |
|
|
|
#pragma mark - 接口数据缓存 |
|
- (void)asyncCacheNetworkWithURLString:(NSString *)URLString response:(NSDictionary *)response; |
|
|
|
- (NSDictionary *)getCacheWithURLString:(NSString *)URLString; |
|
|
|
@end |
|
|
|
NS_ASSUME_NONNULL_END
|
|
|