opt videoplayer and modify navi
This commit is contained in:
@@ -329,7 +329,6 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
|
||||
|
||||
@Override
|
||||
public void onStartNavi() { //开始导航
|
||||
Logger.d(TAG, "onStartNavi -------> ");
|
||||
initModelData();
|
||||
getNavigationData();
|
||||
}
|
||||
@@ -906,7 +905,7 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
|
||||
|
||||
|
||||
/**
|
||||
* 上报分享信息 TODO
|
||||
* 上报分享信息
|
||||
*/
|
||||
private void uploadShareInfo(String poiType, String poiImgUrl, String nickname, String headImgUrl) {
|
||||
double lat = TanluServiceHandler.getLocationClient().getLastKnowLocation().getLatitude();
|
||||
@@ -969,11 +968,16 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
|
||||
// }
|
||||
// });
|
||||
|
||||
|
||||
mTanluModelData.getNaviInformation(new NaviCallback() {
|
||||
@Override
|
||||
public void onSuccess(NaviResult data) {
|
||||
Log.d(TAG, "getNavigationData onSuccess ----->");
|
||||
List<Information> informationList = data.getResult().getInformations();
|
||||
Log.d(TAG, "getNavigationData onSuccess informationList =" + informationList);
|
||||
if (informationList == null || (informationList != null && informationList.size() == 0)) {
|
||||
return;
|
||||
}
|
||||
|
||||
//清除探路之前的数据
|
||||
mMarkerManager.removeMarkers(TanluConstants.MODEL_NAME);
|
||||
|
||||
@@ -999,7 +1003,6 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
|
||||
.longitude(informationList.get(i).lon);
|
||||
|
||||
optionList.add(options);
|
||||
Log.d(TAG, "lat =" + informationList.get(i).lat + ">>>lon =" + informationList.get(i).lon);
|
||||
}
|
||||
Logger.d(TAG, "getNavigationData optionList.size() = " + optionList.size());
|
||||
mMarkerManager.addMarkers(TanluConstants.MODEL_NAME, optionList, true);
|
||||
@@ -1117,6 +1120,11 @@ public class TanluCardViewFragment extends MvpFragment<IView, Presenter<IView>>
|
||||
speakSuccessVoice(o.getResult().getInformations(), discription == null ? "" : discription);
|
||||
|
||||
List<Information> informationList = o.getResult().getInformations();
|
||||
Log.d(TAG, "getVoiceControlRoadData onSuccess informationList =" + informationList);
|
||||
if (informationList == null || (informationList != null && informationList.size() == 0)) {
|
||||
return;
|
||||
}
|
||||
|
||||
//清除探路之前的数据
|
||||
mMarkerManager.removeMarkers(TanluConstants.MODEL_NAME);
|
||||
//添加埋点数据
|
||||
|
||||
@@ -8,10 +8,10 @@ import java.util.List;
|
||||
* @since 2020-02-03
|
||||
*/
|
||||
public class NaviRoadRequest {
|
||||
public List<Double> coordinates;
|
||||
public List<String> coordinates;
|
||||
public int limit;
|
||||
|
||||
public NaviRoadRequest(List<Double> coordinates, int limit) {
|
||||
public NaviRoadRequest(List<String> coordinates, int limit) {
|
||||
this.coordinates = coordinates;
|
||||
this.limit = limit;
|
||||
}
|
||||
|
||||
@@ -291,10 +291,22 @@ public class TanluModelData {
|
||||
*/
|
||||
public void getNaviInformation(final NaviCallback callback) {
|
||||
Gson gson = new Gson();
|
||||
double lng = 120.42;
|
||||
double lat = 36.19;
|
||||
|
||||
double lng2 = 120.66;
|
||||
double lat2 = 36.32;
|
||||
|
||||
List<String> coordinates = new ArrayList<>();
|
||||
coordinates.add(lng + "," + lat);
|
||||
coordinates.add(lng2 + "," + lat2);
|
||||
|
||||
NaviRoadRequest naviRoadRequest = new NaviRoadRequest(coordinates, 10);
|
||||
String naviStr = gson.toJson(naviRoadRequest);
|
||||
Log.d(TAG, "getNaviInformation naviStr = " + naviStr);
|
||||
final Map<String, Object> params = new ParamsProvider.Builder(mContext)
|
||||
.append("sn", Utils.getSn())
|
||||
// .append("data", uploadShareStr)
|
||||
.append("data", naviStr)
|
||||
.build();
|
||||
|
||||
mTanluApiService.getNaviInformation(params)
|
||||
|
||||
@@ -2,6 +2,7 @@ package com.mogo.module.tanlu.video
|
||||
|
||||
import android.content.Context
|
||||
import android.util.AttributeSet
|
||||
import android.util.Log
|
||||
import android.view.Surface
|
||||
import android.view.View
|
||||
import android.widget.ImageView
|
||||
@@ -77,6 +78,33 @@ class SimpleCoverVideoPlayer : StandardGSYVideoPlayer {
|
||||
override fun changeUiToCompleteShow() {
|
||||
super.changeUiToCompleteShow()
|
||||
// setViewShowState(mBottomContainer, View.INVISIBLE)
|
||||
Log.d("liyz", "changeUiToCompleteShow ------------>")
|
||||
}
|
||||
|
||||
override fun hideAllWidget() {
|
||||
super.hideAllWidget()
|
||||
Log.d("liyz", "hideAllWidget ------------>")
|
||||
mBottomContainer.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
override fun changeUiToPrepareingClear() {
|
||||
super.changeUiToPrepareingClear()
|
||||
mBottomContainer.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
override fun changeUiToPlayingBufferingClear() {
|
||||
super.changeUiToPlayingBufferingClear()
|
||||
mBottomContainer.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
override fun changeUiToClear() {
|
||||
super.changeUiToClear()
|
||||
mBottomContainer.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
override fun changeUiToCompleteClear() {
|
||||
super.changeUiToCompleteClear()
|
||||
mBottomContainer.visibility = View.INVISIBLE
|
||||
}
|
||||
|
||||
override fun onAutoCompletion() {
|
||||
|
||||
@@ -14,7 +14,7 @@
|
||||
<dimen name="tanlu_module_full_loading_height">96px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_height">90px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_width">700px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">10px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">5px</dimen>
|
||||
|
||||
<dimen name="tanlu_module_full_top_height">72px</dimen>
|
||||
<dimen name="tanlu_module_full_back_width">25px</dimen>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<dimen name="tanlu_module_full_loading_height">96px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_height">100px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_width">700px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">10px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">5px</dimen>
|
||||
|
||||
<dimen name="tanlu_module_full_top_height">135px</dimen>
|
||||
<dimen name="tanlu_module_full_back_width">50px</dimen>
|
||||
|
||||
@@ -15,7 +15,7 @@
|
||||
<dimen name="tanlu_module_full_loading_height">96px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_height">144px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_width">760px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">10px</dimen>
|
||||
<dimen name="tanlu_module_full_bottom_margin">5px</dimen>
|
||||
|
||||
<dimen name="tanlu_module_full_top_height">135px</dimen>
|
||||
<dimen name="tanlu_module_full_back_width">50px</dimen>
|
||||
|
||||
Reference in New Issue
Block a user