Skip to content

Commit d21d7cc

Browse files
authored
Merge pull request #2256 from nextcloud/fix/noid/colors-on-ios-26
fix: Colors of some elements on iOS 26
2 parents 31b78c3 + d92411c commit d21d7cc

12 files changed

+37
-15
lines changed

NextcloudTalk/Chat/Chat views/Polls/PollCreationViewController.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,9 @@ import UIKit
5151
super.viewDidLoad()
5252

5353
self.creatingPollIndicatorView = UIActivityIndicatorView()
54-
self.creatingPollIndicatorView.color = NCAppBranding.themeTextColor()
54+
if #unavailable(iOS 26.0) {
55+
self.creatingPollIndicatorView.color = NCAppBranding.themeTextColor()
56+
}
5557

5658
self.setMoreOptionsButton()
5759

NextcloudTalk/Chat/Chat views/Polls/PollVotingView.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,9 @@ import UIKit
4848
super.viewDidLoad()
4949

5050
self.activityIndicatorView = UIActivityIndicatorView()
51-
self.activityIndicatorView.color = NCAppBranding.themeTextColor()
51+
if #unavailable(iOS 26.0) {
52+
self.activityIndicatorView.color = NCAppBranding.themeTextColor()
53+
}
5254

5355
self.setMoreOptionsButton()
5456

NextcloudTalk/Chat/ChatViewController.swift

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2411,7 +2411,7 @@ import SwiftUI
24112411
if #unavailable(iOS 26.0) {
24122412
cancelButton.tintColor = NCAppBranding.themeTextColor()
24132413
}
2414-
2414+
24152415
roomInfo.modalPresentationStyle = .pageSheet
24162416

24172417
let navController = UINavigationController(rootViewController: roomInfo)

NextcloudTalk/Chat/MessageTranslationViewController.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,9 @@ import UIKit
6969
self.translateTextView.layer.cornerRadius = 8
7070

7171
self.modifyingProfileView = UIActivityIndicatorView()
72-
self.modifyingProfileView.color = NCAppBranding.themeTextColor()
72+
if #unavailable(iOS 26.0) {
73+
self.modifyingProfileView.color = NCAppBranding.themeTextColor()
74+
}
7375

7476
self.navigationItem.leftBarButtonItem = UIBarButtonItem(barButtonSystemItem: .cancel, target: self, action: #selector(self.cancelButtonPressed))
7577
if #unavailable(iOS 26.0) {

NextcloudTalk/Federation/FederationInvitationTableViewController.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,7 +46,9 @@ class FederationInvitationTableViewController: UITableViewController, Federation
4646
self.backgroundView.placeholderView.isHidden = true
4747
self.backgroundView.loadingView.startAnimating()
4848

49-
self.modifyingViewIndicator.color = NCAppBranding.themeTextColor()
49+
if #unavailable(iOS 26.0) {
50+
self.modifyingViewIndicator.color = NCAppBranding.themeTextColor()
51+
}
5052
}
5153

5254
override func viewWillAppear(_ animated: Bool) {

NextcloudTalk/Rooms/Banned Actors/BannedActorTableViewController.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,9 @@
3636
self.backgroundView.setImage(UIImage(systemName: "person.badge.minus"))
3737
self.backgroundView.loadingView.startAnimating()
3838

39-
self.modifyingViewIndicator.color = NCAppBranding.themeTextColor()
39+
if #unavailable(iOS 26.0) {
40+
self.modifyingViewIndicator.color = NCAppBranding.themeTextColor()
41+
}
4042
}
4143

4244
override func viewWillAppear(_ animated: Bool) {

NextcloudTalk/Rooms/RoomAvatarInfoTableViewController.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,9 @@ enum RoomAvatarInfoSection: Int {
6565
self.tableView.register(TextViewTableViewCell.self, forCellReuseIdentifier: TextViewTableViewCell.identifier)
6666
self.tableView.tableHeaderView = self.headerView
6767

68-
self.modifyingView.color = NCAppBranding.themeTextColor()
68+
if #unavailable(iOS 26.0) {
69+
self.modifyingView.color = NCAppBranding.themeTextColor()
70+
}
6971

7072
if let serverCapabilities = NCDatabaseManager.sharedInstance().serverCapabilities(forAccountId: self.room.accountId) {
7173
self.descriptionMaxLength = serverCapabilities.descriptionLength
@@ -207,6 +209,7 @@ enum RoomAvatarInfoSection: Int {
207209
func removeModifyingView() {
208210
modifyingView.stopAnimating()
209211
self.headerView.changeButtonState(to: true)
212+
self.navigationItem.rightBarButtonItem = nil
210213
self.tableView.isUserInteractionEnabled = true
211214
}
212215

NextcloudTalk/Rooms/RoomCreationTableViewController.swift

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,9 @@ enum RoomVisibilityOption: Int {
9797
self.createButton.isEnabled = false
9898
self.navigationItem.rightBarButtonItem = self.createButton
9999

100-
self.modifyingView.color = NCAppBranding.themeTextColor()
100+
if #unavailable(iOS 26.0) {
101+
self.modifyingView.color = NCAppBranding.themeTextColor()
102+
}
101103

102104
self.headerView.editView.isHidden = !NCDatabaseManager.sharedInstance().serverHasTalkCapability(kCapabilityConversationAvatars, forAccountId: self.account.accountId)
103105
// Need to have an explicit size here for the header view

NextcloudTalk/Rooms/RoomSharedItemsTableViewController.swift

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -141,6 +141,11 @@ import QuickLook
141141
itemTypeSelectorButton.setTitle(buttonTitle, for: .normal)
142142
itemTypeSelectorButton.titleLabel?.font = UIFont.systemFont(ofSize: 17, weight: .medium)
143143
itemTypeSelectorButton.setTitleColor(NCAppBranding.themeTextColor(), for: .normal)
144+
if #available(iOS 26.0, *) {
145+
itemTypeSelectorButton.setTitleColor(.label, for: .normal)
146+
} else {
147+
itemTypeSelectorButton.setTitleColor(NCAppBranding.themeTextColor(), for: .normal)
148+
}
144149
self.navigationItem.titleView = itemTypeSelectorButton
145150

146151
var menuActions: [UIAction] = []

NextcloudTalk/Settings/UserProfileTableViewController.swift

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,10 @@ class UserProfileTableViewController: UITableViewController, DetailedOptionsSele
6666
}
6767

6868
modifyingProfileView = UIActivityIndicatorView()
69-
modifyingProfileView.color = NCAppBranding.themeTextColor()
69+
if #unavailable(iOS 26.0) {
70+
modifyingProfileView.color = NCAppBranding.themeTextColor()
71+
}
72+
7073
tableView.keyboardDismissMode = UIScrollView.KeyboardDismissMode.onDrag
7174
tableView.register(TextFieldTableViewCell.self, forCellReuseIdentifier: TextFieldTableViewCell.identifier)
7275
NotificationCenter.default.addObserver(self, selector: #selector(userProfileImageUpdated), name: NSNotification.Name.NCUserProfileImageUpdated, object: nil)

0 commit comments

Comments
 (0)