QUCBasicViewController.h
2.15 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
//
// QUCBasicViewController.h
// qucsdkFramework
//
// Created by simaopig on 14-6-19.
// Copyright (c) 2014年 Qihoo.360. All rights reserved.
//
#import <UIKit/UIKit.h>
#import "QUCToast+UIView.h"
#import "QUCProgressHUD.h"
#import "UINavigationController+GoTo.h"
#import "QUCUIConfig.h"
/**
* @brief 用户中心SDK通用ViewController\n
*/
@interface QUCBasicViewController : UIViewController
@property (nonatomic, strong) NSDictionary *qucVcConf;
@property (nonatomic, strong) NSString *navTitle;
@property (nonatomic, assign) BOOL keyboardIsVisible;
@property (nonatomic, strong) NSDictionary *keyboardInfo;
@property (nonatomic, strong) NSDictionary *dict;
@property (nonatomic, strong) UIView *toastView;
/**
* @brief viewWillAppear会初始化,用于从dict初始化参数
*/
- (void)initProperty;
/**
* @brief viewWillDisappear等视图不可见时清除,用于清空self.dict
*/
- (void)destructProperty;
- (void)addKeyboardObserver;
- (void)removeKeyboardObserver;
- (void)keyboardWillShow:(NSNotification *)notif;
- (void)keyboardWillHide:(NSNotification *)notif;
- (void)addWillEnterForeground;
- (void)removeWillEnterForeground;
- (void)addDidEnterBackground;
- (void)removeDidEnterBackground;
- (void)didEnterBackground:(NSNotification *)notif;
/**
* @brief 在窗口中间显示toastView,且3秒消失
*
* @param strMsg toastView显示内容
*/
- (void)showToastAlertViewWithMsg:(NSString *)strMsg;
/**
* @brief 在窗口指定位置 显示toastView
*
* @param strMsg 显示内容
* @param interval 几秒种消失
* @param position toastView显示位置,支持@"top", @"bottom", @"center",
*/
- (void)showToastAlertViewWithMsg:(NSString *)strMsg duration:(CGFloat)interval position:(id)position;
// hxs - add
- (void)showToastAlertViewWithHeadMessage:(NSString *)headMessage linkMessage:(NSString *)linkMessage tailMessage:(NSString *)tailMessage target:(id)target;
- (void)showToastAlertViewWithHeadMessage:(NSString *)headMessage linkMessage:(NSString *)linkMessage tailMessage:(NSString *)tailMessage duration:(CGFloat)duration position:(id)position target:(id)target;
- (UIViewController *)initVcByName:(NSString *)vcName;
@end