|
@@ -178,7 +178,7 @@ NSPopoverDelegate>
|
|
|
self.button.title = [NSString stringWithFormat:@" %@ ",NSLocalizedString(@"Upgrade to Pro", nil)];
|
|
|
[self.button setTitleColor:[NSColor whiteColor]];
|
|
|
self.officeButton.layer.backgroundColor = [NSColor clearColor].CGColor;
|
|
|
- self.officeButton.title = [NSString stringWithFormat:@" %@ ",NSLocalizedString(@"PDF To Office", nil)];
|
|
|
+ self.officeButton.title = [NSString stringWithFormat:@" %@ ",NSLocalizedString(@"PDF to Office", nil)];
|
|
|
[self.officeButton setTitleColor:[NSColor whiteColor]];
|
|
|
|
|
|
self.aiLabel.stringValue = NSLocalizedStringFromTable(@"Free Use 1-Year AI Tools", @"MemberCenterLocalizable", nil);
|
|
@@ -351,18 +351,31 @@ NSPopoverDelegate>
|
|
|
}
|
|
|
} else if (type == KMUserScenarioTypeLite_type11) {
|
|
|
self.button.title = [NSString stringWithFormat:@" %@ ",NSLocalizedString(@"Upgrade", nil)];
|
|
|
+ } else if (type == KMUserScenarioTypePro_type3) {
|
|
|
+ if([KMMemberInfo shared].vip_status == 2) {
|
|
|
+ self.button.title = [NSString stringWithFormat:@" %@ ",NSLocalizedStringFromTable(@"Renew now",@"MemberCenterLocalizable", nil)];
|
|
|
+ } else {
|
|
|
+ self.button.title = [NSString stringWithFormat:@" %@ ",NSLocalizedString(@"Upgrade", nil)];
|
|
|
+ }
|
|
|
}
|
|
|
#if !VERSION_FREE
|
|
|
-// VerificationManager.default().needUpgradeLicense
|
|
|
- if ([[VerificationManager defaultManager] needUpgradeLicense]) {
|
|
|
+ BOOL isNoSupportMemberUpgrade = YES;
|
|
|
+ if ([KMMemberInfo shared].vip_status == 1) { //订阅+永久
|
|
|
+ isNoSupportMemberUpgrade = NO;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (![IAPProductsManager defaultManager].isAvailableAdvancedPDFToOffice && isNoSupportMemberUpgrade) {
|
|
|
[self.officeButton setTitleColor:[NSColor whiteColor]];
|
|
|
- self.officeButton.hidden = YES;
|
|
|
- self.officeImg.hidden = YES;
|
|
|
+ self.officeButton.hidden = NO;
|
|
|
+ self.officeImg.hidden = NO;
|
|
|
self.officeButton.frame = CGRectMake(totalWidth, kbottomGap, officeWidth, self.view.frame.size.height -2 *kbottomGap);
|
|
|
CGRect officeRect = self.officeButton.frame;
|
|
|
self.officeImg.frame = officeRect;
|
|
|
totalWidth+=CGRectGetWidth(self.officeButton.bounds);
|
|
|
totalWidth+=4;
|
|
|
+ } else {
|
|
|
+ self.officeButton.hidden = YES;
|
|
|
+ self.officeImg.hidden = YES;
|
|
|
}
|
|
|
#else
|
|
|
self.officeButton.hidden = YES;
|
|
@@ -437,6 +450,30 @@ NSPopoverDelegate>
|
|
|
type == KMUserScenarioTypePro_type5) {
|
|
|
self.button.hidden = YES;
|
|
|
self.bgImg.hidden = YES;
|
|
|
+
|
|
|
+#if !VERSION_FREE
|
|
|
+ BOOL isNoSupportMemberUpgrade = YES;
|
|
|
+ if ([KMMemberInfo shared].vip_status == 1) { //订阅+永久
|
|
|
+ isNoSupportMemberUpgrade = NO;
|
|
|
+ }
|
|
|
+
|
|
|
+ if (![IAPProductsManager defaultManager].isAvailableAdvancedPDFToOffice && isNoSupportMemberUpgrade) {
|
|
|
+ [self.officeButton setTitleColor:[NSColor whiteColor]];
|
|
|
+ self.officeButton.hidden = NO;
|
|
|
+ self.officeImg.hidden = NO;
|
|
|
+ self.officeButton.frame = CGRectMake(totalWidth, kbottomGap, officeWidth, self.view.frame.size.height -2 *kbottomGap);
|
|
|
+ CGRect officeRect = self.officeButton.frame;
|
|
|
+ self.officeImg.frame = officeRect;
|
|
|
+ totalWidth+=CGRectGetWidth(self.officeButton.bounds);
|
|
|
+ totalWidth+=4;
|
|
|
+ } else {
|
|
|
+ self.officeButton.hidden = YES;
|
|
|
+ self.officeImg.hidden = YES;
|
|
|
+ }
|
|
|
+#else
|
|
|
+ self.officeButton.hidden = YES;
|
|
|
+ self.officeImg.hidden = YES;
|
|
|
+#endif
|
|
|
}
|
|
|
#endif
|
|
|
|