Closed foolip closed 4 years ago
http://w3c.github.io/geolocation-api/#dom-navigatorgeolocation-getcurrentposition says:
If the attempt is successful, the successCallback MUST be invoked (i.e. the handleEvent operation MUST be called on the callback object) with a new NavigatorGeolocationPosition object, reflecting the current location of the device.
However, the type definition of the callback is:
callback PositionCallback = void (NavigatorGeolocationPosition position);
This is a https://heycam.github.io/webidl/#idl-callback-functions. The spec wording has it confused with https://heycam.github.io/webidl/#dfn-callback-interface and in particular https://dom.spec.whatwg.org/#callbackdef-eventlistener.
https://heycam.github.io/webidl/#invoke-a-callback-function is the way to invoke callback functions, and https://dom.spec.whatwg.org/#notify-mutation-observers has an example of the phrasing.
http://w3c.github.io/geolocation-api/#dom-navigatorgeolocation-getcurrentposition says:
However, the type definition of the callback is:
This is a https://heycam.github.io/webidl/#idl-callback-functions. The spec wording has it confused with https://heycam.github.io/webidl/#dfn-callback-interface and in particular https://dom.spec.whatwg.org/#callbackdef-eventlistener.
https://heycam.github.io/webidl/#invoke-a-callback-function is the way to invoke callback functions, and https://dom.spec.whatwg.org/#notify-mutation-observers has an example of the phrasing.