From 8d6d10dbfb41eabb3e1f31e119649ae99487a52d Mon Sep 17 00:00:00 2001
From: Vincent Nivoliers <vincent.nivoliers@univ-lyon1.fr>
Date: Fri, 23 Sep 2016 16:46:32 +0200
Subject: [PATCH] using setTimeout in save button

---
 js/pgm_construction.js | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/js/pgm_construction.js b/js/pgm_construction.js
index 3e41a87..f872bfc 100644
--- a/js/pgm_construction.js
+++ b/js/pgm_construction.js
@@ -226,7 +226,7 @@ function blob_download() {
   link.href = generate_blob() ;
   document.body.appendChild(link) ;
 
-  window.requestAnimationFrame(function () {
+  setTimeout(function () {
     var event ;
     if(typeof MouseEvent !== 'function') {
       event = document.createEvent("MouseEvent");
@@ -236,7 +236,7 @@ function blob_download() {
     }
     link.dispatchEvent(event);
     document.body.removeChild(link);
-  });
+  }, 66);
 }
 
 /* load the saved data */
-- 
GitLab