mirror of
https://gitlab.opencode.de/bwi/bundesmessenger/clients/bundesmessenger-ios.git
synced 2026-04-20 08:32:53 +02:00
reskin: Rename RiotDesignValues -> ThemeService
This commit is contained in:
@@ -22,9 +22,9 @@
|
||||
@interface LanguagePickerViewController ()
|
||||
{
|
||||
/**
|
||||
Observe kRiotDesignValuesDidChangeThemeNotification to handle user interface theme change.
|
||||
Observe kThemeServiceDidChangeThemeNotification to handle user interface theme change.
|
||||
*/
|
||||
id kRiotDesignValuesDidChangeThemeNotificationObserver;
|
||||
id kThemeServiceDidChangeThemeNotificationObserver;
|
||||
|
||||
/**
|
||||
The fake top view displayed in case of vertical bounce.
|
||||
@@ -59,7 +59,7 @@
|
||||
[self.tableView addSubview:topview];
|
||||
|
||||
// Observe user interface theme change.
|
||||
kRiotDesignValuesDidChangeThemeNotificationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:kRiotDesignValuesDidChangeThemeNotification object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification *notif) {
|
||||
kThemeServiceDidChangeThemeNotificationObserver = [[NSNotificationCenter defaultCenter] addObserverForName:kThemeServiceDidChangeThemeNotification object:nil queue:[NSOperationQueue mainQueue] usingBlock:^(NSNotification *notif) {
|
||||
|
||||
[self userInterfaceThemeDidChange];
|
||||
|
||||
@@ -69,15 +69,15 @@
|
||||
|
||||
- (void)userInterfaceThemeDidChange
|
||||
{
|
||||
[RiotDesignValues.theme applyStyleOnNavigationBar:self.navigationController.navigationBar];
|
||||
[ThemeService.theme applyStyleOnNavigationBar:self.navigationController.navigationBar];
|
||||
|
||||
self.activityIndicator.backgroundColor = RiotDesignValues.theme.overlayBackgroundColor;
|
||||
self.activityIndicator.backgroundColor = ThemeService.theme.overlayBackgroundColor;
|
||||
|
||||
[RiotDesignValues.theme applyStyleOnSearchBar:self.searchBar];
|
||||
[ThemeService.theme applyStyleOnSearchBar:self.searchBar];
|
||||
|
||||
// Use the primary bg color for the table view in plain style.
|
||||
self.tableView.backgroundColor = RiotDesignValues.theme.backgroundColor;
|
||||
topview.backgroundColor = RiotDesignValues.theme.backgroundColor;
|
||||
self.tableView.backgroundColor = ThemeService.theme.backgroundColor;
|
||||
topview.backgroundColor = ThemeService.theme.backgroundColor;
|
||||
|
||||
if (self.tableView.dataSource)
|
||||
{
|
||||
@@ -87,7 +87,7 @@
|
||||
|
||||
- (UIStatusBarStyle)preferredStatusBarStyle
|
||||
{
|
||||
return RiotDesignValues.theme.statusBarStyle;
|
||||
return ThemeService.theme.statusBarStyle;
|
||||
}
|
||||
|
||||
- (void)destroy
|
||||
@@ -97,10 +97,10 @@
|
||||
[topview removeFromSuperview];
|
||||
topview = nil;
|
||||
|
||||
if (kRiotDesignValuesDidChangeThemeNotificationObserver)
|
||||
if (kThemeServiceDidChangeThemeNotificationObserver)
|
||||
{
|
||||
[[NSNotificationCenter defaultCenter] removeObserver:kRiotDesignValuesDidChangeThemeNotificationObserver];
|
||||
kRiotDesignValuesDidChangeThemeNotificationObserver = nil;
|
||||
[[NSNotificationCenter defaultCenter] removeObserver:kThemeServiceDidChangeThemeNotificationObserver];
|
||||
kThemeServiceDidChangeThemeNotificationObserver = nil;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -114,15 +114,15 @@
|
||||
|
||||
- (void)tableView:(UITableView *)tableView willDisplayCell:(UITableViewCell *)cell forRowAtIndexPath:(NSIndexPath *)indexPath;
|
||||
{
|
||||
cell.textLabel.textColor = RiotDesignValues.theme.textPrimaryColor;
|
||||
cell.detailTextLabel.textColor = RiotDesignValues.theme.textSecondaryColor;
|
||||
cell.backgroundColor = RiotDesignValues.theme.backgroundColor;
|
||||
cell.textLabel.textColor = ThemeService.theme.textPrimaryColor;
|
||||
cell.detailTextLabel.textColor = ThemeService.theme.textSecondaryColor;
|
||||
cell.backgroundColor = ThemeService.theme.backgroundColor;
|
||||
|
||||
// Update the selected background view
|
||||
if (RiotDesignValues.theme.selectedBackgroundColor)
|
||||
if (ThemeService.theme.selectedBackgroundColor)
|
||||
{
|
||||
cell.selectedBackgroundView = [[UIView alloc] init];
|
||||
cell.selectedBackgroundView.backgroundColor = RiotDesignValues.theme.selectedBackgroundColor;
|
||||
cell.selectedBackgroundView.backgroundColor = ThemeService.theme.selectedBackgroundColor;
|
||||
}
|
||||
else
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user