- // Set the first-party cookies icon.
- if (firstPartyCookiesEnabled) {
- firstPartyCookiesPreference.setIcon(R.drawable.cookies_enabled);
- } else {
- if (currentThemeStatus == Configuration.UI_MODE_NIGHT_YES) {
- firstPartyCookiesPreference.setIcon(R.drawable.cookies_disabled_night);
- } else {
- firstPartyCookiesPreference.setIcon(R.drawable.cookies_disabled_day);
- }
- }
-
- // Set the third party cookies icon.
- if (firstPartyCookiesEnabled && Build.VERSION.SDK_INT >= 21) {
- if (savedPreferences.getBoolean("third_party_cookies", false)) {
- thirdPartyCookiesPreference.setIcon(R.drawable.cookies_warning);
- } else {
- if (currentThemeStatus == Configuration.UI_MODE_NIGHT_YES) {
- thirdPartyCookiesPreference.setIcon(R.drawable.cookies_disabled_night);
- } else {
- thirdPartyCookiesPreference.setIcon(R.drawable.cookies_disabled_day);
- }
- }
+ // Set the cookies icon.
+ if (savedPreferences.getBoolean(getString(R.string.cookies_key), false)) {
+ cookiesPreference.setIcon(R.drawable.cookies_enabled);