@@ -130,6 +130,7 @@ public class NearbyMapFragment extends DaggerFragment {
130
130
131
131
private boolean isMapReady ;
132
132
public boolean searchThisAreaModeOn = false ;
133
+ public boolean checkingAround = false ;
133
134
134
135
private Bundle bundleForUpdtes ;// Carry information from activity about changed nearby places and current location
135
136
private boolean searchedAroundCurrentLocation = true ;
@@ -556,6 +557,7 @@ public void onCameraMove() {
556
557
, NearbyController .currentLocation .getLongitude ()));
557
558
558
559
if (distance > NearbyController .searchedRadius *1000 *3 /4 ) { //Convert to meter, and compare if our distance is bigger than 3/4 or our searched area
560
+ checkingAround = true ;
559
561
if (!searchThisAreaModeOn ) { // If we are changing mode, then change click action
560
562
searchThisAreaModeOn = true ;
561
563
searchThisAreaButton .setOnClickListener (new View .OnClickListener () {
@@ -575,6 +577,7 @@ public void onClick(View view) {
575
577
}
576
578
577
579
} else {
580
+ checkingAround = false ;
578
581
if (searchThisAreaModeOn ) {
579
582
searchThisAreaModeOn = false ; // This flag will help us to understand should we folor users location or not
580
583
searchThisAreaButton .setOnClickListener (new View .OnClickListener () {
@@ -1002,6 +1005,12 @@ public void onResume() {
1002
1005
if (mapView != null ) {
1003
1006
mapView .onResume ();
1004
1007
}
1008
+ if (mapboxMap != null ) {
1009
+ mapboxMap .getUiSettings ().setAllGesturesEnabled (true );
1010
+ }
1011
+ searchThisAreaModeOn = false ;
1012
+ checkingAround = false ;
1013
+ searchedAroundCurrentLocation = true ;
1005
1014
initViews ();
1006
1015
setListeners ();
1007
1016
transparentView .setClickable (false );
0 commit comments