Сбой Android Webview Drop Down только на Android Lollipop (5.0 / 5.1) - PullRequest
0 голосов
/ 05 ноября 2019

Используется ниже для исправления сбоя, возникающего только в веб-просмотре Androd 5.0 и 5.1 (Lollipop) при загрузке после загрузки этого веб-просмотра, но содержит раскрывающийся список. Когда я нажимаю на это приложение, происходит сбой

Проблема Android Lollipop WebView Androidсоздать новую конфигурацию только для этой версии Android

private static Context getFixedContext(Context context) {

if (Build.VERSION.SDK_INT == Build.VERSION_CODES.LOLLIPOP || Build.VERSION.SDK_INT == Build.VERSION_CODES.LOLLIPOP_MR1) // Android Lollipop 5.0 & 5.1
        return context.createConfigurationContext(new Configuration());
    return context;
}

enter image description here

Ниже приведен полный журнал:

11-05 17:17:11.900 1696-2754/system_process W/WindowManager: Attempted to add window with non-application token WindowToken{24e85531 null}.  Aborting  
11-05 17:17:11.900 7203-7203/com.example.android W/System.err: android.view.WindowManager$BadTokenException: Unable to add window -- token null is not for an application  
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.view.ViewRootImpl.setView(ViewRootImpl.java:566)  
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.view.WindowManagerGlobal.addView(WindowManagerGlobal.java:272) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.view.WindowManagerImpl.addView(WindowManagerImpl.java:69) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.app.Dialog.show(Dialog.java:298) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.org.chromium.content.browser.input.SelectPopupDialog.show(SelectPopupDialog.java:126) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.org.chromium.content.browser.ContentViewCore.showSelectPopup(ContentViewCore.java:2467) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.org.chromium.base.SystemMessageHandler.nativeDoRunLoopOnce(Native Method) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.org.chromium.base.SystemMessageHandler.handleMessage(SystemMessageHandler.java:28) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.os.Handler.dispatchMessage(Handler.java:102) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.os.Looper.loop(Looper.java:135) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at android.app.ActivityThread.main(ActivityThread.java:5221) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at java.lang.reflect.Method.invoke(Native Method)  
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at java.lang.reflect.Method.invoke(Method.java:372) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:899) . 
11-05 17:17:11.900 7203-7203/com.example.android W/System.err:     at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:694) . 
11-05 17:17:11.900 7203-7203/com.example.android A/chromium: [FATAL:jni_android.cc(271)] Check failed: false. 


    --------- beginning of crash
11-05 17:17:11.901 7203-7203/com.example.android A/libc: Fatal signal 6 (SIGABRT), code -6 in tid 7203 (.example_droid_wrap) . 
11-05 17:17:12.004 1172-1172/? I/DEBUG: *** *** *** *** *** *** *** *** *** *** *** *** *** *** *** ***
11-05 17:17:12.004 1172-1172/? I/DEBUG: Build fingerprint: 'generic_x86_64/sdk_google_phone_x86_64/generic_x86_64:5.0.2/LSY66K/5523115:eng/test-keys'
11-05 17:17:12.004 1172-1172/? I/DEBUG: Revision: '0' . 
11-05 17:17:12.004 1172-1172/? I/DEBUG: ABI: 'x86_64' . 
11-05 17:17:12.005 1172-1172/? I/DEBUG: pid: 7203, tid: 7203,  
 example.android: .example_droid_wrap  >>> com.example.android <<<
11-05 17:17:12.005 1172-1172/? I/DEBUG: signal 6 (SIGABRT), code -6 (SI_TKILL), fault addr --------
11-05 17:17:12.010 1172-1172/? I/DEBUG: Abort message: '[FATAL:jni_android.cc(271)] Check failed: false. 
    '
11-05 17:17:12.011 1172-1172/? I/DEBUG:     rax 0000000000000000  rbx 0000000000001c23  rcx ffffffffffffffff  rdx 0000000000000006
11-05 17:17:12.011 1172-1172/? I/DEBUG:     rsi 0000000000001c23  rdi 0000000000001c23
11-05 17:17:12.011 1172-1172/? I/DEBUG:     r8  0000000000000054  r9  00007fff6df6c2f1  r10 0000000000000008  r11 0000000000000206
11-05 17:17:12.011 1172-1172/? I/DEBUG:     r12 000000000000000b  r13 0000000000000006  r14 00007fff6df6cc80  r15 0000000000000000
11-05 17:17:12.011 1172-1172/? I/DEBUG:     cs  0000000000000033  ss  000000000000002b
11-05 17:17:12.011 1172-1172/? I/DEBUG:     rip 00007f3f99ff7507  rbp 00007f3f9a08b210  rsp 00007fff6df6c648  eflags 0000000000000206
11-05 17:17:12.011 1172-1172/? I/DEBUG: backtrace:
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #00 pc 0000000000076507  /system/lib64/libc.so (tgkill+7)
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #01 pc 000000000002829f  /system/lib64/libc.so (pthread_kill+143)
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #02 pc 0000000000029571  /system/lib64/libc.so (raise+17)
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #03 pc 0000000000022e1d  /system/lib64/libc.so (abort+61)
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #04 pc 000000000057ce0e  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #05 pc 0000000000559960  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #06 pc 0000000000545037  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #07 pc 0000000000809d47  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #08 pc 000000000088614f  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #09 pc 000000000088a6e9  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #10 pc 0000000000883439  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #11 pc 0000000001886770  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #12 pc 000000000055d0a0  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #13 pc 000000000055d18b  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #14 pc 000000000055da24  /system/lib64/libwebviewchromium.so
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #15 pc 0000000000577b12  /system/lib64/libwebviewchromium.so (Java_com_android_org_chromium_base_SystemMessageHandler_nativeDoRunLoopOnce+34)
11-05 17:17:12.011 1172-1172/? I/DEBUG:     #16 pc 00000000000266ef  /data/dalvik-cache/x86_64/system@app@webview@webview.apk@classes.dex
11-05 17:17:12.149 1172-1172/? I/DEBUG: Tombstone written to: /data/tombstones/tombstone_07
...