Browse Source

【综合】偏好设置去除数据绑定逻辑部分的警告

tangchao 1 year ago
parent
commit
f6c7496c59

+ 0 - 48
PDF Office/PDF Master.xcodeproj/xcuserdata/kdanmobile.xcuserdatad/xcdebugger/Breakpoints_v2.xcbkptlist

@@ -260,54 +260,6 @@
             landmarkType = "24">
          </BreakpointContent>
       </BreakpointProxy>
-      <BreakpointProxy
-         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
-         <BreakpointContent
-            uuid = "18BC04BD-79B8-4D17-A2A7-FA67455C311C"
-            shouldBeEnabled = "Yes"
-            ignoreCount = "0"
-            continueAfterRunningActions = "No"
-            filePath = "PDF Master/Class/Common/LineInspector/KMLineInspector.swift"
-            startingColumnNumber = "9223372036854775807"
-            endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "485"
-            endingLineNumber = "485"
-            landmarkName = "_notifyChangeAction(_:)"
-            landmarkType = "7">
-         </BreakpointContent>
-      </BreakpointProxy>
-      <BreakpointProxy
-         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
-         <BreakpointContent
-            uuid = "E31C6AD2-E0CF-41A8-924A-1F55DE9B2D6D"
-            shouldBeEnabled = "Yes"
-            ignoreCount = "0"
-            continueAfterRunningActions = "No"
-            filePath = "PDF Master/Class/Common/LineInspector/KMLineInspector.swift"
-            startingColumnNumber = "9223372036854775807"
-            endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "107"
-            endingLineNumber = "107"
-            landmarkName = "endLineStyle"
-            landmarkType = "24">
-         </BreakpointContent>
-      </BreakpointProxy>
-      <BreakpointProxy
-         BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
-         <BreakpointContent
-            uuid = "2FAEF8D2-4499-4F99-A543-525C4361AA47"
-            shouldBeEnabled = "Yes"
-            ignoreCount = "0"
-            continueAfterRunningActions = "No"
-            filePath = "PDF Master/Class/Common/LineInspector/KMLineInspector.swift"
-            startingColumnNumber = "9223372036854775807"
-            endingColumnNumber = "9223372036854775807"
-            startingLineNumber = "94"
-            endingLineNumber = "94"
-            landmarkName = "startLineStyle"
-            landmarkType = "24">
-         </BreakpointContent>
-      </BreakpointProxy>
       <BreakpointProxy
          BreakpointExtensionID = "Xcode.Breakpoint.FileBreakpoint">
          <BreakpointContent

+ 1 - 1
PDF Office/PDF Master/Class/Analytics/KMAnalytics.swift

