mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-21 17:12:45 +02:00
reskin: Create ThemeService.shared
This commit is contained in:
@@ -114,19 +114,19 @@
|
||||
|
||||
- (void)userInterfaceThemeDidChange
|
||||
{
|
||||
[ThemeService.theme applyStyleOnNavigationBar:self.navigationController.navigationBar];
|
||||
[ThemeService.shared.theme applyStyleOnNavigationBar:self.navigationController.navigationBar];
|
||||
|
||||
self.tabBar.tintColor = ThemeService.theme.tintColor;
|
||||
self.tabBar.barTintColor = ThemeService.theme.headerBackgroundColor;
|
||||
self.tabBar.tintColor = ThemeService.shared.theme.tintColor;
|
||||
self.tabBar.barTintColor = ThemeService.shared.theme.headerBackgroundColor;
|
||||
|
||||
self.view.backgroundColor = ThemeService.theme.backgroundColor;
|
||||
self.view.backgroundColor = ThemeService.shared.theme.backgroundColor;
|
||||
|
||||
[self setNeedsStatusBarAppearanceUpdate];
|
||||
}
|
||||
|
||||
- (UIStatusBarStyle)preferredStatusBarStyle
|
||||
{
|
||||
return ThemeService.theme.statusBarStyle;
|
||||
return ThemeService.shared.theme.statusBarStyle;
|
||||
}
|
||||
|
||||
- (void)viewWillAppear:(BOOL)animated
|
||||
@@ -786,7 +786,7 @@
|
||||
{
|
||||
_hidden = hidden;
|
||||
|
||||
[self.view superview].backgroundColor = ThemeService.theme.backgroundColor;
|
||||
[self.view superview].backgroundColor = ThemeService.shared.theme.backgroundColor;
|
||||
self.view.hidden = hidden;
|
||||
self.navigationController.navigationBar.hidden = hidden;
|
||||
}
|
||||
@@ -798,15 +798,15 @@
|
||||
// Use a middle dot to signal missed notif in favourites
|
||||
[self setMissedDiscussionsMark:(recentsDataSource.missedFavouriteDiscussionsCount? @"\u00B7": nil)
|
||||
onTabBarItem:TABBAR_FAVOURITES_INDEX
|
||||
withBadgeColor:(recentsDataSource.missedHighlightFavouriteDiscussionsCount ? ThemeService.theme.notificationMentionColor : ThemeService.theme.notificationUnreadColor)];
|
||||
withBadgeColor:(recentsDataSource.missedHighlightFavouriteDiscussionsCount ? ThemeService.shared.theme.notificationMentionColor : ThemeService.shared.theme.notificationUnreadColor)];
|
||||
|
||||
// Update the badge on People and Rooms tabs
|
||||
[self setMissedDiscussionsCount:recentsDataSource.missedDirectDiscussionsCount
|
||||
onTabBarItem:TABBAR_PEOPLE_INDEX
|
||||
withBadgeColor:(recentsDataSource.missedHighlightDirectDiscussionsCount ? ThemeService.theme.notificationMentionColor : ThemeService.theme.notificationUnreadColor)];
|
||||
withBadgeColor:(recentsDataSource.missedHighlightDirectDiscussionsCount ? ThemeService.shared.theme.notificationMentionColor : ThemeService.shared.theme.notificationUnreadColor)];
|
||||
[self setMissedDiscussionsCount:recentsDataSource.missedGroupDiscussionsCount
|
||||
onTabBarItem:TABBAR_ROOMS_INDEX
|
||||
withBadgeColor:(recentsDataSource.missedHighlightGroupDiscussionsCount ? ThemeService.theme.notificationMentionColor : ThemeService.theme.notificationUnreadColor)];
|
||||
withBadgeColor:(recentsDataSource.missedHighlightGroupDiscussionsCount ? ThemeService.shared.theme.notificationMentionColor : ThemeService.shared.theme.notificationUnreadColor)];
|
||||
}
|
||||
|
||||
- (void)setMissedDiscussionsCount:(NSUInteger)count onTabBarItem:(NSUInteger)index withBadgeColor:(UIColor*)badgeColor
|
||||
|
||||
Reference in New Issue
Block a user