Commit 2ad2db39 by 刘鹏

feat: 1. 倾诉2.0半屏uid刷新问题修复

parent d78288df
......@@ -5,7 +5,7 @@ ext {
ydlPublishVersion = [
// -------------- 业务模块 --------------
//第三步 若干
"m-confide" : "0.0.50.24",
"m-confide" : "0.0.50.25",
"m-consultant" : "0.0.60.67",
"m-fm" : "0.0.30.09",
"m-user" : "0.0.62.48",
......@@ -94,7 +94,7 @@ ext {
ydlCompileVersion = [
// -------------- 业务模块 --------------
//第三步 若干
"m-confide" : "0.0.50.24",
"m-confide" : "0.0.50.25",
"m-consultant" : "0.0.60.67",
"m-fm" : "0.0.30.09",
"m-user" : "0.0.62.48",
......
......@@ -31,6 +31,7 @@ import com.ydl.confide.home.event.ConfideDialogEvent
import com.ydl.confide.home.http.ConfideHomeApi
import com.ydl.confide.router.PhoneCallIn
import com.ydl.utils.WebUrlParamsUtils
import com.ydl.webview.IJavascriptHandler
import com.ydl.webview.ProgressWebView
import com.ydl.webview.TellData
import com.ydl.webview.WebModularServiceUtils
......@@ -42,6 +43,7 @@ import com.ydl.ydlnet.YDLHttpUtils
import com.yidianling.common.tools.RxImageTool
import com.yidianling.common.tools.ToastUtil
import com.yidianling.im.api.service.IImService
import com.yidianling.user.api.event.UserLoginEvent
import com.yidianling.user.api.service.IUserService
import de.greenrobot.event.EventBus
import io.reactivex.android.schedulers.AndroidSchedulers
......@@ -75,7 +77,7 @@ class ConfideBottomSheetDialogFragment : BottomSheetDialogFragment() {
lateinit var layoutBottom: View
lateinit var itemView: View
var bottomSheet :FrameLayout?=null
var mJtoJHandle:IJavascriptHandler?=null
private var behavior: BottomSheetBehavior<*>? = null
......@@ -345,14 +347,13 @@ class ConfideBottomSheetDialogFragment : BottomSheetDialogFragment() {
setting.setAllowFileAccess(true)
setting.setBlockNetworkImage(false)
wv_content!!.scrollBarStyle = View.SCROLLBARS_INSIDE_OVERLAY //滚动条风格,为0指滚动条不占用空间,直接覆盖在网页上
val jtoJHandle = WebModularServiceUtils.getWebService()
wv_content?.scrollBarStyle = View.SCROLLBARS_INSIDE_OVERLAY //滚动条风格,为0指滚动条不占用空间,直接覆盖在网页上
mJtoJHandle = WebModularServiceUtils.getWebService()
.getJavascripHandler(requireActivity(), tellData = TellData())
wv_content!!.addJavascriptInterface(jtoJHandle, "javascriptHandler")
wv_content?.addJavascriptInterface(mJtoJHandle, "javascriptHandler")
// var jumpurl = "http://192.168.210.152/jy/listenMask?listenerId=257&isFromApp=1"
val url = WebUrlParamsUtils.getSuffix(jumpUrl, jtoJHandle.getUriAppendSuffix())
wv_content.loadUrl(url)
loadUrl()
// wv_content.loadUrl(jumpUrl)
wv_content.setOnTouchListener { p0, p1 -> //canScrollVertically(-1)的值表示是否能向下滚动,false表示已经滚动到顶部
......@@ -418,6 +419,11 @@ class ConfideBottomSheetDialogFragment : BottomSheetDialogFragment() {
}
}
private fun loadUrl() {
val url = WebUrlParamsUtils.getSuffix(jumpUrl, mJtoJHandle?.getUriAppendSuffix())
wv_content?.loadUrl(url)
}
private fun shouldOverridePayUrl(view: WebView, url: String): Boolean {
if (url.startsWith("weixin://")) {
return try {
......@@ -574,4 +580,8 @@ class ConfideBottomSheetDialogFragment : BottomSheetDialogFragment() {
wv_content.destroy()
EventBus.getDefault().unregister(this)
}
fun onEvent(event: UserLoginEvent) {
loadUrl()
}
}
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment