Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(307)

Side by Side Diff: third_party/WebKit/LayoutTests/geolocation-api/resources/cached-position-iframe-inner.html

Issue 2671933003: Move Geolocation out from fast/dom. (Closed)
Patch Set: . Created 3 years, 10 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <html> 1 <html>
2 <body> 2 <body>
3 <script> 3 <script>
4 function successCallback(position) { 4 function successCallback(position) {
5 var message = { 5 var message = {
6 'success': true, 6 'success': true,
7 'message': 'Received cached position lat: ' + position.coords.latitu de + ', long: ' + position.coords.longitude 7 'message': 'Received cached position lat: ' + position.coords.latitu de + ', long: ' + position.coords.longitude
8 }; 8 };
9 parent.postMessage(message, '*'); 9 parent.postMessage(message, '*');
10 } 10 }
11 11
12 function errorCallback(error) { 12 function errorCallback(error) {
13 var message = { 13 var message = {
14 'success': false, 14 'success': false,
15 'message': 'Failed to get position.' 15 'message': 'Failed to get position.'
16 } 16 }
17 parent.postMessage(message, '*'); 17 parent.postMessage(message, '*');
18 } 18 }
19 19
20 navigator.geolocation.getCurrentPosition( 20 navigator.geolocation.getCurrentPosition(
21 successCallback, 21 successCallback,
22 errorCallback, 22 errorCallback,
23 { maximumAge:600000, timeout:0 }); 23 { maximumAge:600000, timeout:0 });
24 </script> 24 </script>
25 </body> 25 </body>
26 </html> 26 </html>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698