checkout / frames-android

Frames Android: making native card payments simple
https://www.checkout.com/docs/integrate/sdks/android-sdk
MIT License
47 stars 32 forks source link

[4.0.0] Web View of 3DS #187

Closed devs-gireeb closed 1 year ago

devs-gireeb commented 1 year ago

Hi all,

I don't understand how webView container works, please check below code:

container = this.findViewById(android.R.id.content),

ThreeDSRequest threeDSRequest = new ThreeDSRequest(
                this.findViewById(android.R.id.content),
                redirectUrl,
                Constants.SUCCESS_URL,
                Constants.FAILURE_URL,
                threeDSResultHandler
        );

Can you explain how it works. I tried to add webView for activity and fragment but it didn't work

maxim-nosov-cko commented 1 year ago

Hi @Devs-97Eats

The container serves as a parent ViewGroup for 3DS. Any ViewGroup can be used for it. F.e. in your case this.findViewById(android.R.id.content) root view group for particular activity is used as a container for 3DS WebView.

Please take a look at our code sample. Documentation.