Merge pull request #196 from TouchInstinct/add/header-for-web_view
add loadUrl with headers
This commit is contained in:
commit
484f87c132
|
|
@ -125,8 +125,8 @@ open class BaseWebView @JvmOverloads constructor(
|
||||||
* if url is null it changes to empty string
|
* if url is null it changes to empty string
|
||||||
* to prevent infinite LOADING state
|
* to prevent infinite LOADING state
|
||||||
*/
|
*/
|
||||||
fun loadUrl(url: String?) {
|
fun loadUrl(url: String?, extraHeaders: Map<String,String> = emptyMap()) {
|
||||||
binding.webView.loadUrl(url ?: "")
|
binding.webView.loadUrl(url ?: "", extraHeaders)
|
||||||
}
|
}
|
||||||
|
|
||||||
fun setState(newState: WebViewLoadingState) {
|
fun setState(newState: WebViewLoadingState) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue