delay install splash screen so user sees it
This commit is contained in:
@@ -9,41 +9,46 @@ var app = electron.app
|
||||
var handlers = require('./handlers')
|
||||
|
||||
function handleArgv (cmd) {
|
||||
if (cmd === '--squirrel-install' || cmd === '--squirrel-updated') {
|
||||
if (cmd === '--squirrel-install') {
|
||||
// App was just installed.
|
||||
handlers.init()
|
||||
|
||||
// TODO:
|
||||
// - Install desktop and start menu shortcuts
|
||||
// - Add explorer context menus
|
||||
|
||||
// Always quit when done
|
||||
// Ensure user sees install splash screen so they realize that Setup.exe actually
|
||||
// installed an application and isn't the application itself.
|
||||
setTimeout(function () {
|
||||
app.quit()
|
||||
}, 5000)
|
||||
return true
|
||||
}
|
||||
|
||||
if (cmd === '--squirrel-updated') {
|
||||
// App was just updated. (Called on new version of app.)
|
||||
handlers.init()
|
||||
app.quit()
|
||||
return true
|
||||
}
|
||||
|
||||
if (cmd === '--squirrel-uninstall') {
|
||||
// Undo anything we did in the --squirrel-install and --squirrel-updated handlers
|
||||
// App was just uninstalled. Undo anything we did in the --squirrel-install and
|
||||
// --squirrel-updated handlers
|
||||
|
||||
// TODO: implement this
|
||||
|
||||
// Always quit when done
|
||||
app.quit()
|
||||
return true
|
||||
}
|
||||
|
||||
if (cmd === '--squirrel-obsolete') {
|
||||
// This is called on the outgoing version of your app before we update to the new
|
||||
// version - it's the opposite of --squirrel-updated
|
||||
|
||||
// Always quit when done
|
||||
// App will be updated. (Called on outgoing version of app.)
|
||||
app.quit()
|
||||
return true
|
||||
}
|
||||
|
||||
if (cmd === '--squirrel-firstrun') {
|
||||
// This is called on the first run of the app.
|
||||
|
||||
// Do not quit the app
|
||||
// This is called on the app's first run. Do not quit, allow startup to continue.
|
||||
return false
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user