Highlight item when in favorites
This commit is contained in:
parent
b88eedc42c
commit
9c916b335e
|
@ -160,6 +160,16 @@ extension UIActivityIndicatorView {
|
|||
}
|
||||
}
|
||||
|
||||
extension UIBarButtonItem {
|
||||
func apply(_ theme: Theme) {
|
||||
tintColor = nil
|
||||
}
|
||||
|
||||
func applyAccent(_ theme: Theme) {
|
||||
tintColor = theme.palette.accent1
|
||||
}
|
||||
}
|
||||
|
||||
// XXX: status bar is broken
|
||||
extension MFMailComposeViewController {
|
||||
func apply(_ theme: Theme) {
|
||||
|
|
|
@ -94,6 +94,9 @@ class ProviderPoolViewController: UIViewController {
|
|||
isShowingFavorites = !isShowingFavorites
|
||||
if isShowingFavorites {
|
||||
reloadFavorites()
|
||||
navigationItem.rightBarButtonItem?.applyAccent(.current)
|
||||
} else {
|
||||
navigationItem.rightBarButtonItem?.apply(.current)
|
||||
}
|
||||
tableView.reloadData()
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue