Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Add favicon switching for success/fail state

  • Loading branch information...
commit 1c2ac525086e696bcc43b2da128971f61eb69f7e 1 parent 70c7665
Isaac Wolkerstorfer authored
BIN  public/images/green.png
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
BIN  public/images/red.png
View
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
9 public/javascripts/client.js
View
@@ -34,6 +34,15 @@ $('.rerun').live('click', function() {
function update_active() {
+ var statusmark = ''
+ for (var path in projects) {
+ if (projects[path] && projects[path].status && projects[path].status == 'err')
+ statusmark = ''
+ }
+
+ $('#favicon').attr('href', '/images/' + (statusmark == '' ? 'green' : 'red') + '.png')
+ document.title = statusmark + ' nosey'
+
if (!active || !active.id || !projects[active.id]) return
var project = projects[active.id]
1  views/layout.jade
View
@@ -6,5 +6,6 @@ html(lang="en")
script(type="text/javascript", src="/javascripts/jquery.js")
script(type="text/javascript", src="/javascripts/client.js")
link(rel="stylesheet", href="/stylesheets/style.css")
+ link#favicon(rel="icon", type="image/x-icon")
body
#main!= body
Please sign in to comment.
Something went wrong with that request. Please try again.