mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-25 19:10:49 +02:00
Feature/3124 release preparation
This commit is contained in:
@@ -64,6 +64,11 @@ struct DeveloperSettingsView: View {
|
||||
.foregroundColor(Color(ThemeService.shared().theme.tintColor))
|
||||
.font(.system(size: 17))
|
||||
}
|
||||
Button(action: { _ = unmarkBannerVersion(mxSession: session) }) {
|
||||
Text(NSLocalizedString("bwi_settings_developer_unmark_banner", tableName: "Bwi", comment: ""))
|
||||
.foregroundColor(Color(ThemeService.shared().theme.tintColor))
|
||||
.font(.system(size: 17))
|
||||
}
|
||||
}
|
||||
.navigationTitle(NSLocalizedString("bwi_settings_developer", tableName: "Vector", comment: ""))
|
||||
.navigationBarTitleDisplayMode(.inline)
|
||||
@@ -112,3 +117,17 @@ fileprivate func unrestrictUser(mxSession: MXSession?) -> Bool {
|
||||
AccountRestrictionService(mxSession: mxSession).updateRestriction(roomAccess: false, addressListAccess: false)
|
||||
return true
|
||||
}
|
||||
|
||||
fileprivate func unmarkBannerVersion(mxSession: MXSession?) -> Bool {
|
||||
guard let mxSession = mxSession else {
|
||||
return false
|
||||
}
|
||||
|
||||
// NSString *version = [[[NSBundle mainBundle] infoDictionary] objectForKey:@"CFBundleShortVersionString"];
|
||||
|
||||
if let version = Bundle.main.infoDictionary?["CFBundleShortVersionString"] as? String {
|
||||
_ = FeatureBannerVisibilityService(mxSession: mxSession).markAsUnread(version: version)
|
||||
}
|
||||
|
||||
return true
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user