Skip to content
This repository has been archived by the owner. It is now read-only.
Permalink
Browse files

Fixed the accessibility value for forget mode button

  • Loading branch information
mahmoud-adam85 committed May 14, 2018
1 parent 747d760 commit b04080ece0542ca99ba10b3a50859f03f6912ffb
Showing with 5 additions and 0 deletions.
  1. +5 −0 Cliqz/Tab Tray/CliqzForgetModeButton.swift
@@ -24,6 +24,7 @@ class CliqzForgetModeButton: UIButton, Themeable {

func applyTheme(_ theme: Theme) {
setTitleColor(UIColor.CliqzTabTray.ButtonText.colorFor(theme), for: [])
isSelected = theme == .Private
accessibilityValue = isSelected ? PrivateModeStrings.toggleAccessibilityValueOn : PrivateModeStrings.toggleAccessibilityValueOff
}

@@ -35,4 +36,8 @@ class CliqzForgetModeButton: UIButton, Themeable {
})
}

override func layoutSubviews() {
super.layoutSubviews()
self.setSelected(isSelected, animated: false)
}
}

0 comments on commit b04080e

Please sign in to comment.