@@ -85,7 +85,7 @@ extension KMAnalytics.Parameter {
  #endif
 #endif
         
-        FirebaseApp.configure()
+//        FirebaseApp.configure()
 //        Analytics.logEvent(AnalyticsEventSignUp, parameters: [
 //            AnalyticsParameterMethod: "method"
 //        ])

+ 2 - 2
PDF Office/PDF Master/Class/PDFWindowController/Toolbar/KMToolbarView.swift

@@ -520,8 +520,8 @@ private let KMToolbarItemSpace = 8.0
         let leftW = NSWidth(self.leftView.frame)
         let contentW = NSWidth(self.contentView.frame)
         let rightW = NSWidth(self.rightView.frame)
-        KMPrint("width: \(leftW), \(contentW), \(rightW)")
-        KMPrint("\(self.frame.size.width)")
+//        KMPrint("width: \(leftW), \(contentW), \(rightW)")
+//        KMPrint("\(self.frame.size.width)")
         
         let contentLength = leftW + contentW + rightW
 //        if (contentLength <= 0) {

+ 4 - 29
PDF Office/PDF Master/Class/Preference/Controller/DisplayPreferences.xib

@@ -52,7 +52,6 @@
                     <connections>
                         <accessibilityConnection property="link" destination="5" id="104"/>
                         <accessibilityConnection property="title" destination="2" id="52"/>
-                        <binding destination="61" name="value" keyPath="values.SKThumbnailSize" id="62"/>
                     </connections>
                 </slider>
                 <textField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="4">
@@ -72,7 +71,6 @@
                     </sliderCell>
                     <connections>
                         <accessibilityConnection property="title" destination="4" id="57"/>
-                        <binding destination="61" name="value" keyPath="values.SKSnapshotThumbnailSize" id="63"/>
                     </connections>
                 </slider>
                 <button toolTip="Restrict thumbnail sizes to discrete values" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="6">
@@ -108,9 +106,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="61" name="value" keyPath="values.SKShouldAntiAlias" id="68"/>
-                    </connections>
                 </button>
                 <textField toolTip="Don't render characters smaller than this size" verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="10">
                     <rect key="frame" x="164" y="188" width="53" height="22"/>
@@ -129,7 +124,6 @@
                     </textFieldCell>
                     <connections>
                         <accessibilityConnection property="title" destination="11" id="54"/>
-                        <binding destination="61" name="value" keyPath="values.SKGreekingThreshold" id="67"/>
                     </connections>
                 </textField>
                 <textField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="11">
@@ -184,11 +178,6 @@
                     <connections>
                         <accessibilityConnection property="link" destination="17" id="107"/>
                         <accessibilityConnection property="title" destination="14" id="59"/>
-                        <binding destination="61" name="value" keyPath="values.SKBackgroundColor" id="76">
-                            <dictionary key="options">
-                                <string key="NSValueTransformerName">NSUnarchiveFromData</string>
-                            </dictionary>
-                        </binding>
                         <outlet property="nextKeyView" destination="17" id="51"/>
                     </connections>
                 </colorWell>
@@ -198,11 +187,6 @@
                     <color key="color" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="calibratedRGB"/>
                     <connections>
                         <accessibilityConnection property="title" destination="15" id="53"/>
-                        <binding destination="61" name="value" keyPath="values.SKFullScreenBackgroundColor" id="75">
-                            <dictionary key="options">
-                                <string key="NSValueTransformerName">NSUnarchiveFromData</string>
-                            </dictionary>
-                        </binding>
                     </connections>
                 </colorWell>
                 <box verticalHuggingPriority="750" fixedFrame="YES" boxType="separator" translatesAutoresizingMaskIntoConstraints="NO" id="20">
@@ -225,11 +209,6 @@
                     <connections>
                         <accessibilityConnection property="link" destination="24" id="102"/>
                         <accessibilityConnection property="title" destination="25" id="55"/>
-                        <binding destination="61" name="value" keyPath="values.SKReadingBarColor" id="79">
-                            <dictionary key="options">
-                                <string key="NSValueTransformerName">NSUnarchiveFromData</string>
-                            </dictionary>
-                        </binding>
                     </connections>
                 </colorWell>
                 <button toolTip="Select to mask the text outside the reading bar" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="24">
@@ -239,9 +218,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="61" name="value" keyPath="values.SKReadingBarInvert" id="80"/>
-                    </connections>
                 </button>
                 <textField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="25">
                     <rect key="frame" x="41" y="24" width="43" height="17"/>
@@ -286,16 +262,15 @@
                     </comboBoxCell>
                     <connections>
                         <accessibilityConnection property="title" destination="28" id="58"/>
-                        <binding destination="61" name="value" keyPath="values.SKTableFontSize" id="Ab9-ya-Ccs"/>
                     </connections>
                 </comboBox>
             </subviews>
             <point key="canvasLocation" x="-3" y="154"/>
         </customView>
         <userDefaultsController representsSharedInstance="YES" id="61"/>
-        <customObject id="108" userLabel="Thumbnail Size Labels" customClass="SKIBArray"/>
-        <customObject id="109" userLabel="Thumbnail Size Controls" customClass="SKIBArray"/>
-        <customObject id="117" userLabel="Color Labels" customClass="SKIBArray"/>
-        <customObject id="121" userLabel="Color Controls" customClass="SKIBArray"/>
+        <customObject id="108" userLabel="Thumbnail Size Labels"/>
+        <customObject id="109" userLabel="Thumbnail Size Controls"/>
+        <customObject id="117" userLabel="Color Labels"/>
+        <customObject id="121" userLabel="Color Controls"/>
     </objects>
 </document>

+ 1 - 23
PDF Office/PDF Master/Class/Preference/Controller/GeneralPreferences.xib

@@ -80,7 +80,6 @@
                     </popUpButtonCell>
                     <connections>
                         <action selector="openTabButtonAction:" target="-2" id="qcO-3g-kjv"/>
-                        <binding destination="58" name="selectedIndex" keyPath="values.KMOpenDocumentInTab" id="yEa-o8-oxx"/>
                     </connections>
                 </popUpButton>
                 <button fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="AVa-Al-8gG">
@@ -112,9 +111,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="58" name="value" keyPath="values.SKReopenLastOpenFiles" id="60"/>
-                    </connections>
                 </button>
                 <button toolTip="Remember and reopen files from a previous run" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="cFS-gz-76C">
                     <rect key="frame" x="18" y="468" width="344" height="18"/>
@@ -186,9 +182,6 @@
                             </buttonCell>
                         </column>
                     </cells>
-                    <connections>
-                        <binding destination="58" name="selectedTag" keyPath="values.SKInitialWindowSizeOption" id="62"/>
-                    </connections>
                 </matrix>
                 <button toolTip="Open the contents pane only when the file has outline" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="3">
                     <rect key="frame" x="18" y="333" width="344" height="18"/>
@@ -197,9 +190,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="58" name="value" keyPath="values.SKOpenContentsPaneOnlyForTOC" id="63"/>
-                    </connections>
                 </button>
                 <button toolTip="Reopen the last viewed snapshots when opening a file" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="18">
                     <rect key="frame" x="18" y="313" width="344" height="18"/>
@@ -208,9 +198,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="58" name="value" keyPath="values.SKRememberSnapshots" id="65"/>
-                    </connections>
                 </button>
                 <textField verticalHuggingPriority="750" fixedFrame="YES" translatesAutoresizingMaskIntoConstraints="NO" id="15">
                     <rect key="frame" x="17" y="290" width="346" height="17"/>
@@ -260,9 +247,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="58" name="value" keyPath="values.SKAutoSaveSkimNotes" id="66"/>
-                    </connections>
                 </button>
                 <button toolTip="Always keep snapshot windows on top of other windows" fixedFrame="YES" imageHugsTitle="YES" translatesAutoresizingMaskIntoConstraints="NO" id="4">
                     <rect key="frame" x="18" y="139" width="344" height="18"/>
@@ -271,9 +255,6 @@
                         <behavior key="behavior" changeContents="YES" doesNotDimImage="YES" lightByContents="YES"/>
                         <font key="font" metaFont="system"/>
                     </buttonCell>
-                    <connections>
-                        <binding destination="58" name="value" keyPath="values.SKSnapshotsOnTop" id="68"/>
-                    </connections>
                 </button>
                 <box hidden="YES" verticalHuggingPriority="750" fixedFrame="YES" boxType="separator" translatesAutoresizingMaskIntoConstraints="NO" id="6">
                     <rect key="frame" x="12" y="123" width="356" height="5"/>
@@ -368,9 +349,6 @@
                             </buttonCell>
                         </column>
                     </cells>
-                    <connections>
-                        <binding destination="58" name="selectedTag" keyPath="values.SKSavePasswordOption" id="69"/>
-                    </connections>
                 </matrix>
             </subviews>
             <constraints>
@@ -383,6 +361,6 @@
             <point key="canvasLocation" x="117" y="78.5"/>
         </customView>
         <userDefaultsController representsSharedInstance="YES" id="58"/>
-        <customObject id="80" userLabel="Revert PDF Display Buttons" customClass="SKIBArray"/>
+        <customObject id="80" userLabel="Revert PDF Display Buttons"/>
     </objects>
 </document>

+ 4 - 5
PDF Office/PDF Master/Class/Preference/Controller/KMDisplayPreferences.swift

@@ -40,6 +40,8 @@ import Cocoa
      - (NSNumber *)objectInSizesAtIndex:(NSUInteger)anIndex;
      */
     
+    let SKDefaultFontSizes: [CGFloat] = [8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 16.0, 18.0, 20.0, 24.0, 28.0, 32.0, 48.0, 64.0]
+    
     override var nibName: NSNib.Name? {
         return "DisplayPreferences"
     }
@@ -80,6 +82,8 @@ import Cocoa
     override func viewDidLoad() {
         super.viewDidLoad()
         // Do view setup here.
+        
+        self.tableFontComboBox.addItems(withObjectValues: SKDefaultFontSizes)
     }
     
     override var title: String? {
@@ -114,11 +118,6 @@ import Cocoa
     }
     
     /*
-     static CGFloat SKDefaultFontSizes[] = {8.0, 9.0, 10.0, 11.0, 12.0, 13.0, 14.0, 16.0, 18.0, 20.0, 24.0, 28.0, 32.0, 48.0, 64.0};
-
-     #pragma mark Accessors
-
-
      - (NSUInteger)countOfSizes {
          return sizeof(SKDefaultFontSizes) / sizeof(CGFloat);
      }

+ 10 - 71
PDF Office/PDF Master/Class/Preference/Controller/NotesPreferences.xib

@@ -8,20 +8,11 @@
     <objects>
         <customObject id="-2" userLabel="File's Owner" customClass="KMNotesPreferences" customModule="PDF_Master" customModuleProvider="target">
             <connections>
-                <outlet property="colorLabels2" destination="170" id="174"/>
-                <outlet property="colorLabels3" destination="171" id="175"/>
-                <outlet property="colorWells1" destination="203" id="246"/>
-                <outlet property="colorWells2" destination="204" id="247"/>
-                <outlet property="colorWells3" destination="205" id="248"/>
                 <outlet property="fontWell1" destination="41" id="TmV-5P-zGD"/>
                 <outlet property="fontWell2" destination="42" id="mTG-QM-jMN"/>
-                <outlet property="labels1" destination="179" id="256"/>
-                <outlet property="lineLabels2" destination="177" id="178"/>
-                <outlet property="lineWells1" destination="207" id="250"/>
                 <outlet property="lineWells1_1" destination="23" id="GeP-cl-1jV"/>
                 <outlet property="lineWells1_2" destination="25" id="gkJ-Ks-DdN"/>
                 <outlet property="lineWells1_3" destination="27" id="yhh-8h-4M1"/>
-                <outlet property="lineWells2" destination="208" id="251"/>
                 <outlet property="lineWells2_1" destination="29" id="NPy-Xh-Hpp"/>
                 <outlet property="lineWells2_2" destination="31" id="F2f-7g-oY9"/>
                 <outlet property="view" destination="1" id="112"/>
@@ -491,68 +482,16 @@
             <point key="canvasLocation" x="139" y="154"/>
         </customView>
         <userDefaultsController representsSharedInstance="YES" id="84"/>
-        <customObject id="179" userLabel="Labels 1" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="3" id="185"/>
-                <outlet property="object2" destination="5" id="186"/>
-                <outlet property="object3" destination="22" id="187"/>
-                <outlet property="object4" destination="263" id="268"/>
-                <outlet property="object5" destination="39" id="257"/>
-                <outlet property="object6" destination="40" id="258"/>
-                <outlet property="object7" destination="24" id="259"/>
-                <outlet property="object8" destination="26" id="260"/>
-                <outlet property="object9" destination="28" id="261"/>
-            </connections>
-        </customObject>
-        <customObject id="170" userLabel="Color Labels 2" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="7" id="189"/>
-                <outlet property="object2" destination="36" id="190"/>
-                <outlet property="object3" destination="9" id="191"/>
-                <outlet property="object4" destination="38" id="192"/>
-            </connections>
-        </customObject>
-        <customObject id="171" userLabel="Color Labels 3" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="11" id="236"/>
-                <outlet property="object2" destination="13" id="237"/>
-                <outlet property="object3" destination="15" id="238"/>
-                <outlet property="object4" destination="17" id="269"/>
-            </connections>
-        </customObject>
-        <customObject id="177" userLabel="Line Labels 2" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="30" id="198"/>
-                <outlet property="object2" destination="32" id="199"/>
-            </connections>
-        </customObject>
-        <customObject id="203" userLabel="Color Wells 1" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="2" id="225"/>
-                <outlet property="object2" destination="4" id="252"/>
-                <outlet property="object3" destination="21" id="253"/>
-                <outlet property="object4" destination="262" id="270"/>
-            </connections>
-        </customObject>
-        <customObject id="204" userLabel="Color Wells 2" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="6" id="229"/>
-                <outlet property="object2" destination="35" id="230"/>
-                <outlet property="object3" destination="8" id="231"/>
-                <outlet property="object4" destination="37" id="232"/>
-            </connections>
-        </customObject>
-        <customObject id="205" userLabel="Color Wells 3" customClass="SKIBArray">
-            <connections>
-                <outlet property="object1" destination="10" id="233"/>
-                <outlet property="object2" destination="12" id="234"/>
-                <outlet property="object3" destination="14" id="235"/>
-                <outlet property="object4" destination="16" id="271"/>
-            </connections>
-        </customObject>
-        <customObject id="206" userLabel="Font Wells" customClass="SKIBArray" customModule="PDF_Master" customModuleProvider="target"/>
-        <customObject id="207" userLabel="Line Wells 1" customClass="SKIBArray"/>
-        <customObject id="208" userLabel="Line Wells 2" customClass="SKIBArray"/>
+        <customObject id="179" userLabel="Labels 1"/>
+        <customObject id="170" userLabel="Color Labels 2"/>
+        <customObject id="171" userLabel="Color Labels 3"/>
+        <customObject id="177" userLabel="Line Labels 2"/>
+        <customObject id="203" userLabel="Color Wells 1"/>
+        <customObject id="204" userLabel="Color Wells 2"/>
+        <customObject id="205" userLabel="Color Wells 3"/>
+        <customObject id="206" userLabel="Font Wells"/>
+        <customObject id="207" userLabel="Line Wells 1"/>
+        <customObject id="208" userLabel="Line Wells 2"/>
     </objects>
     <resources>
         <image name="TextAlignCenter" width="128" height="128"/>

+ 1 - 7
PDF Office/PDF Master/Class/Preference/Window/PreferenceWindow.xib

@@ -8,7 +8,6 @@
     <objects>
         <customObject id="-2" userLabel="File's Owner" customClass="KMPreferenceController" customModule="PDF_Master" customModuleProvider="target">
             <connections>
-                <outlet property="resetButtons" destination="1657" id="1658"/>
                 <outlet property="window" destination="5" id="7"/>
             </connections>
         </customObject>
@@ -54,11 +53,6 @@
             </connections>
             <point key="canvasLocation" x="-273" y="-27"/>
         </window>
-        <customObject id="1657" userLabel="Reset Buttons" customClass="SKIBArray" customModule="PDF_Master" customModuleProvider="target">
-            <connections>
-                <outlet property="object1" destination="492" id="1659"/>
-                <outlet property="object2" destination="491" id="1660"/>
-            </connections>
-        </customObject>
+        <customObject id="1657" userLabel="Reset Buttons"/>
     </objects>
 </document>