diff options
Diffstat (limited to 'app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt')
-rw-r--r-- | app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt b/app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt index 93d5c773..07703dde 100644 --- a/app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt +++ b/app/src/main/kotlin/com/pitchedapps/frost/web/FrostJSI.kt @@ -6,6 +6,7 @@ import android.webkit.JavascriptInterface import com.pitchedapps.frost.activities.MainActivity import com.pitchedapps.frost.dbflow.CookieModel import com.pitchedapps.frost.facebook.FbCookie +import com.pitchedapps.frost.facebook.formattedFbUrl import com.pitchedapps.frost.utils.* import io.reactivex.subjects.Subject @@ -36,6 +37,12 @@ class FrostJSI(val webView: FrostWebViewCore) { = if (url == null) false else webView.requestWebOverlay(url) @JavascriptInterface + fun loadVideo(url: String?) { + if (url != null) + webView.post { activity?.showVideo(url) } + } + + @JavascriptInterface fun reloadBaseUrl(animate: Boolean) { L.d("FrostJSI reload") webView.post { |