]> git.r.bdr.sh - rbdr/heart/blobdiff - js/app.js
Remove unnecessary files
[rbdr/heart] / js / app.js
index 12065b2c704e38320730442fee0d41a611237eb8..63990dc1bbca0e80e7cabea851b2f39b35503a34 100644 (file)
--- a/js/app.js
+++ b/js/app.js
@@ -15,6 +15,8 @@
     heartRenderer.activate();
 
     window.addEventListener('resize', heartRenderer.resize.bind(heartRenderer));
+    window.addEventListener('blur', heartRenderer.stopFollowingMouse.bind(heartRenderer));
+    window.addEventListener('focus', heartRenderer.startFollowingMouse.bind(heartRenderer));
 
     /**
      * Exported global object. This will contain the instance of the heart