summaryrefslogtreecommitdiffstats
path: root/chrome/test
diff options
context:
space:
mode:
Diffstat (limited to 'chrome/test')
-rwxr-xr-xchrome/test/data/geolocation/iframes_different_origin.html22
-rw-r--r--chrome/test/data/geolocation/simple.html4
2 files changed, 24 insertions, 2 deletions
diff --git a/chrome/test/data/geolocation/iframes_different_origin.html b/chrome/test/data/geolocation/iframes_different_origin.html
new file mode 100755
index 0000000..a2607f6
--- /dev/null
+++ b/chrome/test/data/geolocation/iframes_different_origin.html
@@ -0,0 +1,22 @@
+<html>
+<script>
+var iframe_id = 0;
+function addIFrame(url) {
+ var iframe = document.createElement('iframe');
+ iframe.src = url;
+ iframe.id = 'iframe_' + (iframe_id++);
+ document.body.appendChild(iframe);
+}
+
+function addIFrames() {
+ port = location.port;
+ path = location.pathname.substring(0, location.pathname.lastIndexOf('/'));
+ addIFrame('http://localhost:' + port + path + '/simple.html');
+ addIFrame('http://127.0.0.1:' + port + path + '/simple.html');
+ return "1";
+}
+</script>
+<body>
+Testing Geolocation with iframes.
+</body>
+</html>
diff --git a/chrome/test/data/geolocation/simple.html b/chrome/test/data/geolocation/simple.html
index 0e0e5d7..a5d7848 100644
--- a/chrome/test/data/geolocation/simple.html
+++ b/chrome/test/data/geolocation/simple.html
@@ -30,8 +30,8 @@
function geoGetLastError() {
return "" + (last_error ? last_error.code : 0);
}
- function geoDisableAlerts() {
- display_alert = false;
+ function geoEnableAlerts(enabled) {
+ display_alert = enabled;
return "" + display_alert;
}
</script>