ソースを参照

【综合】整理代码

tangchao 1 年間 前
コミット
b5d1f1b261

+ 8 - 26
PDF Office/PDF Master.xcodeproj/project.pbxproj

@@ -2791,12 +2791,6 @@
 		BB9695B629BDB03E00FD68D3 /* InfoWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9695B529BDB03E00FD68D3 /* InfoWindow.xib */; };
 		BB9695B729BDB03E00FD68D3 /* InfoWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9695B529BDB03E00FD68D3 /* InfoWindow.xib */; };
 		BB9695B829BDB03E00FD68D3 /* InfoWindow.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9695B529BDB03E00FD68D3 /* InfoWindow.xib */; };
-		BB9807FD29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = BB9807FA29CA93D400BEEB81 /* WelcomeWindowController.m */; };
-		BB9807FE29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = BB9807FA29CA93D400BEEB81 /* WelcomeWindowController.m */; };
-		BB9807FF29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */ = {isa = PBXBuildFile; fileRef = BB9807FA29CA93D400BEEB81 /* WelcomeWindowController.m */; };
-		BB98080029CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9807FC29CA93D400BEEB81 /* WelcomeWindowController.xib */; };
-		BB98080129CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9807FC29CA93D400BEEB81 /* WelcomeWindowController.xib */; };
-		BB98080229CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB9807FC29CA93D400BEEB81 /* WelcomeWindowController.xib */; };
 		BB981E522AD4F638001988CA /* KMCoverButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E502AD4F637001988CA /* KMCoverButton.swift */; };
 		BB981E532AD4F638001988CA /* KMCoverButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E502AD4F637001988CA /* KMCoverButton.swift */; };
 		BB981E542AD4F638001988CA /* KMCoverButton.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E502AD4F637001988CA /* KMCoverButton.swift */; };
@@ -2806,6 +2800,9 @@
 		BB981E592AD4F70D001988CA /* KMWelcomeWindowController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E582AD4F70D001988CA /* KMWelcomeWindowController.swift */; };
 		BB981E5A2AD4F70D001988CA /* KMWelcomeWindowController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E582AD4F70D001988CA /* KMWelcomeWindowController.swift */; };
 		BB981E5B2AD4F70D001988CA /* KMWelcomeWindowController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB981E582AD4F70D001988CA /* KMWelcomeWindowController.swift */; };
+		BB986AE72AD5376100ADF172 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB986AE62AD5376100ADF172 /* WelcomeWindowController.xib */; };
+		BB986AE82AD5376100ADF172 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB986AE62AD5376100ADF172 /* WelcomeWindowController.xib */; };
+		BB986AE92AD5376100ADF172 /* WelcomeWindowController.xib in Resources */ = {isa = PBXBuildFile; fileRef = BB986AE62AD5376100ADF172 /* WelcomeWindowController.xib */; };
 		BB99ACC2292DE22E0048AFD9 /* KMMergeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB99ACC0292DE22E0048AFD9 /* KMMergeViewController.swift */; };
 		BB99ACC3292DE22E0048AFD9 /* KMMergeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB99ACC0292DE22E0048AFD9 /* KMMergeViewController.swift */; };
 		BB99ACC4292DE22E0048AFD9 /* KMMergeViewController.swift in Sources */ = {isa = PBXBuildFile; fileRef = BB99ACC0292DE22E0048AFD9 /* KMMergeViewController.swift */; };
@@ -4588,12 +4585,10 @@
 		BB9695B029BDA46500FD68D3 /* SKLocalization.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SKLocalization.h; sourceTree = "<group>"; };
 		BB9695B129BDA46500FD68D3 /* SKLocalization.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = SKLocalization.m; sourceTree = "<group>"; };
 		BB9695B529BDB03E00FD68D3 /* InfoWindow.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = InfoWindow.xib; sourceTree = "<group>"; };
-		BB9807FA29CA93D400BEEB81 /* WelcomeWindowController.m */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.objc; path = WelcomeWindowController.m; sourceTree = "<group>"; };
-		BB9807FB29CA93D400BEEB81 /* WelcomeWindowController.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = WelcomeWindowController.h; sourceTree = "<group>"; };
-		BB9807FC29CA93D400BEEB81 /* WelcomeWindowController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = WelcomeWindowController.xib; sourceTree = "<group>"; };
 		BB981E502AD4F637001988CA /* KMCoverButton.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = KMCoverButton.swift; sourceTree = "<group>"; };
 		BB981E512AD4F638001988CA /* KMPageIndicator.swift */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.swift; path = KMPageIndicator.swift; sourceTree = "<group>"; };
 		BB981E582AD4F70D001988CA /* KMWelcomeWindowController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KMWelcomeWindowController.swift; sourceTree = "<group>"; };
+		BB986AE62AD5376100ADF172 /* WelcomeWindowController.xib */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = file.xib; path = WelcomeWindowController.xib; sourceTree = "<group>"; };
 		BB99ACC0292DE22E0048AFD9 /* KMMergeViewController.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KMMergeViewController.swift; sourceTree = "<group>"; };
 		BB99ACC1292DE22E0048AFD9 /* KMMergeViewController.xib */ = {isa = PBXFileReference; lastKnownFileType = file.xib; path = KMMergeViewController.xib; sourceTree = "<group>"; };
 		BB99ACC9292DEE6E0048AFD9 /* KMMergeTitleBar.swift */ = {isa = PBXFileReference; lastKnownFileType = sourcecode.swift; path = KMMergeTitleBar.swift; sourceTree = "<group>"; };
