Bladeren bron

工具栏 - 本地缓存数据

chenrongqian 2 jaren geleden
bovenliggende
commit
50bd89c72f

+ 8 - 8
PDF Office/Helper/SettingHelper.cs

@@ -146,14 +146,14 @@ namespace PDF_Office.Helper
 
         public static DefaultAnnotProperty GetAnnotDefaultProperty(AnnotArgsType annotToolType,string saveKey="")
         {
-            //if (Settings.Default.DefautAnnotProperties != null)
-            //{
-            //    if(saveKey=="")
-            //    {
-            //        return Settings.Default.DefautAnnotProperties.GetAnnotProperty(annotToolType);
-            //    }
-            //    return Settings.Default.DefautAnnotProperties.GetAnnotProperty(annotToolType,saveKey);
-            //}
+            if (Settings.Default.DefautAnnotProperties != null)
+            {
+                if (saveKey == "")
+                {
+                    return Settings.Default.DefautAnnotProperties.GetAnnotProperty(annotToolType);
+                }
+                return Settings.Default.DefautAnnotProperties.GetAnnotProperty(annotToolType, saveKey);
+            }
             return null;
         }
 

+ 11 - 0
PDF Office/Properties/Settings.Designer.cs

@@ -33,5 +33,16 @@ namespace PDF_Office.Properties {
                 this["RecentOpenFiles"] = value;
             }
         }
+        
+        [global::System.Configuration.UserScopedSettingAttribute()]
+        [global::System.Diagnostics.DebuggerNonUserCodeAttribute()]
+        public global::PDFSettings.DefaultAnnotProperties DefautAnnotProperties {
+            get {
+                return ((global::PDFSettings.DefaultAnnotProperties)(this["DefautAnnotProperties"]));
+            }
+            set {
+                this["DefautAnnotProperties"] = value;
+            }
+        }
     }
 }

+ 3 - 0
PDF Office/Properties/Settings.settings

@@ -5,5 +5,8 @@
     <Setting Name="RecentOpenFiles" Type="PDFSettings.Settings.RecentOpenFiles" Scope="User">
       <Value Profile="(Default)" />
     </Setting>
+    <Setting Name="DefautAnnotProperties" Type="PDFSettings.DefaultAnnotProperties" Scope="User">
+      <Value Profile="(Default)" />
+    </Setting>
   </Settings>
 </SettingsFile>