-
Notifications
You must be signed in to change notification settings - Fork 310
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Camera position different from the current location #50
Comments
yes you need to set |
But its not working with the initialcenter, idk why. Maybe by looking at my
code you can realize:
LocationResult result;
if (initialLat != 0 || initialLong != 0) {
result = await showLocationPicker(
context,
'key',
initialCenter: LatLng(initialLat, initialLong),
myLocationButtonEnabled: true,
automaticallyAnimateToCurrentLocation: false,
);
} else {
result = await showLocationPicker(
context, 'key',
myLocationButtonEnabled: true);
}
El dom., 1 mar. 2020 a las 8:59, Ibrahim Eid (<[email protected]>)
escribió:
… Closed #50
<#50>.
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#50?email_source=notifications&email_token=AGODYBKM4XPK66SVKZOM5CLRFJE27A5CNFSM4KZKAOHKYY3PNVWWK3TUL52HS4DFWZEXG43VMVCXMZLOORHG65DJMZUWGYLUNFXW5KTDN5WW2ZLOORPWSZGOW7URJDA#event-3085505676>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGODYBNIEDAGQP2AEVC6EGTRFJE27ANCNFSM4KZKAOHA>
.
|
could you try with the example app and if you can reproduce it there |
Thanks i'll try. Also we got a problem that everywhere that we put the pin,
its says unnamed place, do you know how could we fix it?
Thnks! Sorry for bothering.
El lun., 2 de mar. de 2020 18:38, Ibrahim Eid <[email protected]>
escribió:
… could you try with the example app and if you can reproduce it there
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub
<#50?email_source=notifications&email_token=AGODYBL66RSXRFGNKRIDQN3RFQRMDA5CNFSM4KZKAOHKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOENRCW7Q#issuecomment-593636222>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AGODYBP5S2ZAIYZLEKOCDILRFQRMDANCNFSM4KZKAOHA>
.
|
regarding the unnamed places please take a look at #16 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I am trying to edit an entity that has a pair of Latitude and Longitude, so i edit it through this widget. I want it to show in the map the old location and not my current location. I am setting the automaticallyAnimateToCurrentLocation: as false, but this centers the camera tu a remote island idkwhere. Is there a way to set the camera at a certain LatLng?
My code is the following:
Widget build(BuildContext context) {
return Center(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: [
RaisedButton(
onPressed: () async {
LocationResult result;
if (initialLat != 0 || initialLong != 0) {
result = await showLocationPicker(
context,
'AIzaSyD8_lvGEpZodiVIfNTBE5sOzgRfeVHpFe4',
initialCenter: LatLng(initialLat, initialLong),
myLocationButtonEnabled: true,
automaticallyAnimateToCurrentLocation: false,
);
} else {
result = await showLocationPicker(
context, 'AIzaSyD8_lvGEpZodiVIfNTBE5sOzgRfeVHpFe4',
myLocationButtonEnabled: true);
}
setState(() => _pickedLocation = result);
setLat(_pickedLocation.latLng.latitude);
setLong(_pickedLocation.latLng.longitude);
},
child: Text('Mark your location!'),
),
],
),
);
Thanks in advance!
The text was updated successfully, but these errors were encountered: