rc
This commit is contained in:
2
.idea/misc.xml
generated
2
.idea/misc.xml
generated
@@ -5,7 +5,7 @@
|
||||
<configuration PROFILE_NAME="Debug" CONFIG_NAME="Debug" />
|
||||
</configurations>
|
||||
</component>
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="JDK" project-jdk-type="JavaSDK">
|
||||
<component name="ProjectRootManager" version="2" languageLevel="JDK_1_8" project-jdk-name="1.8" project-jdk-type="JavaSDK">
|
||||
<output url="file://$PROJECT_DIR$/build/classes" />
|
||||
</component>
|
||||
<component name="ProjectType">
|
||||
|
||||
@@ -24,7 +24,6 @@ import com.mogo.service.connection.IMogoOnMessageListener;
|
||||
import com.mogo.service.connection.IMogoSocketManager;
|
||||
import com.mogo.service.imageloader.IMogoImageloader;
|
||||
import com.mogo.service.map.IMogoMapService;
|
||||
import com.mogo.utils.TipToast;
|
||||
import com.mogo.utils.logger.Logger;
|
||||
|
||||
import java.util.List;
|
||||
@@ -106,6 +105,8 @@ public class MarkerServiceHandler {
|
||||
}
|
||||
|
||||
|
||||
private static IMogoMarker lastMarker;
|
||||
|
||||
/**
|
||||
* 地图上的Marker点击回调
|
||||
*/
|
||||
@@ -113,8 +114,40 @@ public class MarkerServiceHandler {
|
||||
|
||||
@Override
|
||||
public boolean onMarkerClicked(IMogoMarker marker) {
|
||||
TipToast.shortTip("点击了大而全中的Marker");
|
||||
Logger.e(TAG, "点击了大而全中的Marker");
|
||||
if (lastMarker != null) {
|
||||
MapMarkerView mapMarkerView = new MapMarkerView(mContext);
|
||||
|
||||
MogoMarkerOptions options = new MogoMarkerOptions()
|
||||
.icon(mapMarkerView)
|
||||
.owner(lastMarker.getOwner())
|
||||
.latitude(lastMarker.getPosition().getLat())
|
||||
.longitude(lastMarker.getPosition().getLng());
|
||||
|
||||
IMogoMarker newMarker = getMarkerManager().addMarker(lastMarker.getOwner(), options);
|
||||
newMarker.setInfoWindowAdapter(markerInfoWindowAdapter);
|
||||
newMarker.setOnMarkerClickListener(mogoMarkerClickListener);
|
||||
newMarker.setObject(lastMarker.getObject());
|
||||
|
||||
lastMarker.destroy();
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
MapMarkerInfoView mapMarkerInfoView = new MapMarkerInfoView(mContext);
|
||||
MogoMarkerOptions options = new MogoMarkerOptions()
|
||||
.icon(mapMarkerInfoView)
|
||||
.owner(marker.getOwner())
|
||||
.latitude(marker.getPosition().getLat())
|
||||
.longitude(marker.getPosition().getLng());
|
||||
|
||||
IMogoMarker newMarker = getMarkerManager().addMarker(marker.getOwner(), options);
|
||||
newMarker.setInfoWindowAdapter(markerInfoWindowAdapter);
|
||||
newMarker.setOnMarkerClickListener(mogoMarkerClickListener);
|
||||
newMarker.setObject(marker.getObject());
|
||||
|
||||
lastMarker = newMarker;
|
||||
marker.destroy();
|
||||
return false;
|
||||
}
|
||||
}
|
||||
@@ -176,7 +209,7 @@ public class MarkerServiceHandler {
|
||||
}
|
||||
|
||||
}
|
||||
getMapUIController().changeZoom(10);
|
||||
getMapUIController().changeZoom(8);
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -191,32 +224,13 @@ public class MarkerServiceHandler {
|
||||
Object bindObject,
|
||||
MarkerLocation markerLocation) {
|
||||
Logger.e(TAG, "绘制Marker====markerTag:" + markerTag);
|
||||
|
||||
MapMarkerView mapMarkerView = new MapMarkerView(mContext);
|
||||
MapMarkerInfoView mapMarkerInfoView = new MapMarkerInfoView(mContext);
|
||||
|
||||
MogoMarkerOptions options = new MogoMarkerOptions()
|
||||
.owner(markerTag)
|
||||
.latitude(markerLocation.getLat())
|
||||
.longitude(markerLocation.getLon());
|
||||
|
||||
switch (markerTag) {
|
||||
case ServiceConst.CARD_TYPE_CARS_CHATTING:
|
||||
options.icon(mapMarkerView);
|
||||
break;
|
||||
case ServiceConst.CARD_TYPE_ROAD_CODITION:
|
||||
options.icon(mapMarkerView);
|
||||
break;
|
||||
case ServiceConst.CARD_TYPE_SHARE_MUSIC:
|
||||
options.icon(mapMarkerView);
|
||||
break;
|
||||
case ServiceConst.CARD_TYPE_USER_DATA:
|
||||
options.icon(mapMarkerInfoView);
|
||||
break;
|
||||
default:
|
||||
options.icon(mapMarkerView);
|
||||
break;
|
||||
}
|
||||
options.icon(mapMarkerView);
|
||||
|
||||
IMogoMarker marker = getMarkerManager().addMarker(markerTag, options);
|
||||
marker.setInfoWindowAdapter(markerInfoWindowAdapter);
|
||||
@@ -241,6 +255,6 @@ public class MarkerServiceHandler {
|
||||
marker.setOnMarkerClickListener(mogoMarkerClickListener);
|
||||
marker.setObject("我是Marker上面绑定的数据");
|
||||
|
||||
getMapUIController().changeZoom(10);
|
||||
getMapUIController().changeZoom(8);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -7,31 +7,46 @@
|
||||
android:orientation="vertical"
|
||||
tools:parentTag="androidx.constraintlayout.widget.ConstraintLayout" >
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivCar"
|
||||
android:layout_width="@dimen/dp_34"
|
||||
android:layout_height="@dimen/dp_64"
|
||||
android:rotation="270"
|
||||
android:src="@drawable/icon_map_marker_car_blue"
|
||||
android:translationY="-5dp"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ivBg"
|
||||
app:layout_constraintStart_toStartOf="@+id/ivBg"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivBg" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivBg"
|
||||
android:layout_width="@dimen/dp_88"
|
||||
android:layout_height="@dimen/dp_105"
|
||||
android:layout_width="@dimen/dp_68"
|
||||
android:layout_height="@dimen/dp_85"
|
||||
android:layout_gravity="center"
|
||||
android:src="@drawable/bg_map_marker_blue"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
<ImageView
|
||||
<com.mogo.service.imageloader.MogoImageView
|
||||
android:id="@+id/ivIcon"
|
||||
android:layout_width="@dimen/dp_76"
|
||||
android:layout_height="@dimen/dp_76"
|
||||
android:layout_width="@dimen/dp_56"
|
||||
android:layout_height="@dimen/dp_56"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="@dimen/dp_6"
|
||||
android:src="@drawable/icon_default"
|
||||
android:background="@drawable/icon_default"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
app:miv_failureHolder="@drawable/icon_default"
|
||||
app:miv_overlayImageId="@drawable/icon_default"
|
||||
app:miv_placeHolder="@drawable/icon_default"
|
||||
app:miv_shape="circle" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivIconForeground"
|
||||
android:layout_width="@dimen/dp_76"
|
||||
android:layout_height="@dimen/dp_76"
|
||||
android:layout_width="@dimen/dp_56"
|
||||
android:layout_height="@dimen/dp_56"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="@dimen/dp_6"
|
||||
android:src="@drawable/icon_map_marker_music_play"
|
||||
@@ -39,14 +54,4 @@
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent" />
|
||||
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivCar"
|
||||
android:layout_width="@dimen/dp_34"
|
||||
android:layout_height="@dimen/dp_64"
|
||||
android:rotation="270"
|
||||
android:src="@drawable/icon_map_marker_car_blue"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ivBg"
|
||||
app:layout_constraintStart_toStartOf="@+id/ivBg"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivBg" />
|
||||
</merge >
|
||||
@@ -8,10 +8,21 @@
|
||||
android:orientation="horizontal"
|
||||
tools:parentTag="androidx.constraintlayout.widget.ConstraintLayout" >
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivCar"
|
||||
android:layout_width="@dimen/dp_34"
|
||||
android:layout_height="@dimen/dp_64"
|
||||
android:rotation="270"
|
||||
android:src="@drawable/icon_map_marker_car_blue"
|
||||
android:translationY="-5dp"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ivReverseTriangle"
|
||||
app:layout_constraintStart_toStartOf="@+id/ivReverseTriangle"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivReverseTriangle" />
|
||||
|
||||
<androidx.constraintlayout.widget.ConstraintLayout
|
||||
android:id="@+id/llMarkerContent"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="@dimen/dp_94"
|
||||
android:layout_height="@dimen/dp_74"
|
||||
android:background="@drawable/bg_map_marker_blue_info"
|
||||
app:layout_constraintEnd_toEndOf="parent"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
@@ -19,8 +30,8 @@
|
||||
|
||||
<com.mogo.service.imageloader.MogoImageView
|
||||
android:id="@+id/ivUserHead"
|
||||
android:layout_width="@dimen/dp_80"
|
||||
android:layout_height="@dimen/dp_80"
|
||||
android:layout_width="@dimen/dp_60"
|
||||
android:layout_height="@dimen/dp_60"
|
||||
android:background="@drawable/icon_default"
|
||||
app:layout_constraintStart_toStartOf="parent"
|
||||
app:layout_constraintTop_toTopOf="parent"
|
||||
@@ -29,6 +40,16 @@
|
||||
app:miv_placeHolder="@drawable/icon_default"
|
||||
app:miv_shape="circle" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivIconForeground"
|
||||
android:layout_width="@dimen/dp_56"
|
||||
android:layout_height="@dimen/dp_56"
|
||||
android:layout_gravity="center"
|
||||
android:layout_marginTop="@dimen/dp_6"
|
||||
android:src="@drawable/icon_map_marker_music_play"
|
||||
app:layout_constraintStart_toStartOf="@+id/ivUserHead"
|
||||
app:layout_constraintTop_toTopOf="@+id/ivUserHead" />
|
||||
|
||||
<TextView
|
||||
android:id="@+id/tvMarkerContent"
|
||||
android:layout_width="wrap_content"
|
||||
@@ -54,13 +75,4 @@
|
||||
app:layout_constraintStart_toStartOf="@+id/llMarkerContent"
|
||||
app:layout_constraintTop_toBottomOf="@+id/llMarkerContent" />
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/ivCar"
|
||||
android:layout_width="@dimen/dp_34"
|
||||
android:layout_height="@dimen/dp_64"
|
||||
android:rotation="270"
|
||||
android:src="@drawable/icon_map_marker_car_blue"
|
||||
app:layout_constraintEnd_toEndOf="@+id/ivReverseTriangle"
|
||||
app:layout_constraintStart_toStartOf="@+id/ivReverseTriangle"
|
||||
app:layout_constraintTop_toBottomOf="@+id/ivReverseTriangle" />
|
||||
</merge >
|
||||
@@ -69,7 +69,6 @@ public class MogoStatusManager implements IMogoStatusManager {
|
||||
return get_bool_val( StatusDescriptor.USER_INTERACTED );
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public boolean isSearchUIShow() {
|
||||
return get_bool_val( StatusDescriptor.SEARCH_UI );
|
||||
|
||||
Reference in New Issue
Block a user