github地址:https://github.com/PZXforXcode/PZXGestureUnlock
使用方式:
导入PZXGestureUnlockView文件夹
#import "PZXGesViewController.h"
- (IBAction)drawGestureButtonPressed:(UIButton *)sender {
PZXGesViewController *vc = [[PZXGesViewController alloc]init];
///创建密码
vc.pzxUnlockType = PZXUnlockTypeCreatePwd;
vc.modalPresentationStyle = UIModalPresentationFullScreen;
[self presentViewController:vc animated:YES completion:nil];
}
- (IBAction)vaildGestureButtonPressed:(UIButton *)sender {
PZXGesViewController *vc = [[PZXGesViewController alloc]init];
///验证密码
vc.pzxUnlockType = PZXUnlockTypeValidatePwd;
vc.modalPresentationStyle = UIModalPresentationFullScreen;
[self presentViewController:vc animated:YES completion:nil];
}
- (IBAction)deleteGestureButtonPressed:(UIButton *)sender {
///删除密码
[PZXGesViewController deleteGesturePwd];
}
网友评论