Merge pull request #221 from timroes/flashWindowFix
Flash Window also without systray icon
This commit is contained in:
commit
6c26fa98a4
13
src/main.js
13
src/main.js
|
@ -218,6 +218,13 @@ allowProtocolDialog.init(mainWindow);
|
||||||
// This method will be called when Electron has finished
|
// This method will be called when Electron has finished
|
||||||
// initialization and is ready to create browser windows.
|
// initialization and is ready to create browser windows.
|
||||||
app.on('ready', function() {
|
app.on('ready', function() {
|
||||||
|
ipcMain.on('notified', function(event, arg) {
|
||||||
|
if (process.platform === 'win32' || process.platform === 'linux') {
|
||||||
|
if (config.notifications.flashWindow === 2) {
|
||||||
|
mainWindow.flashFrame(true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
if (shouldShowTrayIcon()) {
|
if (shouldShowTrayIcon()) {
|
||||||
// set up tray icon
|
// set up tray icon
|
||||||
trayIcon = new Tray(trayImages.normal);
|
trayIcon = new Tray(trayImages.normal);
|
||||||
|
@ -261,12 +268,6 @@ app.on('ready', function() {
|
||||||
mainWindow.focus();
|
mainWindow.focus();
|
||||||
});
|
});
|
||||||
ipcMain.on('notified', function(event, arg) {
|
ipcMain.on('notified', function(event, arg) {
|
||||||
if (process.platform === 'win32' || process.platform === 'linux') {
|
|
||||||
if (config.notifications.flashWindow === 2) {
|
|
||||||
mainWindow.flashFrame(true);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
if (process.platform === 'win32') {
|
if (process.platform === 'win32') {
|
||||||
// On Windows 8.1 and Windows 8, a shortcut with a Application User Model ID must be installed to the Start screen.
|
// On Windows 8.1 and Windows 8, a shortcut with a Application User Model ID must be installed to the Start screen.
|
||||||
// In current version, use tray balloon for notification
|
// In current version, use tray balloon for notification
|
||||||
|
|
Loading…
Reference in a new issue