I'd like to be able to save the current location to the fenix 3 location list from inside my widget and looking through the API documentation I see the Toybox::PersistedLocations module which has a persistLocation function described as follows:
- (Object) persistLocation(location, options)
Save a location to the device's location list
Parameters:
location (Location) — Location object to persist
options (Dictionary) — Dictionary of options, or null to accept defaults
:name (Hash) — a customizable set of options
I'd be interested to know what is the correct syntax when calling this function? I'm thinking to call this as below from my view but not clear what options I can pass and how can I add a location name when saving the location?
[FONT=Courier New]var location_variable = info.position;
PesistedLocations.persistLocation(location_variable, ???);[/FONT]
Thanks very much!