Skip to content

Commit

Permalink
Merge pull request #476 from veritrans/develop
Browse files Browse the repository at this point in the history
Fix several ios 13 issues (#475)
  • Loading branch information
Fauzan Erich Emmerling authored Oct 18, 2019
2 parents fed7ffa + eca9c94 commit eb959db
Show file tree
Hide file tree
Showing 6 changed files with 18 additions and 6 deletions.
2 changes: 1 addition & 1 deletion MidtransCoreKit.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|

s.name = "MidtransCoreKit"
s.version = "1.16.0"
s.version = "1.16.1"
s.summary = "Veritrans mobile SDK beta version"
s.homepage = "https://veritrans.co.id/"
s.license = 'MIT'
Expand Down
1 change: 1 addition & 0 deletions MidtransCoreKit/MidtransCoreKit/Midtrans3DSController.m
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,7 @@ - (void)closePressed:(id)sender {

- (void)showWithCompletion:(void(^)(NSError *error))completion {
UINavigationController *nvc = [[UINavigationController alloc] initWithRootViewController:self];
nvc.modalPresentationStyle = UIModalPresentationFullScreen;
[self.rootViewController presentViewController:nvc animated:YES completion:nil];
self.completion = completion;
}
Expand Down
4 changes: 3 additions & 1 deletion MidtransCoreKit/MidtransCoreKit/MidtransClient.m
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,9 @@ - (void)requestCardBINForInstallmentWithCompletion:(void (^_Nullable)(NSArray *_
}

if (completion) {
completion(contentData,nil);
dispatch_async(dispatch_get_main_queue(), ^{
completion(contentData,nil);
});
}

}
Expand Down
4 changes: 2 additions & 2 deletions MidtransKit.podspec
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
Pod::Spec.new do |s|

s.name = "MidtransKit"
s.version = "1.16.0"
s.version = "1.16.1"
s.summary = "Veritrans mobile SDK beta version"
s.homepage = "https://veritrans.co.id/"
s.license = 'MIT'
Expand All @@ -17,7 +17,7 @@ s.source_files = 'MidtransKit/MidtransKit/**/*.{h,m}'
s.resource_bundles = {
'MidtransKit' => ['MidtransKit/MidtransKit/resources/*']
}
s.dependency 'MidtransCoreKit', '1.16.0'
s.dependency 'MidtransCoreKit', '1.16.1'
s.static_framework = true
s.default_subspec = 'UI'

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ @implementation MidtransUIBaseViewController
- (void)viewDidLoad {
[super viewDidLoad];
//self.navigationItem.backBarButtonItem = [[VTBackBarButtonItem alloc] initWithTitle:UILocalizedString(@"Back", nil)];
if (@available(iOS 13.0, *)) {
self.overrideUserInterfaceStyle = UIUserInterfaceStyleLight;
}
}

@end
Original file line number Diff line number Diff line change
Expand Up @@ -23,12 +23,14 @@ - (instancetype)initWithToken:(MidtransTransactionTokenResponse *)token {
VTPaymentListController *vc = [[VTPaymentListController alloc] initWithToken:token paymentMethodName:nil];
self = [[MidtransUIPaymentViewController alloc] initWithRootViewController:vc];
vc.paymentMethodSelected = nil;
self.modalPresentationStyle = UIModalPresentationFullScreen;
return self;
}
- (instancetype)initCreditCardForm {
VTPaymentListController *vc = [[VTPaymentListController alloc] initWithToken:nil paymentMethodName:nil];
vc.paymentMethodSelected = MIDTRANS_CREDIT_CARD_FORM;
self = [[MidtransUIPaymentViewController alloc] initWithRootViewController:vc];
self.modalPresentationStyle = UIModalPresentationFullScreen;
return self;

}
Expand Down Expand Up @@ -112,10 +114,11 @@ - (instancetype)initWithToken:(MidtransTransactionTokenResponse *)token andPayme
VTPaymentListController *vc = [[VTPaymentListController alloc] initWithToken:token paymentMethodName:nil];
vc.paymentMethodSelected = paymentMethodSelected;
self = [[MidtransUIPaymentViewController alloc] initWithRootViewController:vc];
self.modalPresentationStyle = UIModalPresentationFullScreen;
return self;
}
- (void)viewDidLoad {
[super viewDidLoad];

- (void)viewWillAppear:(BOOL)animated{
if ([[MidtransConfig shared] environment]!=MidtransServerEnvironmentProduction) {
UIWindow *currentWindow = [UIApplication sharedApplication].keyWindow;

Expand All @@ -126,6 +129,9 @@ - (void)viewDidLoad {

[currentWindow addSubview:badgeImageView];
}
}
- (void)viewDidLoad {
[super viewDidLoad];
self.navigationBar.translucent = false;
// to remove 1 px border below nav bar

Expand Down

0 comments on commit eb959db

Please sign in to comment.