@@ -35,75 +35,60 @@ let userAgent: String = {
35
35
return instance
36
36
} ( )
37
37
38
- @objc public var brand : String = " Nextcloud "
39
- @objc public var textCopyrightNextcloudiOS : String = " Nextcloud Hydrogen for iOS %@ © 2024 "
40
- @objc public var textCopyrightNextcloudServer : String = " Nextcloud Server %@ "
41
- @objc public var loginBaseUrl : String = " https://cloud.nextcloud.com "
42
- @objc public var pushNotificationServerProxy : String = " https://push-notifications.nextcloud.com "
43
- @objc public var linkLoginHost : String = " https://nextcloud.com/install "
44
- @objc public var linkloginPreferredProviders : String = " https://nextcloud.com/signup-ios "
45
- @objc public var webLoginAutenticationProtocol : String = " nc:// " // example "abc://"
46
- @objc public var privacy : String = " https://nextcloud.com/privacy "
47
- @objc public var sourceCode : String = " https://github.com/nextcloud/ios "
48
- @objc public var mobileconfig : String = " /remote.php/dav/provisioning/apple-provisioning.mobileconfig "
49
-
50
- // Personalized
51
- @objc public var webCloseViewProtocolPersonalized : String = " " // example "abc://change/plan" Don't touch me !!
52
- @objc public var folderBrandAutoUpload : String = " " // example "_auto_upload_folder_" Don't touch me !!
38
+ var brand : String = " Nextcloud "
39
+ var textCopyrightNextcloudiOS : String = " Nextcloud Hydrogen for iOS %@ © 2024 "
40
+ var textCopyrightNextcloudServer : String = " Nextcloud Server %@ "
41
+ var loginBaseUrl : String = " https://cloud.nextcloud.com "
42
+ @objc var pushNotificationServerProxy : String = " https://push-notifications.nextcloud.com "
43
+ var linkLoginHost : String = " https://nextcloud.com/install "
44
+ var linkloginPreferredProviders : String = " https://nextcloud.com/signup-ios "
45
+ var webLoginAutenticationProtocol : String = " nc:// " // example "abc://"
46
+ var privacy : String = " https://nextcloud.com/privacy "
47
+ var sourceCode : String = " https://github.com/nextcloud/ios "
48
+ var mobileconfig : String = " /remote.php/dav/provisioning/apple-provisioning.mobileconfig "
49
+ var appStoreUrl : String = " https://apps.apple.com/in/app/nextcloud/id1125420102 "
53
50
54
51
// Auto Upload default folder
55
- @ objc public var folderDefaultAutoUpload : String = " Photos "
52
+ var folderDefaultAutoUpload : String = " Photos "
56
53
57
54
// Capabilities Group
58
- @ objc public var capabilitiesGroups : String = " group.it.twsweb.Crypto-Cloud "
59
- @ objc public var capabilitiesGroupApps : String = " group.com.nextcloud.apps "
55
+ var capabilitiesGroups : String = " group.it.twsweb.Crypto-Cloud "
56
+ var capabilitiesGroupApps : String = " group.com.nextcloud.apps "
60
57
61
58
// BRAND ONLY
62
- @objc public var use_login_web_personalized : Bool = false // Don't touch me !!
63
59
@objc public var use_AppConfig : Bool = false // Don't touch me !!
64
- @objc public var use_GroupApps : Bool = true // Don't touch me !!
65
60
66
61
// Options
67
- @objc public var use_default_auto_upload : Bool = false
68
62
@objc public var use_themingColor : Bool = true
69
- @objc public var use_themingLogo : Bool = false
70
- @objc public var use_storeLocalAutoUploadAll : Bool = false
71
- @objc public var use_loginflowv2 : Bool = false // Don't touch me !!
72
-
73
- @objc public var disable_intro : Bool = false
74
- @objc public var disable_request_login_url : Bool = false
75
- @objc public var disable_multiaccount : Bool = false
76
- @objc public var disable_manage_account : Bool = false
77
- @objc public var disable_more_external_site : Bool = false
78
- @objc public var disable_openin_file : Bool = false // Don't touch me !!
79
- @objc public var disable_crash_service : Bool = false
80
- @objc public var disable_log : Bool = false
81
- @objc public var disable_mobileconfig : Bool = false
82
- @objc public var disable_show_more_nextcloud_apps_in_settings : Bool = false
83
- @objc public var doNotAskPasscodeAtStartup : Bool = false
63
+
64
+ var disable_intro : Bool = false
65
+ var disable_request_login_url : Bool = false
66
+ var disable_multiaccount : Bool = false
67
+ var disable_more_external_site : Bool = false
68
+ var disable_openin_file : Bool = false // Don't touch me !!
69
+ var disable_crash_service : Bool = false
70
+ var disable_log : Bool = false
71
+ var disable_mobileconfig : Bool = false
72
+ var disable_show_more_nextcloud_apps_in_settings : Bool = false
73
+ var doNotAskPasscodeAtStartup : Bool = false
84
74
85
75
// Internal option behaviour
86
- @ objc public var cleanUpDay : Int = 0 // Set default "Delete, in the cache, all files older than" possible days value are: 0, 1, 7, 30, 90, 180, 365
76
+ var cleanUpDay : Int = 0 // Set default "Delete, in the cache, all files older than" possible days value are: 0, 1, 7, 30, 90, 180, 365
87
77
88
78
// Max download/upload concurrent
89
- public let maxConcurrentOperationDownload : Int = 5
90
- public let maxConcurrentOperationUpload : Int = 5
79
+ let maxConcurrentOperationDownload : Int = 5
80
+ let maxConcurrentOperationUpload : Int = 5
91
81
92
82
// Number of failed attempts after reset app
93
- @ objc public let resetAppPasscodeAttempts : Int = 10
94
- public let passcodeSecondsFail : Int = 60
83
+ let resetAppPasscodeAttempts : Int = 10
84
+ let passcodeSecondsFail : Int = 60
95
85
96
86
// Info Paging
97
87
enum NCInfoPagingTab : Int , CaseIterable {
98
88
case activity, sharing
99
89
}
100
90
101
91
override init ( ) {
102
-
103
- if folderBrandAutoUpload != " " {
104
- folderDefaultAutoUpload = folderBrandAutoUpload
105
- }
106
-
107
92
// wrapper AppConfig
108
93
if let configurationManaged = UserDefaults . standard. dictionary ( forKey: " com.apple.configuration.managed " ) , use_AppConfig {
109
94
@@ -122,9 +107,6 @@ let userAgent: String = {
122
107
if let str = configurationManaged [ NCGlobal . shared. configuration_disable_log] as? String {
123
108
disable_log = ( str as NSString ) . boolValue
124
109
}
125
- if let str = configurationManaged [ NCGlobal . shared. configuration_disable_manage_account] as? String {
126
- disable_manage_account = ( str as NSString ) . boolValue
127
- }
128
110
if let str = configurationManaged [ NCGlobal . shared. configuration_disable_more_external_site] as? String {
129
111
disable_more_external_site = ( str as NSString ) . boolValue
130
112
}
@@ -140,53 +122,53 @@ let userAgent: String = {
140
122
}
141
123
142
124
class NCBrandColor : NSObject {
143
- @ objc static let shared : NCBrandColor = {
125
+ static let shared : NCBrandColor = {
144
126
let instance = NCBrandColor ( )
145
127
return instance
146
128
} ( )
147
129
148
130
// Color
149
- @ objc public let customer : UIColor = UIColor ( red: 0.0 / 255.0 , green: 130.0 / 255.0 , blue: 201.0 / 255.0 , alpha: 1.0 ) // BLU NC : #0082c9
150
- @ objc public var customerText : UIColor = . white
131
+ let customer : UIColor = UIColor ( red: 0.0 / 255.0 , green: 130.0 / 255.0 , blue: 201.0 / 255.0 , alpha: 1.0 ) // BLU NC : #0082c9
132
+ var customerText : UIColor = . white
151
133
152
- @ objc private var brand : UIColor // don't touch me
153
- @ objc public var brandElement : UIColor // don't touch me
154
- @ objc public var brandText : UIColor // don't touch me
134
+ var brand : UIColor // don't touch me
135
+ var brandElement : UIColor // don't touch me
136
+ var brandText : UIColor // don't touch me
155
137
156
- @ objc public let nextcloud : UIColor = UIColor ( red: 0.0 / 255.0 , green: 130.0 / 255.0 , blue: 201.0 / 255.0 , alpha: 1.0 )
157
- @ objc public let yellowFavorite : UIColor = UIColor ( red: 248.0 / 255.0 , green: 205.0 / 255.0 , blue: 70.0 / 255.0 , alpha: 1.0 )
138
+ let nextcloud : UIColor = UIColor ( red: 0.0 / 255.0 , green: 130.0 / 255.0 , blue: 201.0 / 255.0 , alpha: 1.0 )
139
+ let yellowFavorite : UIColor = UIColor ( red: 248.0 / 255.0 , green: 205.0 / 255.0 , blue: 70.0 / 255.0 , alpha: 1.0 )
158
140
159
- public var userColors : [ CGColor ] = [ ]
160
- public var themingColor : String = " "
161
- public var themingColorElement : String = " "
162
- public var themingColorText : String = " "
141
+ var userColors : [ CGColor ] = [ ]
142
+ var themingColor : String = " "
143
+ var themingColorElement : String = " "
144
+ var themingColorText : String = " "
163
145
164
- @ objc public let iconImageColor : UIColor = . label
165
- @ objc public let iconImageColor2 : UIColor = . secondaryLabel
166
- @ objc public let iconImageMultiColors : [ UIColor ] = [ . secondaryLabel, . label]
146
+ let iconImageColor : UIColor = . label
147
+ let iconImageColor2 : UIColor = . secondaryLabel
148
+ let iconImageMultiColors : [ UIColor ] = [ . secondaryLabel, . label]
167
149
168
- @ objc public let textColor : UIColor = . label
169
- @ objc public let textColor2 : UIColor = . secondaryLabel
150
+ let textColor : UIColor = . label
151
+ let textColor2 : UIColor = . secondaryLabel
170
152
171
- @ objc public var systemMint : UIColor {
153
+ var systemMint : UIColor {
172
154
get {
173
155
return UIColor ( red: 0.0 / 255.0 , green: 199.0 / 255.0 , blue: 190.0 / 255.0 , alpha: 1.0 )
174
156
}
175
157
}
176
158
177
- @ objc public var documentIconColor : UIColor {
159
+ var documentIconColor : UIColor {
178
160
get {
179
161
return UIColor ( hex: " #49abe9 " ) !
180
162
}
181
163
}
182
164
183
- @ objc public var spreadsheetIconColor : UIColor {
165
+ var spreadsheetIconColor : UIColor {
184
166
get {
185
167
return UIColor ( hex: " #9abd4e " ) !
186
168
}
187
169
}
188
170
189
- @ objc public var presentationIconColor : UIColor {
171
+ var presentationIconColor : UIColor {
190
172
get {
191
173
return UIColor ( hex: " #f0965f " ) !
192
174
}
@@ -203,12 +185,10 @@ class NCBrandColor: NSObject {
203
185
}
204
186
205
187
func settingThemingColor( account: String ) {
206
-
207
188
let darker : CGFloat = 30 // %
208
189
let lighter : CGFloat = 30 // %
209
190
210
191
if NCBrandOptions . shared. use_themingColor {
211
-
212
192
self . themingColor = NCGlobal . shared. capabilityThemingColor
213
193
self . themingColorElement = NCGlobal . shared. capabilityThemingColorElement
214
194
self . themingColorText = NCGlobal . shared. capabilityThemingColorText
0 commit comments