Skip to content
This repository has been archived by the owner on Apr 22, 2022. It is now read-only.

Commit

Permalink
Improvements in badge in icon app.
Browse files Browse the repository at this point in the history
  • Loading branch information
saenzramiro committed Jul 13, 2016
1 parent ca1e5bb commit cb9d051
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions electron/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -165,11 +165,11 @@ function createWindow () {
function updateBadge(title) {
const messageCount = (/\(([0-9]+)\)/).exec(title);

if (process.platform === 'darwin') {
app.dock.setBadge(messageCount ? messageCount[1] : '');
} else {
if (process.platform === 'win32') {
tray.setBadge(messageCount);
}

app.setBadgeCount(messageCount);
}

// This method will be called when Electron has finished
Expand Down

0 comments on commit cb9d051

Please sign in to comment.