revoking permission after granting permission

Hi

The geolocation spec says

"For both getCurrentPosition and watchPosition ... If the user denies  
permission, the errorCallback (if present) must be invoked with code  
PERMISSION_DENIED, irrespective of any other errors encountered in the  
above steps."

So if the user first grants permission, but then later denies permission,  
the spec requires the error callback to be invoked, for both  
getCurrentPosition and watchPosition. It doesn't say anything about  
stopping watchPosition if permission is denied after it having been  
granted.

I think getCurrentPosition should only invoke at most one callback, either  
success or error.

I think watchPosition should be aborted if the user revokes permission,  
and should invoke the error callback with PERMISSION_DENIED in that case.

-- 
Simon Pieters
Opera Software

Received on Monday, 7 November 2011 09:40:44 UTC