|
|
@ -35,8 +35,10 @@ class BackstageWebView( |
|
|
|
|
|
|
|
|
|
|
|
suspend fun getStrResponse(): StrResponse = suspendCancellableCoroutine { block -> |
|
|
|
suspend fun getStrResponse(): StrResponse = suspendCancellableCoroutine { block -> |
|
|
|
block.invokeOnCancellation { |
|
|
|
block.invokeOnCancellation { |
|
|
|
|
|
|
|
runOnUI { |
|
|
|
destroy() |
|
|
|
destroy() |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
} |
|
|
|
callback = object : BackstageWebView.Callback() { |
|
|
|
callback = object : BackstageWebView.Callback() { |
|
|
|
override fun onResult(response: StrResponse) { |
|
|
|
override fun onResult(response: StrResponse) { |
|
|
|
if (!block.isCompleted) |
|
|
|
if (!block.isCompleted) |
|
|
|