-
Notifications
You must be signed in to change notification settings - Fork 2.2k
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
Add HTML5 navigator.geolocation options as input to the Geolocate control #3473
Labels
Comments
@andreipopovici thank you for submitting your issue! we would happily consider a pull request implementing this feature. |
hey @andreipopovici I like this idea, are you planning on implementing this as a pull request? If you are great, but if not I'll give this a go. I just don't want to step on your toes if you're working on it. |
Hi there,
By all means, have at it! :D I did not have time to clean the code I used for my needs, and it would take more to go back through it than for someone knowledgeable to replicate the (small) effort.
On Sat, Dec 3, 2016 at 12:24 PM, Andrew Harvey <[email protected]> wrote:
hey @andreipopovici [https://github.com/andreipopovici] I like this idea, are you planning on implementing this as a pull request? If you are great, but if not I'll give this a go. I just don't want to step on your toes if you're working on it.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub [#3473 (comment)] , or mute the thread [https://github.com/notifications/unsubscribe-auth/ABFyefhoj15yA10xJNVdpkAPLwY_PWS2ks5rEUNigaJpZM4KiZJ3] .
|
andrewharvey
added a commit
to andrewharvey/mapbox-gl-js
that referenced
this issue
Dec 5, 2016
5 tasks
lucaswoj
pushed a commit
that referenced
this issue
Dec 6, 2016
* add Geolocation PositionOptions as option to Geolocate Control (#3473) * add option to watchPosition to Geolocate Control
This issue should be closed by #3739 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Motivation
For mobile uses of Mapbox GL, developers would appreciate the enableHighAccuracy option to enable the device's GPS.
Design Alternatives
In https://github.com/mapbox/mapbox-gl-js/blob/master/js/ui/control/geolocate_control.js#L8, the options to be passed to
navigator.geolocation.getCurrentPosition()
are hard-coded.This object could be made a property of the
options
object passed to the Geolocate control before adding it to the map UI.Design
Advantage: finer-grained control for advanced use, with sensible (i.e. current) defaults.
Implementation
The text was updated successfully, but these errors were encountered: