1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071 |
- typedef NS_ENUM(NSInteger, TOPasscodeViewStyle) {
- TOPasscodeViewStyleTranslucentDark,
- TOPasscodeViewStyleTranslucentLight,
- TOPasscodeViewStyleOpaqueDark,
- TOPasscodeViewStyleOpaqueLight
- };
- typedef NS_ENUM(NSInteger, TOPasscodeSettingsViewStyle) {
- TOPasscodeSettingsViewStyleLight,
- TOPasscodeSettingsViewStyleDark
- };
- typedef NS_ENUM(NSInteger, TOPasscodeViewContentSize) {
- TOPasscodeViewContentSizeDefault = 414,
- TOPasscodeViewContentSizeMedium = 375,
- TOPasscodeViewContentSizeSmall = 320
- };
- typedef NS_ENUM(NSInteger, TOPasscodeType) {
- TOPasscodeTypeFourDigits,
- TOPasscodeTypeSixDigits,
- TOPasscodeTypeCustomNumeric,
- TOPasscodeTypeCustomAlphanumeric
- };
- typedef NS_ENUM(NSInteger, TOPasscodeBiometryType) {
- TOPasscodeBiometryTypeTouchID,
- TOPasscodeBiometryTypeFaceID
- };
- static inline BOOL TOPasscodeViewStyleIsTranslucent(TOPasscodeViewStyle style) {
- return style <= TOPasscodeViewStyleTranslucentLight;
- }
- static inline BOOL TOPasscodeViewStyleIsDark(TOPasscodeViewStyle style) {
- return style < TOPasscodeViewStyleTranslucentLight || style == TOPasscodeViewStyleOpaqueDark;
- }
- static inline NSString *TOPasscodeBiometryTitleForType(TOPasscodeBiometryType type) {
- switch (type) {
- case TOPasscodeBiometryTypeFaceID: return NSLocalizedString(@"Face ID", @"");
- default: return NSLocalizedString(@"Touch ID", @"");
- }
- }
|