处理上架的问题

1:处理了openurl 拉起问题
2:去掉了http
3 隐私等等
This commit is contained in:
2026-03-05 14:30:07 +08:00
parent 8cc484edcb
commit d8a84dc478
34 changed files with 506 additions and 511 deletions

View File

@@ -7,7 +7,7 @@
#import "Masonry.h"
#import "KBResponderUtils.h" // UIInputViewController
#import "KBHUD.h"
#import "KBHostAppLauncher.h"
#import "../Utils/KBExtensionAppLauncher.h"
@interface KBFullAccessGuideView ()
@property (nonatomic, strong) UIControl *backdrop;
@@ -159,18 +159,34 @@
// KBResponderUtils.h
// App访宿 UIApplication + Scheme
- (void)onTapGoEnable {
UIInputViewController *ivc = KBFindInputViewController(self);
// responder
UIResponder *start = ivc.view ?: (UIResponder *)self;
// SchemeAppDelegate kbkeyboardAppExtension://settings
NSURL *scheme = [NSURL URLWithString:[NSString stringWithFormat:@"%@@//settings?src=kb_extension", KB_APP_SCHEME]];
BOOL ok = [KBHostAppLauncher openHostAppURL:scheme fromResponder:start];
if (ok) {
[self dismiss];
} else {
NSString *showInfo = [NSString stringWithFormat:KBLocalized(@"Follow: Settings → General → Keyboard → Keyboards → %@ → Allow Full Access"),AppName];
UIInputViewController *ivc = self.ivc ?: KBFindInputViewController(self);
if (!ivc) {
NSString *showInfo = [NSString stringWithFormat:KBLocalized(@"Follow: Settings → General → Keyboard → Keyboards → %@ → Allow Full Access"), AppName];
[KBHUD showInfo:showInfo];
return;
}
// Universal Link 退 Scheme
NSURL *ul = [NSURL URLWithString:[NSString stringWithFormat:@"%@?src=kb_extension", KB_UL_SETTINGS]];
NSURL *scheme = [NSURL URLWithString:[NSString stringWithFormat:@"%@://settings?src=kb_extension", KB_APP_SCHEME]];
__weak typeof(self) weakSelf = self;
[KBExtensionAppLauncher openPrimaryURL:ul
fallbackURL:scheme
usingInputController:ivc
source:(ivc.view ?: (UIResponder *)weakSelf)
completion:^(BOOL success) {
dispatch_async(dispatch_get_main_queue(), ^{
__strong typeof(weakSelf) self = weakSelf;
if (!self) {
return;
}
if (success) {
[self dismiss];
} else {
NSString *showInfo = [NSString stringWithFormat:KBLocalized(@"Follow: Settings → General → Keyboard → Keyboards → %@ → Allow Full Access"), AppName];
[KBHUD showInfo:showInfo];
}
});
}];
}
@end