From 5bbfc85c0c79f11d3f83a65ef969b241b98f0ca3 Mon Sep 17 00:00:00 2001 From: anonfagola Date: Wed, 24 Sep 2014 18:23:15 -0700 Subject: [PATCH 1/3] Added icon changing when thread updated. makeIcon should also have the little *bleep* sound. --- js/auto-reload.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/js/auto-reload.js b/js/auto-reload.js index 548d947e..633e1673 100644 --- a/js/auto-reload.js +++ b/js/auto-reload.js @@ -16,8 +16,16 @@ * */ + +au = false; auto_reload_enabled = true; // for watch.js to interop +function makeIcon(){ + if(au) return; + au = true; + $("link[rel='icon']").attr("href", "favicon_au.png"); +} + $(document).ready(function(){ if($('div.banner').length == 0) return; // not index @@ -98,6 +106,7 @@ $(document).ready(function(){ if($('#' + id).length == 0) { if (!new_posts) { first_new_post = this; + makeIcon(); } $(this).insertAfter($('div.post:last').next()).after('
'); new_posts++; From 170b498121886c2637cfab63b58bbe92b2f681d0 Mon Sep 17 00:00:00 2001 From: anonfagola Date: Wed, 24 Sep 2014 18:26:21 -0700 Subject: [PATCH 2/3] Added favicon for auto updating. --- static/favicon_au.png | Bin 0 -> 337 bytes 1 file changed, 0 insertions(+), 0 deletions(-) create mode 100644 static/favicon_au.png diff --git a/static/favicon_au.png b/static/favicon_au.png new file mode 100644 index 0000000000000000000000000000000000000000..44baded7115e2731c8c45a11aeb1c63a2baefd2f GIT binary patch literal 337 zcmeAS@N?(olHy`uVBq!ia0vp^0wB!61|;P_|4#%`jKx9jP7LeL$-D$|SkfJR9T^xl z_H+M9WCij$3p^r=85sBugD~Uq{1qucL8%hgh?3y^w370~qEv=}#LT=BJwMkFg)(D3 zQ$0figD*u3fvOI8x;Tbd_%EICTJVs9KuhpinLgbBwurX5M;5R?eEX5ZfJgaPviif@ zsqZJ9mH0fpt-#fJ$0D&Ge*;54cV1`FdndYS)`KJ3jJdT6&zaA4%})uQ;9ADtRaGaO)?L&)RJtV>KOCuL)~aNNQ`Er|kXBf?MDfcalck zwG+Z>tPOX?iXuB~rMy?`G>D1XGC*&f+-p*y!i~!l%R(C;QT?R+ENz47y aIr4udJ{SFB!ukg27Y0vPKbLh*2~7ZY*nbrO literal 0 HcmV?d00001 From 25bf9f88f5caaa05d839cc85d3a2306eb1b1111e Mon Sep 17 00:00:00 2001 From: anonfagola Date: Wed, 24 Sep 2014 18:27:17 -0700 Subject: [PATCH 3/3] Update auto-reload.js Changed favicon_au.png to static/favicon_au.png --- js/auto-reload.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/auto-reload.js b/js/auto-reload.js index 633e1673..bfb54d6e 100644 --- a/js/auto-reload.js +++ b/js/auto-reload.js @@ -23,7 +23,7 @@ auto_reload_enabled = true; // for watch.js to interop function makeIcon(){ if(au) return; au = true; - $("link[rel='icon']").attr("href", "favicon_au.png"); + $("link[rel='icon']").attr("href", "../static/favicon_au.png"); } $(document).ready(function(){