@@ -8481,22 +8476,12 @@
 		BB9807F829CA93A900BEEB81 /* Welcome */ = {
 			isa = PBXGroup;
 			children = (
-				BB9807F929CA93A900BEEB81 /* OC */,
+				BB986AE62AD5376100ADF172 /* WelcomeWindowController.xib */,
 				BB981E582AD4F70D001988CA /* KMWelcomeWindowController.swift */,
 			);
 			path = Welcome;
 			sourceTree = "<group>";
 		};
-		BB9807F929CA93A900BEEB81 /* OC */ = {
-			isa = PBXGroup;
-			children = (
-				BB9807FB29CA93D400BEEB81 /* WelcomeWindowController.h */,
-				BB9807FA29CA93D400BEEB81 /* WelcomeWindowController.m */,
-				BB9807FC29CA93D400BEEB81 /* WelcomeWindowController.xib */,
-			);
-			path = OC;
-			sourceTree = "<group>";
-		};
 		BB99ACBA292DDFEC0048AFD9 /* Merge */ = {
 			isa = PBXGroup;
 			children = (
@@ -9394,6 +9379,7 @@
 				AD867FB729DFBB3200F00440 /* KMAnnotationOutlineCellView.xib in Resources */,
 				BB5DF1EC2959C5CB0025CDA1 /* KMHeaderFooterPreviewController.xib in Resources */,
 				ADD1B6CF29431D7100C3FFF7 /* KMPrintPreviewView.xib in Resources */,
+				BB986AE72AD5376100ADF172 /* WelcomeWindowController.xib in Resources */,
 				BB9695B629BDB03E00FD68D3 /* InfoWindow.xib in Resources */,
 				ADD1B6FC2946C0D400C3FFF7 /* KMPrintChoosePageSizePamphletView.xib in Resources */,
 				ADBC376629CD86A000D93208 /* KMReadModelView.xcassets in Resources */,
@@ -9482,7 +9468,6 @@
 				9FA607E128FD4C9F00B46586 /* KMHomePopViewController.xib in Resources */,
 				9F0CB4B82977BC1000007028 /* KMPropertiesPanelPreviewSubVC.xib in Resources */,
 				ADE614BA29861CFF00F62ED7 /* KMBatchSelectedFilesView.xib in Resources */,
-				BB98080029CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */,
 				ADB1FE7229752ED500ED072D /* KMBatchConvertPDFView.xib in Resources */,
 				9FDD0F9C2952FF4D000C4DAD /* comp-light.json in Resources */,
 				F3B7DFA42949C8E300333201 /* CPDFListView.xcassets in Resources */,
@@ -9886,6 +9871,7 @@
 				BB6CA4D0298BB0D000A13864 /* KMPreferenceWindowController.xib in Resources */,
 				BB003019298CA446002DD1A0 /* KMPreferenceGeneralController.xib in Resources */,
 				ADC075C529866B05006C752F /* KMBatchTextRecognitionView.xib in Resources */,
+				BB986AE82AD5376100ADF172 /* WelcomeWindowController.xib in Resources */,
 				ADBC376229CC637900D93208 /* KMReadModelView.xib in Resources */,
 				9F1F82D6292F6D510092C4B4 /* KMPDFInsertPreviewViewController.xib in Resources */,
 				BB003032298D315E002DD1A0 /* KMPreferenceMarkupController.xib in Resources */,
@@ -9937,7 +9923,6 @@
 				BB8F454B295A9CDC0037EA22 /* KMHeaderFooterListController.xib in Resources */,
 				BB69C95D299116FD0001A9B1 /* five_line_score.pdf in Resources */,
 				8942F7FC2926089200389627 /* KMSignatureViewController.xib in Resources */,
-				BB98080129CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */,
 				9F080B18298CFDB300FC27DA /* KMTextImageButtonVC.xib in Resources */,
 				9F02019A2A1F352100C9B673 /* KMAITranslationConfirmWindowController.xib in Resources */,
 				BBFE6E832930EBD400142C01 /* KMCompressWindowController.xib in Resources */,
@@ -10045,6 +10030,7 @@
 				9F853A042947137500DF644E /* default-icon.pdf in Resources */,
 				9F8539ED2947131F00DF644E /* KMChromiumTabView.xib in Resources */,
 				BB6CA4D1298BB0D000A13864 /* KMPreferenceWindowController.xib in Resources */,
+				BB986AE92AD5376100ADF172 /* WelcomeWindowController.xib in Resources */,
 				BBEC00DE295C39FD00A26C98 /* KMBatesPropertyInfoController.xib in Resources */,
 				9F1F82D7292F6D510092C4B4 /* KMPDFInsertPreviewViewController.xib in Resources */,
 				9FAAA337290BD0A20046FFCE /* KMHistoryFileCollectionViewItem.xib in Resources */,
@@ -10111,7 +10097,6 @@
 				AD8810B729A846B100178CA1 /* KMVerficationCodeWindowController.xib in Resources */,
 				BBC348192955920B008D2CD1 /* KMBackgroundPropertyController.xib in Resources */,
 				9F02019B2A1F352100C9B673 /* KMAITranslationConfirmWindowController.xib in Resources */,
-				BB98080229CA93D400BEEB81 /* WelcomeWindowController.xib in Resources */,
 				AD6260702A9D968B006C6413 /* KMEditPDFAssets.xcassets in Resources */,
 				89E4E76629656A88002DBA6F /* KMAnnotationStampViewController.xib in Resources */,
 				899700E428F3A9F2009AF911 /* KMHomeWindowController.xib in Resources */,
@@ -10814,7 +10799,6 @@
 				9F1FE49629406E4700E952CA /* common.c in Sources */,
 				BBD1F79C296FF7A600343885 /* KMPageEditSplitSettingModel.swift in Sources */,
 				BB3198122AC5142900107371 /* NSMenu+KMExtension.swift in Sources */,
-				BB9807FD29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */,
 				BB897265294C724D0045787C /* KMWatermarkAdjectiveOutsideView.swift in Sources */,
 				BBC2BCC6295DA8F30036B983 /* KMCropPreviewController.swift in Sources */,
 				BB0A55142A3052F800B6E84B /* KMCustomTextField.swift in Sources */,
@@ -11603,7 +11587,6 @@
 				BB162E9C295073B50088E9D1 /* KMWatermarkManager.swift in Sources */,
 				BBD1F79D296FF7A600343885 /* KMPageEditSplitSettingModel.swift in Sources */,
 				ADDEEA632AD3A6E700EF675D /* KMPDFSignatureTextView.swift in Sources */,
-				BB9807FE29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */,
 				9FCFEC892AD0EF9900EAD2CB /* KMPopMenuButton.swift in Sources */,
 				BB7BC4D92AD3D6B700D6BEE6 /* PDFListView+KMExtensions.swift in Sources */,
 				BB6DD81929348A00001F0544 /* KMSecureEncryptComboBoxCellView.swift in Sources */,
@@ -12131,7 +12114,6 @@
 				BBC3480E29558DC1008D2CD1 /* KMBackgroundController.swift in Sources */,
 				9F0CB4F7298655D500007028 /* KMDesignToken+Fill.swift in Sources */,
 				BB49ED1F293F4FB200C82CA2 /* KMConvertPPTsSettingView.swift in Sources */,
-				BB9807FF29CA93D400BEEB81 /* WelcomeWindowController.m in Sources */,
 				BB14703D299DC0D200784A6A /* OIDErrorUtilities.m in Sources */,
 				BBFE6E772930E53000142C01 /* KMMergePopoverViewController.swift in Sources */,
 				ADF6B8782A48155E0090CB78 /* KMComparativeViewCollectionItem.swift in Sources */,

+ 1 - 1
PDF Office/PDF Master/Class/ChromiumTabs/KMBrowserWindowController.swift

@@ -38,7 +38,7 @@ import Cocoa
         NotificationCenter.default.addObserver(self, selector: #selector(closeAllTabs(_:)), name: NSNotification.Name.init(rawValue: "KMTabControllerCloseAllTabs"), object: nil)
         NotificationCenter.default.addObserver(self, selector: #selector(openNewWindow(_:)), name: NSNotification.Name.init(rawValue: "KMTabControllerOpenNewWindow"), object: nil)
         
-        if (WelcomeWindowController.welcomeHasShow() == false) {
+        if (KMWelcomeWindowController.welcomeHasShow() == false) {
             //AI 版本禁掉首次开启帮助文档
 //            KMTools.openQuickStartStudy()
             

+ 0 - 18
PDF Office/PDF Master/Class/Welcome/OC/WelcomeWindowController.h

@@ -1,18 +0,0 @@
-//
-//  WelcomeWindowController.h
-//  PDF Reader
-//
-//  Created by wangshuai on 13-12-11.
-//  Copyright (c) 2013年 zhangjie. All rights reserved.
-//
-
-#import <Cocoa/Cocoa.h>
-
-@interface WelcomeWindowController : NSWindowController
-
-@property (nonatomic, copy) void(^itemClick)(NSInteger idx, id param);
-
-// 引导页是否有显示过
-+ (BOOL)welcomeHasShow;
-
-@end

+ 0 - 451
PDF Office/PDF Master/Class/Welcome/OC/WelcomeWindowController.m

@@ -1,451 +0,0 @@
-//
-//  WelcomeWindowController.m
-//  PDF Reader
-//
-//  Created by wangshuai on 13-12-11.
-//  Copyright (c) 2013年 zhangjie. All rights reserved.
-//
-
-#import "WelcomeWindowController.h"
-#import <PDF_Master-Swift.h>
-
-static WelcomeWindowController *windowController = nil;
-static NSString * const kKMWelcomeHasShowKey = @"WelcomeHasShowKey";
-static NSString * const kKMWelcomeRemindMeLaterKey = @"WelcomeRemindMeLaterKey";
-
-@interface WelcomeWindowController ()
-
-@property (nonatomic,assign) IBOutlet NSScrollView *scrollView;
-
-@property (nonatomic,assign) IBOutlet NSView *content1View;
-@property (nonatomic,assign) IBOutlet NSView *content2View;
-@property (nonatomic,assign) IBOutlet NSView *content3View;
-@property (nonatomic,assign) IBOutlet NSView *content4View;
-
-@property (strong) IBOutlet NSView *content5View;
-@property (strong) IBOutlet NSView *content6View;
-
-@property (weak) IBOutlet NSImageView *imageView1;
-@property (weak) IBOutlet NSImageView *imageView2;
-@property (weak) IBOutlet NSImageView *imageView3;
-@property (weak) IBOutlet NSImageView *imageView4;
-@property (weak) IBOutlet NSImageView *imageView6;
-@property (weak) IBOutlet NSImageView *imageView5;
-
-@property (nonatomic,assign) IBOutlet NSTextField *title1Label;
-@property (nonatomic,assign) IBOutlet NSTextField *subtitle1Label;
-@property (nonatomic,assign) IBOutlet NSTextField *title2Label;
-@property (nonatomic,assign) IBOutlet NSTextField *subtitle2Label;
-@property (nonatomic,assign) IBOutlet NSTextField *title3Label;
-@property (nonatomic,assign) IBOutlet NSTextField *subtitle3Label;
-@property (nonatomic,assign) IBOutlet NSTextField *title4Label;
-@property (nonatomic,assign) IBOutlet NSTextField *subtitle4Label;
-
-@property (weak) IBOutlet NSTextField *title5Label;
-@property (weak) IBOutlet NSTextField *subtitle5Label;
-@property (weak) IBOutlet NSTextField *title6Label;
-@property (weak) IBOutlet NSTextField *subtitle6Label;
-
-@property (weak) IBOutlet NSBox *preBox;
-@property (weak) IBOutlet NSBox *nextBox;
-
-@property (nonatomic, strong) KMDesignButton *preButtonVC;
-@property (nonatomic, strong) KMDesignButton *nextButtonVC;
-
-@property (weak) IBOutlet NSBox *next1Box;
-@property (weak) IBOutlet NSBox *remindMeLaterBox;
-@property (weak) IBOutlet NSBox *next2Box;
-@property (weak) IBOutlet NSBox *next3Box;
-@property (weak) IBOutlet NSBox *next4Box;
-@property (weak) IBOutlet NSBox *next5Box;
-
-@property (weak) IBOutlet NSBox *signUpBox;
-
-@property (nonatomic, strong) KMDesignButton *next1ButtonVC;
-@property (nonatomic, strong) KMDesignButton *remindMeLaterButtonVC;
-@property (nonatomic, strong) KMDesignButton *next2ButtonVC;
-@property (nonatomic, strong) KMDesignButton *next3ButtonVC;
-@property (nonatomic, strong) KMDesignButton *next4ButtonVC;
-
-@property (nonatomic, strong) KMDesignButton *signUpButtonVC;
-
-@property (weak) IBOutlet TCPageIndicator *pageIndicator1;
-@property (weak) IBOutlet TCPageIndicator *pageIndicator2;
-@property (weak) IBOutlet TCPageIndicator *pageIndicator3;
-@property (weak) IBOutlet TCPageIndicator *pageIndicator4;
-@property (weak) IBOutlet TCPageIndicator *pageIndicator5;
-@property (weak) IBOutlet TCPageIndicator *pageIndicator6;
-
-@property (nonatomic,retain) NSArray *contentViews;
-@property (nonatomic,assign) NSInteger currentIndex;
-
-@property (weak) IBOutlet NSButton *closeButton;
-@property (weak) IBOutlet KMBox *closeBox;
-
-@end
-
-@implementation WelcomeWindowController
-
-- (void)dealloc {
-#if DEBUG
-    NSLog(@"%s", __func__);
-#endif
-}
-
-+ (void)load {
-    // 处理再次提醒
-    if ([[NSUserDefaults standardUserDefaults] boolForKey:kKMWelcomeRemindMeLaterKey]) {
-        [[NSUserDefaults standardUserDefaults] setBool:NO forKey:kKMWelcomeRemindMeLaterKey];
-        [[NSUserDefaults standardUserDefaults] setBool:NO forKey:kKMWelcomeHasShowKey];
-        [[NSUserDefaults standardUserDefaults] synchronize];
-    }
-}
-
-+ (BOOL)welcomeHasShow {
-    return [[NSUserDefaults standardUserDefaults] boolForKey:kKMWelcomeHasShowKey];
-}
-
-#pragma mark Init Methods
-
-- (id)init {
-    if (self = [super initWithWindowNibName:@"WelcomeWindowController"]) {
-        windowController = self;
-    }
-    return self;
-}
-
-- (void)awakeFromNib {
-    [super awakeFromNib];
-    
-    NSClipView *clipView = self.scrollView.contentView;
-    // ,self.content4View
-    self.contentViews = @[self.content1View, self.content2View, self.content3View, self.content4View, self.content6View, self.content5View];
-    for (int i=0; i<self.contentViews.count; i++) {
-        NSView *view = self.contentViews[i];
-        view.frame = CGRectMake(i*clipView.bounds.size.width, 0,
-                                clipView.bounds.size.width,
-                                clipView.bounds.size.height);
-        [self.scrollView.documentView addSubview:view];
-    }
-    self.scrollView.documentView.frame = CGRectMake(0, 0, clipView.bounds.size.width*self.contentViews.count, clipView.bounds.size.height);
-}
-
-- (void)windowDidLoad {
-    [super windowDidLoad];
-    
-    [self localizedString];
-    [self initSubViews];
-    [self setupUI];
-    [self reloadData];
-    
-    // 设置【显示】标识
-    [[NSUserDefaults standardUserDefaults] setBool:YES forKey:kKMWelcomeHasShowKey];
-    [[NSUserDefaults standardUserDefaults] synchronize];
-}
-
-- (void)localizedString {
-//#if VERSION_DMG
-//    self.imageView1.image = [NSImage imageNamed:@"KMImageNameWelcomeHomeNew"];
-//    self.imageView2.image = [NSImage imageNamed:@"KMImageNameWelcomeAnnotation"];
-//    self.imageView3.image = [NSImage imageNamed:@"KMImageNameWelcomeEdit"];
-//    self.imageView4.image = [NSImage imageNamed:@"KMImageNameWelcomePageEdit"];
-//    self.imageView5.image = [NSImage imageNamed:@"KMImageNameWelcomeConvert"];
-//    self.imageView6.image = [NSImage imageNamed:@"KMImageNameWelcome3"];
-//
-//    self.title1Label.stringValue = NSLocalizedString(@"The Brand New PDF Master", nil);
-//    self.subtitle1Label.stringValue = NSLocalizedString(@"PDF Master Beta Invites You to Enjoy All Advanced Features!\n\nEdit, Annotate and Convert PDFs with PDF Master to boost your productivity", nil);
-//
-//    self.title2Label.stringValue = NSLocalizedString(@"Comment PDFs with Rich Annotation Tools", nil);
-//    self.subtitle2Label.stringValue = NSLocalizedString(@"Add highlights, freehand, text, stamps, links, shapes, and notes to your documents. Easily mark up your PDFs anytime!", nil);
-//
-////    self.title3Label.stringValue = NSLocalizedString(@"Convert PDF to Office Fast and Easily", nil);
-////    self.subtitle3Label.stringValue = NSLocalizedString(@"Convert PDF to editable Word, Excel, PPT, Text and image with all your fonts and formatting preserved.", nil);
-//        self.title3Label.stringValue = NSLocalizedString(@"Edit Original Text and Images Like Word", nil);
-//        self.subtitle3Label.stringValue = NSLocalizedString(@"Fix a typo or add a new text box in a PDF effortlessly. Crop, replace, rotate, flip, and export images as desired.", nil);
-//
-////    self.title4Label.stringValue = NSLocalizedString(@"Fill out Form & Sign Documents", nil);
-////    self.subtitle4Label.stringValue = NSLocalizedString(@"Fill out forms effortlessly and add text, image or handwritten signatures to PDFs.", nil);
-//        self.title4Label.stringValue = NSLocalizedString(@"Organize PDF Pages with Ease", nil);
-//        self.subtitle4Label.stringValue = NSLocalizedString(@"Drag and drop page thumbnails to rearrange pages. Or easily delete, insert, rotate, split pages.", nil);
-//
-//    self.title6Label.stringValue = NSLocalizedString(@"Convert PDF to Office Fast and Easily", nil);
-//    self.subtitle6Label.stringValue = NSLocalizedString(@"Convert PDF to editable Word, Excel, PPT, Text and image with all your fonts and formatting preserved.", nil);
-//
-//    self.title5Label.stringValue = NSLocalizedString(@"Sign up to Unlock Premium Features", nil);
-//    self.subtitle5Label.stringValue = NSLocalizedString(@"All advanced features in PDF Master can be used after registration, including converting PDFs without limitation. ", nil);
-//#else
-    self.imageView1.image = [NSImage imageNamed:@"KMImageNameWelcome1"];
-    self.imageView2.image = [NSImage imageNamed:@"KMImageNameWelcome2"];
-    self.imageView3.image = [NSImage imageNamed:@"KMImageNameWelcomeAnnotation"];
-    self.imageView4.image = [NSImage imageNamed:@"KMImageNameWelcomeEdit"];
-    self.imageView5.image = [NSImage imageNamed:@"KMImageNameWelcomePageEdit"];
-    self.imageView6.image = [NSImage imageNamed:@"KMImageNameWelcomeConvert"];
-//    self.imageView6.image = [NSImage imageNamed:@"KMImageNameWelcome3"];
-    
-    self.title1Label.stringValue = NSLocalizedString(@"The Brand New PDF Master", nil);
-    self.subtitle1Label.stringValue = NSLocalizedString(@"PDF Master Invites You to Enjoy All Advanced Features! Use the new powerful software integrated with AI technology to edit your PDFs", nil);
-    
-    self.title2Label.stringValue = NSLocalizedString(@"Process PDF Document wit AI Robot", nil);
-    self.subtitle2Label.stringValue = NSLocalizedString(@"Smart PDF AI robot, powered by Chatgpt helps you translate, rewrite, and correct PDFs with ease, bringing you an enhanced PDF experience.", nil);
-    
-    self.title3Label.stringValue = NSLocalizedString(@"Comment PDFs with Rich Annotation Tools", nil);
-    self.subtitle3Label.stringValue = NSLocalizedString(@"Add highlights, freehand, text, stamps, links, shapes, and notes to your documents. Easily mark up your PDFs anytime!", nil);
-
-    self.title4Label.stringValue = NSLocalizedString(@"Edit Original Text and Images Like Word", nil);
-    self.subtitle4Label.stringValue = NSLocalizedString(@"Fix a typo or add a new text box in a PDF effortlessly. Crop, replace, rotate, flip, and export images as desired.", nil);
-    
-    self.title6Label.stringValue = NSLocalizedString(@"Organize PDF Pages with Ease", nil);
-    self.subtitle6Label.stringValue = NSLocalizedString(@"Drag and drop page thumbnails to rearrange pages. Or easily delete, insert, rotate, split pages.", nil);
-    
-    self.title5Label.stringValue = NSLocalizedString(@"Convert PDF to Office Fast and Easily", nil);
-    self.subtitle5Label.stringValue = NSLocalizedString(@"Convert PDF to editable Word, Excel, PPT, Text and image with all your fonts and formatting preserved.", nil);
-    
-//    self.title5Label.stringValue = NSLocalizedString(@"Sign up to Unlock Premium Features", nil);
-//    self.subtitle5Label.stringValue = NSLocalizedString(@"All advanced features in PDF Master can be used after registration.", nil);
-//#endif
-}
-
-- (void)initSubViews {
-    self.preBox.borderType = NSNoBorder;
-    self.preButtonVC = [[KMDesignButton alloc] initWithType:DesignButtonTypeImage];
-    [self.preBox.contentView addSubview:self.preButtonVC.view];
-    self.preButtonVC.view.frame = self.preBox.contentView.bounds;
-    self.preButtonVC.view.autoresizingMask = NSViewWidthSizable | NSViewHeightSizable;
-    self.preButtonVC.image = [NSImage imageNamed:@"KMImageNamePreviousPageImage"];
-    [self.preButtonVC pagination];
-    self.preButtonVC.target = self;
-    self.preButtonVC.action = @selector(previousButtonAction:);
-    
-    self.nextBox.borderType = NSNoBorder;
-    self.nextButtonVC = [[KMDesignButton alloc] initWithType:DesignButtonTypeImage];
-    [self.nextBox.contentView addSubview:self.nextButtonVC.view];
-    self.nextButtonVC.view.frame = self.nextBox.contentView.bounds;
-    self.nextButtonVC.view.autoresizingMask = NSViewWidthSizable | NSViewHeightSizable;
-    self.nextButtonVC.image = [NSImage imageNamed:@"KMImageNameNextPageImage"];
-    [self.nextButtonVC pagination];
-    self.nextButtonVC.target = self;
-    self.nextButtonVC.action = @selector(nextButtonAction:);
-    
-    for (NSBox *box in @[self.next1Box, self.next2Box, self.next3Box, self.next4Box, self.next5Box]) {
-        box.borderType = NSNoBorder;
-        KMDesignButton *nextButtonVC = [[KMDesignButton alloc] initWithType:DesignButtonTypeText];
-        [box.contentView addSubview:nextButtonVC.view];
-        nextButtonVC.view.frame = box.contentView.bounds;
-        nextButtonVC.view.autoresizingMask = NSViewWidthSizable | NSViewHeightSizable;
-//        nextButtonVC.stringValue = NSLocalizedString(@"Next", nil);
-        if (KMLightMemberManager.manager.isLogin) { // let’s start
-            nextButtonVC.stringValue = NSLocalizedString(@"Let's Start", nil);
-        } else {
-            nextButtonVC.stringValue = NSLocalizedString(@"Sign up", nil);
-        }
-        nextButtonVC.target = self;
-//        nextButtonVC.action = @selector(nextButtonAction:);
-        nextButtonVC.action = @selector(signUpButtonAction:);
-        
-        [nextButtonVC buttonWithType:TokenButtonTypeCta size:TokenButtonSizeL height:[[NSLayoutConstraint alloc] init]];
-        
-        if ([box isEqual:self.next1Box]) {
-            self.next1ButtonVC = nextButtonVC;
-        } else if ([box isEqual:self.next2Box]) {
-            self.next2ButtonVC = nextButtonVC;
-        } else if ([box isEqual:self.next3Box]) {
-            self.next3ButtonVC = nextButtonVC;
-        } else if ([box isEqual:self.next4Box]) {
-            self.next4ButtonVC = nextButtonVC;
-        } else if ([box isEqual:self.next5Box]) {
-//            self.next5
-        }
-    }
-    
-    self.remindMeLaterBox.borderType = NSNoBorder;
-    self.remindMeLaterButtonVC = [[KMDesignButton alloc] initWithType:DesignButtonTypeText];
-    [self.remindMeLaterBox.contentView addSubview:self.remindMeLaterButtonVC.view];
-    self.remindMeLaterButtonVC.view.frame = self.remindMeLaterBox.contentView.bounds;
-    self.remindMeLaterButtonVC.view.autoresizingMask = NSViewWidthSizable | NSViewHeightSizable;
-    self.remindMeLaterButtonVC.stringValue = NSLocalizedString(@"Remind Me Later", nil);
-    self.remindMeLaterButtonVC.target = self;
-    self.remindMeLaterButtonVC.action = @selector(remindMeLaterButtonAction:);
-    // TokenButtonTypeLink
-    [self.remindMeLaterButtonVC buttonWithType:TokenButtonTypeText size:TokenButtonSizeM height:[[NSLayoutConstraint alloc] init]];
-    
-    self.signUpBox.borderType = NSNoBorder;
-    self.signUpButtonVC = [[KMDesignButton alloc] initWithType:DesignButtonTypeText];
-    [self.signUpBox.contentView addSubview:self.signUpButtonVC.view];
-    self.signUpButtonVC.view.frame = self.signUpBox.contentView.bounds;
-    self.signUpButtonVC.view.autoresizingMask = NSViewWidthSizable | NSViewHeightSizable;
-    if (KMLightMemberManager.manager.isLogin) { // let’s start
-        self.signUpButtonVC.stringValue = NSLocalizedString(@"Let's Start", nil);
-    } else {
-        self.signUpButtonVC.stringValue = NSLocalizedString(@"Sign up", nil);
-    }
-    
-    self.signUpButtonVC.target = self;
-    self.signUpButtonVC.action = @selector(signUpButtonAction:);
-    [self.signUpButtonVC buttonWithType:TokenButtonTypeCta size:TokenButtonSizeL height:[[NSLayoutConstraint alloc] init]];
-    
-    // , self.pageIndicator5
-    for (TCPageIndicator *pageindicator in @[self.pageIndicator1, self.pageIndicator2, self.pageIndicator3, self.pageIndicator4, self.pageIndicator5, self.pageIndicator6]) {
-        pageindicator.numberOfPages = 6;
-        pageindicator.selectedColor = [NSColor colorWithRed:39/255.f green:60/255.f blue:98/255.f alpha:1.f];
-        pageindicator.normalColor = [NSColor colorWithRed:0/255.f green:0/255.f blue:0/255.f alpha:0.2];
-        pageindicator.pageIndicatorSize = NSMakeSize(6, 6);
-        pageindicator.enabled = NO;
-        
-        if ([pageindicator isEqual:self.pageIndicator1]) {
-            pageindicator.currentPage = 0;
-        } else if ([pageindicator isEqual:self.pageIndicator2]) {
-            pageindicator.currentPage = 1;
-        } else if ([pageindicator isEqual:self.pageIndicator3]) {
-            pageindicator.currentPage = 2;
-        } else if ([pageindicator isEqual:self.pageIndicator4]) {
-            pageindicator.currentPage = 3;
-        } else if ([pageindicator isEqual:self.pageIndicator5]) {
-            pageindicator.currentPage = 5;
-        } else if ([pageindicator isEqual:self.pageIndicator6]) {
-            pageindicator.currentPage = 4;
-        }
-    }
-    
-    __weak typeof(self)weakSelf = self;
-    self.closeBox.moveCallback = ^(BOOL mouseEntered, KMBox *mouseBox) {
-        if (mouseEntered) {
-            weakSelf.closeButton.image = [NSImage imageNamed:@"control_btn_icon_close_hov"];
-        } else {
-            weakSelf.closeButton.image = [NSImage imageNamed:@"control_btn_icon_close"];
-        }
-    };
-    
-    for (NSView *view in self.contentViews) {
-        NSTextField *label = [NSTextField labelWithString:NSLocalizedString(@"Sign up to Unlock Premium Features", nil)];
-        [view addSubview:label];
-        label.frame = NSMakeRect(0, 14, NSWidth(view.frame), 18);
-        label.alignment = NSTextAlignmentCenter;
-        label.font = [NSFont fontWithName:@"SFProText-Regular" size:14];
-        label.textColor = [NSColor colorWithRed:23/255.f green:112/255.f blue:244/255.f alpha:1.f];
-        
-        if (KMLightMemberManager.manager.isLogin) {
-            label.hidden = YES;
-        } else {
-            label.hidden = NO;
-        }
-    }
-    self.remindMeLaterBox.hidden = YES;
-}
-
-- (void)setupUI {
-    for (NSTextField *titleLabel in @[self.title1Label, self.title2Label, self.title3Label,
-                                      self.title4Label, self.title6Label, self.title5Label]) {
-        titleLabel.font = [NSFont fontWithName:@"SFProText-Semibold" size:20];
-        titleLabel.textColor = [NSColor colorWithRed:37/255.f green:38/255.f blue:41/255.f alpha:1.f];
-    }
-    
-    NSMutableParagraphStyle *ps = [[NSMutableParagraphStyle alloc] init];
-    ps.lineSpacing = 6;
-    ps.alignment = NSTextAlignmentCenter;
-    for (NSTextField *subtitleLabel in @[self.subtitle1Label, self.subtitle2Label, self.subtitle3Label,
-                                      self.subtitle4Label, self.subtitle6Label, self.subtitle5Label]) {
-//        if ([subtitleLabel isEqual:self.subtitle1Label]) {
-//            NSMutableParagraphStyle *ps_ = [[NSMutableParagraphStyle alloc] init];
-//            ps_.lineSpacing = 6;
-//            ps_.alignment = NSTextAlignmentCenter;
-//            subtitleLabel.attributedStringValue = [[NSAttributedString alloc] initWithString:subtitleLabel.stringValue attributes:@{
-//                NSFontAttributeName : [NSFont fontWithName:@"SFProText-Regular" size:14],
-//                NSForegroundColorAttributeName : [NSColor colorWithRed:97/255.f green:100/255.f blue:105/255.f alpha:1.f],
-//                NSParagraphStyleAttributeName : ps_
-//            }];
-//        } else {
-            subtitleLabel.attributedStringValue = [[NSAttributedString alloc] initWithString:subtitleLabel.stringValue attributes:@{
-                NSFontAttributeName : [NSFont fontWithName:@"SFProText-Regular" size:14],
-                NSForegroundColorAttributeName : [NSColor colorWithRed:97/255.f green:100/255.f blue:105/255.f alpha:1.f],
-                NSParagraphStyleAttributeName : ps
-            }];
-//        }
-    }
-}
-
-- (void)close {
-    windowController = nil;
-    
-    [super close];
-}
-
-#pragma mark Private Methods
-
-- (void)reloadData {
-    self.preBox.hidden = NO;
-    self.nextBox.hidden = NO;
-    
-    if (self.currentIndex == 0) {
-        self.preBox.hidden = YES;
-    } else if (self.currentIndex == 1) {
-    } else if (self.currentIndex == 2) {
-//        self.nextBox.hidden = YES;
-    } else if (self.currentIndex == 3) {
-    } else if (self.currentIndex == 4){
-        
-    } else if (self.currentIndex == 5) {
-        self.nextBox.hidden = YES;
-    }
-}
-
-#pragma mark Button Actions
-
-- (IBAction)previousButtonAction:(id)sender {
-    if (self.currentIndex <= 0) {
-        return;
-    }
-    self.currentIndex--;
-    [NSAnimationContext beginGrouping];
-    NSClipView *clipView = [self.scrollView contentView];
-    NSPoint newOrigin = [clipView bounds].origin;
-    newOrigin.x = clipView.bounds.size.width*self.currentIndex;
-    [[clipView animator] setBoundsOrigin:newOrigin];
-    [NSAnimationContext endGrouping];
-    
-    [self reloadData];
-}
-
-- (IBAction)nextButtonAction:(id)sender {
-    if (self.currentIndex >= self.contentViews.count-1) {
-        return;
-    }
-    self.currentIndex++;
-    [NSAnimationContext beginGrouping];
-    NSClipView *clipView = [self.scrollView contentView];
-    NSPoint newOrigin = [clipView bounds].origin;
-    newOrigin.x = clipView.bounds.size.width*self.currentIndex;
-    [[clipView animator] setBoundsOrigin:newOrigin];
-    [NSAnimationContext endGrouping];
-    
-    [self reloadData];
-}
-
-- (IBAction)closeAction:(id)sender {
-    if (self.itemClick) {
-        self.itemClick(1, self);
-    }
-    [self close];
-}
-
-- (void)signUpButtonAction:(NSButton *)sender {
-    if (KMLightMemberManager.manager.isLogin) {
-        [self closeAction:sender];
-    } else {
-        if (self.itemClick) {
-            self.itemClick(3, self);
-        }
-        [self close];
-    }
-}
-
-- (void)remindMeLaterButtonAction:(NSButton *)sender {
-    [[NSUserDefaults standardUserDefaults] setBool:YES forKey:kKMWelcomeRemindMeLaterKey];
-    [[NSUserDefaults standardUserDefaults] synchronize];
-    
-    if (self.itemClick) {
-        self.itemClick(2, self);
-    }
-    [self close];
-}
-
-@end

PDF Office/PDF Master/Class/Welcome/OC/WelcomeWindowController.xib → PDF Office/PDF Master/Class/Welcome/WelcomeWindowController.xib


+ 0 - 1
PDF Office/PDF Master/PDF_Master DMG-Bridging-Header.h

@@ -57,7 +57,6 @@
 #import "SKKeychain.h"
 #import "CSelfSignAnnotationFreeText.h"
 #import "CSelfSignAnnotation.h"
-#import "WelcomeWindowController.h"
 //广告
 #import "KMRecommondManager.h"
 #import "CPDFListView+Extension.h"

+ 0 - 1
PDF Office/PDF Master/PDF_Master Pro-Bridging-Header.h

@@ -38,7 +38,6 @@
 #import "KMEmailSubWindowController.h"
 #import "SKInfoWindowController.h"
 #import "SKKeychain.h"
-#import "WelcomeWindowController.h"
 //广告
 #import "KMRecommondManager.h"
 #import "CPDFListView+Extension.h"

+ 0 - 1
PDF Office/PDF Master/PDF_Master-Bridging-Header.h

@@ -55,7 +55,6 @@
 #import "SKKeychain.h"
 #import "CSelfSignAnnotationFreeText.h"
 #import "CSelfSignAnnotation.h"
-#import "WelcomeWindowController.h"
 //广告
 #import "KMRecommondManager.h"
 #import "CPDFListView+Extension.h"