瀏覽代碼

add new option

marinofaggiana 4 年之前
父節點
當前提交
3318dd3fcc

+ 2 - 0
iOSClient/Supporting Files/en.lproj/Localizable.strings

@@ -143,6 +143,8 @@
 "_leave_share_"             = "Leave this share";
 "_delete_file_"             = "Delete file";
 "_delete_folder_"           = "Delete folder";
+"_automatic_Download_Image_" = "Use images in full resolution";
+"_automatic_Download_Image_footer_" = "When viewing images always download, if not available locally, the images in full resolution";
 
 // App
 

+ 3 - 0
iOSClient/Utility/CCUtility.h

@@ -176,6 +176,9 @@
 + (BOOL)getAudioMute;
 + (void)setAudioMute:(BOOL)set;
 
++ (BOOL)getAutomaticDownloadImage;
++ (void)setAutomaticDownloadImage:(BOOL)set;
+
 // ===== Varius =====
 
 + (BOOL)addSkipBackupAttributeToItemAtURL:(NSURL *)URL;

+ 12 - 0
iOSClient/Utility/CCUtility.m

@@ -718,6 +718,18 @@
     [UICKeyChainStore setString:sSet forKey:@"audioMute" service:k_serviceShareKeyChain];
 }
 
++ (BOOL)getAutomaticDownloadImage
+{
+    return [[UICKeyChainStore stringForKey:@"automaticDownloadImage" service:k_serviceShareKeyChain] boolValue];
+}
+
++ (void)setAutomaticDownloadImage:(BOOL)set
+{
+    NSString *sSet = (set) ? @"true" : @"false";
+    [UICKeyChainStore setString:sSet forKey:@"automaticDownloadImage" service:k_serviceShareKeyChain];
+}
+
+
 #pragma --------------------------------------------------------------------------------------------
 #pragma mark ===== Various =====
 #pragma --------------------------------------------------------------------------------------------