Skip to content

Commit afb7b9b

Browse files
committed
nit
1 parent 2d3c4e7 commit afb7b9b

File tree

1 file changed

+2
-11
lines changed

1 file changed

+2
-11
lines changed

maps-googlemaps-sample/src/main/java/com/what3words/samples/googlemaps/compose/ui/overlaymap/ExistingMapWithDrawerScreen.kt

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,6 @@ import com.google.maps.android.compose.CameraPositionState
3737
import com.google.maps.android.compose.Circle
3838
import com.google.maps.android.compose.ComposeMapColorScheme
3939
import com.google.maps.android.compose.GoogleMap
40-
import com.google.maps.android.compose.MapEffect
4140
import com.google.maps.android.compose.MapProperties
4241
import com.google.maps.android.compose.MapType
4342
import com.google.maps.android.compose.MapUiSettings
@@ -52,7 +51,6 @@ import com.what3words.components.compose.maps.W3WMapDefaults
5251
import com.what3words.components.compose.maps.mapper.toGoogleLatLng
5352
import com.what3words.components.compose.maps.models.W3WMarkerColor
5453
import com.what3words.components.compose.maps.providers.googlemap.W3WGoogleMapDrawer
55-
import com.what3words.components.compose.maps.providers.googlemap.W3WGoogleMapProjection
5654
import com.what3words.components.compose.maps.providers.googlemap.updateCameraBound
5755
import com.what3words.components.compose.maps.rememberW3WMapManager
5856
import com.what3words.components.compose.maps.state.camera.W3WGoogleCameraState
@@ -72,7 +70,7 @@ import kotlinx.coroutines.flow.launchIn
7270
import kotlinx.coroutines.flow.onEach
7371
import kotlinx.coroutines.launch
7472

75-
private const val TAG = "GoogleMapWithW3WActivity"
73+
private const val TAG = "ExistingMapWithDrawerScreen"
7674

7775
val defaultCameraPosition = CameraPosition.fromLatLngZoom(london1Coordinate.toGoogleLatLng(), 11f)
7876

@@ -119,9 +117,7 @@ fun ExistingMapWithDrawerScreen(
119117
w3wGoogleCameraState?.cameraState = cameraPositionState
120118
onDispose { }
121119
}
122-
var mapProjection: W3WGoogleMapProjection? by remember {
123-
mutableStateOf(null)
124-
}
120+
125121
val w3wGoogleCameraState = mapState.cameraState as W3WGoogleCameraState
126122
var lastProcessedPosition by remember { mutableStateOf(cameraPositionState.position) }
127123

@@ -210,11 +206,6 @@ fun ExistingMapWithDrawerScreen(
210206
},
211207
content = {
212208
//region What3words map components setup
213-
//REQUIRED - needed to draw the 3x3m grid on the map
214-
MapEffect(Unit) { map ->
215-
mapProjection = W3WGoogleMapProjection(map.projection)
216-
}
217-
218209
//REQUIRED - needed to draw the 3x3m grid on the map
219210
W3WGoogleMapDrawer(
220211
state = mapState,

0 commit comments

Comments
 (0)