]> gitweb.stoutner.com Git - PrivacyBrowserAndroid.git/blobdiff - app/src/main/java/com/stoutner/privacybrowser/dialogs/FontSizeDialog.kt
Fix the app bar and options menu icon colors. https://redmine.stoutner.com/issues/618
[PrivacyBrowserAndroid.git] / app / src / main / java / com / stoutner / privacybrowser / dialogs / FontSizeDialog.kt
index 75ef4e4517a88caa2bd9840e8097ae0db82d428d..e6f3110ba5e0f11c38a67d41a91becba92b1328e 100644 (file)
@@ -85,15 +85,8 @@ class FontSizeDialog: DialogFragment() {
         // Use a builder to create the alert dialog.
         val dialogBuilder = AlertDialog.Builder(requireContext(), R.style.PrivacyBrowserAlertDialog)
 
         // Use a builder to create the alert dialog.
         val dialogBuilder = AlertDialog.Builder(requireContext(), R.style.PrivacyBrowserAlertDialog)
 
-        // Get the current theme status.
-        val currentThemeStatus = resources.configuration.uiMode and Configuration.UI_MODE_NIGHT_MASK
-
         // Set the icon according to the theme.
         // Set the icon according to the theme.
-        if (currentThemeStatus == Configuration.UI_MODE_NIGHT_NO) {
-            dialogBuilder.setIcon(R.drawable.font_size_day)
-        } else {
-            dialogBuilder.setIcon(R.drawable.font_size_night)
-        }
+        dialogBuilder.setIconAttribute(R.attr.fontSizeBlueIcon)
 
         // Set the title.
         dialogBuilder.setTitle(R.string.font_size)
 
         // Set the title.
         dialogBuilder.setTitle(R.string.font_size)