|
@@ -353,16 +353,23 @@ NSPopoverDelegate>
|
|
|
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 +444,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
|
|
|
|