From ef8fa0de5e79f5339eb17e7eb575aa37f3bf5db6 Mon Sep 17 00:00:00 2001
From: "mathias.chouet" <mathias.chouet@irstea.fr>
Date: Fri, 20 Sep 2019 15:03:19 +0200
Subject: [PATCH] Update #250 add delay before notification, to prevent
 expose-effect in Gnome3

---
 main.js | 12 +++++++-----
 1 file changed, 7 insertions(+), 5 deletions(-)

diff --git a/main.js b/main.js
index 65838ad8d..f61100f23 100644
--- a/main.js
+++ b/main.js
@@ -34,12 +34,12 @@ function createWindow () {
     // Close the app.
     win.on('close', () => {
         // @TODO does not render properly on Linux
-        /* var choice = dialog.showMessageBox(this,
+        /* const choice = dialog.showMessageBox(this,
             {
               type: 'question',
-              buttons: ['Yes', 'No'],
-              title: 'Confirm',
-              message: 'Are you sure you want to quit?'
+              buttons: ['Certes', 'Fuque'],
+              title: 'Confirme-z-y voir',
+              message: "T'es-tu sûr de vouloir quitter, là ?"
            }
         );
         if(choice == 1){
@@ -119,7 +119,9 @@ const lookForUpdates = function() {
                                 // ask system to open URL with default browser
                                 shell.openExternal(latestVersionURL);
                             });
-                            notif.show();
+                            setTimeout(() => {
+                                notif.show();
+                            }, 2000);
                         }
                     } else {
                         console.error(`could not find download link for version ${data.latest} on platform ${platform}`);
-- 
GitLab