jenkins-bot has submitted this change and it was merged. ( 
https://gerrit.wikimedia.org/r/383754 )

Change subject: Fix: Invisible texts in Popup Dialog in Dark Mode
......................................................................


Fix: Invisible texts in Popup Dialog in Dark Mode

Looks like the popup dialog after long pressing on the interal link does not 
apply the "alertDialogTheme" correctly.

We can use "android:alertDialogTheme" and inherit the "AlertDialog" theme with 
the android:backgroundTint.

Bug: T177129
Change-Id: I87ea82116d9a98a085313e9a5ff2b9bb9f2e902e
---
M app/src/main/res/values/styles_dark.xml
M app/src/main/res/values/styles_light.xml
2 files changed, 16 insertions(+), 2 deletions(-)

Approvals:
  Dbrant: Looks good to me, approved
  jenkins-bot: Verified



diff --git a/app/src/main/res/values/styles_dark.xml 
b/app/src/main/res/values/styles_dark.xml
index b22e72d..271175b 100644
--- a/app/src/main/res/values/styles_dark.xml
+++ b/app/src/main/res/values/styles_dark.xml
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<resources>
+<resources xmlns:tools="http://schemas.android.com/tools";>
 
     <style name="ThemeDark">
 
@@ -31,6 +31,9 @@
         <item name="dialogTheme">@style/DialogDark</item>
         <item name="alertDialogTheme">@style/AlertDialogDark</item>
         <item name="bottomSheetDialogTheme">@style/BottomSheetDialogDark</item>
+
+        <!-- Theme for dialog after long pressing on internal links -->
+        <item 
name="android:alertDialogTheme">@style/LongPressAlertDialogDark</item>
 
         <!-- Overrides of our own custom style attributes -->
         <item 
name="toc_item_background">@drawable/toc_item_background_dark</item>
@@ -75,6 +78,10 @@
         <item name="android:colorBackground">?attr/paper_color</item>
     </style>
 
+    <style name="LongPressAlertDialogDark" parent="AlertDialogDark">
+        <item name="android:backgroundTint" 
tools:targetApi="21">?attr/paper_color</item>
+    </style>
+
     <style name="DialogDark" parent="Theme.AppCompat.Dialog">
         <item name="windowActionBar">false</item>
         <item name="windowNoTitle">true</item>
diff --git a/app/src/main/res/values/styles_light.xml 
b/app/src/main/res/values/styles_light.xml
index 04bc3e0..2dbd51f 100644
--- a/app/src/main/res/values/styles_light.xml
+++ b/app/src/main/res/values/styles_light.xml
@@ -1,5 +1,5 @@
 <?xml version="1.0" encoding="utf-8"?>
-<resources>
+<resources xmlns:tools="http://schemas.android.com/tools";>
 
     <style name="ThemeLight">
 
@@ -31,6 +31,9 @@
         <item name="dialogTheme">@style/DialogLight</item>
         <item name="alertDialogTheme">@style/AlertDialogLight</item>
         <item 
name="bottomSheetDialogTheme">@style/BottomSheetDialogLight</item>
+
+        <!-- Theme for dialog after long pressing on internal links -->
+        <item 
name="android:alertDialogTheme">@style/LongPressAlertDialogLight</item>
 
         <!-- Overrides of our own custom style attributes -->
         <item 
name="toc_item_background">@drawable/toc_item_background_light</item>
@@ -75,6 +78,10 @@
         <item name="android:colorBackground">?attr/paper_color</item>
     </style>
 
+    <style name="LongPressAlertDialogLight" parent="AlertDialogLight">
+        <item name="android:backgroundTint" 
tools:targetApi="21">?attr/paper_color</item>
+    </style>
+
     <style name="DialogLight" parent="Theme.AppCompat.Light.Dialog">
         <item name="windowActionBar">false</item>
         <item name="windowNoTitle">true</item>

-- 
To view, visit https://gerrit.wikimedia.org/r/383754
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I87ea82116d9a98a085313e9a5ff2b9bb9f2e902e
Gerrit-PatchSet: 3
Gerrit-Project: apps/android/wikipedia
Gerrit-Branch: master
Gerrit-Owner: Cooltey <cf...@wikimedia.org>
Gerrit-Reviewer: Brion VIBBER <br...@wikimedia.org>
Gerrit-Reviewer: Cooltey <cf...@wikimedia.org>
Gerrit-Reviewer: Dbrant <dbr...@wikimedia.org>
Gerrit-Reviewer: Mholloway <mhollo...@wikimedia.org>
Gerrit-Reviewer: Sharvaniharan <sha...@wikimedia.org>
Gerrit-Reviewer: jenkins-bot <>

_______________________________________________
MediaWiki-commits mailing list
MediaWiki-commits@lists.wikimedia.org
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits

Reply via email to