1
0
Переглянути джерело

Merge branch 'cabinet_req_2023_05_04' of zhushouping/ich-android into cabinet_req_2023_05_04

寄件开柜弹窗报错处理
朱寿平 1 рік тому
батько
коміт
0f605c8bb5

+ 12 - 12
app/src/main/java/com/emato/ich/fragment/SendInfoConfirmFragment.java

@@ -258,13 +258,13 @@ public class SendInfoConfirmFragment extends Fragment {
                         dialog.dismiss();
                     }).create();
             alertDialog.show();
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setTextSize(20);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
 
             try {
                 //获取mAlert对象
-                Field mAlert = androidx.appcompat.app.AlertDialog.class.getDeclaredField("mAlert");
+                Field mAlert = AlertDialog.class.getDeclaredField("mAlert");
                 mAlert.setAccessible(true);
                 Object mAlertController = mAlert.get(alertDialog);
                 //获取mTitleView并设置大小颜色
@@ -309,13 +309,13 @@ public class SendInfoConfirmFragment extends Fragment {
                         dialog.dismiss();
                     })).create();
             alertDialog.show();
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setTextSize(20);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
 
             try {
                 //获取mAlert对象
-                Field mAlert = androidx.appcompat.app.AlertDialog.class.getDeclaredField("mAlert");
+                Field mAlert = AlertDialog.class.getDeclaredField("mAlert");
                 mAlert.setAccessible(true);
                 Object mAlertController = mAlert.get(alertDialog);
                 //获取mTitleView并设置大小颜色
@@ -360,13 +360,13 @@ public class SendInfoConfirmFragment extends Fragment {
                         dialog.dismiss();
                     })).create();
             alertDialog.show();
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_POSITIVE).setTextSize(20);
-            alertDialog.getButton(androidx.appcompat.app.AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setBackgroundColor(Color.BLUE);
+            alertDialog.getButton(AlertDialog.BUTTON_POSITIVE).setTextSize(20);
+            alertDialog.getButton(AlertDialog.BUTTON_NEGATIVE).setTextSize(20);
 
             try {
                 //获取mAlert对象
-                Field mAlert = androidx.appcompat.app.AlertDialog.class.getDeclaredField("mAlert");
+                Field mAlert = AlertDialog.class.getDeclaredField("mAlert");
                 mAlert.setAccessible(true);
                 Object mAlertController = mAlert.get(alertDialog);
                 //获取mTitleView并设置大小颜色