location_monitor_start


Description:

public async bool location_monitor_start (Parent? parent, uint distance_threshold, uint time_threshold, LocationAccuracy accuracy, LocationMonitorFlags flags, Cancellable? cancellable) throws Error

Makes `XdpPortal` start monitoring location changes.

When the location changes, the [signal@Portal:XdpPortal:location-updated]. signal is emitted.

Use [method@Portal.location_monitor_stop] to stop monitoring.

Note that [class@Portal] only maintains a single location monitor at a time. If you want to change the distance_threshold, time_threshold or accuracy of the current monitor, you first have to call [method@Portal.location_monitor_stop] to stop monitoring.

Parameters:

this

a [class@Portal]

parent

a [struct@Parent], or `NULL`

distance_threshold

distance threshold, in meters

time_threshold

time threshold, in seconds

accuracy

desired accuracy

flags

options for this call

cancellable

optional [class@Gio.Cancellable]

callback

a callback to call when the request is done

data

data to pass to callback