Skip to content

Commit

Permalink
修改绘制点击事件为onSingleTapConfirmed
Browse files Browse the repository at this point in the history
  • Loading branch information
roomanl committed Dec 20, 2021
1 parent 577e9df commit 73a81f6
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -35,19 +35,19 @@ public ArcgisToolManager(Context context,MapView mMapView) {
this.context=context;
listener=new DefaultMapViewOnTouchListener(context,mMapView){
@Override
public boolean onSingleTapUp(MotionEvent e) {
public boolean onSingleTapConfirmed(MotionEvent e) {
if(measureToolManager!=null){
measureToolManager.onMapSingleTapUp(e);
measureToolManager.onSingleTapConfirmed(e);
}

if(drawGraphManager!=null){
drawGraphManager.onMapSingleTapUp(e);
drawGraphManager.onSingleTapConfirmed(e);
}
if(mapListener!=null){
super.onSingleTapUp(e);
return mapListener.onSingleTapUp(e);
super.onSingleTapConfirmed(e);
return mapListener.onSingleTapConfirmed(e);
}
return super.onSingleTapUp(e);
return super.onSingleTapConfirmed(e);
}

@Override
Expand Down Expand Up @@ -165,12 +165,12 @@ public boolean onScaleBegin(ScaleGestureDetector detector) {
}

@Override
public boolean onSingleTapConfirmed(MotionEvent e) {
public boolean onSingleTapUp(MotionEvent e) {
if(mapListener!=null) {
super.onSingleTapConfirmed(e);
return mapListener.onSingleTapConfirmed(e);
super.onSingleTapUp(e);
return mapListener.onSingleTapUp(e);
}
return super.onSingleTapConfirmed(e);
return super.onSingleTapUp(e);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public DrawGraphManager(DrawGraphView drawGraphView, MapView mMapView) {
drawGraphView.init(mMapView);
}

public void onMapSingleTapUp(MotionEvent e){
drawGraphView.onMapSingleTapUp(e);
public void onSingleTapConfirmed(MotionEvent e){
drawGraphView.onSingleTapConfirmed(e);
}
public void onScroll(MotionEvent e1,MotionEvent e2,float distanceX, float distanceY){
drawGraphView.onScroll(e1,e2,distanceX,distanceY);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,8 @@ public MeasureToolManager(MeasureToolView measureToolView,MapView mMapView) {
measureToolView.init(mMapView);
}

public void onMapSingleTapUp(MotionEvent e){
measureToolView.onMapSingleTapUp(e);
public void onSingleTapConfirmed(MotionEvent e){
measureToolView.onSingleTapConfirmed(e);
}
public MeasureToolManager setMeasureClickListener(MeasureClickListener measureClickListener) {
measureToolView.setMeasureClickListener(measureClickListener);
Expand Down

0 comments on commit 73a81f6

Please sign in to comment.