SettingsPasswdSetViewController.m 1.7 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566
  1. //
  2. // SettingsPasswdSetViewController.m
  3. // OneCable
  4. //
  5. // Created by nComz on 2017. 4. 19..
  6. // Copyright © 2017년 ntels. All rights reserved.
  7. //
  8. #import "SettingsPasswdSetViewController.h"
  9. #import "CustomTextField.h"
  10. #import "CustomButton.h"
  11. #import "CustomLabel.h"
  12. @interface SettingsPasswdSetViewController () <CustomTextFieldDelegate>
  13. @end
  14. @implementation SettingsPasswdSetViewController
  15. - (void)viewDidLoad {
  16. [super viewDidLoad];
  17. [self initUI];
  18. }
  19. - (void)initUI {
  20. UIView *statusBar = [[[UIApplication sharedApplication] valueForKey:@"statusBarWindow"] valueForKey:@"statusBar"];
  21. statusBar.backgroundColor = [UIColor whiteColor];
  22. _txtInputPasswd.returnKeyType = UIReturnKeyDone;
  23. _txtInputPasswd.delegate = self;
  24. [self.navigationController.navigationBar setHidden:YES];
  25. self.navigationController.interactivePopGestureRecognizer.enabled = NO;
  26. }
  27. - (IBAction)btnCancelTouched:(id)sender {
  28. [[self navigationController] popToRootViewControllerAnimated:YES];
  29. }
  30. - (IBAction)btnSaveTouched:(id)sender {
  31. // 두 입력 값 불일치 -
  32. // 입력된 비밀번호가 서로 일치하지 않습니다.
  33. // 다시 한 번 확인해주세요.
  34. // 비밀번호 설정 정책 위배 -
  35. // "영문 대/소문자,숫자,특수기호" 중 2가지 이상을 조합하여
  36. // 8~20 자리로 비밀번호를 설정해주세요.
  37. // 정책 ( 영문 필수 , 2개 이상조합 , 대/소문자 구분)
  38. // 8자리 이상시 버튼 활성화
  39. }
  40. - (BOOL)textFieldShouldReturn:(UITextField *)textField {
  41. if ([textField isEqual:_txtInputPasswd]) {
  42. [textField resignFirstResponder];
  43. }
  44. return YES;
  45. }
  46. - (void)didReceiveMemoryWarning {
  47. [super didReceiveMemoryWarning];
  48. }
  49. @end