Skip to content

Commit

Permalink
debuginfo: error when websocket isn't supported
Browse files Browse the repository at this point in the history
  • Loading branch information
kevinmehall committed Mar 13, 2012
1 parent 960cef5 commit 88aacb9
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 1 deletion.
8 changes: 7 additions & 1 deletion debuginfo.coffee
Expand Up @@ -15,6 +15,7 @@ app.init = (server, params) ->
<h1>Nonolith Connect not found</h1>
<p>Make sure it is running or
<a href='http://apps.nonolithlabs.cee/start'>Install it</a></p>
<p>Platform: #{window.navigator.userAgent}</p>
")

server.connected.listen app.update
Expand Down Expand Up @@ -59,6 +60,11 @@ app.update = ->
$("<h2>").text("No devices found").appendTo(e)


$(document).ready ->
$(document).ready ->
$(document.body).append("<p>Platform: #{window.navigator.userAgent}</p>");
if not window.WebSocket
$(document.body).append("<p>Your browser does not support webSocket</p>")
else
$(document.body).append("<p>Loading....</p>")
app.init(server)

3 changes: 3 additions & 0 deletions debuginfo.html
Expand Up @@ -10,6 +10,9 @@
<script src='lib/jquery-1.7.1.min.js'></script>
<script src='dataserver.coffee' type='text/coffeescript'></script>
<script src='debuginfo.coffee' type='text/coffeescript'></script>
</head>

<body>
Loading...
</body>
</html>

0 comments on commit 88aacb9

Please sign in to comment.