key缺少,添加权限多语言
This commit is contained in:
@@ -372,9 +372,9 @@
|
||||
_agreementTextView.textContainer.lineFragmentPadding = 0;
|
||||
|
||||
// 协议文案:terms of service / privacy policy 为纯黑色并可点击,其余为 #717171
|
||||
NSString *fullText = @"By continuing, you agree to our terms of service and confirm that you have read our privacy policy";
|
||||
NSString *termsText = @"terms of service";
|
||||
NSString *privacyText = @"privacy policy";
|
||||
NSString *fullText = KBLocalized(@"By continuing, you agree to our terms of service and confirm that you have read our privacy policy");
|
||||
NSString *termsText = KBLocalized(@"terms of service");
|
||||
NSString *privacyText = KBLocalized(@"privacy policy");
|
||||
|
||||
NSMutableParagraphStyle *paragraph = [[NSMutableParagraphStyle alloc] init];
|
||||
paragraph.alignment = NSTextAlignmentCenter; // 多行文本整体居中
|
||||
@@ -488,8 +488,10 @@
|
||||
NSUInteger charIndex = [layoutManager characterIndexForGlyphAtIndex:glyphIndex];
|
||||
|
||||
NSString *lowerFull = textView.text.lowercaseString ?: @"";
|
||||
NSRange termsRange = [lowerFull rangeOfString:@"terms of service"];
|
||||
NSRange privacyRange = [lowerFull rangeOfString:@"privacy policy"];
|
||||
NSString *termsText = [KBLocalized(@"terms of service") lowercaseString];
|
||||
NSString *privacyText = [KBLocalized(@"privacy policy") lowercaseString];
|
||||
NSRange termsRange = [lowerFull rangeOfString:termsText];
|
||||
NSRange privacyRange = [lowerFull rangeOfString:privacyText];
|
||||
|
||||
BOOL hitTerms = (termsRange.location != NSNotFound && NSLocationInRange(charIndex, termsRange));
|
||||
BOOL hitPrivacy = (privacyRange.location != NSNotFound && NSLocationInRange(charIndex, privacyRange));
|
||||
|
||||
Reference in New Issue
Block a user