Merge branch 'issue/35' into develop
diff --git a/weinre.doc/Home.body.html b/weinre.doc/Home.body.html
index 1660429..79c0896 100644
--- a/weinre.doc/Home.body.html
+++ b/weinre.doc/Home.body.html
@@ -97,32 +97,37 @@
 how to use it, visit the <a href="TestDrive.html">Test Drive</a>.
 
 <!-- ======================================================== -->
-<h2>Supported Platforms</h2>
+<h2>Supported Libraries and Platforms</h2>
+
+<p>Generally version numbers listed here are the earliest
+versions of the relevant thing that have been tested.
+Later versions of those things are also hopefully supported,
+but let us know.
+
+<h3>Libraries not supported</h3>
+
+<ul>
+<li>versions of Prototype.js before version 1.7 are not supported,
+as they do not support the <tt>JSON.stringify()</tt> API correctly.  You
+will get an <tt>alert()</tt> in the web page you are debugging if you
+attempt to debug it with weinre and you are using an unsupported
+version of Prototype.js.
+</ul>
 
 <h3>Debug client - the browser where the debugger user interface runs</h3>
 
 <ul>
 <li>weinre Mac application - Mac OS X 10.6 64-bit
-<li>Google Chrome 8.x beta
+<li>Google Chrome 8.x
 <li>Apple Safari 5.x 
-<li>others? please set us know
 </ul>
 
 <h3>Debug target - the browser with the page you are debugging</h3>
 
 <ul>
-<li>Android 2.3 Browser application
-<li>Android 2.3 w/PhoneGap 0.9.2
 <li>Android 2.2 Browser application
 <li>Android 2.2 w/PhoneGap 0.9.2
 <li>iOS 4.2.x Mobile Safari application
 <li>BlackBerry v6.x simulator
-<li>others? please set us know
-</ul>
-
-<h3>Platforms that do not work</h3>
-
-<ul>
-<li>others? please set us know
 </ul>
 
diff --git a/weinre.web/demo/weinre-demo-min.html b/weinre.web/demo/weinre-demo-min.html
index 3170577..9adcc3b 100644
--- a/weinre.web/demo/weinre-demo-min.html
+++ b/weinre.web/demo/weinre-demo-min.html
@@ -14,7 +14,6 @@
 
 <script type="text/javascript">
     require("weinre/common/Weinre").showNotImplemented()
-    require("weinre/target/Target").main()
 </script>
 
 <script src="weinre-demo.js"></script>
diff --git a/weinre.web/demo/weinre-demo-pieces.html b/weinre.web/demo/weinre-demo-pieces.html
index 2ef3573..fa4ca1a 100644
--- a/weinre.web/demo/weinre-demo-pieces.html
+++ b/weinre.web/demo/weinre-demo-pieces.html
@@ -26,6 +26,7 @@
 <script src="/weinre/common/IDGenerator.transportd.js"></script>
 <script src="/weinre/target/Console.transportd.js"></script>
 <script src="/add-css-properties.js"></script>
+<script src="/weinre/target/CheckForProblems.transportd.js"></script>
 <script src="/weinre/target/WiConsoleImpl.transportd.js"></script>
 <script src="/weinre/target/WiCSSImpl.transportd.js"></script>
 <script src="/weinre/target/WiDatabaseImpl.transportd.js"></script>
@@ -45,7 +46,6 @@
 
 <script type="text/javascript">
     require("weinre/common/Weinre").showNotImplemented()
-    require("weinre/target/Target").main()
 </script>
 
 <script src="weinre-demo.js"></script>
diff --git a/weinre.web/demo/weinre-demo.html b/weinre.web/demo/weinre-demo.html
index 9300102..ebdd2de 100644
--- a/weinre.web/demo/weinre-demo.html
+++ b/weinre.web/demo/weinre-demo.html
@@ -14,7 +14,6 @@
 
 <script type="text/javascript">
     require("weinre/common/Weinre").showNotImplemented()
-    require("weinre/target/Target").main()
 </script>
 
 <script src="weinre-demo.js"></script>
diff --git a/weinre.web/modules/weinre/target/CheckForProblems.scoop b/weinre.web/modules/weinre/target/CheckForProblems.scoop
new file mode 100644
index 0000000..dc25ab8
--- /dev/null
+++ b/weinre.web/modules/weinre/target/CheckForProblems.scoop
@@ -0,0 +1,28 @@
+
+/*
+ * weinre is available under *either* the terms of the modified BSD license *or* the
+ * MIT License (2008). See http://opensource.org/licenses/alphabetical for full text.
+ * 
+ * Copyright (c) 2010, 2011 IBM Corporation
+ */
+
+//-----------------------------------------------------------------------------
+class CheckForProblems
+
+//-----------------------------------------------------------------------------
+static method check
+    checkForOldPrototypeVersion()
+
+//-----------------------------------------------------------------------------
+function checkForOldPrototypeVersion
+    var badVersion = false
+
+    if (typeof Prototype == "undefined") return
+    if (!Prototype.Version) return
+    
+    if (Prototype.Version.match(/^1\.5.*/)) badVersion = true
+    if (Prototype.Version.match(/^1\.6.*/)) badVersion = true
+    
+    if (badVersion) {
+        alert("Sorry, weinre is not support in versions of Prototype earlier than 1.7")
+    }
\ No newline at end of file
diff --git a/weinre.web/modules/weinre/target/Target.scoop b/weinre.web/modules/weinre/target/Target.scoop
index 73d8c00..d51ce41 100644
--- a/weinre.web/modules/weinre/target/Target.scoop
+++ b/weinre.web/modules/weinre/target/Target.scoop
@@ -14,6 +14,7 @@
 requireClass ../common/MessageDispatcher
 requireClass ../common/Weinre
 
+requireClass ./CheckForProblems
 requireClass ./NodeStore
 requireClass ./CSSStore
 requireClass ./ElementHighlighter
@@ -34,6 +35,8 @@
 
 //-----------------------------------------------------------------------------
 static method main
+    CheckForProblems.check()
+    
     Weinre.target = new Target()
     Weinre.target.initialize()