|
@@ -262,16 +262,16 @@ NSPopoverDelegate>
|
|
|
|
|
|
if (type == KMUserScenarioTypeDmg_type2 ||
|
|
|
type == KMUserScenarioTypeDmg_type19 ||
|
|
|
+ type == KMUserScenarioTypeDmg_type20 ||
|
|
|
+ type == KMUserScenarioTypeDmg_type21 ||
|
|
|
type == KMUserScenarioTypeDmg_type22 ||
|
|
|
- type == KMUserScenarioTypeDmg_type33 ||
|
|
|
type == KMUserScenarioTypeDmg_type30 ||
|
|
|
- type == KMUserScenarioTypeDmg_type20 ||
|
|
|
type == KMUserScenarioTypeDmg_type31 ||
|
|
|
- type == KMUserScenarioTypeDmg_type21 ||
|
|
|
- type == KMUserScenarioTypeDmg_type32) {
|
|
|
+ type == KMUserScenarioTypeDmg_type32 ||
|
|
|
+ type == KMUserScenarioTypeDmg_type33) {
|
|
|
[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;
|
|
@@ -545,7 +545,9 @@ NSPopoverDelegate>
|
|
|
}
|
|
|
|
|
|
- (IBAction)officeButtonAction:(id)sender {
|
|
|
-
|
|
|
+ DMGEmbeddedOldWC *embeddedWC = [DMGEmbeddedOldWC currentFirstTrialWC:@"com.brother.pdfreaderpro.mac.product_2"];
|
|
|
+ [embeddedWC showWindow:nil];
|
|
|
+ [embeddedWC.window center];
|
|
|
}
|
|
|
|
|
|
- (NSAttributedString *)numberConvertColor:(NSColor*)color String:(NSString *)string {
|
|
@@ -621,27 +623,14 @@ NSPopoverDelegate>
|
|
|
}
|
|
|
|
|
|
- (IBAction)personalCenterAction:(NSButton *)sender {
|
|
|
- [KMUserInfoViewController refreshTokenUserInfoWithCallback:^(BOOL success,KMMemberCenterResult*resDic) {
|
|
|
- if(success) {
|
|
|
- if([KMMemberInfo shared].isLogin == YES) {
|
|
|
- // 用户头像点击事件
|
|
|
- self.userMenu = [[NSMenu alloc] init];
|
|
|
- KMUserInfoViewController *userInfo = [[KMUserInfoViewController alloc] init];
|
|
|
- NSMenuItem *item = [self.userMenu addItemWithTitle:@"" action:nil target:@""];
|
|
|
- item.target = self;
|
|
|
- item.representedObject = userInfo;
|
|
|
- item.view = userInfo.view;
|
|
|
- [self.userMenu popUpMenuPositioningItem:nil atLocation:NSMakePoint(-130, 30) inView:sender];
|
|
|
- }
|
|
|
- } else {
|
|
|
- NSInteger code = resDic.code;
|
|
|
- if(code == 304) {
|
|
|
- [[KMLoginWindowsController shared] showWindow:nil];
|
|
|
- }
|
|
|
- }
|
|
|
- }];
|
|
|
-
|
|
|
-
|
|
|
+ // 用户头像点击事件
|
|
|
+ self.userMenu = [[NSMenu alloc] init];
|
|
|
+ KMUserInfoViewController *userInfo = [[KMUserInfoViewController alloc] init];
|
|
|
+ NSMenuItem *item = [self.userMenu addItemWithTitle:@"" action:nil target:@""];
|
|
|
+ item.target = self;
|
|
|
+ item.representedObject = userInfo;
|
|
|
+ item.view = userInfo.view;
|
|
|
+ [self.userMenu popUpMenuPositioningItem:nil atLocation:NSMakePoint(-130, 30) inView:sender];
|
|
|
}
|
|
|
|
|
|
- (IBAction)signUpAction:(NSButton *)sender {
|