NCSettings.m 20 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445
  1. //
  2. // NCSettings.m
  3. // Nextcloud
  4. //
  5. // Created by Marino Faggiana on 24/11/14.
  6. // Copyright (c) 2014 Marino Faggiana. All rights reserved.
  7. //
  8. // Author Marino Faggiana <marino.faggiana@nextcloud.com>
  9. //
  10. // This program is free software: you can redistribute it and/or modify
  11. // it under the terms of the GNU General Public License as published by
  12. // the Free Software Foundation, either version 3 of the License, or
  13. // (at your option) any later version.
  14. //
  15. // This program is distributed in the hope that it will be useful,
  16. // but WITHOUT ANY WARRANTY; without even the implied warranty of
  17. // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  18. // GNU General Public License for more details.
  19. //
  20. // You should have received a copy of the GNU General Public License
  21. // along with this program. If not, see <http://www.gnu.org/licenses/>.
  22. //
  23. #import "NCSettings.h"
  24. #import "CCAdvanced.h"
  25. #import "CCManageAccount.h"
  26. #import "CCManageAutoUpload.h"
  27. #import "NCManageEndToEndEncryption.h"
  28. #import "NCBridgeSwift.h"
  29. #import "NSNotificationCenter+MainThread.h"
  30. #import <LocalAuthentication/LocalAuthentication.h>
  31. #import <TOPasscodeViewController/TOPasscodeViewController.h>
  32. #define alertViewEsci 1
  33. #define alertViewAzzeraCache 2
  34. @interface NCSettings () <TOPasscodeSettingsViewControllerDelegate, TOPasscodeViewControllerDelegate>
  35. {
  36. AppDelegate *appDelegate;
  37. TOPasscodeViewController *passcodeViewController;
  38. TOPasscodeSettingsViewController *passcodeSettingsViewController;
  39. }
  40. @end
  41. @implementation NCSettings
  42. - (void)initializeForm
  43. {
  44. XLFormDescriptor *form = [XLFormDescriptor formDescriptor];
  45. XLFormSectionDescriptor *section;
  46. XLFormRowDescriptor *row;
  47. //NSInteger serverVersionMajor = [[NCManageDatabase shared] getCapabilitiesServerIntWithAccount:appDelegate.account elements:NCElementsJSON.shared.capabilitiesVersionMajor];
  48. form.rowNavigationOptions = XLFormRowNavigationOptionNone;
  49. // Section AUTO UPLOAD OF CAMERA IMAGES ----------------------------
  50. section = [XLFormSectionDescriptor formSection];
  51. [form addFormSection:section];
  52. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"autoUpload" rowType:XLFormRowDescriptorTypeButton title:NSLocalizedString(@"_settings_autoupload_", nil)];
  53. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  54. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  55. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  56. [row.cellConfig setObject:[[UIImage imageNamed:@"autoUpload"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  57. row.action.viewControllerClass = [CCManageAutoUpload class];
  58. [section addFormRow:row];
  59. // Section : LOCK --------------------------------------------------------------
  60. section = [XLFormSectionDescriptor formSectionWithTitle:NSLocalizedString(@"_lock_", nil)];
  61. [form addFormSection:section];
  62. // Lock active YES/NO
  63. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"bloccopasscode" rowType:XLFormRowDescriptorTypeButton title:NSLocalizedString(@"_lock_not_active_", nil)];
  64. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  65. [row.cellConfig setObject:[[UIImage imageNamed:@"settingsPasscodeNO"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  66. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  67. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  68. [row.cellConfig setObject:@(NSTextAlignmentLeft) forKey:@"textLabel.textAlignment"];
  69. //[row.cellConfig setObject:@(UITableViewCellAccessoryDisclosureIndicator) forKey:@"accessoryType"];
  70. row.action.formSelector = @selector(passcode:);
  71. [section addFormRow:row];
  72. // Enable Touch ID
  73. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"enableTouchDaceID" rowType:XLFormRowDescriptorTypeBooleanSwitch title:NSLocalizedString(@"_enable_touch_face_id_", nil)];
  74. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  75. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  76. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  77. [section addFormRow:row];
  78. // Lock no screen
  79. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"notPasscodeAtStart" rowType:XLFormRowDescriptorTypeBooleanSwitch title:NSLocalizedString(@"_lock_protection_no_screen_", nil)];
  80. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  81. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  82. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  83. [section addFormRow:row];
  84. // Section : Screen --------------------------------------------------------------
  85. section = [XLFormSectionDescriptor formSectionWithTitle:NSLocalizedString(@"_screen_", nil)];
  86. [form addFormSection:section];
  87. // Dark Mode
  88. if (@available(iOS 13.0, *)) {
  89. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"darkModeDetect" rowType:XLFormRowDescriptorTypeBooleanSwitch title:NSLocalizedString(@"_dark_mode_detect_", nil)];
  90. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  91. [row.cellConfig setObject:[[UIImage imageNamed:@"darkModeDetect"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  92. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  93. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  94. if ([CCUtility getDarkModeDetect]) row.value = @1;
  95. else row.value = @0;
  96. [section addFormRow:row];
  97. } else {
  98. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"darkMode" rowType:XLFormRowDescriptorTypeBooleanSwitch title:NSLocalizedString(@"_dark_mode_", nil)];
  99. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  100. [row.cellConfig setObject:[[UIImage imageNamed:@"themeLightDark"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  101. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  102. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  103. if ([CCUtility getDarkMode]) row.value = @1;
  104. else row.value = @0;
  105. [section addFormRow:row];
  106. }
  107. // Section : E2EEncryption --------------------------------------------------------------
  108. section = [XLFormSectionDescriptor formSectionWithTitle:NSLocalizedString(@"_e2e_settings_title_", nil)];
  109. [form addFormSection:section];
  110. // EndToEnd Encryption
  111. NSString *title = [NSString stringWithFormat:@"%@ (%@)",NSLocalizedString(@"_e2e_settings_", nil), NSLocalizedString(@"_experimental_", nil)];
  112. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"e2eEncryption" rowType:XLFormRowDescriptorTypeButton title:title];
  113. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  114. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  115. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  116. [row.cellConfig setObject:[[UIImage imageNamed:@"lock"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  117. row.action.viewControllerClass = [NCManageEndToEndEncryption class];
  118. [section addFormRow:row];
  119. // Section Advanced -------------------------------------------------
  120. section = [XLFormSectionDescriptor formSection];
  121. [form addFormSection:section];
  122. // Advanced
  123. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"advanced" rowType:XLFormRowDescriptorTypeButton title:NSLocalizedString(@"_advanced_", nil)];
  124. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  125. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  126. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  127. [row.cellConfig setObject:[[NCCollectionCommon shared] loadImageWithNamed:@"gear" color:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  128. row.action.viewControllerClass = [CCAdvanced class];
  129. [section addFormRow:row];
  130. // Section : INFORMATION ------------------------------------------------
  131. section = [XLFormSectionDescriptor formSectionWithTitle:NSLocalizedString(@"_information_", nil)];
  132. [form addFormSection:section];
  133. // Acknowledgements
  134. row = [XLFormRowDescriptor formRowDescriptorWithTag:@"buttonLeftAligned" rowType:XLFormRowDescriptorTypeButton title:NSLocalizedString(@"_acknowledgements_", nil)];
  135. row.cellConfigAtConfigure[@"backgroundColor"] = NCBrandColor.shared.backgroundView;
  136. [row.cellConfig setObject:[UIFont systemFontOfSize:15.0] forKey:@"textLabel.font"];
  137. [row.cellConfig setObject:@(NSTextAlignmentLeft) forKey:@"textLabel.textAlignment"];
  138. [row.cellConfig setObject:NCBrandColor.shared.textView forKey:@"textLabel.textColor"];
  139. [row.cellConfig setObject:[[UIImage imageNamed:@"acknowledgements"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  140. row.action.formBlock = ^(XLFormRowDescriptor * sender){
  141. [self performSegueWithIdentifier:@"AcknowledgementsSegue" sender:sender];
  142. [self deselectFormRow:sender];
  143. };
  144. [section addFormRow:row];
  145. self.tableView.showsVerticalScrollIndicator = NO;
  146. self.tableView.contentInset = UIEdgeInsetsMake(0, 0, 35, 0);
  147. self.form = form;
  148. }
  149. #pragma mark - Life Cycle
  150. - (void)viewDidLoad
  151. {
  152. [super viewDidLoad];
  153. self.title = NSLocalizedString(@"_settings_", nil);
  154. appDelegate = (AppDelegate *)[[UIApplication sharedApplication] delegate];
  155. [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(changeTheming) name:NCGlobal.shared.notificationCenterChangeTheming object:nil];
  156. [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(applicationDidEnterBackground) name:NCGlobal.shared.notificationCenterApplicationDidEnterBackground object:nil];
  157. [[NSNotificationCenter defaultCenter] addObserver:self selector:@selector(initializeMain) name:NCGlobal.shared.notificationCenterInitializeMain object:nil];
  158. [self changeTheming];
  159. }
  160. - (void)viewWillAppear:(BOOL)animated
  161. {
  162. [super viewWillAppear:animated];
  163. appDelegate.activeViewController = self;
  164. [self initializeForm];
  165. [self reloadForm];
  166. }
  167. #pragma mark - NotificationCenter
  168. - (void)changeTheming
  169. {
  170. self.view.backgroundColor = NCBrandColor.shared.backgroundForm;
  171. self.tableView.backgroundColor = NCBrandColor.shared.backgroundForm;
  172. [self initializeForm];
  173. [self reloadForm];
  174. }
  175. - (void)initializeMain
  176. {
  177. [self initializeForm];
  178. [self reloadForm];
  179. }
  180. - (void)applicationDidEnterBackground
  181. {
  182. if (passcodeViewController.view.window != nil) {
  183. [passcodeViewController dismissViewControllerAnimated:true completion:nil];
  184. }
  185. if (passcodeSettingsViewController.view.window != nil) {
  186. [passcodeSettingsViewController dismissViewControllerAnimated:true completion:nil];
  187. }
  188. }
  189. #pragma mark -
  190. - (void)reloadForm
  191. {
  192. self.form.delegate = nil;
  193. // ------------------------------------------------------------------
  194. XLFormRowDescriptor *rowBloccoPasscode = [self.form formRowWithTag:@"bloccopasscode"];
  195. XLFormRowDescriptor *rowNotPasscodeAtStart = [self.form formRowWithTag:@"notPasscodeAtStart"];
  196. XLFormRowDescriptor *rowEnableTouchDaceID = [self.form formRowWithTag:@"enableTouchDaceID"];
  197. XLFormRowDescriptor *rowDarkModeDetect = [self.form formRowWithTag:@"darkModeDetect"];
  198. XLFormRowDescriptor *rowDarkMode = [self.form formRowWithTag:@"darkMode"];
  199. // ------------------------------------------------------------------
  200. if ([[CCUtility getPasscode] length]) {
  201. rowBloccoPasscode.title = NSLocalizedString(@"_lock_active_", nil);
  202. [rowBloccoPasscode.cellConfig setObject:[[UIImage imageNamed:@"settingsPasscodeYES"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  203. } else {
  204. rowBloccoPasscode.title = NSLocalizedString(@"_lock_not_active_", nil);
  205. [rowBloccoPasscode.cellConfig setObject:[[UIImage imageNamed:@"settingsPasscodeNO"] imageWithColor:NCBrandColor.shared.icon size:25] forKey:@"imageView.image"];
  206. }
  207. if ([CCUtility getEnableTouchFaceID]) [rowEnableTouchDaceID setValue:@1]; else [rowEnableTouchDaceID setValue:@0];
  208. if ([CCUtility getNotPasscodeAtStart]) [rowNotPasscodeAtStart setValue:@1]; else [rowNotPasscodeAtStart setValue:@0];
  209. if ([CCUtility getDarkModeDetect]) [rowDarkModeDetect setValue:@1]; else [rowDarkModeDetect setValue:@0];
  210. if ([CCUtility getDarkMode]) [rowDarkMode setValue:@1]; else [rowDarkMode setValue:@0];
  211. // -----------------------------------------------------------------
  212. [self.tableView reloadData];
  213. self.form.delegate = self;
  214. }
  215. - (void)formRowDescriptorValueHasChanged:(XLFormRowDescriptor *)rowDescriptor oldValue:(id)oldValue newValue:(id)newValue
  216. {
  217. [super formRowDescriptorValueHasChanged:rowDescriptor oldValue:oldValue newValue:newValue];
  218. if ([rowDescriptor.tag isEqualToString:@"notPasscodeAtStart"]) {
  219. if ([[rowDescriptor.value valueData] boolValue] == YES) {
  220. [CCUtility setNotPasscodeAtStart:true];
  221. } else {
  222. [CCUtility setNotPasscodeAtStart:false];
  223. }
  224. }
  225. if ([rowDescriptor.tag isEqualToString:@"enableTouchDaceID"]) {
  226. if ([[rowDescriptor.value valueData] boolValue] == YES) {
  227. [CCUtility setEnableTouchFaceID:true];
  228. } else {
  229. [CCUtility setEnableTouchFaceID:false];
  230. }
  231. }
  232. if ([rowDescriptor.tag isEqualToString:@"darkMode"]) {
  233. if ([[rowDescriptor.value valueData] boolValue] == YES) {
  234. [CCUtility setDarkMode:true];
  235. } else {
  236. [CCUtility setDarkMode:false];
  237. }
  238. [[NSNotificationCenter defaultCenter] postNotificationOnMainThreadName:NCGlobal.shared.notificationCenterChangeTheming object:nil];
  239. }
  240. if ([rowDescriptor.tag isEqualToString:@"darkModeDetect"]) {
  241. if ([[rowDescriptor.value valueData] boolValue] == YES) {
  242. [CCUtility setDarkModeDetect:true];
  243. // detect Dark Mode
  244. if (self.traitCollection.userInterfaceStyle == UIUserInterfaceStyleDark) {
  245. [CCUtility setDarkMode:YES];
  246. } else {
  247. [CCUtility setDarkMode:NO];
  248. }
  249. } else {
  250. [CCUtility setDarkModeDetect:false];
  251. [CCUtility setDarkMode:false];
  252. }
  253. [[NSNotificationCenter defaultCenter] postNotificationOnMainThreadName:NCGlobal.shared.notificationCenterChangeTheming object:nil];
  254. }
  255. }
  256. #pragma mark - Passcode
  257. - (void)didPerformBiometricValidationRequestInPasscodeViewController:(TOPasscodeViewController *)passcodeViewController
  258. {
  259. [[LAContext new] evaluatePolicy:LAPolicyDeviceOwnerAuthenticationWithBiometrics localizedReason:[[NCBrandOptions shared] brand] reply:^(BOOL success, NSError * _Nullable error) {
  260. if (success) {
  261. dispatch_after(dispatch_time(DISPATCH_TIME_NOW, 0.5 * NSEC_PER_SEC), dispatch_get_main_queue(), ^(void) {
  262. [CCUtility setPasscode:@""];
  263. [passcodeViewController dismissViewControllerAnimated:YES completion:nil];
  264. [self reloadForm];
  265. });
  266. }
  267. }];
  268. }
  269. - (void)passcodeSettingsViewController:(TOPasscodeSettingsViewController *)passcodeSettingsViewController didChangeToNewPasscode:(NSString *)passcode ofType:(TOPasscodeType)type
  270. {
  271. [CCUtility setPasscode:passcode];
  272. [passcodeSettingsViewController dismissViewControllerAnimated:YES completion:nil];
  273. [self reloadForm];
  274. }
  275. - (void)didTapCancelInPasscodeViewController:(TOPasscodeViewController *)passcodeViewController
  276. {
  277. [passcodeViewController dismissViewControllerAnimated:YES completion:nil];
  278. }
  279. - (BOOL)passcodeViewController:(TOPasscodeViewController *)passcodeViewController isCorrectCode:(NSString *)code
  280. {
  281. if ([code isEqualToString:[CCUtility getPasscode]]) {
  282. [CCUtility setPasscode:@""];
  283. [self reloadForm];
  284. return YES;
  285. }
  286. return NO;
  287. }
  288. - (void)passcode:(XLFormRowDescriptor *)sender
  289. {
  290. LAContext *laContext = [LAContext new];
  291. NSError *error;
  292. [self deselectFormRow:sender];
  293. if ([[CCUtility getPasscode] length] == 0) {
  294. passcodeSettingsViewController = [[TOPasscodeSettingsViewController alloc] init];
  295. if (@available(iOS 13.0, *)) {
  296. if ([[UITraitCollection currentTraitCollection] userInterfaceStyle] == UIUserInterfaceStyleDark) {
  297. passcodeSettingsViewController.style = TOPasscodeSettingsViewStyleDark;
  298. }
  299. }
  300. passcodeSettingsViewController.hideOptionsButton = YES;
  301. passcodeSettingsViewController.requireCurrentPasscode = NO;
  302. passcodeSettingsViewController.passcodeType = TOPasscodeTypeSixDigits;
  303. passcodeSettingsViewController.delegate = self;
  304. [self presentViewController:passcodeSettingsViewController animated:YES completion:nil];
  305. } else {
  306. passcodeViewController = [[TOPasscodeViewController alloc] initWithStyle:TOPasscodeViewStyleTranslucentLight passcodeType:TOPasscodeTypeSixDigits];
  307. if (@available(iOS 13.0, *)) {
  308. if ([[UITraitCollection currentTraitCollection] userInterfaceStyle] == UIUserInterfaceStyleDark) {
  309. passcodeViewController.style = TOPasscodeViewStyleTranslucentDark;
  310. }
  311. }
  312. passcodeViewController.allowCancel = true;
  313. passcodeViewController.delegate = self;
  314. passcodeViewController.keypadButtonShowLettering = false;
  315. if (CCUtility.getEnableTouchFaceID && [laContext canEvaluatePolicy:LAPolicyDeviceOwnerAuthenticationWithBiometrics error:&error]) {
  316. if (error == NULL) {
  317. if (laContext.biometryType == LABiometryTypeFaceID) {
  318. passcodeViewController.biometryType = TOPasscodeBiometryTypeFaceID;
  319. passcodeViewController.allowBiometricValidation = true;
  320. passcodeViewController.automaticallyPromptForBiometricValidation = true;
  321. } else if (laContext.biometryType == LABiometryTypeTouchID) {
  322. passcodeViewController.biometryType = TOPasscodeBiometryTypeTouchID;
  323. passcodeViewController.allowBiometricValidation = true;
  324. passcodeViewController.automaticallyPromptForBiometricValidation = true;
  325. } else {
  326. NSLog(@"No Biometric support");
  327. }
  328. }
  329. }
  330. [self presentViewController:passcodeViewController animated:YES completion:nil];
  331. }
  332. }
  333. #pragma mark -
  334. - (NSString *)tableView:(UITableView *)tableView titleForFooterInSection:(NSInteger)section
  335. {
  336. NSString *sectionName;
  337. switch (section)
  338. {
  339. case 1: {
  340. sectionName = NSLocalizedString(@"_lock_protection_no_screen_footer_", nil);
  341. }
  342. break;
  343. case 5: {
  344. NSString *versionServer = [[NCManageDatabase shared] getCapabilitiesServerStringWithAccount:appDelegate.account elements:NCElementsJSON.shared.capabilitiesVersionString];
  345. NSString *themingName = [[NCManageDatabase shared] getCapabilitiesServerStringWithAccount:appDelegate.account elements:NCElementsJSON.shared.capabilitiesThemingName];
  346. NSString *themingSlogan = [[NCManageDatabase shared] getCapabilitiesServerStringWithAccount:appDelegate.account elements:NCElementsJSON.shared.capabilitiesThemingSlogan];
  347. NSString *versionNextcloud = [NSString stringWithFormat:[NCBrandOptions shared].textCopyrightNextcloudServer, versionServer];
  348. NSString *versionNextcloudiOS = [NSString stringWithFormat:[NCBrandOptions shared].textCopyrightNextcloudiOS, NCUtility.shared.getVersionApp];
  349. NSString *nameSlogan = [NSString stringWithFormat:@"%@ - %@", themingName, themingSlogan];
  350. sectionName = [NSString stringWithFormat:@"\n%@\n\n%@\n%@", versionNextcloudiOS, versionNextcloud, nameSlogan];
  351. }
  352. break;
  353. }
  354. return sectionName;
  355. }
  356. @end