function test1() {
send404_geolocationProvider(test2);
}
function errorCallback(error) {
// GeolocationPositionError has no interface object, so we can't get constants off that.
is(error.code, error.POSITION_UNAVAILABLE, "Geolocation error handler fired");
is(error.POSITION_UNAVAILABLE, 2, "Value of POSITION_UNAVAILABLE should be correct");
SimpleTest.finish();
}
function successCallback(position) {
test2();
}
function test2() {
navigator.geolocation.getCurrentPosition(successCallback, errorCallback);
}
</script>
</pre>
</body>
</html>
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.