|
@@ -13,7 +13,7 @@
|
|
|
#import "KMVerificationAlertViewController.h"
|
|
|
#import "KMActivityALertViewController.h"
|
|
|
#import "KMVerificationInfoViewController.h"
|
|
|
-//#import "VerificationManager.h"
|
|
|
+#import "VerificationManager.h"
|
|
|
//#import "KMMailHelper.h"
|
|
|
#import "GBDeviceInfo.h"
|
|
|
#import "Reachability.h"
|
|
@@ -46,72 +46,70 @@
|
|
|
@implementation KMVerificationWindowController
|
|
|
|
|
|
+ (void)launching {
|
|
|
-// [VerificationManager manager];
|
|
|
+ [VerificationManager manager];
|
|
|
}
|
|
|
|
|
|
+ (BOOL)allowsShowExpired {
|
|
|
-//#if VERSION_DMG
|
|
|
-// if ([VerificationManager manager].status == ActivityStatusTrialExpire &&
|
|
|
-// [VerificationManager manager].secondTrialEnabled == NO) {
|
|
|
-// if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowTrialExpireShowKeyDMG"]) {
|
|
|
-// [[NSUserDefaults standardUserDefaults] setObject:@"YES" forKey:@"allowTrialExpireShowKeyDMG"];
|
|
|
-// return YES;
|
|
|
-// }
|
|
|
-// }
|
|
|
-// return NO;
|
|
|
-//#else
|
|
|
-// NSDate *lastTimeDate = [[NSUserDefaults standardUserDefaults] objectForKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
-// if (lastTimeDate) {
|
|
|
-// NSDate *date = [NSDate date];
|
|
|
-// NSTimeInterval time = [date timeIntervalSinceDate:lastTimeDate];
|
|
|
-// int days = ((int)time)/(3600*24);
|
|
|
-// if (days < 15) {
|
|
|
-// return NO;
|
|
|
-// }
|
|
|
-// }
|
|
|
-//#endif
|
|
|
+#if VERSION_DMG
|
|
|
+ if ([VerificationManager manager].status == ActivityStatusTrialExpire &&
|
|
|
+ [VerificationManager manager].secondTrialEnabled == NO) {
|
|
|
+ if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowTrialExpireShowKeyDMG"]) {
|
|
|
+ [[NSUserDefaults standardUserDefaults] setObject:@"YES" forKey:@"allowTrialExpireShowKeyDMG"];
|
|
|
+ return YES;
|
|
|
+ }
|
|
|
+ }
|
|
|
+ return NO;
|
|
|
+#else
|
|
|
+ NSDate *lastTimeDate = [[NSUserDefaults standardUserDefaults] objectForKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
+ if (lastTimeDate) {
|
|
|
+ NSDate *date = [NSDate date];
|
|
|
+ NSTimeInterval time = [date timeIntervalSinceDate:lastTimeDate];
|
|
|
+ int days = ((int)time)/(3600*24);
|
|
|
+ if (days < 15) {
|
|
|
+ return NO;
|
|
|
+ }
|
|
|
+ }
|
|
|
+#endif
|
|
|
return YES;
|
|
|
}
|
|
|
|
|
|
+ (void)showExpiredInfo {
|
|
|
-// if (ActivityStatusTrialExpire == [VerificationManager manager].status) {
|
|
|
-// if ([KMVerificationWindowController allowsShowExpired]) {
|
|
|
-// KMVerificationWindowController *vc = [KMVerificationWindowController verificationWithType:KMVerificationTypeTrialExpired];
|
|
|
-// [vc showWindow:nil];
|
|
|
-// [vc release];
|
|
|
-//
|
|
|
-// [[NSUserDefaults standardUserDefaults] setObject:[NSDate date] forKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
-// [[NSUserDefaults standardUserDefaults] synchronize];
|
|
|
-// }
|
|
|
-// } else if (ActivityStatusVerifExpire == [VerificationManager manager].status) {
|
|
|
-// if ([KMVerificationWindowController allowsShowExpired]) {
|
|
|
-// KMVerificationWindowController *vc = [KMVerificationWindowController verificationWithType:KMVerificationTypeActivateExpired];
|
|
|
-// [vc showWindow:nil];
|
|
|
-// [vc release];
|
|
|
-//
|
|
|
-// [[NSUserDefaults standardUserDefaults] setObject:[NSDate date] forKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
-// [[NSUserDefaults standardUserDefaults] synchronize];
|
|
|
-// }
|
|
|
-// }
|
|
|
+ if (ActivityStatusTrialExpire == [VerificationManager manager].status) {
|
|
|
+ if ([KMVerificationWindowController allowsShowExpired]) {
|
|
|
+ KMVerificationWindowController *vc = [KMVerificationWindowController verificationWithType:KMVerificationTypeTrialExpired];
|
|
|
+ [vc showWindow:nil];
|
|
|
+
|
|
|
+ [[NSUserDefaults standardUserDefaults] setObject:[NSDate date] forKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
+ [[NSUserDefaults standardUserDefaults] synchronize];
|
|
|
+ }
|
|
|
+ } else if (ActivityStatusVerifExpire == [VerificationManager manager].status) {
|
|
|
+ if ([KMVerificationWindowController allowsShowExpired]) {
|
|
|
+ KMVerificationWindowController *vc = [KMVerificationWindowController verificationWithType:KMVerificationTypeActivateExpired];
|
|
|
+ [vc showWindow:nil];
|
|
|
+
|
|
|
+ [[NSUserDefaults standardUserDefaults] setObject:[NSDate date] forKey:@"kVerificationExpiredShowLastTimeDateKay"];
|
|
|
+ [[NSUserDefaults standardUserDefaults] synchronize];
|
|
|
+ }
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
+ (BOOL)allowRepeatTrialAlertShow {
|
|
|
-// //是否在开启APP时弹出二次试用弹窗提示框
|
|
|
-// if ([VerificationManager manager].secondTrialEnabled) {
|
|
|
-// if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowRepeatTrialAlertShowKey"]) {
|
|
|
-// return YES;
|
|
|
-// }
|
|
|
-// }
|
|
|
+ //是否在开启APP时弹出二次试用弹窗提示框
|
|
|
+ if ([VerificationManager manager].secondTrialEnabled) {
|
|
|
+ if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowRepeatTrialAlertShowKey"]) {
|
|
|
+ return YES;
|
|
|
+ }
|
|
|
+ }
|
|
|
return NO;
|
|
|
}
|
|
|
|
|
|
+ (BOOL)allowRepeatTrialExpireShow {
|
|
|
-// if ([VerificationManager manager].status == ActivityStatusTrialExpire &&
|
|
|
-// [VerificationManager manager].trialTimes == 2) {
|
|
|
-// if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowRepeatTrialExpireShowKey"]) {
|
|
|
-// return YES;
|
|
|
-// }
|
|
|
-// }
|
|
|
+ if ([VerificationManager manager].status == ActivityStatusTrialExpire &&
|
|
|
+ [VerificationManager manager].trialTimes == 2) {
|
|
|
+ if (![[NSUserDefaults standardUserDefaults] objectForKey:@"allowRepeatTrialExpireShowKey"]) {
|
|
|
+ return YES;
|
|
|
+ }
|
|
|
+ }
|
|
|
return NO;
|
|
|
}
|
|
|
|
|
@@ -286,8 +284,8 @@ static KMVerificationWindowController *_currentWindowController = nil;
|
|
|
_repeatTrialAlertController.callback = ^(NSInteger clickIndex, KMRepeatTrialAlertController * _Nonnull tRController) {
|
|
|
if (clickIndex == 0) {
|
|
|
//免费试用
|
|
|
-// [blockSelf verificationTrialForEmail:[VerificationManager manager].email
|
|
|
-// name:[VerificationManager manager].accountName] ;
|
|
|
+ [blockSelf verificationTrialForEmail:[VerificationManager manager].email
|
|
|
+ name:[VerificationManager manager].accountName] ;
|
|
|
} else if (clickIndex == 1) {
|
|
|
//了解更多
|
|
|
NSURL *url = [NSURL URLWithString:@"https://www.pdfreaderpro.com/store?utm_source=app_dmg&utm_medium=dmg_puw_sec_free_trial"];
|
|
@@ -455,23 +453,23 @@ static KMVerificationWindowController *_currentWindowController = nil;
|
|
|
self.progressIndicator.hidden = NO;
|
|
|
[self.progressIndicator startAnimation:nil];
|
|
|
[self.trialViewController setEnabled:NO];
|
|
|
-// [[VerificationManager manager] trialForDays:7 email:email name:name complention:^(ActivityStatus status, NSDictionary *info, NSError *error) {
|
|
|
-// blockSelf.progressIndicator.hidden = YES;
|
|
|
-// [blockSelf.progressIndicator stopAnimation:nil];
|
|
|
-// [blockSelf.trialViewController setEnabled:YES];
|
|
|
-// if (error ||
|
|
|
-// status != ActivityStatusTrial) {
|
|
|
-// NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
-// defaultButton:NSLocalizedString(@"Try Again", nil)
|
|
|
-// alternateButton:nil
|
|
|
-// otherButton:nil
|
|
|
-// informativeTextWithFormat:NSLocalizedString(@"Failed to sign up for the free trial. Please make sure your internet connection is available and try again later.", nil), nil];
|
|
|
-// [alert runModal];
|
|
|
-// } else {
|
|
|
-// blockSelf.type = KMVerificationTypeTrialSuccess;
|
|
|
-// [blockSelf updateViewInfo];
|
|
|
-// }
|
|
|
-// }];
|
|
|
+ [[VerificationManager manager] trialForDays:7 email:email name:name complention:^(ActivityStatus status, NSDictionary *info, NSError *error) {
|
|
|
+ blockSelf.progressIndicator.hidden = YES;
|
|
|
+ [blockSelf.progressIndicator stopAnimation:nil];
|
|
|
+ [blockSelf.trialViewController setEnabled:YES];
|
|
|
+ if (error ||
|
|
|
+ status != ActivityStatusTrial) {
|
|
|
+ NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
+ defaultButton:NSLocalizedString(@"Try Again", nil)
|
|
|
+ alternateButton:nil
|
|
|
+ otherButton:nil
|
|
|
+ informativeTextWithFormat:NSLocalizedString(@"Failed to sign up for the free trial. Please make sure your internet connection is available and try again later.", nil), nil];
|
|
|
+ [alert runModal];
|
|
|
+ } else {
|
|
|
+ blockSelf.type = KMVerificationTypeTrialSuccess;
|
|
|
+ [blockSelf updateViewInfo];
|
|
|
+ }
|
|
|
+ }];
|
|
|
}
|
|
|
|
|
|
- (void)verificationActivate:(NSString *)license {
|
|
@@ -512,88 +510,88 @@ static KMVerificationWindowController *_currentWindowController = nil;
|
|
|
[self.progressIndicator startAnimation:nil];
|
|
|
[self.activateViewController setEnabled:NO];
|
|
|
NSDictionary *infoDic = @{@"cdkey":license};
|
|
|
-// [[VerificationManager manager] activateDeviceWithInfo:infoDic complention:^(ActivityStatus status, NSDictionary *info, NSError *error) {
|
|
|
-// blockSelf.progressIndicator.hidden = YES;
|
|
|
-// [blockSelf.progressIndicator stopAnimation:nil];
|
|
|
-// [blockSelf.activateViewController setEnabled:YES];
|
|
|
-// if (error) {
|
|
|
-//
|
|
|
-// NSString *tTitle0 = NSLocalizedString(@"The license you have entered is not correct. Please enter valid license.", nil);
|
|
|
-// NSString *tTitle1 = NSLocalizedString(@"If you have already purchased PDF Reader Pro for Mac, you should find your license in an email confirmation.", nil);
|
|
|
-//
|
|
|
-// NSString *message = [NSString stringWithFormat:@"%@\n\n%@", tTitle0, tTitle1];
|
|
|
-//
|
|
|
-// if (ActivityErrorTypeCDKeyEmpty == error.code) {
|
|
|
-// message = [NSString stringWithFormat:@"%@\n\n%@", NSLocalizedString(@"License number can not be empty.", nil), @""];
|
|
|
-// } else if (ActivityErrorTypeCDKeyNotExist == error.code) {
|
|
|
-// message = [NSString stringWithFormat:@"%@\n\n%@", NSLocalizedString(@"License number does not exist.", nil), @""];
|
|
|
-// } else if (ActivityErrorTypeOutNumber == error.code) {
|
|
|
-// NSString *tMsg0 = NSLocalizedString(@"The devices connected to the license number has outnumbered.", nil);
|
|
|
-// NSString *tMsg1 = NSLocalizedString(@"Please deactivate license on one of them, to use PDF Reader Pro on this computer", nil);
|
|
|
-// message = [NSString stringWithFormat:@"%@\n\n%@", tMsg0, tMsg1];
|
|
|
-// } else if (ActivityErrorTypeNetworkDisable == error.code) {
|
|
|
-// message = NSLocalizedString(@"The network is unavailable.", nil);
|
|
|
-// } else if (ActivityErrorTypeCDKeyExpire == error.code) {
|
|
|
-// message = NSLocalizedString(@"The license number expired.", nil);
|
|
|
-// } else if (ActivityErrorTypeInvalidInfo == error.code) {
|
|
|
-// message = NSLocalizedString(@"Activation error. Please try to input correct license, or contact us.", nil);
|
|
|
-// } else if (ActivityErrorTypeNotMatchProduct == error.code) {
|
|
|
-// message = NSLocalizedString(@"The license number is wrong, please input right license which is for this app.", nil);
|
|
|
-// } else if (ActivityErrorTypeFormatError == error.code) {
|
|
|
-// message = NSLocalizedString(@"The license format is wrong. Please input correct license.", nil);
|
|
|
-// }
|
|
|
-//
|
|
|
-// if ((ActivityErrorTypeUnknow == error.code) || (ActivityErrorTypeOutNumber == error.code) || (ActivityErrorTypeInvalidInfo == error.code)) {
|
|
|
-// NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
-// defaultButton:NSLocalizedString(@"Contact Us", nil)
|
|
|
-// alternateButton:NSLocalizedString(@"Try Again", nil)
|
|
|
-// otherButton:nil
|
|
|
-// informativeTextWithFormat:message, nil];
|
|
|
-// if ([alert runModal]) {
|
|
|
-// [blockSelf verificationFeedback];
|
|
|
-// }
|
|
|
-// } else {
|
|
|
-// if (ActivityErrorTypeNetworkDisable == error.code) {
|
|
|
-// NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Connection Error", nil)
|
|
|
-// defaultButton:NSLocalizedString(@"OK", nil)
|
|
|
-// alternateButton:nil
|
|
|
-// otherButton:nil
|
|
|
-// informativeTextWithFormat:@"", nil];
|
|
|
-//
|
|
|
-// NSButton *accessryBtn = [[NSButton alloc] initWithFrame:CGRectMake(0, 0, 180, 44)];
|
|
|
-// accessryBtn.autoresizingMask = NSViewMaxXMargin | NSViewMinYMargin | NSViewMaxYMargin;
|
|
|
-// accessryBtn.bezelStyle = NSBezelStyleRegularSquare;
|
|
|
-// accessryBtn.bordered = NO;
|
|
|
-// accessryBtn.target = self;
|
|
|
-// accessryBtn.action = @selector(accessryBtnClicked:);
|
|
|
-// NSMutableAttributedString *mutAttrString = [[[NSMutableAttributedString alloc] initWithString:NSLocalizedString(@"Please make sure your internet connection is available.", nil)] autorelease];
|
|
|
-// [mutAttrString addAttribute:NSFontAttributeName value:[NSFont systemFontOfSize:12] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
-// [mutAttrString addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
-// [mutAttrString addAttribute:NSForegroundColorAttributeName value:[KMAppearance KMColor_Interactive_M0] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
-//
|
|
|
-// accessryBtn.attributedTitle = mutAttrString;
|
|
|
-// NSRect rect = [mutAttrString boundingRectWithSize:CGSizeMake(180, MAXFLOAT) options:NSStringDrawingUsesLineFragmentOrigin | NSStringDrawingUsesFontLeading];
|
|
|
-// CGRect frame = accessryBtn.frame;
|
|
|
-// frame.size.height = rect.size.height;
|
|
|
-// accessryBtn.frame = frame;
|
|
|
-// alert.accessoryView = accessryBtn;
|
|
|
-//
|
|
|
-// [alert runModal];
|
|
|
-// } else {
|
|
|
-// NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
-// defaultButton:NSLocalizedString(@"Try Again", nil)
|
|
|
-// alternateButton:nil
|
|
|
-// otherButton:nil
|
|
|
-// informativeTextWithFormat:message, nil];
|
|
|
-// [alert runModal];
|
|
|
-// }
|
|
|
-// }
|
|
|
-// } else {
|
|
|
-// blockSelf.activityAlertViewController.alertTitle = NSLocalizedString(@"Successful activation!", nil);
|
|
|
-// blockSelf.activityAlertViewController.alertMessage = NSLocalizedString(@"Congrats! You can start enjoying the advanced features of PDF Reader Pro.", nil);
|
|
|
-// [blockSelf setContentView:blockSelf.activityAlertViewController.view];
|
|
|
-// }
|
|
|
-// }];
|
|
|
+ [[VerificationManager manager] activateDeviceWithInfo:infoDic complention:^(ActivityStatus status, NSDictionary *info, NSError *error) {
|
|
|
+ blockSelf.progressIndicator.hidden = YES;
|
|
|
+ [blockSelf.progressIndicator stopAnimation:nil];
|
|
|
+ [blockSelf.activateViewController setEnabled:YES];
|
|
|
+ if (error) {
|
|
|
+
|
|
|
+ NSString *tTitle0 = NSLocalizedString(@"The license you have entered is not correct. Please enter valid license.", nil);
|
|
|
+ NSString *tTitle1 = NSLocalizedString(@"If you have already purchased PDF Reader Pro for Mac, you should find your license in an email confirmation.", nil);
|
|
|
+
|
|
|
+ NSString *message = [NSString stringWithFormat:@"%@\n\n%@", tTitle0, tTitle1];
|
|
|
+
|
|
|
+ if (ActivityErrorTypeCDKeyEmpty == error.code) {
|
|
|
+ message = [NSString stringWithFormat:@"%@\n\n%@", NSLocalizedString(@"License number can not be empty.", nil), @""];
|
|
|
+ } else if (ActivityErrorTypeCDKeyNotExist == error.code) {
|
|
|
+ message = [NSString stringWithFormat:@"%@\n\n%@", NSLocalizedString(@"License number does not exist.", nil), @""];
|
|
|
+ } else if (ActivityErrorTypeOutNumber == error.code) {
|
|
|
+ NSString *tMsg0 = NSLocalizedString(@"The devices connected to the license number has outnumbered.", nil);
|
|
|
+ NSString *tMsg1 = NSLocalizedString(@"Please deactivate license on one of them, to use PDF Reader Pro on this computer", nil);
|
|
|
+ message = [NSString stringWithFormat:@"%@\n\n%@", tMsg0, tMsg1];
|
|
|
+ } else if (ActivityErrorTypeNetworkDisable == error.code) {
|
|
|
+ message = NSLocalizedString(@"The network is unavailable.", nil);
|
|
|
+ } else if (ActivityErrorTypeCDKeyExpire == error.code) {
|
|
|
+ message = NSLocalizedString(@"The license number expired.", nil);
|
|
|
+ } else if (ActivityErrorTypeInvalidInfo == error.code) {
|
|
|
+ message = NSLocalizedString(@"Activation error. Please try to input correct license, or contact us.", nil);
|
|
|
+ } else if (ActivityErrorTypeNotMatchProduct == error.code) {
|
|
|
+ message = NSLocalizedString(@"The license number is wrong, please input right license which is for this app.", nil);
|
|
|
+ } else if (ActivityErrorTypeFormatError == error.code) {
|
|
|
+ message = NSLocalizedString(@"The license format is wrong. Please input correct license.", nil);
|
|
|
+ }
|
|
|
+
|
|
|
+ if ((ActivityErrorTypeUnknow == error.code) || (ActivityErrorTypeOutNumber == error.code) || (ActivityErrorTypeInvalidInfo == error.code)) {
|
|
|
+ NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
+ defaultButton:NSLocalizedString(@"Contact Us", nil)
|
|
|
+ alternateButton:NSLocalizedString(@"Try Again", nil)
|
|
|
+ otherButton:nil
|
|
|
+ informativeTextWithFormat:message, nil];
|
|
|
+ if ([alert runModal]) {
|
|
|
+ [blockSelf verificationFeedback];
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if (ActivityErrorTypeNetworkDisable == error.code) {
|
|
|
+ NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Connection Error", nil)
|
|
|
+ defaultButton:NSLocalizedString(@"OK", nil)
|
|
|
+ alternateButton:nil
|
|
|
+ otherButton:nil
|
|
|
+ informativeTextWithFormat:@"", nil];
|
|
|
+
|
|
|
+ NSButton *accessryBtn = [[NSButton alloc] initWithFrame:CGRectMake(0, 0, 180, 44)];
|
|
|
+ accessryBtn.autoresizingMask = NSViewMaxXMargin | NSViewMinYMargin | NSViewMaxYMargin;
|
|
|
+ accessryBtn.bezelStyle = NSBezelStyleRegularSquare;
|
|
|
+ accessryBtn.bordered = NO;
|
|
|
+ accessryBtn.target = self;
|
|
|
+ accessryBtn.action = @selector(accessryBtnClicked:);
|
|
|
+ NSMutableAttributedString *mutAttrString = [[NSMutableAttributedString alloc] initWithString:NSLocalizedString(@"Please make sure your internet connection is available.", nil)];
|
|
|
+ [mutAttrString addAttribute:NSFontAttributeName value:[NSFont systemFontOfSize:12] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
+ [mutAttrString addAttribute:NSUnderlineStyleAttributeName value:[NSNumber numberWithInteger:NSUnderlineStyleSingle] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
+ [mutAttrString addAttribute:NSForegroundColorAttributeName value:[KMAppearance KMColor_Interactive_M0] range:NSMakeRange(0, [mutAttrString length])];
|
|
|
+
|
|
|
+ accessryBtn.attributedTitle = mutAttrString;
|
|
|
+ NSRect rect = [mutAttrString boundingRectWithSize:CGSizeMake(180, MAXFLOAT) options:NSStringDrawingUsesLineFragmentOrigin | NSStringDrawingUsesFontLeading];
|
|
|
+ CGRect frame = accessryBtn.frame;
|
|
|
+ frame.size.height = rect.size.height;
|
|
|
+ accessryBtn.frame = frame;
|
|
|
+ alert.accessoryView = accessryBtn;
|
|
|
+
|
|
|
+ [alert runModal];
|
|
|
+ } else {
|
|
|
+ NSAlert *alert = [NSAlert alertWithMessageText:NSLocalizedString(@"Activation Error", nil)
|
|
|
+ defaultButton:NSLocalizedString(@"Try Again", nil)
|
|
|
+ alternateButton:nil
|
|
|
+ otherButton:nil
|
|
|
+ informativeTextWithFormat:message, nil];
|
|
|
+ [alert runModal];
|
|
|
+ }
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ blockSelf.activityAlertViewController.alertTitle = NSLocalizedString(@"Successful activation!", nil);
|
|
|
+ blockSelf.activityAlertViewController.alertMessage = NSLocalizedString(@"Congrats! You can start enjoying the advanced features of PDF Reader Pro.", nil);
|
|
|
+ [blockSelf setContentView:blockSelf.activityAlertViewController.view];
|
|
|
+ }
|
|
|
+ }];
|
|
|
|
|
|
}
|
|
|
|
|
@@ -639,7 +637,7 @@ static KMVerificationWindowController *_currentWindowController = nil;
|
|
|
subjects = [subjects stringByAppendingString:[NSString stringWithFormat:@"%@;",tAppVersion]];
|
|
|
subjects = [subjects stringByAppendingString:[NSString stringWithFormat:@" %@;",versionString]];
|
|
|
subjects = [subjects stringByAppendingString:[NSString stringWithFormat:@" %@",NSLocalizedString(@"Unbind License Code:", nil)]];
|
|
|
-// subjects = [subjects stringByAppendingString:[NSString stringWithFormat:@"%@",[VerificationManager manager].detailInfo[@"device"][@"unique_sn"]?:@""]];
|
|
|
+ subjects = [subjects stringByAppendingString:[NSString stringWithFormat:@"%@",[VerificationManager manager].detailInfo[@"device"][@"unique_sn"]?:@""]];
|
|
|
|
|
|
NSString *mailtoAddress = [NSString stringWithFormat:@"mailto:%@?Subject=%@&body=%@",@"support@pdfreaderpro.com",[self URLEncodedString:subjects],[self URLEncodedString:NSLocalizedString(@"Hi PDF Reader Pro Team, I need to unbind my license code, thanks!\nNotice: Please do not modify the subtitle content", nil)]];
|
|
|
[[NSWorkspace sharedWorkspace] openURL:[NSURL URLWithString:mailtoAddress]];
|