Fixing marker position text

This commit is contained in:
Brice Zele 2020-04-06 14:46:31 +01:00
parent 921f8b1a30
commit bed929ed63
2 changed files with 16 additions and 14 deletions

File diff suppressed because one or more lines are too long

View File

@ -475,7 +475,7 @@ class Home extends BaseScreen {
pitch: 0, pitch: 0,
heading: 0, heading: 0,
altitude: 5, altitude: 5,
zoom: 13 zoom: 12
}, 1000) }, 1000)
this.setState({ myPositionIsAnimated: true }) this.setState({ myPositionIsAnimated: true })
@ -542,7 +542,7 @@ class Home extends BaseScreen {
longitudeDelta: 0.01, longitudeDelta: 0.01,
} }
this.setState({ myPosition: myPosition }); this.setState({ myPosition: myPosition });
this.refocusMap(false); this.refocusMap(true);
} }
/*if (Platform.OS === 'android') { /*if (Platform.OS === 'android') {
@ -1417,17 +1417,19 @@ class Home extends BaseScreen {
latitude: parseFloat(user.latitude), latitude: parseFloat(user.latitude),
longitude: parseFloat(user.longitude) longitude: parseFloat(user.longitude)
} }
this.setState({ myPosition });
this.mapRef.animateCamera({ this.refocusMap(false);
center: { /*
latitude: myPosition.latitude, this.mapRef.animateCamera({
longitude: myPosition.longitude center: {
}, latitude: myPosition.latitude,
pitch: 0, longitude: myPosition.longitude
heading: 0, },
altitude: 5, pitch: 0,
zoom: 12 heading: 0,
}, 1000); altitude: 5,
zoom: 12
}, 1000); */
if (user.category) { if (user.category) {
this.setState({ loadingDialog: false }) this.setState({ loadingDialog: false })