Oops.
This commit is contained in:
parent
97353ead0f
commit
129c7275a7
6
main.js
6
main.js
@ -44,7 +44,7 @@ function createWindow() {
|
|||||||
mainWindow.setIcon(normalIcon);
|
mainWindow.setIcon(normalIcon);
|
||||||
|
|
||||||
// Tray icon. Do not create it on macOS.
|
// Tray icon. Do not create it on macOS.
|
||||||
if (app.platform != "darwin") {
|
if (process.platform != "darwin") {
|
||||||
tray = new Tray(normalIcon);
|
tray = new Tray(normalIcon);
|
||||||
const contextMenu = Menu.buildFromTemplate([
|
const contextMenu = Menu.buildFromTemplate([
|
||||||
{ label: 'Open Yandex.Mail window', type: 'normal', click: showHideMainWindow },
|
{ label: 'Open Yandex.Mail window', type: 'normal', click: showHideMainWindow },
|
||||||
@ -87,7 +87,7 @@ app.on('activate', function () {
|
|||||||
|
|
||||||
ipc.on("has-unread", function (event, count) {
|
ipc.on("has-unread", function (event, count) {
|
||||||
mainWindow.setIcon(unreadIcon);
|
mainWindow.setIcon(unreadIcon);
|
||||||
if (app.platform == "darwin") {
|
if (process.platform == "darwin") {
|
||||||
app.setBadgeCount(count);
|
app.setBadgeCount(count);
|
||||||
} else {
|
} else {
|
||||||
tray.setImage(unreadIcon);
|
tray.setImage(unreadIcon);
|
||||||
@ -96,7 +96,7 @@ ipc.on("has-unread", function (event, count) {
|
|||||||
|
|
||||||
ipc.on("has-no-unread", function (event, count) {
|
ipc.on("has-no-unread", function (event, count) {
|
||||||
mainWindow.setIcon(normalIcon);
|
mainWindow.setIcon(normalIcon);
|
||||||
if (app.platform == "darwin") {
|
if (process.platform == "darwin") {
|
||||||
app.setBadgeCount(count);
|
app.setBadgeCount(count);
|
||||||
} else {
|
} else {
|
||||||
tray.setImage(unreadIcon);
|
tray.setImage(unreadIcon);
|
||||||
|
Reference in New Issue
Block a user