[fea]
[乘客屏 视角切换]
This commit is contained in:
yangyakun
2024-07-08 19:24:34 +08:00
parent c5bf3381bd
commit e0aa56d32c
5 changed files with 73 additions and 10 deletions

View File

@@ -125,6 +125,7 @@ class TaxiPassengerBaseFragment() :
}
rbv_setting_music.setShowOnlySetting(0)
lbv_go2_center.visibility = View.VISIBLE
lbv_go2_center.showAngle()
pcnActionView.visibility = View.VISIBLE
CallerHmiManager.showTrafficLightView()
infoVideoView.visibility = View.GONE
@@ -138,7 +139,8 @@ class TaxiPassengerBaseFragment() :
romaPView.updateVisible(false)
romaDistanceView.visibility = View.GONE
rbv_setting_music.setShowOnlySetting(0)
lbv_go2_center.visibility = View.GONE
lbv_go2_center.visibility = View.VISIBLE
lbv_go2_center.showOnlyCenter()
pcnActionView.visibility = View.VISIBLE
CallerHmiManager.showTrafficLightView()
infoVideoView.visibility = View.GONE

View File

@@ -8,7 +8,10 @@ import androidx.constraintlayout.widget.ConstraintLayout
import com.mogo.eagle.core.utilcode.kotlin.onClick
import com.mogo.och.common.module.wigets.map.switchvisual.SeekBarView
import com.mogo.och.taxi.passenger.common.R
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.iv_center_location_bg
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.aciv_only_center
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.clgroup_self_map
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.clgroup_self_only_map
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.iv_center_location
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.iv_visual_angle_title_bottom
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.iv_visual_angle_title_head
import kotlinx.android.synthetic.main.taxi_p_leftbar.view.iv_visual_angle_title_value_bg
@@ -34,7 +37,10 @@ class LeftBarView : ConstraintLayout {
private fun initView() {
LayoutInflater.from(context).inflate(R.layout.taxi_p_leftbar, this, true)
iv_center_location_bg.onClick {
iv_center_location.onClick {
this.rightBarCallback?.setGo2CenterClick()
}
aciv_only_center.onClick {
this.rightBarCallback?.setGo2CenterClick()
}
@@ -54,6 +60,16 @@ class LeftBarView : ConstraintLayout {
}
}
fun showAngle(){
clgroup_self_map.visibility = VISIBLE
clgroup_self_only_map.visibility = GONE
}
fun showOnlyCenter(){
clgroup_self_map.visibility = GONE
clgroup_self_only_map.visibility = VISIBLE
}
override fun onVisibilityAggregated(isVisible: Boolean) {
super.onVisibilityAggregated(isVisible)
}

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.6 KiB

View File

@@ -8,8 +8,8 @@
<ImageView
android:id="@+id/iv_center_location_bg"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:layout_width="@dimen/dp_103"
android:layout_height="@dimen/dp_441"
android:src="@drawable/taxi_p_left_bar_bg"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="parent" />
@@ -35,9 +35,11 @@
<ImageView
android:id="@+id/iv_center_location"
android:layout_width="@dimen/dp_44"
android:layout_height="@dimen/dp_44"
android:layout_marginBottom="@dimen/dp_63"
android:layout_width="@dimen/dp_103"
android:layout_height="@dimen/dp_84"
android:paddingBottom="@dimen/dp_20"
android:paddingTop="@dimen/dp_20"
android:layout_marginBottom="@dimen/dp_23"
android:src="@drawable/taxi_p_center_location_selector"
app:layout_constraintBottom_toBottomOf="@+id/iv_center_location_bg"
app:layout_constraintEnd_toEndOf="@+id/iv_center_location_bg"
@@ -48,6 +50,7 @@
android:background="@drawable/taxi_p_left_bar_split"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:layout_marginTop="@dimen/dp_20"
app:layout_constraintBottom_toTopOf="@+id/iv_center_location"
app:layout_constraintTop_toBottomOf="@+id/iv_visual_angle_title_bottom"
android:layout_width="@dimen/dp_68"
@@ -63,4 +66,41 @@
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent" />
<androidx.constraintlayout.widget.Group
android:id="@+id/clgroup_self_map"
app:constraint_referenced_ids="iv_center_location_bg,iv_visual_angle_title_value_bg,iv_visual_angle_title_head,iv_center_location,view_split,iv_visual_angle_title_bottom"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
<androidx.constraintlayout.widget.Group
android:id="@+id/clgroup_self_only_map"
android:visibility="gone"
app:constraint_referenced_ids="aciv_only_center_bg,aciv_only_center"
android:layout_width="wrap_content"
android:layout_height="wrap_content"/>
<androidx.appcompat.widget.AppCompatImageView
android:id="@+id/aciv_only_center_bg"
android:src="@drawable/taxi_p_only_center_bg"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:layout_width="@dimen/dp_103"
android:layout_height="@dimen/dp_103"/>
<androidx.appcompat.widget.AppCompatImageView
android:id="@+id/aciv_only_center"
android:src="@drawable/taxi_p_center_location_selector"
app:layout_constraintTop_toTopOf="parent"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintEnd_toEndOf="parent"
android:layout_width="@dimen/dp_103"
android:layout_height="@dimen/dp_84"
android:paddingBottom="@dimen/dp_20"
android:paddingTop="@dimen/dp_20" />
</merge>

View File

@@ -9,6 +9,7 @@ import android.view.View
import com.alibaba.android.arouter.launcher.ARouter
import com.mogo.commons.mvp.MvpFragment
import com.mogo.commons.voice.AIAssist
import com.mogo.eagle.core.data.map.MogoLatLng
import com.mogo.eagle.core.function.call.hmi.CallerHmiManager
import com.mogo.eagle.core.function.call.map.CallerMapUIServiceManager
import com.mogo.eagle.core.utilcode.mogo.logger.CallerLogger
@@ -18,6 +19,7 @@ import com.mogo.eagle.core.utilcode.util.UiThreadHandler
import com.mogo.map.listener.IMogoMapListener
import com.mogo.och.common.module.biz.provider.CommonService
import com.mogo.och.common.module.constant.OchCommonConst
import com.mogo.och.common.module.manager.autopilot.location.OchLocationManager
import com.mogo.och.common.module.manager.xiaozhi.ZhiStateManager
import com.mogo.och.common.module.utils.RxUtils
import com.mogo.och.common.module.voice.VoiceNotice
@@ -108,7 +110,8 @@ class TaxiPassengerBaseFragment() :
BottomBar.SelectView.PRECISIONMAP -> {
//切换到地图中间
mapBizView.getUI()?.let {
it.changeMapVisualAngle(it.getVrAngleDefaultMode(), null)
val wgs02Location = OchLocationManager.getWgs02Location()
it.moveToCenter(MogoLatLng(wgs02Location.latitude,wgs02Location.longitude))
}
}
BottomBar.SelectView.OVERMAPVIEW -> {
@@ -141,6 +144,7 @@ class TaxiPassengerBaseFragment() :
}
rbv_setting_music.setShowOnlySetting(0)
lbv_go2_center.visibility = View.VISIBLE
lbv_go2_center.showAngle()
pcnActionView.visibility = View.VISIBLE
CallerHmiManager.showTrafficLightView()
infoVideoView.visibility = View.GONE
@@ -154,7 +158,8 @@ class TaxiPassengerBaseFragment() :
romaPView.updateVisible(false)
romaDistanceView.visibility = View.GONE
rbv_setting_music.setShowOnlySetting(0)
lbv_go2_center.visibility = View.GONE
lbv_go2_center.visibility = View.VISIBLE
lbv_go2_center.showOnlyCenter()
pcnActionView.visibility = View.VISIBLE
CallerHmiManager.showTrafficLightView()
infoVideoView.visibility = View.GONE