Sfoglia il codice sorgente

Insert themingLogoBlack

marinofaggiana 5 anni fa
parent
commit
40b628548b

+ 21 - 0
iOSClient/Brand/Custom.xcassets/themingLogoBlack.imageset/Contents.json

@@ -0,0 +1,21 @@
+{
+  "images" : [
+    {
+      "idiom" : "universal",
+      "scale" : "1x"
+    },
+    {
+      "idiom" : "universal",
+      "filename" : "themingLogoBlack@2x.png",
+      "scale" : "2x"
+    },
+    {
+      "idiom" : "universal",
+      "scale" : "3x"
+    }
+  ],
+  "info" : {
+    "version" : 1,
+    "author" : "xcode"
+  }
+}

BIN
iOSClient/Brand/Custom.xcassets/themingLogoBlack.imageset/themingLogoBlack@2x.png


+ 5 - 0
iOSClient/Main/CCMain.m

@@ -581,6 +581,11 @@
 {
     UIImage *image = [UIImage imageNamed:@"themingLogo"];
     
+    tableCapabilities *capabilities = [[NCManageDatabase sharedInstance] getCapabilitesWithAccount:appDelegate.activeAccount];
+    if ([capabilities.themingColorText isEqualToString:@"#000000"] && [UIImage imageNamed:@"themingLogoBlack"]) {
+        image = [UIImage imageNamed:@"themingLogoBlack"];
+    }
+   
     if ([NCBrandOptions sharedInstance].use_themingLogo) {
         
         image = [UIImage imageWithContentsOfFile:[NSString stringWithFormat:@"%@/%@-themingLogo.png", [CCUtility getDirectoryUserData], [CCUtility getStringUser:appDelegate.activeUser activeUrl:appDelegate.activeUrl]]];