增加了地图Marker自定义组合控件

This commit is contained in:
董宏宇
2020-01-06 19:58:30 +08:00
parent e6898c7919
commit abba443edc
4 changed files with 84 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
package com.mogo.module.service.marker;
import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.widget.LinearLayout;
import androidx.annotation.Nullable;
import com.mogo.module.service.R;
/**
* author : donghongyu
* e-mail : 1358506549@qq.com
* date : 2020-01-0619:55
* desc : 地图Marker图标带文本信息
* version: 1.0
*/
public class MapMarkerInfoView extends LinearLayout {
public MapMarkerInfoView(Context context) {
super(context);
initView(context);
}
public MapMarkerInfoView(Context context, @Nullable AttributeSet attrs) {
super(context, attrs);
initView(context);
}
public MapMarkerInfoView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
initView(context);
}
private void initView(Context context) {
LayoutInflater.from(context).inflate(R.layout.view_map_marker_info, this);
}
}

View File

@@ -0,0 +1,42 @@
package com.mogo.module.service.marker;
import android.content.Context;
import android.util.AttributeSet;
import android.view.LayoutInflater;
import android.widget.LinearLayout;
import androidx.annotation.Nullable;
import com.mogo.module.service.R;
/**
* author : donghongyu
* e-mail : 1358506549@qq.com
* date : 2020-01-0619:55
* desc : 地图Marker图标
* version: 1.0
*/
public class MapMarkerView extends LinearLayout {
public MapMarkerView(Context context) {
super(context);
initView(context);
}
public MapMarkerView(Context context, @Nullable AttributeSet attrs) {
super(context, attrs);
initView(context);
}
public MapMarkerView(Context context, @Nullable AttributeSet attrs, int defStyleAttr) {
super(context, attrs, defStyleAttr);
initView(context);
}
private void initView(Context context) {
LayoutInflater.from(context).inflate(R.layout.view_map_marker, this);
}
}