[6.0.0] 合并6.0.0
This commit is contained in:
@@ -16,6 +16,10 @@ import com.mogo.och.common.module.utils.DateTimeUtil
|
||||
*/
|
||||
object DriverM1ServiceManager {
|
||||
|
||||
init {
|
||||
|
||||
}
|
||||
|
||||
private val mDriverM1ServiceApi: IDriverM1Service =
|
||||
MoGoRetrofitFactory.getInstance(OchCommonConst.getBaseUrl()).create(
|
||||
IDriverM1Service::class.java
|
||||
|
||||
@@ -9,6 +9,7 @@ import com.magic.mogo.och.charter.callback.IDriverM1ControllerStatusCallback
|
||||
import com.magic.mogo.och.charter.fragment.DriverM1Fragment
|
||||
import com.magic.mogo.och.charter.manager.CharterTrajectoryManager
|
||||
import com.magic.mogo.och.charter.model.DriverM1Model
|
||||
import com.mogo.commons.AbsMogoApplication
|
||||
import com.mogo.commons.mvp.Presenter
|
||||
import com.mogo.eagle.core.data.map.MogoLocation
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
@@ -21,6 +22,7 @@ import com.mogo.och.common.module.biz.bean.DriverStatusQueryRespBean
|
||||
import com.mogo.och.common.module.biz.callback.ILoginCallback
|
||||
import com.mogo.och.common.module.biz.common.socketmessage.OCHSocketMessageManager.OPERATION_ROAD_SIDE_TYPE
|
||||
import com.mogo.och.common.module.biz.constant.LoginStatusManager.isLogin
|
||||
import com.mogo.och.common.module.manager.OCHAdasAbilityManager
|
||||
import com.mogo.och.common.module.manager.StopSideStatusManager
|
||||
import com.mogo.och.common.module.utils.DateTimeUtil
|
||||
import mogo.telematics.pad.MessagePad
|
||||
@@ -41,6 +43,7 @@ class DriverM1Presenter(view: DriverM1Fragment?) :
|
||||
|
||||
init {
|
||||
DriverM1Model.get().init(context)
|
||||
OCHAdasAbilityManager.getInstance().init(AbsMogoApplication.getApp())
|
||||
registerListener()
|
||||
}
|
||||
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<manifest xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
package="com.mogo.och.bus.passenger">
|
||||
package="com.mogo.och.charter.passenger">
|
||||
|
||||
</manifest>
|
||||
@@ -1,6 +0,0 @@
|
||||
package com.mogo.och.bus.passenger.bean.event
|
||||
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.SiteInfoResponse
|
||||
|
||||
data class EventLineSites(val lineInfo: LineInfoResponse.LineInfo?, val sites: List<SiteInfoResponse.SiteInfo>?, val clear:Boolean=false)
|
||||
@@ -1,3 +0,0 @@
|
||||
package com.mogo.och.bus.passenger.ui.debugview
|
||||
|
||||
data class DebugEvent(val type: String)
|
||||
@@ -1,66 +0,0 @@
|
||||
package com.mogo.och.bus.passenger.utils
|
||||
|
||||
import android.view.View
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.och.bus.passenger.ui.toast.ToastCharterView
|
||||
import me.jessyan.autosize.utils.AutoSizeUtils
|
||||
|
||||
object ToastCharterUtils {
|
||||
const val TAG = "ToastCharterUtils"
|
||||
fun showTaost(toastText: String) {
|
||||
val context = ActivityUtils.getTopActivity()
|
||||
val marker = ToastCharterView(context)
|
||||
marker.setText(toastText)
|
||||
marker.measure(
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 145f),
|
||||
View.MeasureSpec.UNSPECIFIED
|
||||
),
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 34f),
|
||||
View.MeasureSpec.EXACTLY
|
||||
)
|
||||
)
|
||||
marker.layout(0, 0, marker.measuredWidth, marker.measuredHeight)
|
||||
ToastUtils.showShort(marker)
|
||||
}
|
||||
|
||||
fun showLong(toastText: String) {
|
||||
val context = ActivityUtils.getTopActivity()
|
||||
val marker = ToastCharterView(context)
|
||||
marker.setText(toastText)
|
||||
marker.measure(
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 145f),
|
||||
View.MeasureSpec.UNSPECIFIED
|
||||
),
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 34f),
|
||||
View.MeasureSpec.EXACTLY
|
||||
)
|
||||
)
|
||||
marker.layout(0, 0, marker.measuredWidth, marker.measuredHeight)
|
||||
ToastUtils.showLong(marker)
|
||||
}
|
||||
|
||||
fun showShort(toastText: String?) {
|
||||
toastText?.let {
|
||||
val context = ActivityUtils.getTopActivity()
|
||||
val marker = ToastCharterView(context)
|
||||
marker.setText(toastText)
|
||||
marker.measure(
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 145f),
|
||||
View.MeasureSpec.UNSPECIFIED
|
||||
),
|
||||
View.MeasureSpec.makeMeasureSpec(
|
||||
AutoSizeUtils.dp2px(context, 34f),
|
||||
View.MeasureSpec.EXACTLY
|
||||
)
|
||||
)
|
||||
marker.layout(0, 0, marker.measuredWidth, marker.measuredHeight)
|
||||
ToastUtils.showShort(marker)
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger
|
||||
package com.mogo.och.charter.passenger
|
||||
|
||||
import android.content.Context
|
||||
import androidx.fragment.app.Fragment
|
||||
@@ -10,8 +10,8 @@ import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager.getMapUIC
|
||||
import com.mogo.eagle.core.function.call.setting.CallerMoGoUiSettingManager.stepInDayMode
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.d
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.och.bus.passenger.constant.CharterPassengerConst
|
||||
import com.mogo.och.bus.passenger.ui.MainFragment
|
||||
import com.mogo.och.charter.passenger.constant.CharterPassengerConst
|
||||
import com.mogo.och.charter.passenger.ui.MainFragment
|
||||
|
||||
/**
|
||||
* 网约车-Bus-乘客端
|
||||
@@ -46,7 +46,7 @@ class MogoOCHBusPassenger : IMoGoFunctionProvider {
|
||||
val supportFragmentManager: FragmentManager? = mActivity?.supportFragmentManager
|
||||
|
||||
if (mPassengerFragment == null) {
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备add fragment======")
|
||||
d(SceneConstant.M_TAXI_P + com.mogo.och.charter.passenger.MogoOCHBusPassenger.Companion.TAG, "准备add fragment======")
|
||||
var fragmentByTag: Fragment? = supportFragmentManager?.findFragmentByTag(MainFragment.TAG)
|
||||
mPassengerFragment = if (fragmentByTag is MainFragment){
|
||||
fragmentByTag
|
||||
@@ -60,7 +60,7 @@ class MogoOCHBusPassenger : IMoGoFunctionProvider {
|
||||
}
|
||||
return
|
||||
}
|
||||
d(SceneConstant.M_TAXI_P + TAG, "准备show fragment")
|
||||
d(SceneConstant.M_TAXI_P + com.mogo.och.charter.passenger.MogoOCHBusPassenger.Companion.TAG, "准备show fragment")
|
||||
supportFragmentManager?.beginTransaction()?.show(mPassengerFragment!!)
|
||||
?.commitAllowingStateLoss()
|
||||
}
|
||||
@@ -73,6 +73,6 @@ class MogoOCHBusPassenger : IMoGoFunctionProvider {
|
||||
}
|
||||
|
||||
companion object {
|
||||
private val TAG = MogoOCHBusPassenger::class.java.simpleName
|
||||
private val TAG = com.mogo.och.charter.passenger.MogoOCHBusPassenger::class.java.simpleName
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean;
|
||||
package com.mogo.och.charter.passenger.bean;
|
||||
|
||||
public class TaxiPassengerVideoPlay {
|
||||
|
||||
@@ -1,3 +1,3 @@
|
||||
package com.mogo.och.bus.passenger.bean
|
||||
package com.mogo.och.charter.passenger.bean
|
||||
|
||||
data class Temperature(val index:Int,val value:Int,val showTitle:String)
|
||||
@@ -0,0 +1,6 @@
|
||||
package com.mogo.och.charter.passenger.bean.event
|
||||
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.SiteInfoResponse
|
||||
|
||||
data class EventLineSites(val lineInfo: LineInfoResponse.LineInfo?, val sites: List<SiteInfoResponse.SiteInfo>?, val clear:Boolean=false)
|
||||
@@ -1,3 +1,3 @@
|
||||
package com.mogo.och.bus.passenger.bean.request
|
||||
package com.mogo.och.charter.passenger.bean.request
|
||||
|
||||
data class ArriveDestRequest(val sn:String, val lineId:Long,val writeVersion:Long)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.request;
|
||||
package com.mogo.och.charter.passenger.bean.request;
|
||||
|
||||
public
|
||||
/**
|
||||
@@ -1,3 +1,3 @@
|
||||
package com.mogo.och.bus.passenger.bean.request
|
||||
package com.mogo.och.charter.passenger.bean.request
|
||||
|
||||
data class EndOrderRequest(val sn:String,val orderNo:String)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
import java.util.*
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
import com.mogo.och.common.module.bean.dpmsg.LineSite
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.bean.response
|
||||
package com.mogo.och.charter.passenger.bean.response
|
||||
|
||||
import com.amap.api.maps.model.LatLng
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback;
|
||||
package com.mogo.och.charter.passenger.callback;
|
||||
|
||||
import com.mogo.eagle.core.data.map.MogoLocation;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback
|
||||
package com.mogo.och.charter.passenger.callback
|
||||
|
||||
/**
|
||||
* Created on 2022/3/31
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback
|
||||
package com.mogo.och.charter.passenger.callback
|
||||
|
||||
interface IClearViewCallback {
|
||||
fun goneAllView()
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback
|
||||
package com.mogo.och.charter.passenger.callback
|
||||
|
||||
interface IDistanceCallback {
|
||||
fun setDistancecAndTime(meters:Long , timeInSecond:Long )
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback
|
||||
package com.mogo.och.charter.passenger.callback
|
||||
|
||||
interface IOrderChangeCallback {
|
||||
/**
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.callback
|
||||
package com.mogo.och.charter.passenger.callback
|
||||
|
||||
interface ITimeCallback {
|
||||
fun setOrderTimeCallBack(timeInSecond: Long)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.constant
|
||||
package com.mogo.och.charter.passenger.constant
|
||||
|
||||
/**
|
||||
* Created on 2021/12/6
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.model
|
||||
package com.mogo.och.charter.passenger.model
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
@@ -12,7 +12,6 @@ import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters.AutoPilotLi
|
||||
import com.mogo.eagle.core.data.autopilot.AutopilotControlParameters.AutoPilotLonLat
|
||||
import com.mogo.eagle.core.data.map.MogoLocation
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisLocationGCJ02Listener
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoPlanningRottingListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.*
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager.startAutoPilot
|
||||
@@ -24,15 +23,15 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.e
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_BUS_P
|
||||
import com.mogo.eagle.core.utilcode.util.*
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.common.module.manager.loopmanager.LoopInfo
|
||||
import com.mogo.och.bus.passenger.bean.response.*
|
||||
import com.mogo.och.bus.passenger.callback.*
|
||||
import com.mogo.och.bus.passenger.constant.CharterPassengerConst
|
||||
import com.mogo.och.charter.passenger.bean.response.*
|
||||
import com.mogo.och.charter.passenger.callback.*
|
||||
import com.mogo.och.charter.passenger.constant.CharterPassengerConst
|
||||
import com.mogo.och.common.module.manager.loopmanager.BizLoopManager
|
||||
import com.mogo.och.bus.passenger.net.BusPassengerServiceManager
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.bus.passenger.utils.VoiceFocusManager
|
||||
import com.mogo.och.charter.passenger.net.BusPassengerServiceManager
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.utils.VoiceFocusManager
|
||||
import com.mogo.och.common.module.bean.dpmsg.BaseDPMsg
|
||||
import com.mogo.och.common.module.bean.dpmsg.ChangeDestMsg
|
||||
import com.mogo.och.common.module.biz.common.socketmessage.OCHSocketMessageManager
|
||||
@@ -196,7 +195,7 @@ object CharterPassengerModel {
|
||||
super.onAutopilotGuardian(guardianInfo)
|
||||
guardianInfo?.let {
|
||||
if (it.code=="IMAP_TRA_LOADED") {
|
||||
ToastCharterUtils.showShort("请等待车辆完成掉头后再出发吧~")
|
||||
ToastCharterUtils.showToastShort("请等待车辆完成掉头后再出发吧~")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -349,7 +348,7 @@ object CharterPassengerModel {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -478,7 +477,7 @@ object CharterPassengerModel {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -585,7 +584,7 @@ object CharterPassengerModel {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -609,7 +608,7 @@ object CharterPassengerModel {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -890,7 +889,7 @@ object CharterPassengerModel {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
broadcastList[requestIngSign] = false
|
||||
}
|
||||
|
||||
@@ -1027,7 +1026,7 @@ object CharterPassengerModel {
|
||||
*/
|
||||
fun startAutopilot() {
|
||||
if (!OCHAdasAbilityManager.getInstance().autopilotAbilityStatus) {
|
||||
ToastCharterUtils.showLong(
|
||||
ToastCharterUtils.showToastLong(
|
||||
OCHAdasAbilityManager.getInstance().autopilotUnAbilityReason +
|
||||
", 请稍候重试"
|
||||
)
|
||||
@@ -1035,19 +1034,19 @@ object CharterPassengerModel {
|
||||
}
|
||||
orderInfo?.let {
|
||||
if (it.arriveStatus == OrderInfoResponse.ARRIVED) {
|
||||
ToastCharterUtils.showLong("已到达目的地请重新选择线路")
|
||||
ToastCharterUtils.showToastLong("已到达目的地请重新选择线路")
|
||||
return
|
||||
}
|
||||
val parameters = initAutopilotControlParameters()
|
||||
if (null == parameters) {
|
||||
ToastCharterUtils.showShort("请选择站点")
|
||||
ToastCharterUtils.showToastShort("请选择站点")
|
||||
e(
|
||||
SceneConstant.M_BUS + TAG,
|
||||
"行程日志-AutopilotControlParameters is empty."
|
||||
)
|
||||
return
|
||||
}
|
||||
ToastCharterUtils.showShort("启动自动驾驶中")
|
||||
ToastCharterUtils.showToastShort("启动自动驾驶中")
|
||||
cleanRoutePoints()
|
||||
startAutoPilot(parameters)
|
||||
d(
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.model
|
||||
package com.mogo.och.charter.passenger.model
|
||||
|
||||
/**
|
||||
* Created on 2022/08/19
|
||||
@@ -1,13 +1,13 @@
|
||||
package com.mogo.och.bus.passenger.net
|
||||
package com.mogo.och.charter.passenger.net
|
||||
|
||||
import android.content.Context
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager
|
||||
import com.mogo.eagle.core.network.MoGoRetrofitFactory
|
||||
import com.mogo.och.bus.passenger.bean.request.ArriveDestRequest
|
||||
import com.mogo.och.bus.passenger.bean.request.EndOrderRequest
|
||||
import com.mogo.och.bus.passenger.bean.response.*
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.bean.request.ArriveDestRequest
|
||||
import com.mogo.och.charter.passenger.bean.request.EndOrderRequest
|
||||
import com.mogo.och.charter.passenger.bean.response.*
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.biz.constant.OchCommonConst
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceCallback
|
||||
import com.mogo.och.common.module.biz.network.OchCommonSubscribeImpl
|
||||
@@ -39,7 +39,7 @@ object BusPassengerServiceManager {
|
||||
|
||||
private fun beforeNet():Boolean{
|
||||
if (draiverSn.isBlank()) {
|
||||
ToastCharterUtils.showShort("已断开司机屏连接、请联系安全员")
|
||||
ToastCharterUtils.showToastShort("已断开司机屏连接、请联系安全员")
|
||||
return true
|
||||
}
|
||||
return false
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.net
|
||||
package com.mogo.och.charter.passenger.net
|
||||
|
||||
import com.mogo.cloud.passport.MoGoAiCloudClientConfig
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager
|
||||
import com.mogo.och.bus.passenger.bean.request.ArriveDestRequest
|
||||
import com.mogo.och.bus.passenger.bean.request.EndOrderRequest
|
||||
import com.mogo.och.bus.passenger.bean.response.*
|
||||
import com.mogo.och.charter.passenger.bean.request.ArriveDestRequest
|
||||
import com.mogo.och.charter.passenger.bean.request.EndOrderRequest
|
||||
import com.mogo.och.charter.passenger.bean.response.*
|
||||
import io.reactivex.Observable
|
||||
import retrofit2.http.*
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.mogo.och.bus.passenger.presenter
|
||||
package com.mogo.och.charter.passenger.presenter
|
||||
|
||||
import androidx.lifecycle.LifecycleOwner
|
||||
import com.mogo.commons.mvp.IView
|
||||
import com.mogo.commons.mvp.Presenter
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.common.module.utils.RxUtils
|
||||
import io.reactivex.disposables.Disposable
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
package com.mogo.och.bus.passenger.presenter
|
||||
package com.mogo.och.charter.passenger.presenter
|
||||
|
||||
import com.mogo.och.bus.passenger.ui.dialogfragment.M1CarUserNoOrderFragment
|
||||
import com.mogo.och.charter.passenger.ui.dialogfragment.M1CarUserNoOrderFragment
|
||||
|
||||
class BusPassengerCarUseAndNoOrderPresenter(view: M1CarUserNoOrderFragment?) :
|
||||
BusBasePassengerFunctionDevicePresenter<M1CarUserNoOrderFragment?>(view){
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.presenter
|
||||
package com.mogo.och.charter.passenger.presenter
|
||||
|
||||
import android.graphics.Bitmap
|
||||
import android.graphics.BitmapFactory
|
||||
@@ -6,6 +6,7 @@ import android.graphics.Canvas
|
||||
import android.view.View
|
||||
import androidx.lifecycle.LifecycleOwner
|
||||
import com.amap.api.maps.model.LatLng
|
||||
import com.mogo.commons.AbsMogoApplication
|
||||
import com.mogo.commons.voice.AIAssist
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
@@ -17,25 +18,26 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_BUS_P
|
||||
import com.mogo.eagle.core.utilcode.util.SharedPrefs
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.TrajectoriesResponse
|
||||
import com.mogo.och.bus.passenger.callback.IOrderChangeCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.bus.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.bus.passenger.receive.DriverMessage
|
||||
import com.mogo.och.bus.passenger.ui.MainFragment
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.bus.passenger.ui.overmapview.MakerWithSiteName
|
||||
import com.mogo.och.bus.passenger.ui.overmapview.MakerWithSiteNamewithCheck
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.TrajectoriesResponse
|
||||
import com.mogo.och.charter.passenger.callback.IOrderChangeCallback
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.charter.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.charter.passenger.receive.DriverMessage
|
||||
import com.mogo.och.charter.passenger.ui.MainFragment
|
||||
import com.mogo.och.charter.passenger.ui.overmapview.MakerWithSiteName
|
||||
import com.mogo.och.charter.passenger.ui.overmapview.MakerWithSiteNamewithCheck
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceCallback
|
||||
import com.mogo.och.common.module.manager.OCHAdasAbilityManager
|
||||
import com.mogo.och.common.module.manager.StopSideStatusManager
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorCallback
|
||||
import com.mogo.och.common.module.utils.CoordinateCalculateRouteUtil
|
||||
import com.mogo.och.common.module.voice.VoiceNotice
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import me.jessyan.autosize.utils.AutoSizeUtils
|
||||
import java.util.concurrent.ConcurrentHashMap
|
||||
|
||||
@@ -52,6 +54,10 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
|
||||
}
|
||||
|
||||
init {
|
||||
OCHAdasAbilityManager.getInstance().init(AbsMogoApplication.getApp())
|
||||
}
|
||||
|
||||
override fun onCreate(owner: LifecycleOwner) {
|
||||
super.onCreate(owner)
|
||||
CharterPassengerModel.init()
|
||||
@@ -61,7 +67,6 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
CallerTelematicListenerManager.addListener(TAG, DriverMessage)
|
||||
StopSideStatusManager.addListener(TAG, this)
|
||||
setCarChangeListener(R.raw.m1)
|
||||
|
||||
}
|
||||
|
||||
override fun onDestroy(owner: LifecycleOwner) {
|
||||
@@ -114,11 +119,11 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
OrderStatusEnum.NoOrderUse -> {
|
||||
when (CallerAutoPilotStatusListenerManager.getState()) {
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_DISABLE -> {// 不可自动驾驶
|
||||
ToastCharterUtils.showShort("设备未就绪请稍等,请安全员主动停止车辆")
|
||||
ToastCharterUtils.showToastShort("设备未就绪请稍等,请安全员主动停止车辆")
|
||||
}
|
||||
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_ENABLE -> {//
|
||||
ToastCharterUtils.showShort("因车辆正在人工驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
ToastCharterUtils.showToastShort("因车辆正在人工驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
}
|
||||
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_RUNNING -> {
|
||||
@@ -127,7 +132,7 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
}
|
||||
|
||||
IMoGoAutopilotStatusListener.STATUS_PARALLEL_DRIVING -> {
|
||||
ToastCharterUtils.showShort("因车辆正在平行驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
ToastCharterUtils.showToastShort("因车辆正在平行驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
}
|
||||
|
||||
else -> {}
|
||||
@@ -184,7 +189,7 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
UiThreadHandler.post {
|
||||
when (actionStatus) {
|
||||
StopSideStatusManager.Status.NOSTART -> {
|
||||
ToastCharterUtils.showShort(errorInfo?:"")
|
||||
ToastCharterUtils.showToastShort(errorInfo?:"")
|
||||
}
|
||||
|
||||
StopSideStatusManager.Status.START -> {
|
||||
@@ -199,7 +204,7 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
}
|
||||
|
||||
StopSideStatusManager.Status.EndingSuccess -> {
|
||||
ToastCharterUtils.showShort("靠边停车成功")
|
||||
ToastCharterUtils.showToastShort("靠边停车成功")
|
||||
VoiceNotice.showNotice(
|
||||
context.getString(R.string.m1_stop_site_success),
|
||||
AIAssist.LEVEL0
|
||||
@@ -207,7 +212,7 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
}
|
||||
|
||||
StopSideStatusManager.Status.EndingFaile -> {
|
||||
ToastCharterUtils.showShort("车辆系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("车辆系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -216,9 +221,9 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
override fun onDoorStatusCallback(isOpen: Boolean, isFirst: Boolean) {
|
||||
if (!isFirst) {
|
||||
if (isOpen) {
|
||||
ToastCharterUtils.showShort("已开启车门")
|
||||
ToastCharterUtils.showToastShort("已开启车门")
|
||||
} else {
|
||||
ToastCharterUtils.showShort("已关门车门")
|
||||
ToastCharterUtils.showToastShort("已关门车门")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -247,7 +252,7 @@ class BusPassengerPresenter(view: MainFragment?) :
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
|
||||
@@ -1,9 +1,9 @@
|
||||
package com.mogo.och.bus.passenger.presenter
|
||||
package com.mogo.och.charter.passenger.presenter
|
||||
|
||||
import androidx.lifecycle.LifecycleOwner
|
||||
import com.mogo.och.bus.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.ui.dialogfragment.NoviceGuidanceFragment
|
||||
import com.mogo.och.charter.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.ui.dialogfragment.NoviceGuidanceFragment
|
||||
import com.mogo.och.common.module.utils.DateTimeUtil
|
||||
import com.mogo.och.common.module.utils.RxUtils
|
||||
import io.reactivex.disposables.Disposable
|
||||
@@ -1,15 +1,16 @@
|
||||
package com.mogo.och.bus.passenger.provider;
|
||||
package com.mogo.och.charter.passenger.provider;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.View;
|
||||
|
||||
import com.mogo.och.bus.passenger.ui.statusbar.StatusBarView;
|
||||
import com.mogo.och.charter.passenger.ui.statusbar.StatusBarView;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
|
||||
import com.alibaba.android.arouter.facade.annotation.Route;
|
||||
import com.mogo.eagle.core.data.constants.MogoServicePaths;
|
||||
import com.mogo.eagle.core.function.api.hmi.view.IStatusViewLayout;
|
||||
import com.mogo.och.charter.passenger.ui.statusbar.StatusBarView;
|
||||
|
||||
/**
|
||||
* @author congtaowang
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.receive
|
||||
package com.mogo.och.charter.passenger.receive
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication
|
||||
import com.mogo.commons.voice.AIAssist
|
||||
@@ -8,9 +8,9 @@ import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.eagle.core.utilcode.util.GsonUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.common.module.bean.dpmsg.*
|
||||
import com.mogo.och.common.module.biz.common.socketmessage.OCHSocketMessageManager
|
||||
import com.mogo.och.common.module.biz.constant.OchCommonConst
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui
|
||||
package com.mogo.och.charter.passenger.ui
|
||||
|
||||
import android.graphics.BitmapFactory
|
||||
import android.os.Bundle
|
||||
@@ -21,16 +21,16 @@ import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.map.listener.IMogoMapListener
|
||||
import com.mogo.map.listener.MogoMapListenerHandler
|
||||
import com.mogo.map.uicontroller.VisualAngleMode
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.bus.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.bus.passenger.presenter.BusPassengerPresenter
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomBar
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.bus.passenger.ui.dialogfragment.M1CarUserNoOrderFragment
|
||||
import com.mogo.och.bus.passenger.ui.dialogfragment.NoviceGuidanceFragment
|
||||
import com.mogo.och.bus.passenger.ui.statusbar.StatusBarView
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.charter.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.charter.passenger.presenter.BusPassengerPresenter
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomBar
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.charter.passenger.ui.dialogfragment.M1CarUserNoOrderFragment
|
||||
import com.mogo.och.charter.passenger.ui.dialogfragment.NoviceGuidanceFragment
|
||||
import com.mogo.och.charter.passenger.ui.statusbar.StatusBarView
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.biz.constant.LoginStatusManager
|
||||
import kotlinx.android.synthetic.main.m1_main_fragment.*
|
||||
import org.greenrobot.eventbus.EventBus
|
||||
@@ -115,11 +115,11 @@ class MainFragment : MvpFragment<MainFragment?, BusPassengerPresenter?>(), IMogo
|
||||
if (mPresenter?.haveOrder() == true) {
|
||||
|
||||
} else {
|
||||
ToastCharterUtils.showShort("请确认订单")
|
||||
ToastCharterUtils.showToastShort("请确认订单")
|
||||
return true
|
||||
}
|
||||
} else {
|
||||
ToastCharterUtils.showShort(requireContext().getString(R.string.m1_please_login_driver))
|
||||
ToastCharterUtils.showToastShort(requireContext().getString(R.string.m1_please_login_driver))
|
||||
return true
|
||||
}
|
||||
showBizView(orderinfo = true)
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom
|
||||
package com.mogo.och.charter.passenger.ui.bottom
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.utilcode.kotlin.onClick
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_bottom_bar.view.*
|
||||
|
||||
class BottomBar @JvmOverloads constructor(
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom
|
||||
package com.mogo.och.charter.passenger.ui.bottom
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_bottom_stop_site.view.*
|
||||
|
||||
open class BottomCheckView @JvmOverloads constructor(
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom
|
||||
package com.mogo.och.charter.passenger.ui.bottom
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
@@ -9,7 +9,7 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_bottom_stop_site.view.*
|
||||
|
||||
open class BottomClickView @JvmOverloads constructor(
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom
|
||||
package com.mogo.och.charter.passenger.ui.bottom
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -8,11 +8,11 @@ import com.mogo.commons.AbsMogoApplication
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.callback.ITimeCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.bus.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.callback.ITimeCallback
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.charter.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.common.module.utils.DateTimeUtil
|
||||
import kotlinx.android.synthetic.main.m1_bottom_orderinfo.view.*
|
||||
import java.util.UUID
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom.impl
|
||||
package com.mogo.och.charter.passenger.ui.bottom.impl
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorManager
|
||||
import com.mogo.och.common.module.utils.SoundPoolHelper
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom.impl
|
||||
package com.mogo.och.charter.passenger.ui.bottom.impl
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
@@ -15,11 +15,11 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_BUS_P
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ClickUtils
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.callback.ICharterPassengerAutoStatusChangeCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.callback.ICharterPassengerAutoStatusChangeCallback
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorStatusManager
|
||||
import com.mogo.och.common.module.utils.RxUtils
|
||||
import com.mogo.och.common.module.utils.SoundPoolHelper
|
||||
@@ -66,7 +66,7 @@ class GoViewWithArrive @JvmOverloads constructor(
|
||||
})
|
||||
setOnClickListener {
|
||||
if (ClickUtils.isClickTooFrequent(this,3000)) {
|
||||
ToastCharterUtils.showShort("请稍后点击")
|
||||
ToastCharterUtils.showToastShort("请稍后点击")
|
||||
return@setOnClickListener
|
||||
}
|
||||
startGo()
|
||||
@@ -78,12 +78,12 @@ class GoViewWithArrive @JvmOverloads constructor(
|
||||
|
||||
if (LightAirconditionDoorStatusManager.doorStatus.isOpen) {
|
||||
val string = AbsMogoApplication.getApp().getString(R.string.m1_close_door_and_startauto)
|
||||
ToastCharterUtils.showShort(string)
|
||||
ToastCharterUtils.showToastShort(string)
|
||||
return
|
||||
}
|
||||
when (CallerAutoPilotStatusListenerManager.getState()) {
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_DISABLE -> {// 不可自动驾驶
|
||||
ToastCharterUtils.showShort("设备未就绪请稍等")
|
||||
ToastCharterUtils.showToastShort("设备未就绪请稍等")
|
||||
}
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_ENABLE -> {//
|
||||
onceRegisterAutoStatus()
|
||||
@@ -94,7 +94,7 @@ class GoViewWithArrive @JvmOverloads constructor(
|
||||
CharterPassengerModel.leaveStation()
|
||||
}
|
||||
IMoGoAutopilotStatusListener.STATUS_PARALLEL_DRIVING -> {
|
||||
ToastCharterUtils.showShort("因车辆正在平行驾驶中无法靠边停车,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("因车辆正在平行驾驶中无法靠边停车,请稍后再试")
|
||||
}
|
||||
else -> {}
|
||||
}
|
||||
@@ -123,7 +123,7 @@ class GoViewWithArrive @JvmOverloads constructor(
|
||||
startAutoTimeOut = RxUtils.createSubscribe(20_000) {
|
||||
if (CallerAutoPilotStatusListenerManager.getState() != IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_RUNNING) {
|
||||
val string = AbsMogoApplication.getApp().getString(R.string.m1_start_auto_fail)
|
||||
ToastCharterUtils.showLong(string)
|
||||
ToastCharterUtils.showToastLong(string)
|
||||
}
|
||||
CharterPassengerModel.setAutoStatusCallback(TAG, null)
|
||||
}
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom.impl
|
||||
package com.mogo.och.charter.passenger.ui.bottom.impl
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorManager
|
||||
import com.mogo.och.common.module.utils.SoundPoolHelper
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.bottom.impl
|
||||
package com.mogo.och.charter.passenger.ui.bottom.impl
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -6,9 +6,9 @@ import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotStatusListenerManager
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.ui.bottom.BottomClickView
|
||||
import com.mogo.och.common.module.utils.SoundPoolHelper
|
||||
|
||||
class StopSiteView @JvmOverloads constructor(
|
||||
@@ -31,17 +31,17 @@ class StopSiteView @JvmOverloads constructor(
|
||||
private fun stopSite(){
|
||||
when (CallerAutoPilotStatusListenerManager.getState()) {
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_DISABLE -> {// 不可自动驾驶
|
||||
ToastCharterUtils.showShort("设备未就绪请稍等,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("设备未就绪请稍等,请稍后再试")
|
||||
}
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_ENABLE -> {//
|
||||
ToastCharterUtils.showShort("因车辆正在人工驾驶中无法靠边停车,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("因车辆正在人工驾驶中无法靠边停车,请稍后再试")
|
||||
}
|
||||
IMoGoAutopilotStatusListener.STATUS_AUTOPILOT_RUNNING -> {
|
||||
// 靠边停车
|
||||
CallerAutoPilotControlManager.sendPlanningCmd(1)
|
||||
}
|
||||
IMoGoAutopilotStatusListener.STATUS_PARALLEL_DRIVING -> {
|
||||
ToastCharterUtils.showShort("因车辆正在平行驾驶中无法靠边停车,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("因车辆正在平行驾驶中无法靠边停车,请稍后再试")
|
||||
}
|
||||
else -> {}
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
package com.mogo.och.charter.passenger.ui.debugview
|
||||
|
||||
data class DebugEvent(val type: String)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.debugview
|
||||
package com.mogo.och.charter.passenger.ui.debugview
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -10,13 +10,12 @@ import com.mogo.eagle.core.data.config.HdMapBuildConfig
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.function.hmi.ui.setting.ToggleDebugView
|
||||
import com.mogo.eagle.core.utilcode.util.ActivityUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.ui.debugview.DebugView
|
||||
import com.mogo.och.bus.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.ui.MainFragment
|
||||
import com.mogo.och.bus.passenger.ui.statusbar.StatusBarView
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.response.OrderInfoResponse
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.ui.MainFragment
|
||||
import com.mogo.och.charter.passenger.ui.statusbar.StatusBarView
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.manager.debug.DebugViewWatchDogFragment
|
||||
import kotlinx.android.synthetic.main.m1_p_debug.view.debug_arrive_dest
|
||||
import kotlinx.android.synthetic.main.m1_p_debug.view.debug_change_modle
|
||||
@@ -66,7 +65,7 @@ class DebugView @JvmOverloads constructor(
|
||||
fragment?.showNoviceGuidanceFragment()
|
||||
}
|
||||
debug_change_modle.setOnClickListener {
|
||||
ToastCharterUtils.showShort("因车辆正在人工驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
ToastCharterUtils.showToastShort("因车辆正在人工驾驶中无法靠边停车,请安全员主动停止车辆")
|
||||
when (HdMapBuildConfig.currentCarVrIconRes) {
|
||||
R.raw.aiqinghao -> {
|
||||
fragment?.setCarMode(OrderInfoResponse.M1_FAMILY)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.dialogfragment
|
||||
package com.mogo.och.charter.passenger.ui.dialogfragment
|
||||
|
||||
import android.os.Bundle
|
||||
import android.util.Log
|
||||
@@ -15,8 +15,8 @@ import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_
|
||||
import com.mogo.eagle.core.utilcode.util.AppStateManager
|
||||
import com.mogo.eagle.core.utilcode.util.BarUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ClickUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.presenter.BusPassengerCarUseAndNoOrderPresenter
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.presenter.BusPassengerCarUseAndNoOrderPresenter
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorManager
|
||||
import com.mogo.och.common.module.voice.VoiceManager
|
||||
import kotlinx.android.synthetic.main.m1_order_end.*
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.dialogfragment
|
||||
package com.mogo.och.charter.passenger.ui.dialogfragment
|
||||
|
||||
import android.content.DialogInterface
|
||||
import android.os.Bundle
|
||||
@@ -15,11 +15,11 @@ import com.mogo.commons.voice.AIAssist
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_BUS_P
|
||||
import com.mogo.eagle.core.utilcode.util.*
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.presenter.BusPassengerPresenter
|
||||
import com.mogo.och.bus.passenger.presenter.CharterPassengerNoviceGuidancePresenter
|
||||
import com.mogo.och.bus.passenger.ui.MainFragment
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.presenter.BusPassengerPresenter
|
||||
import com.mogo.och.charter.passenger.presenter.CharterPassengerNoviceGuidancePresenter
|
||||
import com.mogo.och.charter.passenger.ui.MainFragment
|
||||
import com.mogo.och.common.module.voice.VoiceNotice
|
||||
import kotlinx.android.synthetic.main.m1_novice_guidance_fragment.*
|
||||
import kotlinx.android.synthetic.main.m1_novice_guidance_welcome_1_fragment.*
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.itinerary
|
||||
package com.mogo.och.charter.passenger.ui.itinerary
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -6,7 +6,7 @@ import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.lifecycle.ViewModelProvider
|
||||
import androidx.lifecycle.findViewTreeViewModelStoreOwner
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_itinerary_info.view.tv_distance
|
||||
import kotlinx.android.synthetic.main.m1_itinerary_info.view.tv_distance_arrive_time
|
||||
import kotlinx.android.synthetic.main.m1_itinerary_info.view.tv_distance_surplus_time
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.itinerary
|
||||
package com.mogo.och.charter.passenger.ui.itinerary
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import com.mogo.commons.AbsMogoApplication
|
||||
@@ -6,11 +6,11 @@ import com.mogo.eagle.core.data.map.MogoLocation
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoChassisLocationGCJ02Listener
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerChassisLocationGCJ02ListenerManager
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.callback.IDistanceCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.bus.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.callback.IDistanceCallback
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.charter.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.common.module.utils.DateTimeUtil
|
||||
import com.mogo.och.common.module.utils.NumberFormatUtil
|
||||
import kotlin.math.abs
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.lockview
|
||||
package com.mogo.och.charter.passenger.ui.lockview
|
||||
|
||||
import android.content.Context
|
||||
import android.os.Handler
|
||||
@@ -10,7 +10,7 @@ import android.view.MotionEvent
|
||||
import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.common.module.utils.FrameAnimatorContainer
|
||||
import kotlinx.android.synthetic.main.m1_devices_lock_unlock.view.aciv_screen_lock
|
||||
import kotlinx.android.synthetic.main.m1_devices_lock_unlock.view.aciv_screen_lock_bg
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.lockview
|
||||
package com.mogo.och.charter.passenger.ui.lockview
|
||||
|
||||
import android.os.Handler
|
||||
import android.os.HandlerThread
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.lockview
|
||||
package com.mogo.och.charter.passenger.ui.lockview
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -7,7 +7,7 @@ import android.view.View
|
||||
import androidx.appcompat.widget.AppCompatImageView
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
|
||||
class LockViewConstrainLayout : ConstraintLayout {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.lockview
|
||||
package com.mogo.och.charter.passenger.ui.lockview
|
||||
|
||||
import android.content.Context
|
||||
import android.os.Handler
|
||||
@@ -11,7 +11,7 @@ import android.view.View
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_devices_unlock.view.aciv_only_unlock
|
||||
import kotlinx.android.synthetic.main.m1_devices_unlock.view.actv_lock_status
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.orderinfo
|
||||
package com.mogo.och.charter.passenger.ui.orderinfo
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -8,8 +8,8 @@ import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.lifecycle.ViewModelProvider
|
||||
import androidx.lifecycle.findViewTreeViewModelStoreOwner
|
||||
import com.mogo.eagle.core.utilcode.kotlin.onClick
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.callback.IClearViewCallback
|
||||
import kotlinx.android.synthetic.main.m1_devices_fragment.view.actv_contain_order
|
||||
import kotlinx.android.synthetic.main.m1_devices_fragment.view.actv_end_order
|
||||
import kotlinx.android.synthetic.main.m1_devices_fragment.view.actv_end_order_submit
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.orderinfo
|
||||
package com.mogo.och.charter.passenger.ui.orderinfo
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import com.mogo.eagle.core.data.BaseData
|
||||
@@ -7,9 +7,9 @@ import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.GsonUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.callback.ITimeCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.callback.ITimeCallback
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.bean.dpmsg.BaseDPMsg
|
||||
import com.mogo.och.common.module.bean.dpmsg.EndOrderMsg
|
||||
import com.mogo.och.common.module.biz.constant.OchCommonConst
|
||||
@@ -68,7 +68,7 @@ class OrderInfoViewModel: ViewModel(), ITimeCallback {
|
||||
CharterPassengerModel.endOrder(object : OchCommonServiceCallback<BaseData> {
|
||||
override fun onSuccess(data: BaseData?) {
|
||||
if (null != data && 0 == data.code) {
|
||||
ToastCharterUtils.showShort("结束成功")
|
||||
ToastCharterUtils.showToastShort("结束成功")
|
||||
CharterPassengerModel.setEndOrderStatus()
|
||||
viewCallback?.setViewGone()
|
||||
val msg = EndOrderMsg(
|
||||
@@ -83,7 +83,7 @@ class OrderInfoViewModel: ViewModel(), ITimeCallback {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("$code:$msg")
|
||||
ToastCharterUtils.showToastShort("$code:$msg")
|
||||
}
|
||||
})
|
||||
}
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.ui.overmapview
|
||||
package com.mogo.och.charter.passenger.ui.overmapview
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.Bitmap
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.view_maker_sitename.view.*
|
||||
|
||||
/**
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline
|
||||
package com.mogo.och.charter.passenger.ui.selectline
|
||||
|
||||
import android.animation.ObjectAnimator
|
||||
import android.content.Context
|
||||
@@ -13,16 +13,14 @@ import androidx.lifecycle.findViewTreeViewModelStoreOwner
|
||||
import androidx.recyclerview.widget.LinearLayoutManager
|
||||
import com.elegant.utils.UiThreadHandler
|
||||
import com.mogo.eagle.core.utilcode.kotlin.onClick
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.bus.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.ui.selectline.adapter.OrderLineItemAdapter
|
||||
import com.mogo.och.bus.passenger.ui.selectline.adapter.OrderSiteItemAdapter
|
||||
import com.mogo.och.bus.passenger.ui.selectline.layoutmanage.BottomDecoration
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.charter.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.charter.passenger.ui.selectline.adapter.OrderLineItemAdapter
|
||||
import com.mogo.och.charter.passenger.ui.selectline.adapter.OrderSiteItemAdapter
|
||||
import com.mogo.och.charter.passenger.ui.selectline.layoutmanage.BottomDecoration
|
||||
import com.mogo.och.common.module.utils.RxUtils
|
||||
import io.reactivex.disposables.Disposable
|
||||
import kotlinx.android.synthetic.main.m1_order_fragment.view.aciv_driver_refuse_group
|
||||
@@ -100,7 +98,7 @@ class SelectLineView : ConstraintLayout, SelectLineViewModel.SelectLineViewCallb
|
||||
rlv_line_list.layoutManager =
|
||||
LinearLayoutManager(context, LinearLayoutManager.VERTICAL, false)
|
||||
rlv_line_list.addItemDecoration(
|
||||
BottomDecoration(
|
||||
com.mogo.och.charter.passenger.ui.selectline.layoutmanage.BottomDecoration(
|
||||
AutoSizeUtils.dp2px(context, 60f)
|
||||
)
|
||||
)
|
||||
@@ -109,7 +107,7 @@ class SelectLineView : ConstraintLayout, SelectLineViewModel.SelectLineViewCallb
|
||||
rv_site_list.layoutManager =
|
||||
LinearLayoutManager(context, LinearLayoutManager.VERTICAL, false)
|
||||
rv_site_list.addItemDecoration(
|
||||
BottomDecoration(
|
||||
com.mogo.och.charter.passenger.ui.selectline.layoutmanage.BottomDecoration(
|
||||
AutoSizeUtils.dp2px(context, 90f)
|
||||
)
|
||||
)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline
|
||||
package com.mogo.och.charter.passenger.ui.selectline
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import com.elegant.utils.UiThreadHandler
|
||||
@@ -12,15 +12,15 @@ import com.mogo.eagle.core.function.call.telematic.CallerTelematicManager
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.GsonUtils
|
||||
import com.mogo.och.bus.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoListResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.bus.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.bus.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.bus.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.bus.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.bus.passenger.net.BusPassengerServiceManager
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoListResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.charter.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.charter.passenger.model.CharterPassengerModel
|
||||
import com.mogo.och.charter.passenger.model.IOrderStatusChangeListener
|
||||
import com.mogo.och.charter.passenger.model.OrderStatusEnum
|
||||
import com.mogo.och.charter.passenger.net.BusPassengerServiceManager
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.bean.dpmsg.BaseDPMsg
|
||||
import com.mogo.och.common.module.bean.dpmsg.ChangeDestMsg
|
||||
import com.mogo.och.common.module.bean.dpmsg.DPMsgType
|
||||
@@ -85,7 +85,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
if (msg.arriveStatus == 2) {
|
||||
return@post
|
||||
}
|
||||
ToastCharterUtils.showShort("站点确定")
|
||||
ToastCharterUtils.showToastShort("站点确定")
|
||||
viewCallback?.setEnableSiteStatus(true)
|
||||
checkLine = tempCheckLine
|
||||
checkSite = tempCheckSite
|
||||
@@ -98,7 +98,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
CharterPassengerModel.cleanbroadcastListInfo(checkSite)
|
||||
CharterPassengerModel.queryOrder()
|
||||
} else {
|
||||
ToastCharterUtils.showShort("司机端拒绝请重新选择")
|
||||
ToastCharterUtils.showToastShort("司机端拒绝请重新选择")
|
||||
viewCallback?.hideDataDriverRefuse()
|
||||
}
|
||||
RxUtils.disposeSubscribe(subscribeSelectSite)
|
||||
@@ -201,7 +201,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String) {
|
||||
ToastCharterUtils.showShort("查询线路失败")
|
||||
ToastCharterUtils.showToastShort("查询线路失败")
|
||||
viewCallback?.setVisableByTrun(showNetError = true)
|
||||
}
|
||||
|
||||
@@ -214,7 +214,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
|
||||
fun changeSites(siteList: MutableList<SiteInfoResponse.SiteInfo>) {
|
||||
if (!CallerTelematicManager.getClientConnStatus()) {
|
||||
ToastCharterUtils.showLong("乘客屏无法连接司机屏请联系安全员")
|
||||
ToastCharterUtils.showToastLong("乘客屏无法连接司机屏请联系安全员")
|
||||
return
|
||||
}
|
||||
val sentDataSite: MutableList<LineSite> = mutableListOf()
|
||||
@@ -249,7 +249,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
|
||||
RxUtils.disposeSubscribe(subscribeSelectSite)
|
||||
subscribeSelectSite = RxUtils.createSubscribe(120_000) {
|
||||
ToastCharterUtils.showShort("请联系安全员确认")
|
||||
ToastCharterUtils.showToastShort("请联系安全员确认")
|
||||
viewCallback?.hideDataDriverRefuse()
|
||||
}
|
||||
}
|
||||
@@ -297,13 +297,13 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
}
|
||||
|
||||
override fun onFail(code: Int, msg: String?) {
|
||||
ToastCharterUtils.showShort("查询站点失败")
|
||||
ToastCharterUtils.showToastShort("查询站点失败")
|
||||
viewCallback?.setVisableByTrun(showNetError = true)
|
||||
}
|
||||
|
||||
override fun onError() {
|
||||
super.onError()
|
||||
ToastCharterUtils.showShort("查询站点失败")
|
||||
ToastCharterUtils.showToastShort("查询站点失败")
|
||||
viewCallback?.setVisableByTrun(showNetError = true)
|
||||
}
|
||||
})
|
||||
@@ -311,7 +311,7 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
|
||||
private fun checkServerStatus() {
|
||||
if (!CallerTelematicManager.getClientConnStatus()) {
|
||||
ToastCharterUtils.showShort("断开和司机端连接、请联系安全员")
|
||||
ToastCharterUtils.showToastShort("断开和司机端连接、请联系安全员")
|
||||
BizLoopManager.removeLoopFunction(TAGLINELOOP)
|
||||
viewCallback?.hideDataDriverRefuse()
|
||||
CallerLogger.d(
|
||||
@@ -383,21 +383,21 @@ class SelectLineViewModel : ViewModel(), IOrderStatusChangeListener {
|
||||
}
|
||||
|
||||
else -> {
|
||||
ToastCharterUtils.showShort("自动驾驶中无法切换线路")
|
||||
ToastCharterUtils.showToastShort("自动驾驶中无法切换线路")
|
||||
false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
IMoGoAutopilotStatusListener.STATUS_PARALLEL_DRIVING -> {
|
||||
ToastCharterUtils.showShort("因车辆正在平行驾驶中无法切换线路")
|
||||
ToastCharterUtils.showToastShort("因车辆正在平行驾驶中无法切换线路")
|
||||
return false
|
||||
}
|
||||
|
||||
else -> {}
|
||||
}
|
||||
} else {
|
||||
ToastCharterUtils.showShort("请停车后再修改目的地~")
|
||||
ToastCharterUtils.showToastShort("请停车后再修改目的地~")
|
||||
return false
|
||||
}
|
||||
return true
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline.adapter
|
||||
package com.mogo.och.charter.passenger.ui.selectline.adapter
|
||||
|
||||
import android.content.Context
|
||||
import android.view.LayoutInflater
|
||||
@@ -6,8 +6,8 @@ import android.view.View
|
||||
import android.view.ViewGroup
|
||||
import android.widget.TextView
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.response.LineInfoResponse
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.response.LineInfoResponse
|
||||
|
||||
/**
|
||||
* Created by adityagohad on 06/06/17.
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline.adapter
|
||||
package com.mogo.och.charter.passenger.ui.selectline.adapter
|
||||
|
||||
import android.content.Context
|
||||
import android.view.LayoutInflater
|
||||
@@ -8,10 +8,10 @@ import android.widget.ImageView
|
||||
import android.widget.TextView
|
||||
import androidx.core.content.ContextCompat
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.bus.passenger.bean.response.SiteInfoResponse
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.event.EventLineSites
|
||||
import com.mogo.och.charter.passenger.bean.response.SiteInfoResponse
|
||||
import org.greenrobot.eventbus.EventBus
|
||||
|
||||
/**
|
||||
@@ -95,9 +95,9 @@ class OrderSiteItemAdapter(
|
||||
checkChangeListener?.onCheckListener(tempInfo)
|
||||
} else {
|
||||
if (siteInfo.isNear) {
|
||||
ToastCharterUtils.showShort("您已在此站点附近")
|
||||
ToastCharterUtils.showToastShort("您已在此站点附近")
|
||||
} else {
|
||||
ToastCharterUtils.showShort("站点已过,请选择返程路线")
|
||||
ToastCharterUtils.showToastShort("站点已过,请选择返程路线")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.selectline.layoutmanage;
|
||||
|
||||
import android.graphics.Rect;
|
||||
import android.view.View;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.selectline.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.selectline.layoutmanage;
|
||||
|
||||
import android.content.Context;
|
||||
import android.util.DisplayMetrics;
|
||||
@@ -10,7 +10,7 @@ import androidx.recyclerview.widget.LinearLayoutManager;
|
||||
import androidx.recyclerview.widget.LinearSmoothScroller;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.mogo.och.bus.passenger.R;
|
||||
import com.mogo.och.charter.passenger.R;
|
||||
|
||||
public class PickerLayoutManager extends LinearLayoutManager {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol
|
||||
|
||||
import android.animation.ObjectAnimator
|
||||
import android.animation.ValueAnimator
|
||||
@@ -26,14 +26,14 @@ import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.mogo.storage.SharedPrefsMgr
|
||||
import com.mogo.eagle.core.utilcode.util.ClickUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.Temperature
|
||||
import com.mogo.och.bus.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.bus.passenger.ui.selectline.layoutmanage.PickerLayoutManager
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.adapter.TemperatureAdapter
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage.PagerCenterSnapHelper
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.Temperature
|
||||
import com.mogo.och.charter.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.charter.passenger.ui.selectline.layoutmanage.PickerLayoutManager
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.PagerCenterSnapHelper
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.utils.RxUtils
|
||||
import com.mogo.och.common.module.utils.SoundPoolHelper
|
||||
import com.mogo.och.common.module.wigets.MineGradientDrawable
|
||||
@@ -188,10 +188,10 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
tv_temperature_title.isEnabled = enable
|
||||
rv_aircondition_temperature.isEnabled = enable
|
||||
val layoutManager = rv_aircondition_temperature.layoutManager
|
||||
if (layoutManager is PickerLayoutManager) {
|
||||
if (layoutManager is com.mogo.och.charter.passenger.ui.selectline.layoutmanage.PickerLayoutManager) {
|
||||
layoutManager.setHorizontallyScroll(enable)
|
||||
}
|
||||
val adapter = rv_aircondition_temperature.adapter as TemperatureAdapter
|
||||
val adapter = rv_aircondition_temperature.adapter as com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter
|
||||
if (enable) {
|
||||
adapter.setEnable(true)
|
||||
if (tv_setting_aircondition.isChecked) {
|
||||
@@ -322,7 +322,7 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
viewModel?.openAndSetAircondition(modeCmd, windSpeedCmd, temperatureCmd)
|
||||
}
|
||||
|
||||
private fun setCheckAir(adapter: TemperatureAdapter, tag: Temperature) {
|
||||
private fun setCheckAir(adapter: com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter, tag: Temperature) {
|
||||
adapter.setCheckIndex(tag.index)
|
||||
currentTemperature = tag
|
||||
if (rv_aircondition_temperature.tag == touchTag) {
|
||||
@@ -385,11 +385,11 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
if (leftLight) {
|
||||
tv_light_top_01.text = context.getString(R.string.bus_p_m1_close_light1)
|
||||
tv_light_top_01.isChecked = true
|
||||
if (!isFirst) ToastCharterUtils.showShort("打开顶灯1")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("打开顶灯1")
|
||||
} else {
|
||||
tv_light_top_01.text = context.getString(R.string.bus_p_m1_open_light1)
|
||||
tv_light_top_01.isChecked = false
|
||||
if (!isFirst) ToastCharterUtils.showShort("关闭顶灯1")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("关闭顶灯1")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -399,11 +399,11 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
if (rightLight) {
|
||||
tv_light_top_02.text = context.getString(R.string.bus_p_m1_close_light2)
|
||||
tv_light_top_02.isChecked = true
|
||||
if (!isFirst) ToastCharterUtils.showShort("打开顶灯2")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("打开顶灯2")
|
||||
} else {
|
||||
tv_light_top_02.text = context.getString(R.string.bus_p_m1_open_light2)
|
||||
tv_light_top_02.isChecked = false
|
||||
if (!isFirst) ToastCharterUtils.showShort("关闭顶灯2")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("关闭顶灯2")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -414,12 +414,12 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
tv_light_atmosphere.text = context.getString(R.string.bus_p_m1_close_atmosphere)
|
||||
tv_light_atmosphere.isChecked = true
|
||||
iv_bottom_light_setting.setImageResource(R.drawable.bus_p_function_atmosphere_select)
|
||||
if (!isFirst) ToastCharterUtils.showShort("打开氛围灯")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("打开氛围灯")
|
||||
} else {
|
||||
tv_light_atmosphere.text = context.getString(R.string.bus_p_m1_open_atmosphere)
|
||||
tv_light_atmosphere.isChecked = false
|
||||
iv_bottom_light_setting.setImageResource(R.drawable.bus_p_function_atmosphere_nor)
|
||||
if (!isFirst) ToastCharterUtils.showShort("关闭氛围灯")
|
||||
if (!isFirst) ToastCharterUtils.showToastShort("关闭氛围灯")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -629,25 +629,32 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
openAircondition()
|
||||
}
|
||||
}
|
||||
val pickerLayoutManager = PickerLayoutManager(
|
||||
context, PickerLayoutManager.HORIZONTAL, false
|
||||
)
|
||||
val pickerLayoutManager =
|
||||
com.mogo.och.charter.passenger.ui.selectline.layoutmanage.PickerLayoutManager(
|
||||
context,
|
||||
com.mogo.och.charter.passenger.ui.selectline.layoutmanage.PickerLayoutManager.HORIZONTAL,
|
||||
false
|
||||
)
|
||||
pickerLayoutManager.isChangeAlpha = true
|
||||
pickerLayoutManager.scaleDownBy = 0.29f
|
||||
pickerLayoutManager.scaleDownDistance = 0.8f
|
||||
|
||||
val data = getData()
|
||||
val adapter = TemperatureAdapter(context, data, rv_aircondition_temperature)
|
||||
val adapter = com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter(
|
||||
context,
|
||||
data,
|
||||
rv_aircondition_temperature
|
||||
)
|
||||
val snapHelper = PagerCenterSnapHelper()
|
||||
snapHelper.attachToRecyclerView(rv_aircondition_temperature)
|
||||
rv_aircondition_temperature.layoutManager = pickerLayoutManager
|
||||
rv_aircondition_temperature.adapter = adapter
|
||||
HorizontalDecoration.distance = SharedPrefsMgr.getInstance(context).getInt(
|
||||
HorizontalDecoration.distancekey, 0
|
||||
com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration.distance = SharedPrefsMgr.getInstance(context).getInt(
|
||||
com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration.distancekey, 0
|
||||
)
|
||||
val space = AutoSizeUtils.dp2px(context, 15f)
|
||||
rv_aircondition_temperature.addItemDecoration(
|
||||
HorizontalDecoration(
|
||||
com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration(
|
||||
space, data.size - 1
|
||||
)
|
||||
)
|
||||
@@ -673,7 +680,7 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
|
||||
}
|
||||
}
|
||||
if (HorizontalDecoration.distance != 0) {
|
||||
if (com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.HorizontalDecoration.distance != 0) {
|
||||
rv_aircondition_temperature.scrollToPosition(data.size - 1)
|
||||
adapter.setCheckIndex(data.size - 1)
|
||||
}
|
||||
@@ -722,7 +729,7 @@ class SoftControlView : ConstraintLayout, SoftControlViewModel.SoftControlCallba
|
||||
}
|
||||
if (airIsOpen) {
|
||||
val adapter = rv_aircondition_temperature.adapter
|
||||
if (adapter is TemperatureAdapter) {
|
||||
if (adapter is com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter) {
|
||||
adapter.data.forEach {
|
||||
if (it.value == temperatureCmd) {
|
||||
rv_aircondition_temperature.tag = touchTag
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol
|
||||
|
||||
import androidx.lifecycle.ViewModel
|
||||
import com.mogo.eagle.core.function.call.autopilot.CallerAutoPilotControlManager
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant.Companion.M_BUS_P
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorCallback
|
||||
import com.mogo.och.common.module.manager.devicemanage.LightAirconditionDoorStatusManager
|
||||
import com.mogo.och.common.module.manager.devicemanage.data.AirconditionStatus
|
||||
@@ -146,7 +146,7 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
RxUtils.disposeSubscribe(airconditionDisposable)
|
||||
airconditionDisposable = RxUtils.createSubscribe(10000) {
|
||||
if (!LightAirconditionDoorStatusManager.airconditionStatus.isOpen && LightAirconditionDoorStatusManager.airconditionStatus.windSpeed != windSpeedCmd && LightAirconditionDoorStatusManager.airconditionStatus.temperature != temperatureCmd && LightAirconditionDoorStatusManager.airconditionStatus.pattert != modeCmd) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -159,7 +159,7 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
RxUtils.disposeSubscribe(airconditionDisposable)
|
||||
airconditionDisposable = RxUtils.createSubscribe(10000) {
|
||||
if (LightAirconditionDoorStatusManager.airconditionStatus.isOpen) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -173,7 +173,7 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
RxUtils.disposeSubscribe(heaterDisposable)
|
||||
heaterDisposable = RxUtils.createSubscribe(10000) {
|
||||
if (!LightAirconditionDoorStatusManager.heaterStatue.isOpen && LightAirconditionDoorStatusManager.heaterStatue.windSpeed != windSpeedCmd) {
|
||||
ToastCharterUtils.showShort("暖风机操作未生效,请稍后重试吧~")
|
||||
ToastCharterUtils.showToastShort("暖风机操作未生效,请稍后重试吧~")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -184,7 +184,7 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
RxUtils.disposeSubscribe(heaterDisposable)
|
||||
heaterDisposable = RxUtils.createSubscribe(10000) {
|
||||
if (LightAirconditionDoorStatusManager.heaterStatue.isOpen) {
|
||||
ToastCharterUtils.showShort("暖风机操作未生效,请稍后重试吧~")//还是开着的
|
||||
ToastCharterUtils.showToastShort("暖风机操作未生效,请稍后重试吧~")//还是开着的
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -196,14 +196,14 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1MainLamp1Cmd(1)
|
||||
RxUtils.createSubscribe {
|
||||
if (!LightAirconditionDoorStatusManager.lightStatus.isOpenLight1) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1MainLamp1Cmd(2)
|
||||
RxUtils.createSubscribe {
|
||||
if (LightAirconditionDoorStatusManager.lightStatus.isOpenLight1) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -216,14 +216,14 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1MainLamp2Cmd(1)
|
||||
RxUtils.createSubscribe {
|
||||
if (!LightAirconditionDoorStatusManager.lightStatus.isOpenLight2) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1MainLamp2Cmd(2)
|
||||
RxUtils.createSubscribe {
|
||||
if (LightAirconditionDoorStatusManager.lightStatus.isOpenLight2) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -236,14 +236,14 @@ class SoftControlViewModel : ViewModel(), LightAirconditionDoorCallback {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1SmallLampCmd(1)
|
||||
RxUtils.createSubscribe {
|
||||
if (!LightAirconditionDoorStatusManager.lightStatus.isOpenatmosphere) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
} else {
|
||||
CallerAutoPilotControlManager.sendRoboBusJinlvM1SmallLampCmd(2)
|
||||
RxUtils.createSubscribe {
|
||||
if (LightAirconditionDoorStatusManager.lightStatus.isOpenatmosphere) {
|
||||
ToastCharterUtils.showShort("控制系统繁忙,请稍后再试")
|
||||
ToastCharterUtils.showToastShort("控制系统繁忙,请稍后再试")
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.adapter;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Color;
|
||||
@@ -10,8 +10,9 @@ import android.widget.TextView;
|
||||
import androidx.core.content.ContextCompat;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.mogo.och.bus.passenger.R;
|
||||
import com.mogo.och.bus.passenger.bean.Temperature;
|
||||
import com.mogo.och.charter.passenger.R;
|
||||
import com.mogo.och.charter.passenger.bean.Temperature;
|
||||
import com.mogo.och.charter.passenger.bean.Temperature;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage;
|
||||
|
||||
import android.graphics.PointF;
|
||||
import android.os.Build;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage;
|
||||
|
||||
import android.view.View;
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage;
|
||||
|
||||
import androidx.annotation.NonNull;
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage;
|
||||
|
||||
import android.graphics.Rect;
|
||||
import android.view.View;
|
||||
@@ -8,7 +8,8 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.mogo.commons.AbsMogoApplication;
|
||||
import com.mogo.eagle.core.utilcode.mogo.storage.SharedPrefsMgr;
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.adapter.TemperatureAdapter;
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter;
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.adapter.TemperatureAdapter;
|
||||
|
||||
public class HorizontalDecoration extends RecyclerView.ItemDecoration {
|
||||
private int space = 0;
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage;
|
||||
|
||||
public class ItemTransformation {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage
|
||||
|
||||
import android.view.View
|
||||
import androidx.recyclerview.widget.OrientationHelper
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.view
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.view
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.Bitmap
|
||||
@@ -7,7 +7,7 @@ import android.graphics.Canvas
|
||||
import android.graphics.Paint
|
||||
import android.util.AttributeSet
|
||||
import android.view.View
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
|
||||
|
||||
class DrawBitmapView @JvmOverloads constructor(
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.softcontrol.view;
|
||||
package com.mogo.och.charter.passenger.ui.softcontrol.view;
|
||||
|
||||
import android.content.Context;
|
||||
import android.graphics.Bitmap;
|
||||
@@ -1,11 +1,11 @@
|
||||
package com.mogo.och.bus.passenger.ui.statusbar
|
||||
package com.mogo.och.charter.passenger.ui.statusbar
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.view.LayoutInflater
|
||||
import com.mogo.eagle.core.function.api.devatools.IMoGoDevaToolsListener
|
||||
import com.mogo.eagle.core.function.hmi.ui.widget.BlueToothView
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import kotlinx.android.synthetic.main.m1_statusview_blue_tooth.view.*
|
||||
|
||||
/**
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.statusbar
|
||||
package com.mogo.och.charter.passenger.ui.statusbar
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.content.Context
|
||||
@@ -27,8 +27,8 @@ import com.mogo.eagle.core.function.hmi.ui.widget.DemoModeView
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.util.ClickUtils
|
||||
import com.mogo.eagle.core.utilcode.util.UiThreadHandler
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.ui.debugview.DebugEvent
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.ui.debugview.DebugEvent
|
||||
import com.mogo.och.common.module.manager.loopmanager.BizLoopManager
|
||||
import com.mogo.och.common.module.manager.loopmanager.LoopInfo
|
||||
import kotlinx.android.synthetic.main.m1_statusview_datetime.view.*
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.video
|
||||
package com.mogo.och.charter.passenger.ui.video
|
||||
|
||||
import android.app.Activity
|
||||
import android.content.Context
|
||||
@@ -18,10 +18,10 @@ import androidx.appcompat.widget.AppCompatImageView
|
||||
import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.core.app.ActivityCompat
|
||||
import com.mogo.eagle.core.utilcode.util.TimeTransformUtils
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import com.mogo.eagle.core.widget.media.video.TextureVideoViewOutlineProvider
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.utils.FullVideoUtils
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.utils.FullVideoUtils
|
||||
import com.shuyu.gsyvideoplayer.listener.VideoAllCallBack
|
||||
import com.shuyu.gsyvideoplayer.utils.GSYVideoType
|
||||
import com.shuyu.gsyvideoplayer.video.StandardGSYVideoPlayer
|
||||
@@ -141,7 +141,7 @@ class ConsultVideoPlayer : StandardGSYVideoPlayer {
|
||||
override fun setStateAndUi(state: Int) {
|
||||
super.setStateAndUi(state)
|
||||
if(state==CURRENT_STATE_PLAYING_BUFFERING_START){
|
||||
ToastCharterUtils.showShort("加载中请稍等")
|
||||
ToastCharterUtils.showToastShort("加载中请稍等")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -267,7 +267,7 @@ class ConsultVideoPlayer : StandardGSYVideoPlayer {
|
||||
override fun onError(what: Int, extra: Int) {
|
||||
super.onError(what, extra)
|
||||
mThumbImageViewLayout?.visibility = View.VISIBLE
|
||||
ToastCharterUtils.showLong("哎呀,出错了,看看其他视频吧")
|
||||
ToastCharterUtils.showToastLong("哎呀,出错了,看看其他视频吧")
|
||||
currentTime = -1
|
||||
if(isIfCurrentIsFullscreen){
|
||||
smalllPlayer?.clearFullscreenLayout(this)
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.video
|
||||
package com.mogo.och.charter.passenger.ui.video
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
@@ -8,13 +8,13 @@ import androidx.constraintlayout.widget.ConstraintLayout
|
||||
import androidx.recyclerview.widget.RecyclerView
|
||||
import com.mogo.eagle.core.function.api.autopilot.IMoGoAutopilotStatusListener
|
||||
import com.mogo.eagle.core.utilcode.kotlin.onClick
|
||||
import com.mogo.och.bus.passenger.R
|
||||
import com.mogo.och.bus.passenger.bean.TaxiPassengerVideoPlay
|
||||
import com.mogo.och.bus.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage.CarouselLayoutManager
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage.CarouselZoomPostLayoutListener
|
||||
import com.mogo.och.bus.passenger.ui.softcontrol.layoutmanage.CenterScrollListener
|
||||
import com.mogo.och.bus.passenger.ui.video.adapter.RecyclerVideoAdapter
|
||||
import com.mogo.och.charter.passenger.R
|
||||
import com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay
|
||||
import com.mogo.och.charter.passenger.callback.IClearViewCallback
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselLayoutManager
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselZoomPostLayoutListener
|
||||
import com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CenterScrollListener
|
||||
import com.mogo.och.charter.passenger.ui.video.adapter.RecyclerVideoAdapter
|
||||
import com.shuyu.gsyvideoplayer.video.base.GSYVideoView
|
||||
import kotlinx.android.synthetic.main.m1_video_fragment.view.rvVideoPlaylist
|
||||
import kotlin.math.floor
|
||||
@@ -29,7 +29,7 @@ class VideoView @JvmOverloads constructor(
|
||||
const val TAG = "DebugView"
|
||||
}
|
||||
|
||||
private val arrayListOf = ArrayList<TaxiPassengerVideoPlay>()
|
||||
private val arrayListOf = ArrayList<com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay>()
|
||||
|
||||
var goneViewListener: IClearViewCallback? = null
|
||||
|
||||
@@ -39,10 +39,14 @@ class VideoView @JvmOverloads constructor(
|
||||
goneViewListener?.goneAllView()
|
||||
}
|
||||
initConsultData()
|
||||
val carouselLayoutManager = CarouselLayoutManager(CarouselLayoutManager.HORIZONTAL, true)
|
||||
carouselLayoutManager.setPostLayoutListener(CarouselZoomPostLayoutListener())
|
||||
val carouselLayoutManager =
|
||||
com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselLayoutManager(
|
||||
CarouselLayoutManager.HORIZONTAL,
|
||||
true
|
||||
)
|
||||
carouselLayoutManager.setPostLayoutListener(com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselZoomPostLayoutListener())
|
||||
carouselLayoutManager.maxVisibleItems = 1
|
||||
rvVideoPlaylist.addOnScrollListener(object : CenterScrollListener() {
|
||||
rvVideoPlaylist.addOnScrollListener(object : com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CenterScrollListener() {
|
||||
var prePlayerPosition = 0
|
||||
override fun pageSelect(recyclerView: RecyclerView?, newState: Int) {
|
||||
//播放视频
|
||||
@@ -83,7 +87,12 @@ class VideoView @JvmOverloads constructor(
|
||||
}
|
||||
}
|
||||
}
|
||||
val recyclerVideoAdapter = RecyclerVideoAdapter(context, arrayListOf, rvVideoPlaylist)
|
||||
val recyclerVideoAdapter =
|
||||
com.mogo.och.charter.passenger.ui.video.adapter.RecyclerVideoAdapter(
|
||||
context,
|
||||
arrayListOf,
|
||||
rvVideoPlaylist
|
||||
)
|
||||
recyclerVideoAdapter.setOnThumbImageClilckListener {
|
||||
val (_, player) = getPlayer(carouselLayoutManager)
|
||||
if (player is ConsultVideoPlayer) {
|
||||
@@ -102,7 +111,7 @@ class VideoView @JvmOverloads constructor(
|
||||
|
||||
}
|
||||
|
||||
private fun getPlayer(carouselLayoutManager: CarouselLayoutManager): Pair<Int, ConsultVideoPlayer?> {
|
||||
private fun getPlayer(carouselLayoutManager: com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselLayoutManager): Pair<Int, ConsultVideoPlayer?> {
|
||||
val centerItemPosition: Int = carouselLayoutManager.centerItemPosition
|
||||
val playerHolder = carouselLayoutManager.findViewByPosition(centerItemPosition)
|
||||
val player = playerHolder?.findViewById<ConsultVideoPlayer>(R.id.video_item_player)
|
||||
@@ -118,7 +127,7 @@ class VideoView @JvmOverloads constructor(
|
||||
if (changedView != this) {
|
||||
return
|
||||
}
|
||||
val carouselLayoutManager = rvVideoPlaylist?.layoutManager as CarouselLayoutManager
|
||||
val carouselLayoutManager = rvVideoPlaylist?.layoutManager as com.mogo.och.charter.passenger.ui.softcontrol.layoutmanage.CarouselLayoutManager
|
||||
val (_, player) = getPlayer(carouselLayoutManager)
|
||||
when (visibility) {
|
||||
View.VISIBLE -> {}
|
||||
@@ -135,28 +144,28 @@ class VideoView @JvmOverloads constructor(
|
||||
private fun initConsultData() {
|
||||
arrayListOf.clear()
|
||||
arrayListOf.add(
|
||||
TaxiPassengerVideoPlay(
|
||||
com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay(
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655708596763/全车型混剪增加红旗车队.m4v",
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655969511280/车队.png",
|
||||
"蘑菇车联覆盖生活的方方面面"
|
||||
)
|
||||
)
|
||||
arrayListOf.add(
|
||||
TaxiPassengerVideoPlay(
|
||||
com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay(
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655708554279/红旗车队.m4v",
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655969553174/红旗重新排版.png",
|
||||
"蘑菇车联之红旗车队"
|
||||
)
|
||||
)
|
||||
arrayListOf.add(
|
||||
TaxiPassengerVideoPlay(
|
||||
com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay(
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655708499497/大运会合作解说版.m4v",
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655969536177/大运会.png",
|
||||
"蘑菇车联牵手成都大运会"
|
||||
)
|
||||
)
|
||||
arrayListOf.add(
|
||||
TaxiPassengerVideoPlay(
|
||||
com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay(
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655708409810/20210610重新排版3屏.m4v",
|
||||
"https://img.zhidaohulian.com/fileServer/online_car_hailing/1655969579713/三屏.png",
|
||||
"多视角体验蘑菇车联自动驾驶"
|
||||
@@ -1,12 +1,12 @@
|
||||
package com.mogo.och.bus.passenger.ui.video.adapter;
|
||||
package com.mogo.och.charter.passenger.ui.video.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.View;
|
||||
|
||||
import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.mogo.och.bus.passenger.R;
|
||||
import com.mogo.och.bus.passenger.ui.video.ConsultVideoPlayer;
|
||||
import com.mogo.och.charter.passenger.R;
|
||||
import com.mogo.och.charter.passenger.ui.video.ConsultVideoPlayer;
|
||||
import com.shuyu.gsyvideoplayer.builder.GSYVideoOptionBuilder;
|
||||
|
||||
public class RecyclerItemVideoHolder extends RecyclerView.ViewHolder {
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.ui.video.adapter;
|
||||
package com.mogo.och.charter.passenger.ui.video.adapter;
|
||||
|
||||
import android.content.Context;
|
||||
import android.view.LayoutInflater;
|
||||
@@ -10,9 +10,9 @@ import androidx.recyclerview.widget.RecyclerView;
|
||||
|
||||
import com.bumptech.glide.Glide;
|
||||
import com.bumptech.glide.request.RequestOptions;
|
||||
import com.mogo.och.bus.passenger.utils.ToastCharterUtils;
|
||||
import com.mogo.och.bus.passenger.R;
|
||||
import com.mogo.och.bus.passenger.bean.TaxiPassengerVideoPlay;
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils;
|
||||
import com.mogo.och.charter.passenger.R;
|
||||
import com.mogo.och.charter.passenger.bean.TaxiPassengerVideoPlay;
|
||||
import com.shuyu.gsyvideoplayer.listener.GSYSampleCallBack;
|
||||
|
||||
import java.util.List;
|
||||
@@ -102,12 +102,12 @@ public class RecyclerVideoAdapter extends RecyclerView.Adapter<RecyclerItemVideo
|
||||
|
||||
@Override
|
||||
public void onPlayError(String url, Object... objects) {
|
||||
ToastCharterUtils.INSTANCE.showLong("哎呀,出错了,看看其他视频吧");
|
||||
ToastCharterUtils.INSTANCE.showCharterLongToast("哎呀,出错了,看看其他视频吧");
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onClickStartError(String url, Object... objects) {
|
||||
ToastCharterUtils.INSTANCE.showLong("哎呀,出错了,看看其他视频吧");
|
||||
ToastCharterUtils.INSTANCE.showCharterLongToast("哎呀,出错了,看看其他视频吧");
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.utils;
|
||||
package com.mogo.och.charter.passenger.utils;
|
||||
|
||||
|
||||
import android.content.Context;
|
||||
@@ -1,10 +1,10 @@
|
||||
package com.mogo.och.bus.passenger.utils
|
||||
package com.mogo.och.charter.passenger.utils
|
||||
|
||||
import android.annotation.SuppressLint
|
||||
import android.app.Activity
|
||||
import android.view.View
|
||||
import android.view.WindowManager
|
||||
import com.mogo.och.bus.passenger.ui.video.ConsultVideoPlayer
|
||||
import com.mogo.och.charter.passenger.ui.video.ConsultVideoPlayer
|
||||
import com.shuyu.gsyvideoplayer.GSYVideoManager
|
||||
import java.lang.Exception
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.utils
|
||||
package com.mogo.och.charter.passenger.utils
|
||||
|
||||
import android.os.Build
|
||||
import androidx.annotation.RequiresApi
|
||||
@@ -1,4 +1,4 @@
|
||||
package com.mogo.och.bus.passenger.utils
|
||||
package com.mogo.och.charter.passenger.utils
|
||||
|
||||
import android.content.Context
|
||||
import android.graphics.*
|
||||
@@ -8,7 +8,7 @@
|
||||
tools:ignore="MissingDefaultResource">
|
||||
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.impl.GoViewWithArrive
|
||||
<com.mogo.och.charter.passenger.ui.bottom.impl.GoViewWithArrive
|
||||
android:id="@+id/aciv_center_image"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
@@ -26,7 +26,7 @@
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.impl.StopSiteView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.impl.StopSiteView
|
||||
android:id="@+id/actv_stop_site"
|
||||
app:backageViewId="@+id/actv_stop_site_press"
|
||||
app:selectedDrawable="@drawable/charter_p_bottom_stopsite_press"
|
||||
@@ -48,7 +48,7 @@
|
||||
android:layout_width="@dimen/dp_359"
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.impl.CloseDoorView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.impl.CloseDoorView
|
||||
android:id="@+id/actv_close_door"
|
||||
app:backageViewId="@+id/actv_close_door_press"
|
||||
app:selectedDrawable="@drawable/charter_p_bottom_closedoor_press"
|
||||
@@ -70,7 +70,7 @@
|
||||
android:layout_width="@dimen/dp_359"
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.impl.OpenDoorView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.impl.OpenDoorView
|
||||
android:id="@+id/actv_open_door"
|
||||
android:gravity="center"
|
||||
app:backageViewId="@+id/actv_open_door_press"
|
||||
@@ -93,7 +93,7 @@
|
||||
android:layout_width="@dimen/dp_359"
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomOrderInfoView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomOrderInfoView
|
||||
android:id="@+id/cl_order_time"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toStartOf="@+id/actv_setting"
|
||||
@@ -112,7 +112,7 @@
|
||||
android:layout_width="@dimen/dp_359"
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomCheckView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomCheckView
|
||||
android:id="@+id/actv_setting"
|
||||
app:backageViewId="@+id/actv_setting_press"
|
||||
app:selectedDrawable="@drawable/charter_p_bottom_softsettiing_press"
|
||||
@@ -135,7 +135,7 @@
|
||||
android:layout_width="@dimen/dp_359"
|
||||
android:layout_height="@dimen/dp_107"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomCheckView
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomCheckView
|
||||
android:id="@+id/actv_line"
|
||||
app:backageViewId="@+id/actv_line_press"
|
||||
app:selectedDrawable="@drawable/charter_p_bottom_line_press"
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="wrap_content"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomBar
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomBar
|
||||
android:id="@+id/bb_bottom_bar"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<com.mogo.och.bus.passenger.ui.lockview.LockViewConstrainLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
<com.mogo.och.charter.passenger.ui.lockview.LockViewConstrainLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent">
|
||||
@@ -91,13 +91,13 @@
|
||||
app:layout_constraintEnd_toEndOf="@+id/viewBusPM1MsgBoxButton"
|
||||
app:layout_constraintTop_toBottomOf="@+id/viewBusPM1MsgBoxButton" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.itinerary.ItineraryView
|
||||
<com.mogo.och.charter.passenger.ui.itinerary.ItineraryView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.orderinfo.OrderInfoView
|
||||
<com.mogo.och.charter.passenger.ui.orderinfo.OrderInfoView
|
||||
android:id="@+id/biz_orderinfo"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="0dp"
|
||||
@@ -106,13 +106,13 @@
|
||||
app:layout_constraintBottom_toTopOf="@+id/bb_boorombar"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.softcontrol.SoftControlView
|
||||
<com.mogo.och.charter.passenger.ui.softcontrol.SoftControlView
|
||||
android:id="@+id/biz_softcontrol"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:visibility="gone" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.selectline.SelectLineView
|
||||
<com.mogo.och.charter.passenger.ui.selectline.SelectLineView
|
||||
android:id="@+id/biz_selectline"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
@@ -123,14 +123,14 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.video.VideoView
|
||||
<com.mogo.och.charter.passenger.ui.video.VideoView
|
||||
android:id="@+id/biz_video"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:visibility="gone" />
|
||||
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomBar
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomBar
|
||||
android:id="@+id/bb_boorombar"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="@dimen/dp_107"
|
||||
@@ -138,7 +138,7 @@
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.debugview.DebugView
|
||||
<com.mogo.och.charter.passenger.ui.debugview.DebugView
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_marginTop="@dimen/dp_47"
|
||||
@@ -146,7 +146,7 @@
|
||||
app:layout_constraintEnd_toEndOf="@+id/mapBizView"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.lockview.UnlockView
|
||||
<com.mogo.och.charter.passenger.ui.lockview.UnlockView
|
||||
android:id="@+id/uv_only_unlock"
|
||||
android:visibility="gone"
|
||||
android:background="@color/bus_p_m1_66000000"
|
||||
@@ -157,7 +157,7 @@
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"/>
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.lockview.LockAndUnlockView
|
||||
<com.mogo.och.charter.passenger.ui.lockview.LockAndUnlockView
|
||||
android:layout_width="@dimen/dp_138"
|
||||
android:layout_height="@dimen/dp_138"
|
||||
app:layout_constraintBottom_toTopOf="@+id/aciv_map_2_default"
|
||||
@@ -165,4 +165,4 @@
|
||||
app:layout_constraintEnd_toEndOf="parent" />
|
||||
|
||||
|
||||
</com.mogo.och.bus.passenger.ui.lockview.LockViewConstrainLayout>
|
||||
</com.mogo.och.charter.passenger.ui.lockview.LockViewConstrainLayout>
|
||||
@@ -84,7 +84,7 @@
|
||||
app:layout_constraintStart_toStartOf="@+id/gl_left"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.softcontrol.view.DrawBitmapView
|
||||
<com.mogo.och.charter.passenger.ui.softcontrol.view.DrawBitmapView
|
||||
android:id="@+id/dbv_wind"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="0dp"
|
||||
@@ -93,7 +93,7 @@
|
||||
app:layout_constraintHeight_percent="0.5"
|
||||
app:layout_constraintStart_toStartOf="@+id/iv_aircondition" />
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.softcontrol.view.DrawableCheckBox
|
||||
<com.mogo.och.charter.passenger.ui.softcontrol.view.DrawableCheckBox
|
||||
android:id="@+id/tv_aircondition_switch"
|
||||
android:layout_width="0dp"
|
||||
android:layout_height="@dimen/dp_76"
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
android:layout_marginStart="@dimen/dp_80" />
|
||||
|
||||
<!--魔方连接状态-->
|
||||
<com.mogo.och.bus.passenger.ui.statusbar.M1BlueToothView
|
||||
<com.mogo.och.charter.passenger.ui.statusbar.M1BlueToothView
|
||||
android:id="@+id/blueToothView"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
android:layout_width="@dimen/dp_1300"
|
||||
android:layout_height="@dimen/dp_731">
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.video.ConsultVideoPlayer
|
||||
<com.mogo.och.charter.passenger.ui.video.ConsultVideoPlayer
|
||||
android:id="@+id/video_item_player"
|
||||
android:layout_gravity="center"
|
||||
android:layout_width="@dimen/dp_1300"
|
||||
|
||||
@@ -144,7 +144,7 @@
|
||||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||||
|
||||
|
||||
<com.mogo.och.bus.passenger.ui.bottom.BottomBar
|
||||
<com.mogo.och.charter.passenger.ui.bottom.BottomBar
|
||||
app:layout_constraintBottom_toBottomOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
|
||||
@@ -16,6 +16,7 @@ import com.mogo.och.common.module.biz.constant.TaxiLoginStatusEnum
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceCallback
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceManager
|
||||
import com.mogo.och.common.module.utils.ToastUtilsOch
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
|
||||
/**
|
||||
* Created by pangfan on 2021/8/19
|
||||
@@ -63,20 +64,20 @@ object OchCommonLoginModel {
|
||||
override fun onSuccess(data: BaseData?) {
|
||||
if (null != data && 0 == data.code) {
|
||||
// 获取验证码成功
|
||||
ToastUtils.showShort(mContext?.getString(R.string.module_och_taxi_login_get_code_success))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.module_och_taxi_login_get_code_success))
|
||||
iTaxiLoginCallback?.getPhoneCodeSuccess()
|
||||
} else {
|
||||
if (data != null) {
|
||||
ToastUtils.showShort(data.code)
|
||||
ToastCharterUtils.showToastShort(data.code.toString())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onError() {
|
||||
if (!NetworkUtils.isConnected(mContext)) {
|
||||
ToastUtils.showShort(mContext?.getString(R.string.network_error_tip))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.network_error_tip))
|
||||
} else {
|
||||
ToastUtils.showShort(mContext?.getString(R.string.request_error_tip))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.request_error_tip))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -97,7 +98,7 @@ object OchCommonLoginModel {
|
||||
override fun onSuccess(data: TaxiLoginRespBean?) {
|
||||
if (null != data && 0 == data.code) {
|
||||
// 获取验证码成功
|
||||
ToastUtils.showShort(mContext?.getString(R.string.module_och_taxi_login_login_success))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.module_och_taxi_login_login_success))
|
||||
LoginStatusManager.setLoginStatus(TaxiLoginStatusEnum.Login)
|
||||
mContext?.let {
|
||||
SharedPrefs.getInstance(it).putString("och_account", phone)
|
||||
@@ -105,16 +106,16 @@ object OchCommonLoginModel {
|
||||
iTaxiLoginCallback?.loginSuccess()
|
||||
} else {
|
||||
if (data != null) {
|
||||
ToastUtils.showShort(data.code)
|
||||
ToastCharterUtils.showToastShort(data.code.toString())
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
override fun onError() {
|
||||
if (!NetworkUtils.isConnected(mContext)) {
|
||||
ToastUtils.showShort(mContext?.getString(R.string.network_error_tip))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.network_error_tip))
|
||||
} else {
|
||||
ToastUtils.showShort(mContext?.getString(R.string.request_error_tip))
|
||||
ToastCharterUtils.showToastShort(mContext?.getString(R.string.request_error_tip))
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -17,6 +17,7 @@ import com.mogo.och.common.module.biz.constant.OchCommonConst;
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceCallback;
|
||||
import com.mogo.och.common.module.biz.network.OchCommonServiceManager;
|
||||
import com.mogo.och.common.module.utils.ToastUtilsOch;
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils;
|
||||
|
||||
import java.util.concurrent.TimeUnit;
|
||||
|
||||
@@ -67,9 +68,9 @@ public abstract class OchCommonLoginStatusModel {
|
||||
@Override
|
||||
public void onError() {
|
||||
if (!NetworkUtils.isConnected(mContext)) {
|
||||
ToastUtils.showShort(mContext.getString(R.string.network_error_tip));
|
||||
ToastCharterUtils.showToastShort(mContext.getString(R.string.network_error_tip));
|
||||
} else {
|
||||
ToastUtils.showShort(mContext.getString(R.string.request_error_tip));
|
||||
ToastCharterUtils.showToastShort(mContext.getString(R.string.request_error_tip));
|
||||
}
|
||||
subscribe = Observable.timer(5, TimeUnit.SECONDS).subscribe(aLong -> {
|
||||
queryCarStatus();
|
||||
@@ -106,9 +107,9 @@ public abstract class OchCommonLoginStatusModel {
|
||||
@Override
|
||||
public void onError() {
|
||||
if (!NetworkUtils.isConnected(mContext)) {
|
||||
ToastUtils.showShort(mContext.getString(R.string.network_error_tip));
|
||||
ToastCharterUtils.showToastShort(mContext.getString(R.string.network_error_tip));
|
||||
} else {
|
||||
ToastUtils.showShort(mContext.getString(R.string.request_error_tip));
|
||||
ToastCharterUtils.showToastShort(mContext.getString(R.string.request_error_tip));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -6,11 +6,11 @@ import com.mogo.commons.mvp.Presenter
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.scene.SceneConstant
|
||||
import com.mogo.eagle.core.utilcode.util.RegexUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.och.common.module.R
|
||||
import com.mogo.och.common.module.biz.ui.TaxiLoginDialogFragment
|
||||
import com.mogo.och.common.module.biz.callback.ITaxiLoginCallback
|
||||
import com.mogo.och.common.module.biz.model.OchCommonLoginModel
|
||||
import com.mogo.och.common.module.biz.ui.TaxiLoginDialogFragment
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import io.reactivex.Observable
|
||||
import io.reactivex.android.schedulers.AndroidSchedulers
|
||||
import io.reactivex.disposables.Disposable
|
||||
@@ -42,7 +42,7 @@ class OchCommonLoginPresenter(view: TaxiLoginDialogFragment?) :
|
||||
initListeners()
|
||||
}
|
||||
if (!RegexUtils.isMobileExact(phone)) {
|
||||
ToastUtils.showShort(R.string.module_och_taxi_login_phone_error)
|
||||
ToastCharterUtils.showToastShort(R.string.module_och_taxi_login_phone_error)
|
||||
mView?.inputPhoneError()
|
||||
return
|
||||
}
|
||||
@@ -98,12 +98,12 @@ class OchCommonLoginPresenter(view: TaxiLoginDialogFragment?) :
|
||||
initListeners()
|
||||
}
|
||||
if (!RegexUtils.isMobileExact(phone)) {
|
||||
ToastUtils.showShort(R.string.module_och_taxi_login_phone_error)
|
||||
ToastCharterUtils.showToastShort(R.string.module_och_taxi_login_phone_error)
|
||||
mView?.inputPhoneError()
|
||||
return
|
||||
}
|
||||
if(code.isBlank()||code.length<4){
|
||||
ToastUtils.showShort(R.string.module_och_taxi_login_code_error)
|
||||
ToastCharterUtils.showToastShort(R.string.module_och_taxi_login_code_error)
|
||||
return
|
||||
}
|
||||
mView?.closeSoftInput()
|
||||
|
||||
@@ -9,8 +9,8 @@ import com.mogo.eagle.core.data.config.FunctionBuildConfig
|
||||
import com.mogo.eagle.core.utilcode.mogo.AppIdentityModeUtils
|
||||
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger.i
|
||||
import com.mogo.eagle.core.utilcode.util.NetworkUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.och.common.module.utils.PermissionUtil
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import io.reactivex.Observable
|
||||
import io.reactivex.android.schedulers.AndroidSchedulers
|
||||
import io.reactivex.disposables.Disposable
|
||||
@@ -36,9 +36,9 @@ object AbnormalFactorsLoopManager : IMogoStatusChangedListener {
|
||||
return@observable
|
||||
}
|
||||
if (newValue) {
|
||||
ToastUtils.showLong("长链接状态恢复")
|
||||
ToastCharterUtils.showToastLong("长链接状态恢复")
|
||||
} else {
|
||||
ToastUtils.showLong("长链接异常,请开启相应权限或者查看网络")
|
||||
ToastCharterUtils.showToastLong("长链接异常,请开启相应权限或者查看网络")
|
||||
}
|
||||
}
|
||||
|
||||
@@ -88,7 +88,7 @@ object AbnormalFactorsLoopManager : IMogoStatusChangedListener {
|
||||
i(TAG, "abnormal_factors_Str = $toastStr")
|
||||
|
||||
if (!FunctionBuildConfig.isDemoMode && toastStr !== "") {
|
||||
ToastUtils.showLong(toastStr + "请开启相应权限或者查看网络")
|
||||
ToastCharterUtils.showToastLong(toastStr + "请开启相应权限或者查看网络")
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -17,8 +17,8 @@ import com.mogo.eagle.core.utilcode.util.AppStateManager
|
||||
import com.mogo.eagle.core.utilcode.util.BarUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ClickUtils
|
||||
import com.mogo.eagle.core.utilcode.util.KeyboardUtils
|
||||
import com.mogo.eagle.core.utilcode.util.ToastUtils
|
||||
import com.mogo.och.common.module.R
|
||||
import com.mogo.och.common.module.wigets.toast.ToastCharterUtils
|
||||
import kotlinx.android.synthetic.main.m1_debugview_pass.*
|
||||
|
||||
/**
|
||||
@@ -43,7 +43,7 @@ class DebugViewWatchDogFragment :
|
||||
actv_password_submit.setOnClickListener {
|
||||
val text = acet_close.text
|
||||
if(text==null||text.isEmpty()){
|
||||
ToastUtils.showShort("请输入密码")
|
||||
ToastCharterUtils.showToastShort("请输入密码")
|
||||
}else{
|
||||
if(text.toString() == "123987"){
|
||||
dismissAllowingStateLoss()
|
||||
@@ -52,7 +52,7 @@ class DebugViewWatchDogFragment :
|
||||
}
|
||||
ToggleDebugView.toggleDebugView.toggle(requireContext())
|
||||
}else{
|
||||
ToastUtils.showShort("请输入正确密码")
|
||||
ToastCharterUtils.showToastShort("请输入正确密码")
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user