react-native-webview-bootpay 11.6.47 → 11.18.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +83 -93
- package/android/.gradle/6.8/executionHistory/executionHistory.bin +0 -0
- package/android/.gradle/6.8/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/{7.0-rc-1 → 6.8}/fileChanges/last-build.bin +0 -0
- package/android/.gradle/6.8/fileHashes/fileHashes.bin +0 -0
- package/android/.gradle/6.8/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/{7.0-rc-1/dependencies-accessors → 6.8}/gc.properties +0 -0
- package/android/.gradle/7.1.1/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/{7.0-rc-1 → 7.1.1/dependencies-accessors}/gc.properties +0 -0
- package/android/.gradle/7.1.1/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.1.1/fileChanges/last-build.bin +0 -0
- package/android/.gradle/7.1.1/fileHashes/fileHashes.lock +0 -0
- package/android/.gradle/7.1.1/gc.properties +0 -0
- package/android/.gradle/buildOutputCleanup/buildOutputCleanup.lock +0 -0
- package/android/.gradle/buildOutputCleanup/cache.properties +2 -2
- package/android/.gradle/buildOutputCleanup/outputFiles.bin +0 -0
- package/android/.gradle/checksums/checksums.lock +0 -0
- package/android/.gradle/checksums/md5-checksums.bin +0 -0
- package/android/.gradle/checksums/sha1-checksums.bin +0 -0
- package/android/.idea/.gitignore +3 -0
- package/android/.idea/compiler.xml +6 -0
- package/android/.idea/gradle.xml +19 -0
- package/android/.idea/jarRepositories.xml +30 -0
- package/android/.idea/libraries/Gradle__androidx_annotation_annotation_1_1_0.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_appcompat_appcompat_1_0_2_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_arch_core_core_common_2_0_0.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_arch_core_core_runtime_2_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_asynclayoutinflater_asynclayoutinflater_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_autofill_autofill_1_1_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_collection_collection_1_0_0.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_coordinatorlayout_coordinatorlayout_1_0_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_core_core_1_1_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_cursoradapter_cursoradapter_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_customview_customview_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_documentfile_documentfile_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_drawerlayout_drawerlayout_1_0_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_fragment_fragment_1_0_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_interpolator_interpolator_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_legacy_legacy_support_core_ui_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_legacy_legacy_support_core_utils_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_common_2_0_0.xml +11 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_2_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_livedata_core_2_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_runtime_2_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_lifecycle_lifecycle_viewmodel_2_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_loader_loader_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_localbroadcastmanager_localbroadcastmanager_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_print_print_1_0_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_slidingpanelayout_slidingpanelayout_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_swiperefreshlayout_swiperefreshlayout_1_0_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_1_0_1_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_vectordrawable_vectordrawable_animated_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_versionedparcelable_versionedparcelable_1_1_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_viewpager_viewpager_1_0_0_aar.xml +13 -0
- package/android/.idea/libraries/Gradle__androidx_webkit_webkit_1_4_0_aar.xml +16 -0
- package/android/.idea/libraries/Gradle__com_facebook_fbjni_fbjni_java_only_0_2_2.xml +13 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_drawee_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_fbcore_2_5_0_aar.xml +18 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_fresco_2_5_0_aar.xml +18 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_2_5_0_aar.xml +18 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_base_2_5_0_aar.xml +18 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_native_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_imagepipeline_okhttp3_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_memory_type_ashmem_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_memory_type_java_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_memory_type_native_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_nativeimagefilters_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_nativeimagetranscoder_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_fresco_ui_common_2_5_0_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_infer_annotation_infer_annotation_0_18_0.xml +13 -0
- package/android/.idea/libraries/Gradle__com_facebook_react_react_native_0_66_4_aar.xml +14 -0
- package/android/.idea/libraries/Gradle__com_facebook_soloader_annotation_0_10_1.xml +13 -0
- package/android/.idea/libraries/Gradle__com_facebook_soloader_nativeloader_0_10_1.xml +13 -0
- package/android/.idea/libraries/Gradle__com_facebook_soloader_soloader_0_10_1_aar.xml +15 -0
- package/android/.idea/libraries/Gradle__com_facebook_yoga_proguard_annotations_1_19_0.xml +13 -0
- package/android/.idea/libraries/Gradle__com_google_code_findbugs_jsr305_3_0_2.xml +13 -0
- package/android/.idea/libraries/Gradle__com_squareup_okhttp3_okhttp_4_9_1.xml +13 -0
- package/android/.idea/libraries/Gradle__com_squareup_okhttp3_okhttp_urlconnection_4_9_1.xml +13 -0
- package/android/.idea/libraries/Gradle__com_squareup_okio_okio_2_9_0.xml +13 -0
- package/android/.idea/libraries/Gradle__javax_inject_javax_inject_1.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_annotations_13_0.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_kotlin_kotlin_annotations_jvm_1_3_72.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_kotlin_kotlin_stdlib_1_4_10.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_kotlin_kotlin_stdlib_common_1_4_10.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_kotlin_kotlin_stdlib_jdk7_1_4_10.xml +13 -0
- package/android/.idea/libraries/Gradle__org_jetbrains_kotlin_kotlin_stdlib_jdk8_1_4_10.xml +13 -0
- package/android/.idea/misc.xml +9 -0
- package/android/.idea/modules/android.iml +133 -0
- package/android/.idea/modules.xml +8 -0
- package/android/.idea/vcs.xml +6 -0
- package/android/build/.transforms/cef19407ab645b1b4c01cb89efaec997/results.bin +1 -0
- package/android/build/.transforms/cef19407ab645b1b4c01cb89efaec997/transformed/classes/classes.dex +0 -0
- package/android/build/generated/source/buildConfig/debug/kr/co/bootpay/webview/BuildConfig.java +10 -0
- package/android/build/intermediates/aapt_friendly_merged_manifests/debug/aapt/AndroidManifest.xml +21 -0
- package/android/build/intermediates/aapt_friendly_merged_manifests/debug/aapt/output-metadata.json +18 -0
- package/android/build/intermediates/aar_metadata/debug/aar-metadata.properties +4 -0
- package/android/build/intermediates/annotation_processor_list/debug/annotationProcessors.json +1 -0
- package/android/build/intermediates/compile_library_classes_jar/debug/classes.jar +0 -0
- package/android/build/intermediates/compile_r_class_jar/debug/R.jar +0 -0
- package/android/build/intermediates/compile_symbol_list/debug/R.txt +1857 -0
- package/android/build/intermediates/compiled_local_resources/debug/out/xml_file_provider_paths.xml.flat +0 -0
- package/android/build/intermediates/incremental/mergeDebugJniLibFolders/merger.xml +2 -0
- package/android/build/intermediates/incremental/mergeDebugShaders/merger.xml +2 -0
- package/android/build/intermediates/incremental/packageDebugAssets/merger.xml +2 -0
- package/android/build/intermediates/incremental/packageDebugResources/compile-file-map.properties +2 -0
- package/android/build/intermediates/incremental/packageDebugResources/merger.xml +2 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebChromeClient.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebView$1.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebView$BPCWebViewBridge.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebView$ProgressChangedFilter.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebView.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewClient.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewFileProvider.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewManager$1.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewManager$2.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewManager$3.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewManager$4.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewManager.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule$1.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule$2.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule$MimeType.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule$ShouldOverrideUrlLoadingLock$ShouldOverrideCallbackState.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule$ShouldOverrideUrlLoadingLock.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BPCWebViewModule.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BasicAuthCredential.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/BuildConfig.class +0 -0
- package/android/build/intermediates/javac/debug/classes/kr/co/bootpay/webview/WebViewConfig.class +0 -0
- package/android/build/intermediates/library_java_res/debug/res.jar +0 -0
- package/android/build/intermediates/local_only_symbol_list/debug/R-def.txt +3 -0
- package/android/build/intermediates/manifest_merge_blame_file/debug/manifest-merger-blame-debug-report.txt +32 -0
- package/android/build/intermediates/merged_manifest/debug/AndroidManifest.xml +21 -0
- package/android/build/intermediates/navigation_json/debug/navigation.json +1 -0
- package/android/build/intermediates/packaged_manifests/debug/output-metadata.json +18 -0
- package/android/build/intermediates/packaged_res/debug/xml/file_provider_paths.xml +6 -0
- package/android/build/intermediates/runtime_library_classes_jar/debug/classes.jar +0 -0
- package/android/build/intermediates/symbol_list_with_package_name/debug/package-aware-r.txt +1377 -0
- package/android/build/kotlin/compileDebugKotlin/build-history.bin +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/inputs/source-to-output.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-attributes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/class-fq-name-to-source.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/constants.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/internal-name-to-source.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/proto.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/source-to-classes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/subtypes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/jvm/kotlin/supertypes.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/counters.tab +2 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/file-to-id.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/id-to-file.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab.keystream +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab.keystream.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab.values.at +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab_i +0 -0
- package/android/build/kotlin/compileDebugKotlin/caches-jvm/lookups/lookups.tab_i.len +0 -0
- package/android/build/kotlin/compileDebugKotlin/last-build.bin +0 -0
- package/android/build/outputs/logs/manifest-merger-debug-report.txt +43 -0
- package/android/build/tmp/compileDebugJavaWithJavac/previous-compilation-data.bin +0 -0
- package/android/build/tmp/kotlin-classes/debug/META-INF/react-native-webview_debug.kotlin_module +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/BPCWebViewPackage.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopHttpErrorEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopHttpErrorEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingErrorEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingErrorEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingFinishEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingFinishEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingProgressEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingProgressEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingStartEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopLoadingStartEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopMessageEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopMessageEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopRenderProcessGoneEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopRenderProcessGoneEvent.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopShouldStartLoadWithRequestEvent$Companion.class +0 -0
- package/android/build/tmp/kotlin-classes/debug/kr/co/bootpay/webview/events/TopShouldStartLoadWithRequestEvent.class +0 -0
- package/android/build.gradle +4 -6
- package/android/gradle/wrapper/gradle-wrapper.jar +0 -0
- package/android/gradle/wrapper/gradle-wrapper.properties +5 -0
- package/android/gradle.properties +6 -5
- package/android/gradlew +185 -0
- package/android/gradlew.bat +89 -0
- package/android/local.properties +8 -0
- package/android/src/main/AndroidManifest.xml +0 -78
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebChromeClient.java +2 -114
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebView.java +26 -11
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebViewClient.java +134 -103
- package/android/src/main/java/kr/co/bootpay/webview/BPCWebViewManager.java +95 -49
- package/android/src/main/java/kr/co/bootpay/webview/BasicAuthCredential.java +12 -0
- package/apple/BPCWebView.h +19 -0
- package/apple/BPCWebView.m +363 -161
- package/apple/BPCWebViewManager.h +2 -0
- package/apple/BPCWebViewManager.m +25 -1
- package/index.d.ts +5 -5
- package/ios/.DS_Store +0 -0
- package/ios/RNCWebView.xcodeproj/project.pbxproj +18 -18
- package/ios/RNCWebView.xcodeproj/project.xcworkspace/contents.xcworkspacedata +7 -0
- package/ios/RNCWebView.xcodeproj/project.xcworkspace/xcshareddata/IDEWorkspaceChecks.plist +8 -0
- package/ios/RNCWebView.xcodeproj/project.xcworkspace/xcuserdata/bootpay.xcuserdatad/UserInterfaceState.xcuserstate +0 -0
- package/ios/RNCWebView.xcodeproj/xcshareddata/xcschemes/RNCWebView.xcscheme +68 -0
- package/ios/RNCWebView.xcodeproj/xcuserdata/bootpay.xcuserdatad/xcschemes/xcschememanagement.plist +22 -0
- package/lib/WebView.android.d.ts +3 -0
- package/lib/WebView.android.d.ts.map +1 -1
- package/lib/WebView.android.js +22 -11
- package/lib/WebView.d.ts +2 -2
- package/lib/WebView.d.ts.map +1 -1
- package/lib/WebView.ios.d.ts +1 -0
- package/lib/WebView.ios.d.ts.map +1 -1
- package/lib/WebView.ios.js +23 -14
- package/lib/WebView.js +4 -4
- package/lib/WebView.macos.d.ts.map +1 -1
- package/lib/WebView.macos.js +21 -13
- package/lib/WebView.windows.d.ts +4 -2
- package/lib/WebView.windows.d.ts.map +1 -1
- package/lib/WebView.windows.js +22 -14
- package/lib/WebViewNativeComponent.android.d.ts +4 -0
- package/lib/WebViewNativeComponent.android.d.ts.map +1 -0
- package/lib/WebViewNativeComponent.android.js +3 -0
- package/lib/WebViewNativeComponent.ios.d.ts +4 -0
- package/lib/WebViewNativeComponent.ios.d.ts.map +1 -0
- package/lib/WebViewNativeComponent.ios.js +3 -0
- package/lib/WebViewNativeComponent.macos.d.ts +4 -0
- package/lib/WebViewNativeComponent.macos.d.ts.map +1 -0
- package/lib/WebViewNativeComponent.macos.js +3 -0
- package/lib/WebViewNativeComponent.windows.d.ts +4 -0
- package/lib/WebViewNativeComponent.windows.d.ts.map +1 -0
- package/lib/WebViewNativeComponent.windows.js +3 -0
- package/lib/WebViewShared.d.ts +1 -0
- package/lib/WebViewShared.d.ts.map +1 -1
- package/lib/WebViewShared.js +14 -12
- package/lib/WebViewTypes.d.ts +113 -2
- package/lib/WebViewTypes.d.ts.map +1 -1
- package/lib/WebViewTypes.js +3 -1
- package/lib/index.d.ts +4 -0
- package/lib/index.d.ts.map +1 -0
- package/lib/index.js +3 -0
- package/package.json +31 -32
- package/react-native-webview-bootpay.podspec +1 -3
- package/react-native.config.js +47 -61
- package/windows/ExperimentalFeatures.props +12 -0
- package/windows/ReactNativeWebView/ReactNativeWebView.vcxproj +37 -20
- package/windows/ReactNativeWebView/ReactPackageProvider.cpp +5 -1
- package/windows/ReactNativeWebView/ReactWebView.cpp +2 -6
- package/windows/ReactNativeWebView/ReactWebView.h +3 -2
- package/windows/ReactNativeWebView/ReactWebView.idl +13 -1
- package/windows/ReactNativeWebView/ReactWebView2.cpp +119 -0
- package/windows/ReactNativeWebView/ReactWebView2.h +43 -0
- package/windows/ReactNativeWebView/ReactWebView2Manager.cpp +147 -0
- package/windows/ReactNativeWebView/ReactWebView2Manager.h +54 -0
- package/windows/ReactNativeWebView/ReactWebViewManager.cpp +36 -31
- package/windows/{WebViewBridgeComponent → ReactNativeWebView}/WebBridge.cpp +1 -1
- package/windows/{WebViewBridgeComponent → ReactNativeWebView}/WebBridge.h +2 -2
- package/windows/{WebViewBridgeComponent → ReactNativeWebView}/WebBridge.idl +1 -1
- package/windows/ReactNativeWebView/packages.config +2 -0
- package/windows/ReactNativeWebView/pch.h +6 -0
- package/windows/ReactNativeWebView.sln +81 -119
- package/android/.gradle/7.0-rc-1/dependencies-accessors/dependencies-accessors.lock +0 -0
- package/android/.gradle/7.0-rc-1/executionHistory/executionHistory.lock +0 -0
- package/android/.gradle/7.0-rc-1/fileHashes/fileHashes.lock +0 -0
- package/android/.project +0 -28
- package/android/.settings/org.eclipse.buildship.core.prefs +0 -13
- package/windows/WebViewBridgeComponent/PropertySheet.props +0 -16
- package/windows/WebViewBridgeComponent/WebViewBridgeComponent.def +0 -3
- package/windows/WebViewBridgeComponent/WebViewBridgeComponent.vcxproj +0 -160
- package/windows/WebViewBridgeComponent/WebViewBridgeComponent.vcxproj.filters +0 -33
- package/windows/WebViewBridgeComponent/packages.config +0 -4
- package/windows/WebViewBridgeComponent/pch.cpp +0 -1
- package/windows/WebViewBridgeComponent/pch.h +0 -4
- package/windows/WebViewBridgeComponent/readme.txt +0 -23
|
@@ -10,6 +10,7 @@ import android.net.http.SslError;
|
|
|
10
10
|
import android.os.Build;
|
|
11
11
|
import android.os.SystemClock;
|
|
12
12
|
import android.util.Log;
|
|
13
|
+
import android.webkit.HttpAuthHandler;
|
|
13
14
|
import android.webkit.RenderProcessGoneDetail;
|
|
14
15
|
import android.webkit.SslErrorHandler;
|
|
15
16
|
import android.webkit.WebResourceRequest;
|
|
@@ -30,15 +31,18 @@ import com.facebook.react.bridge.WritableMap;
|
|
|
30
31
|
import java.net.URISyntaxException;
|
|
31
32
|
import java.util.concurrent.atomic.AtomicReference;
|
|
32
33
|
|
|
34
|
+
|
|
33
35
|
import kr.co.bootpay.webview.events.TopHttpErrorEvent;
|
|
34
36
|
import kr.co.bootpay.webview.events.TopLoadingErrorEvent;
|
|
35
37
|
import kr.co.bootpay.webview.events.TopLoadingFinishEvent;
|
|
36
38
|
import kr.co.bootpay.webview.events.TopLoadingStartEvent;
|
|
37
39
|
import kr.co.bootpay.webview.events.TopRenderProcessGoneEvent;
|
|
38
40
|
import kr.co.bootpay.webview.events.TopShouldStartLoadWithRequestEvent;
|
|
41
|
+
import kr.co.bootpay.webview.BPCWebViewModule.ShouldOverrideUrlLoadingLock.ShouldOverrideCallbackState;
|
|
42
|
+
|
|
39
43
|
|
|
40
|
-
|
|
41
|
-
private static final String TAG = "
|
|
44
|
+
class BPCWebViewClient extends WebViewClient {
|
|
45
|
+
private static final String TAG = "BPCWebViewManager";
|
|
42
46
|
protected static final int SHOULD_OVERRIDE_URL_LOADING_TIMEOUT = 250;
|
|
43
47
|
|
|
44
48
|
protected boolean mLastLoadFailed = false;
|
|
@@ -46,11 +50,16 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
46
50
|
ReadableArray mUrlPrefixesForDefaultIntent;
|
|
47
51
|
protected BPCWebView.ProgressChangedFilter progressChangedFilter = null;
|
|
48
52
|
protected @Nullable String ignoreErrFailedForThisURL = null;
|
|
53
|
+
protected @Nullable BasicAuthCredential basicAuthCredential = null;
|
|
49
54
|
|
|
50
55
|
public void setIgnoreErrFailedForThisURL(@Nullable String url) {
|
|
51
56
|
ignoreErrFailedForThisURL = url;
|
|
52
57
|
}
|
|
53
58
|
|
|
59
|
+
public void setBasicAuthCredential(@Nullable BasicAuthCredential credential) {
|
|
60
|
+
basicAuthCredential = credential;
|
|
61
|
+
}
|
|
62
|
+
|
|
54
63
|
@Override
|
|
55
64
|
public void onPageFinished(WebView webView, String url) {
|
|
56
65
|
super.onPageFinished(webView, url);
|
|
@@ -94,20 +103,17 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
94
103
|
if(isInstallApp(intent, context)) return startApp(intent, context);
|
|
95
104
|
else return startGooglePlay(intent, context);
|
|
96
105
|
}
|
|
97
|
-
// return url.contains("vguardend");
|
|
98
106
|
return shouldOverrideUrlLoadingRN(view, url);
|
|
99
107
|
}
|
|
100
108
|
|
|
101
|
-
|
|
102
|
-
private boolean shouldOverrideUrlLoadingRN(WebView view, String url) {
|
|
103
|
-
|
|
109
|
+
public boolean shouldOverrideUrlLoadingRN(WebView view, String url) {
|
|
104
110
|
final BPCWebView bpcWebView = (BPCWebView) view;
|
|
105
111
|
final boolean isJsDebugging = ((ReactContext) view.getContext()).getJavaScriptContextHolder().get() == 0;
|
|
106
112
|
|
|
107
113
|
if (!isJsDebugging && bpcWebView.mCatalystInstance != null) {
|
|
108
|
-
final Pair<Integer, AtomicReference<
|
|
114
|
+
final Pair<Integer, AtomicReference<ShouldOverrideCallbackState>> lock = BPCWebViewModule.shouldOverrideUrlLoadingLock.getNewLock();
|
|
109
115
|
final int lockIdentifier = lock.first;
|
|
110
|
-
final AtomicReference<
|
|
116
|
+
final AtomicReference<ShouldOverrideCallbackState> lockObject = lock.second;
|
|
111
117
|
|
|
112
118
|
final WritableMap event = createWebViewEvent(view, url);
|
|
113
119
|
event.putInt("lockIdentifier", lockIdentifier);
|
|
@@ -117,7 +123,7 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
117
123
|
assert lockObject != null;
|
|
118
124
|
synchronized (lockObject) {
|
|
119
125
|
final long startTime = SystemClock.elapsedRealtime();
|
|
120
|
-
while (lockObject.get() ==
|
|
126
|
+
while (lockObject.get() == ShouldOverrideCallbackState.UNDECIDED) {
|
|
121
127
|
if (SystemClock.elapsedRealtime() - startTime > SHOULD_OVERRIDE_URL_LOADING_TIMEOUT) {
|
|
122
128
|
FLog.w(TAG, "Did not receive response to shouldOverrideUrlLoading in time, defaulting to allow loading.");
|
|
123
129
|
BPCWebViewModule.shouldOverrideUrlLoadingLock.removeLock(lockIdentifier);
|
|
@@ -132,7 +138,7 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
132
138
|
return false;
|
|
133
139
|
}
|
|
134
140
|
|
|
135
|
-
final boolean shouldOverride = lockObject.get() ==
|
|
141
|
+
final boolean shouldOverride = lockObject.get() == ShouldOverrideCallbackState.SHOULD_OVERRIDE;
|
|
136
142
|
BPCWebViewModule.shouldOverrideUrlLoadingLock.removeLock(lockIdentifier);
|
|
137
143
|
|
|
138
144
|
return shouldOverride;
|
|
@@ -148,96 +154,6 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
148
154
|
}
|
|
149
155
|
}
|
|
150
156
|
|
|
151
|
-
|
|
152
|
-
protected Boolean isSpecialCase(String url) {
|
|
153
|
-
return url.matches("^shinhan\\S+$")
|
|
154
|
-
|| url.startsWith("kftc-bankpay://")
|
|
155
|
-
|| url.startsWith("v3mobileplusweb://")
|
|
156
|
-
|| url.startsWith("hdcardappcardansimclick://")
|
|
157
|
-
|| url.startsWith("nidlogin://")
|
|
158
|
-
|| url.startsWith("mpocket.online.ansimclick://")
|
|
159
|
-
|| url.startsWith("wooripay://")
|
|
160
|
-
|| url.startsWith("kakaotalk://");
|
|
161
|
-
}
|
|
162
|
-
|
|
163
|
-
protected Boolean isIntent(String url) {
|
|
164
|
-
return url.startsWith("intent:");
|
|
165
|
-
}
|
|
166
|
-
protected Boolean isMarket(String url) {
|
|
167
|
-
return url.startsWith("market://");
|
|
168
|
-
}
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
protected Intent getIntentWithPackage(String url) {
|
|
172
|
-
try {
|
|
173
|
-
Intent intent = Intent.parseUri(url, Intent.URI_INTENT_SCHEME);
|
|
174
|
-
if(intent.getPackage() == null) {
|
|
175
|
-
if (url == null) return intent;
|
|
176
|
-
if (url.startsWith("shinhan-sr-ansimclick")) intent.setPackage("com.shcard.smartpay");
|
|
177
|
-
else if (url.startsWith("kftc-bankpay")) intent.setPackage("com.kftc.bankpay.android");
|
|
178
|
-
else if (url.startsWith("ispmobile")) intent.setPackage("kvp.jjy.MispAndroid320");
|
|
179
|
-
else if (url.startsWith("hdcardappcardansimclick")) intent.setPackage("com.hyundaicard.appcard");
|
|
180
|
-
else if (url.startsWith("kb-acp")) intent.setPackage("com.kbcard.kbkookmincard");
|
|
181
|
-
else if (url.startsWith("mpocket.online.ansimclick")) intent.setPackage("kr.co.samsungcard.mpocket");
|
|
182
|
-
else if (url.startsWith("lotteappcard")) intent.setPackage("com.lcacApp");
|
|
183
|
-
else if (url.startsWith("cloudpay")) intent.setPackage("com.hanaskcard.paycla");
|
|
184
|
-
else if (url.startsWith("nhappvardansimclick")) intent.setPackage("nh.smart.nhallonepay");
|
|
185
|
-
else if (url.startsWith("citispay")) intent.setPackage("kr.co.citibank.citimobile");
|
|
186
|
-
else if (url.startsWith("kakaotalk")) intent.setPackage("com.kakao.talk");
|
|
187
|
-
}
|
|
188
|
-
return intent;
|
|
189
|
-
} catch (URISyntaxException e) {
|
|
190
|
-
e.printStackTrace();
|
|
191
|
-
return null;
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
|
|
195
|
-
protected boolean isInstallApp(Intent intent, Context context) {
|
|
196
|
-
return isExistPackageInfo(intent, context) || isExistLaunchedIntent(intent, context);
|
|
197
|
-
}
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
protected boolean isExistPackageInfo(Intent intent, Context context) {
|
|
201
|
-
try {
|
|
202
|
-
return intent != null && context.getPackageManager().getPackageInfo(intent.getPackage(), PackageManager.GET_ACTIVITIES) != null;
|
|
203
|
-
} catch (PackageManager.NameNotFoundException e) {
|
|
204
|
-
e.printStackTrace();
|
|
205
|
-
return false;
|
|
206
|
-
}
|
|
207
|
-
}
|
|
208
|
-
|
|
209
|
-
protected boolean isExistLaunchedIntent(Intent intent, Context context) {
|
|
210
|
-
return intent != null && intent.getPackage() != null && context.getPackageManager().getLaunchIntentForPackage(intent.getPackage()) != null;
|
|
211
|
-
}
|
|
212
|
-
|
|
213
|
-
protected boolean startApp(Intent intent, Context context) {
|
|
214
|
-
context.startActivity(intent);
|
|
215
|
-
return true;
|
|
216
|
-
}
|
|
217
|
-
|
|
218
|
-
protected boolean startGooglePlay(Intent intent, Context context) {
|
|
219
|
-
final String appPackageName = intent.getPackage();
|
|
220
|
-
if(appPackageName == null) {
|
|
221
|
-
Uri dataUri = intent.getData();
|
|
222
|
-
|
|
223
|
-
try {
|
|
224
|
-
context.startActivity(new Intent(Intent.ACTION_VIEW, intent.getData()));
|
|
225
|
-
} catch (Exception e) {
|
|
226
|
-
String packageName = "com.nhn.android.search"; //appPackageName이 비어있으면 네이버로 보내기(네이버 로그인)
|
|
227
|
-
if(dataUri != null && dataUri.toString().startsWith("wooripay://")) packageName = "com.wooricard.wpay"; //우리카드 예외처리
|
|
228
|
-
|
|
229
|
-
context.startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=" + packageName)));
|
|
230
|
-
}
|
|
231
|
-
return true;
|
|
232
|
-
}
|
|
233
|
-
try {
|
|
234
|
-
context.startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appPackageName)));
|
|
235
|
-
} catch (android.content.ActivityNotFoundException anfe) {
|
|
236
|
-
context.startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=" + appPackageName)));
|
|
237
|
-
}
|
|
238
|
-
return true;
|
|
239
|
-
}
|
|
240
|
-
|
|
241
157
|
@TargetApi(Build.VERSION_CODES.N)
|
|
242
158
|
@Override
|
|
243
159
|
public boolean shouldOverrideUrlLoading(WebView view, WebResourceRequest request) {
|
|
@@ -245,6 +161,15 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
245
161
|
return this.shouldOverrideUrlLoading(view, url);
|
|
246
162
|
}
|
|
247
163
|
|
|
164
|
+
@Override
|
|
165
|
+
public void onReceivedHttpAuthRequest(WebView view, HttpAuthHandler handler, String host, String realm) {
|
|
166
|
+
if (basicAuthCredential != null) {
|
|
167
|
+
handler.proceed(basicAuthCredential.username, basicAuthCredential.password);
|
|
168
|
+
return;
|
|
169
|
+
}
|
|
170
|
+
super.onReceivedHttpAuthRequest(view, handler, host, realm);
|
|
171
|
+
}
|
|
172
|
+
|
|
248
173
|
@Override
|
|
249
174
|
public void onReceivedSslError(final WebView webView, final SslErrorHandler handler, final SslError error) {
|
|
250
175
|
// onReceivedSslError is called for most requests, per Android docs: https://developer.android.com/reference/android/webkit/WebViewClient#onReceivedSslError(android.webkit.WebView,%2520android.webkit.SslErrorHandler,%2520android.net.http.SslError)
|
|
@@ -261,7 +186,7 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
261
186
|
|
|
262
187
|
if (!topWindowUrl.equalsIgnoreCase(failingUrl)) {
|
|
263
188
|
// If error is not due to top-level navigation, then do not call onReceivedError()
|
|
264
|
-
Log.w(
|
|
189
|
+
Log.w(TAG, "Resource blocked from loading due to SSL error. Blocked URL: "+failingUrl);
|
|
265
190
|
return;
|
|
266
191
|
}
|
|
267
192
|
|
|
@@ -370,10 +295,10 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
370
295
|
super.onRenderProcessGone(webView, detail);
|
|
371
296
|
|
|
372
297
|
if(detail.didCrash()){
|
|
373
|
-
Log.e(
|
|
298
|
+
Log.e(TAG, "The WebView rendering process crashed.");
|
|
374
299
|
}
|
|
375
300
|
else{
|
|
376
|
-
Log.w(
|
|
301
|
+
Log.w(TAG, "The WebView rendering process was killed by the system.");
|
|
377
302
|
}
|
|
378
303
|
|
|
379
304
|
// if webView is null, we cannot return any event
|
|
@@ -423,4 +348,110 @@ public class BPCWebViewClient extends WebViewClient {
|
|
|
423
348
|
public void setProgressChangedFilter(BPCWebView.ProgressChangedFilter filter) {
|
|
424
349
|
progressChangedFilter = filter;
|
|
425
350
|
}
|
|
351
|
+
|
|
352
|
+
|
|
353
|
+
protected Boolean isSpecialCase(String url) {
|
|
354
|
+
return url.matches("^shinhan\\S+$")
|
|
355
|
+
|| url.startsWith("kftc-bankpay://")
|
|
356
|
+
|| url.startsWith("v3mobileplusweb://")
|
|
357
|
+
|| url.startsWith("hdcardappcardansimclick://")
|
|
358
|
+
|| url.startsWith("nidlogin://")
|
|
359
|
+
|| url.startsWith("mpocket.online.ansimclick://")
|
|
360
|
+
|| url.startsWith("wooripay://")
|
|
361
|
+
|| url.startsWith("kakaotalk://");
|
|
362
|
+
}
|
|
363
|
+
|
|
364
|
+
protected Boolean isIntent(String url) {
|
|
365
|
+
return url.startsWith("intent:");
|
|
366
|
+
}
|
|
367
|
+
protected Boolean isMarket(String url) {
|
|
368
|
+
return url.startsWith("market://");
|
|
369
|
+
}
|
|
370
|
+
|
|
371
|
+
|
|
372
|
+
protected Intent getIntentWithPackage(String url) {
|
|
373
|
+
try {
|
|
374
|
+
Intent intent = Intent.parseUri(url, Intent.URI_INTENT_SCHEME);
|
|
375
|
+
if(intent.getPackage() == null) {
|
|
376
|
+
if (url == null) return intent;
|
|
377
|
+
if (url.startsWith("shinhan-sr-ansimclick")) intent.setPackage("com.shcard.smartpay");
|
|
378
|
+
else if (url.startsWith("kftc-bankpay")) intent.setPackage("com.kftc.bankpay.android");
|
|
379
|
+
else if (url.startsWith("ispmobile")) intent.setPackage("kvp.jjy.MispAndroid320");
|
|
380
|
+
else if (url.startsWith("hdcardappcardansimclick")) intent.setPackage("com.hyundaicard.appcard");
|
|
381
|
+
else if (url.startsWith("kb-acp")) intent.setPackage("com.kbcard.kbkookmincard");
|
|
382
|
+
else if (url.startsWith("mpocket.online.ansimclick")) intent.setPackage("kr.co.samsungcard.mpocket");
|
|
383
|
+
else if (url.startsWith("lotteappcard")) intent.setPackage("com.lcacApp");
|
|
384
|
+
else if (url.startsWith("cloudpay")) intent.setPackage("com.hanaskcard.paycla");
|
|
385
|
+
else if (url.startsWith("nhappvardansimclick")) intent.setPackage("nh.smart.nhallonepay");
|
|
386
|
+
else if (url.startsWith("citispay")) intent.setPackage("kr.co.citibank.citimobile");
|
|
387
|
+
else if (url.startsWith("kakaotalk")) intent.setPackage("com.kakao.talk");
|
|
388
|
+
}
|
|
389
|
+
return intent;
|
|
390
|
+
} catch (URISyntaxException e) {
|
|
391
|
+
e.printStackTrace();
|
|
392
|
+
return null;
|
|
393
|
+
}
|
|
394
|
+
}
|
|
395
|
+
|
|
396
|
+
protected boolean isInstallApp(Intent intent, Context context) {
|
|
397
|
+
return isExistPackageInfo(intent, context) || isExistLaunchedIntent(intent, context);
|
|
398
|
+
}
|
|
399
|
+
|
|
400
|
+
|
|
401
|
+
protected boolean isExistPackageInfo(Intent intent, Context context) {
|
|
402
|
+
try {
|
|
403
|
+
return intent != null && context.getPackageManager().getPackageInfo(intent.getPackage(), PackageManager.GET_ACTIVITIES) != null;
|
|
404
|
+
} catch (PackageManager.NameNotFoundException e) {
|
|
405
|
+
e.printStackTrace();
|
|
406
|
+
return false;
|
|
407
|
+
}
|
|
408
|
+
}
|
|
409
|
+
|
|
410
|
+
protected boolean isExistLaunchedIntent(Intent intent, Context context) {
|
|
411
|
+
return intent != null && intent.getPackage() != null && context.getPackageManager().getLaunchIntentForPackage(intent.getPackage()) != null;
|
|
412
|
+
}
|
|
413
|
+
|
|
414
|
+
protected boolean startApp(Intent intent, Context context) {
|
|
415
|
+
intent.addFlags(intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
416
|
+
intent.addFlags(intent.FLAG_ACTIVITY_NEW_TASK);
|
|
417
|
+
context.startActivity(intent);
|
|
418
|
+
return true;
|
|
419
|
+
}
|
|
420
|
+
|
|
421
|
+
protected boolean startGooglePlay(Intent intent, Context context) {
|
|
422
|
+
final String appPackageName = intent.getPackage();
|
|
423
|
+
|
|
424
|
+
if(appPackageName == null) {
|
|
425
|
+
Uri dataUri = intent.getData();
|
|
426
|
+
|
|
427
|
+
try {
|
|
428
|
+
Intent addIntent = new Intent(Intent.ACTION_VIEW, intent.getData());
|
|
429
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
430
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_NEW_TASK);
|
|
431
|
+
context.startActivity(addIntent);
|
|
432
|
+
} catch (Exception e) {
|
|
433
|
+
String packageName = "com.nhn.android.search"; //appPackageName이 비어있으면 네이버로 보내기(네이버 로그인)
|
|
434
|
+
if(dataUri != null && dataUri.toString().startsWith("wooripay://")) packageName = "com.wooricard.wpay"; //우리카드 예외처리
|
|
435
|
+
|
|
436
|
+
Intent addIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=" + packageName));
|
|
437
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
438
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_NEW_TASK);
|
|
439
|
+
context.startActivity(addIntent);
|
|
440
|
+
// context.startActivity(new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=" + packageName)));
|
|
441
|
+
}
|
|
442
|
+
return true;
|
|
443
|
+
}
|
|
444
|
+
try {
|
|
445
|
+
Intent addIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("market://details?id=" + appPackageName));
|
|
446
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
447
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_NEW_TASK);
|
|
448
|
+
context.startActivity(addIntent);
|
|
449
|
+
} catch (android.content.ActivityNotFoundException anfe) {
|
|
450
|
+
Intent addIntent = new Intent(Intent.ACTION_VIEW, Uri.parse("https://play.google.com/store/apps/details?id=" + appPackageName));
|
|
451
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_CLEAR_TASK);
|
|
452
|
+
addIntent.addFlags(intent.FLAG_ACTIVITY_NEW_TASK);
|
|
453
|
+
context.startActivity(addIntent);
|
|
454
|
+
}
|
|
455
|
+
return true;
|
|
456
|
+
}
|
|
426
457
|
}
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
package kr.co.bootpay.webview;
|
|
2
2
|
|
|
3
|
-
import android.annotation.SuppressLint;
|
|
4
3
|
import android.annotation.TargetApi;
|
|
5
4
|
import android.app.Activity;
|
|
6
5
|
import android.app.DownloadManager;
|
|
@@ -10,13 +9,10 @@ import android.content.pm.PackageManager;
|
|
|
10
9
|
import android.graphics.Bitmap;
|
|
11
10
|
import android.graphics.Color;
|
|
12
11
|
import android.Manifest;
|
|
13
|
-
import android.net.http.SslError;
|
|
14
12
|
import android.net.Uri;
|
|
15
13
|
import android.os.Build;
|
|
16
14
|
import android.os.Environment;
|
|
17
15
|
import android.os.Message;
|
|
18
|
-
import android.os.SystemClock;
|
|
19
|
-
import android.text.TextUtils;
|
|
20
16
|
import android.util.Log;
|
|
21
17
|
import android.view.Gravity;
|
|
22
18
|
import android.view.View;
|
|
@@ -27,51 +23,36 @@ import android.webkit.ConsoleMessage;
|
|
|
27
23
|
import android.webkit.CookieManager;
|
|
28
24
|
import android.webkit.DownloadListener;
|
|
29
25
|
import android.webkit.GeolocationPermissions;
|
|
30
|
-
import android.webkit.JavascriptInterface;
|
|
31
|
-
import android.webkit.RenderProcessGoneDetail;
|
|
32
|
-
import android.webkit.SslErrorHandler;
|
|
33
26
|
import android.webkit.PermissionRequest;
|
|
34
27
|
import android.webkit.URLUtil;
|
|
35
28
|
import android.webkit.ValueCallback;
|
|
36
29
|
import android.webkit.WebChromeClient;
|
|
37
|
-
import android.webkit.WebResourceRequest;
|
|
38
|
-
import android.webkit.WebResourceResponse;
|
|
39
30
|
import android.webkit.WebSettings;
|
|
40
31
|
import android.webkit.WebView;
|
|
41
|
-
import android.webkit.WebViewClient;
|
|
42
32
|
import android.widget.FrameLayout;
|
|
43
33
|
|
|
44
34
|
import androidx.annotation.Nullable;
|
|
45
35
|
import androidx.annotation.RequiresApi;
|
|
46
36
|
import androidx.core.content.ContextCompat;
|
|
47
|
-
import androidx.
|
|
37
|
+
import androidx.webkit.WebSettingsCompat;
|
|
38
|
+
import androidx.webkit.WebViewFeature;
|
|
48
39
|
|
|
49
|
-
import com.facebook.common.logging.FLog;
|
|
50
40
|
import com.facebook.react.modules.core.PermissionAwareActivity;
|
|
51
41
|
import com.facebook.react.modules.core.PermissionListener;
|
|
52
|
-
import com.facebook.react.views.scroll.ScrollEvent;
|
|
53
42
|
import com.facebook.react.views.scroll.ScrollEventType;
|
|
54
|
-
import com.facebook.react.views.scroll.OnScrollDispatchHelper;
|
|
55
43
|
import com.facebook.react.bridge.Arguments;
|
|
56
|
-
import com.facebook.react.bridge.CatalystInstance;
|
|
57
44
|
import com.facebook.react.bridge.LifecycleEventListener;
|
|
58
45
|
import com.facebook.react.bridge.ReactContext;
|
|
59
46
|
import com.facebook.react.bridge.ReadableArray;
|
|
60
47
|
import com.facebook.react.bridge.ReadableMap;
|
|
61
48
|
import com.facebook.react.bridge.ReadableMapKeySetIterator;
|
|
62
49
|
import com.facebook.react.bridge.WritableMap;
|
|
63
|
-
import com.facebook.react.bridge.WritableNativeArray;
|
|
64
|
-
import com.facebook.react.bridge.WritableNativeMap;
|
|
65
50
|
import com.facebook.react.common.MapBuilder;
|
|
66
51
|
import com.facebook.react.common.build.ReactBuildConfig;
|
|
67
52
|
import com.facebook.react.module.annotations.ReactModule;
|
|
68
53
|
import com.facebook.react.uimanager.SimpleViewManager;
|
|
69
54
|
import com.facebook.react.uimanager.ThemedReactContext;
|
|
70
|
-
import com.facebook.react.uimanager.UIManagerModule;
|
|
71
55
|
import com.facebook.react.uimanager.annotations.ReactProp;
|
|
72
|
-
import com.facebook.react.uimanager.events.ContentSizeChangeEvent;
|
|
73
|
-
import com.facebook.react.uimanager.events.Event;
|
|
74
|
-
import com.facebook.react.uimanager.events.EventDispatcher;
|
|
75
56
|
import kr.co.bootpay.webview.BPCWebViewModule.ShouldOverrideUrlLoadingLock.ShouldOverrideCallbackState;
|
|
76
57
|
import kr.co.bootpay.webview.events.TopLoadingErrorEvent;
|
|
77
58
|
import kr.co.bootpay.webview.events.TopHttpErrorEvent;
|
|
@@ -86,16 +67,15 @@ import org.json.JSONException;
|
|
|
86
67
|
import org.json.JSONObject;
|
|
87
68
|
|
|
88
69
|
import java.io.UnsupportedEncodingException;
|
|
70
|
+
import java.lang.IllegalArgumentException;
|
|
89
71
|
import java.net.MalformedURLException;
|
|
90
72
|
import java.net.URL;
|
|
91
|
-
import java.net.URLEncoder;
|
|
92
73
|
import java.util.ArrayList;
|
|
93
74
|
import java.util.Collections;
|
|
94
75
|
import java.util.HashMap;
|
|
95
76
|
import java.util.List;
|
|
96
77
|
import java.util.Locale;
|
|
97
78
|
import java.util.Map;
|
|
98
|
-
import java.util.concurrent.atomic.AtomicReference;
|
|
99
79
|
|
|
100
80
|
/**
|
|
101
81
|
* Manages instances of {@link WebView}
|
|
@@ -123,6 +103,7 @@ import java.util.concurrent.atomic.AtomicReference;
|
|
|
123
103
|
*/
|
|
124
104
|
@ReactModule(name = BPCWebViewManager.REACT_CLASS)
|
|
125
105
|
public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
106
|
+
private static final String TAG = "BPCWebViewManager";
|
|
126
107
|
|
|
127
108
|
public static final int COMMAND_GO_BACK = 1;
|
|
128
109
|
public static final int COMMAND_GO_FORWARD = 2;
|
|
@@ -141,11 +122,12 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
141
122
|
protected static final String REACT_CLASS = "BPCWebView";
|
|
142
123
|
protected static final String HTML_ENCODING = "UTF-8";
|
|
143
124
|
protected static final String HTML_MIME_TYPE = "text/html";
|
|
144
|
-
|
|
125
|
+
// protected static final String JAVASCRIPT_INTERFACE = "ReactNativeWebView";
|
|
145
126
|
protected static final String HTTP_METHOD_POST = "POST";
|
|
146
127
|
// Use `webView.loadUrl("about:blank")` to reliably reset the view
|
|
147
128
|
// state and release page resources (including any running JavaScript).
|
|
148
129
|
protected static final String BLANK_URL = "about:blank";
|
|
130
|
+
|
|
149
131
|
protected WebViewConfig mWebViewConfig;
|
|
150
132
|
|
|
151
133
|
protected BPCWebChromeClient mWebChromeClient = null;
|
|
@@ -209,7 +191,13 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
209
191
|
|
|
210
192
|
BPCWebViewModule module = getModule(reactContext);
|
|
211
193
|
|
|
212
|
-
DownloadManager.Request request
|
|
194
|
+
DownloadManager.Request request;
|
|
195
|
+
try {
|
|
196
|
+
request = new DownloadManager.Request(Uri.parse(url));
|
|
197
|
+
} catch (IllegalArgumentException e) {
|
|
198
|
+
Log.w(TAG, "Unsupported URI, aborting download", e);
|
|
199
|
+
return;
|
|
200
|
+
}
|
|
213
201
|
|
|
214
202
|
String fileName = URLUtil.guessFileName(url, contentDisposition, mimetype);
|
|
215
203
|
String downloadMessage = "Downloading " + fileName;
|
|
@@ -222,8 +210,7 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
222
210
|
String cookie = CookieManager.getInstance().getCookie(baseUrl);
|
|
223
211
|
request.addRequestHeader("Cookie", cookie);
|
|
224
212
|
} catch (MalformedURLException e) {
|
|
225
|
-
|
|
226
|
-
e.printStackTrace();
|
|
213
|
+
Log.w(TAG, "Error getting cookie for DownloadManager", e);
|
|
227
214
|
}
|
|
228
215
|
|
|
229
216
|
//Finish setting up request
|
|
@@ -250,6 +237,16 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
250
237
|
view.getSettings().setJavaScriptEnabled(enabled);
|
|
251
238
|
}
|
|
252
239
|
|
|
240
|
+
@ReactProp(name = "setBuiltInZoomControls")
|
|
241
|
+
public void setBuiltInZoomControls(WebView view, boolean enabled) {
|
|
242
|
+
view.getSettings().setBuiltInZoomControls(enabled);
|
|
243
|
+
}
|
|
244
|
+
|
|
245
|
+
@ReactProp(name = "setDisplayZoomControls")
|
|
246
|
+
public void setDisplayZoomControls(WebView view, boolean enabled) {
|
|
247
|
+
view.getSettings().setDisplayZoomControls(enabled);
|
|
248
|
+
}
|
|
249
|
+
|
|
253
250
|
@ReactProp(name = "setSupportMultipleWindows")
|
|
254
251
|
public void setSupportMultipleWindows(WebView view, boolean enabled){
|
|
255
252
|
view.getSettings().setSupportMultipleWindows(enabled);
|
|
@@ -341,6 +338,11 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
341
338
|
view.setOverScrollMode(overScrollMode);
|
|
342
339
|
}
|
|
343
340
|
|
|
341
|
+
@ReactProp(name = "nestedScrollEnabled")
|
|
342
|
+
public void setNestedScrollEnabled(WebView view, boolean enabled) {
|
|
343
|
+
((BPCWebView) view).setNestedScrollEnabled(enabled);
|
|
344
|
+
}
|
|
345
|
+
|
|
344
346
|
@ReactProp(name = "thirdPartyCookiesEnabled")
|
|
345
347
|
public void setThirdPartyCookiesEnabled(WebView view, boolean enabled) {
|
|
346
348
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.LOLLIPOP) {
|
|
@@ -536,6 +538,19 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
536
538
|
view.loadUrl(BLANK_URL);
|
|
537
539
|
}
|
|
538
540
|
|
|
541
|
+
@ReactProp(name = "basicAuthCredential")
|
|
542
|
+
public void setBasicAuthCredential(WebView view, @Nullable ReadableMap credential) {
|
|
543
|
+
@Nullable BasicAuthCredential basicAuthCredential = null;
|
|
544
|
+
if (credential != null) {
|
|
545
|
+
if (credential.hasKey("username") && credential.hasKey("password")) {
|
|
546
|
+
String username = credential.getString("username");
|
|
547
|
+
String password = credential.getString("password");
|
|
548
|
+
basicAuthCredential = new BasicAuthCredential(username, password);
|
|
549
|
+
}
|
|
550
|
+
}
|
|
551
|
+
((BPCWebView) view).setBasicAuthCredential(basicAuthCredential);
|
|
552
|
+
}
|
|
553
|
+
|
|
539
554
|
@ReactProp(name = "onContentSizeChange")
|
|
540
555
|
public void setOnContentSizeChange(WebView view, boolean sendContentSizeChangeEvents) {
|
|
541
556
|
((BPCWebView) view).setSendContentSizeChangeEvents(sendContentSizeChangeEvents);
|
|
@@ -591,6 +606,32 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
591
606
|
((BPCWebView) view).setHasScrollEvent(hasScrollEvent);
|
|
592
607
|
}
|
|
593
608
|
|
|
609
|
+
@ReactProp(name = "forceDarkOn")
|
|
610
|
+
public void setForceDarkOn(WebView view, boolean enabled) {
|
|
611
|
+
// Only Android 10+ support dark mode
|
|
612
|
+
if (Build.VERSION.SDK_INT > Build.VERSION_CODES.P) {
|
|
613
|
+
// Switch WebView dark mode
|
|
614
|
+
if (WebViewFeature.isFeatureSupported(WebViewFeature.FORCE_DARK)) {
|
|
615
|
+
int forceDarkMode = enabled ? WebSettingsCompat.FORCE_DARK_ON : WebSettingsCompat.FORCE_DARK_OFF;
|
|
616
|
+
WebSettingsCompat.setForceDark(view.getSettings(), forceDarkMode);
|
|
617
|
+
}
|
|
618
|
+
|
|
619
|
+
// Set how WebView content should be darkened.
|
|
620
|
+
// PREFER_WEB_THEME_OVER_USER_AGENT_DARKENING: checks for the "color-scheme" <meta> tag.
|
|
621
|
+
// If present, it uses media queries. If absent, it applies user-agent (automatic)
|
|
622
|
+
// More information about Force Dark Strategy can be found here:
|
|
623
|
+
// https://developer.android.com/reference/androidx/webkit/WebSettingsCompat#setForceDarkStrategy(android.webkit.WebSettings)
|
|
624
|
+
if (enabled && WebViewFeature.isFeatureSupported(WebViewFeature.FORCE_DARK_STRATEGY)) {
|
|
625
|
+
WebSettingsCompat.setForceDarkStrategy(view.getSettings(), WebSettingsCompat.DARK_STRATEGY_PREFER_WEB_THEME_OVER_USER_AGENT_DARKENING);
|
|
626
|
+
}
|
|
627
|
+
}
|
|
628
|
+
}
|
|
629
|
+
|
|
630
|
+
@ReactProp(name = "minimumFontSize")
|
|
631
|
+
public void setMinimumFontSize(WebView view, int fontSize) {
|
|
632
|
+
view.getSettings().setMinimumFontSize(fontSize);
|
|
633
|
+
}
|
|
634
|
+
|
|
594
635
|
@Override
|
|
595
636
|
protected void addEventEmitters(ThemedReactContext reactContext, WebView view) {
|
|
596
637
|
// Do not register default touch emitter and let WebView implementation handle touches
|
|
@@ -704,8 +745,11 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
704
745
|
}
|
|
705
746
|
|
|
706
747
|
protected void setupWebChromeClient(ReactContext reactContext, WebView webView) {
|
|
707
|
-
|
|
708
|
-
|
|
748
|
+
Activity activity = reactContext.getCurrentActivity();
|
|
749
|
+
|
|
750
|
+
if (mAllowsFullscreenVideo && activity != null) {
|
|
751
|
+
int initialRequestedOrientation = activity.getRequestedOrientation();
|
|
752
|
+
|
|
709
753
|
mWebChromeClient = new BPCWebChromeClient(reactContext, webView) {
|
|
710
754
|
@Override
|
|
711
755
|
public Bitmap getDefaultVideoPoster() {
|
|
@@ -722,31 +766,32 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
722
766
|
mVideoView = view;
|
|
723
767
|
mCustomViewCallback = callback;
|
|
724
768
|
|
|
725
|
-
|
|
769
|
+
activity.setRequestedOrientation(ActivityInfo.SCREEN_ORIENTATION_UNSPECIFIED);
|
|
726
770
|
|
|
727
771
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
|
|
728
772
|
mVideoView.setSystemUiVisibility(FULLSCREEN_SYSTEM_UI_VISIBILITY);
|
|
729
|
-
|
|
773
|
+
activity.getWindow().setFlags(
|
|
774
|
+
WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS,
|
|
775
|
+
WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS
|
|
776
|
+
);
|
|
730
777
|
}
|
|
731
778
|
|
|
732
779
|
mVideoView.setBackgroundColor(Color.BLACK);
|
|
733
780
|
|
|
734
|
-
//
|
|
735
|
-
// we will decide which View to
|
|
736
|
-
// does not match (i.e., the
|
|
737
|
-
// NOTE: We could use mWebView.getRootView() instead of getRootView()
|
|
781
|
+
// Since RN's Modals interfere with the View hierarchy
|
|
782
|
+
// we will decide which View to hide if the hierarchy
|
|
783
|
+
// does not match (i.e., the WebView is within a Modal)
|
|
784
|
+
// NOTE: We could use `mWebView.getRootView()` instead of `getRootView()`
|
|
738
785
|
// but that breaks the Modal's styles and layout, so we need this to render
|
|
739
|
-
// in the main View hierarchy regardless
|
|
786
|
+
// in the main View hierarchy regardless
|
|
740
787
|
ViewGroup rootView = getRootView();
|
|
741
788
|
rootView.addView(mVideoView, FULLSCREEN_LAYOUT_PARAMS);
|
|
742
789
|
|
|
743
790
|
// Different root views, we are in a Modal
|
|
744
|
-
if(rootView.getRootView() != mWebView.getRootView()){
|
|
791
|
+
if (rootView.getRootView() != mWebView.getRootView()) {
|
|
745
792
|
mWebView.getRootView().setVisibility(View.GONE);
|
|
746
|
-
}
|
|
747
|
-
|
|
748
|
-
// Same view hierarchy (no Modal), just hide the webview then
|
|
749
|
-
else{
|
|
793
|
+
} else {
|
|
794
|
+
// Same view hierarchy (no Modal), just hide the WebView then
|
|
750
795
|
mWebView.setVisibility(View.GONE);
|
|
751
796
|
}
|
|
752
797
|
|
|
@@ -759,20 +804,18 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
759
804
|
return;
|
|
760
805
|
}
|
|
761
806
|
|
|
762
|
-
//
|
|
807
|
+
// Same logic as above
|
|
763
808
|
ViewGroup rootView = getRootView();
|
|
764
809
|
|
|
765
|
-
if(rootView.getRootView() !=
|
|
810
|
+
if (rootView.getRootView() != mWebView.getRootView()) {
|
|
766
811
|
mWebView.getRootView().setVisibility(View.VISIBLE);
|
|
767
|
-
}
|
|
768
|
-
|
|
769
|
-
// Same view hierarchy (no Modal)
|
|
770
|
-
else{
|
|
812
|
+
} else {
|
|
813
|
+
// Same view hierarchy (no Modal)
|
|
771
814
|
mWebView.setVisibility(View.VISIBLE);
|
|
772
815
|
}
|
|
773
816
|
|
|
774
817
|
if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.KITKAT) {
|
|
775
|
-
|
|
818
|
+
activity.getWindow().clearFlags(WindowManager.LayoutParams.FLAG_LAYOUT_NO_LIMITS);
|
|
776
819
|
}
|
|
777
820
|
|
|
778
821
|
rootView.removeView(mVideoView);
|
|
@@ -781,22 +824,25 @@ public class BPCWebViewManager extends SimpleViewManager<WebView> {
|
|
|
781
824
|
mVideoView = null;
|
|
782
825
|
mCustomViewCallback = null;
|
|
783
826
|
|
|
784
|
-
|
|
827
|
+
activity.setRequestedOrientation(initialRequestedOrientation);
|
|
785
828
|
|
|
786
829
|
mReactContext.removeLifecycleEventListener(this);
|
|
787
830
|
}
|
|
788
831
|
};
|
|
832
|
+
|
|
789
833
|
webView.setWebChromeClient(mWebChromeClient);
|
|
790
834
|
} else {
|
|
791
835
|
if (mWebChromeClient != null) {
|
|
792
836
|
mWebChromeClient.onHideCustomView();
|
|
793
837
|
}
|
|
838
|
+
|
|
794
839
|
mWebChromeClient = new BPCWebChromeClient(reactContext, webView) {
|
|
795
840
|
@Override
|
|
796
841
|
public Bitmap getDefaultVideoPoster() {
|
|
797
842
|
return Bitmap.createBitmap(50, 50, Bitmap.Config.ARGB_8888);
|
|
798
843
|
}
|
|
799
844
|
};
|
|
845
|
+
|
|
800
846
|
webView.setWebChromeClient(mWebChromeClient);
|
|
801
847
|
}
|
|
802
848
|
}
|