mirror of
https://github.com/smogon/pokemon-showdown-client.git
synced 2026-03-21 17:50:29 -05:00
Update nwjs API for later version (#1246)
This commit is contained in:
parent
d843455588
commit
6a38e809bc
|
|
@ -3,7 +3,7 @@
|
|||
"version": "0.3.0",
|
||||
|
||||
"main": "index.html",
|
||||
"node-remote": "play.pokemonshowdown.com",
|
||||
"node-remote": "*://play.pokemonshowdown.com/*",
|
||||
"no-edit-menu": false,
|
||||
"window": {
|
||||
"icon": "icons/icon_32x32.png",
|
||||
|
|
|
|||
|
|
@ -147,7 +147,7 @@
|
|||
sideBuf += this.renderRoomTab(room);
|
||||
}
|
||||
if (window.nodewebkit) {
|
||||
if (nwWindow.setBadgeLabel) nwWindow.setBadgeLabel(notificationCount || '');
|
||||
if (nwWindow.setBadgeLabel) nwWindow.setBadgeLabel('' + notificationCount || '');
|
||||
} else {
|
||||
var $favicon = $('#dynamic-favicon');
|
||||
if (!!$favicon.data('on') !== !!notificationCount) {
|
||||
|
|
|
|||
|
|
@ -1594,7 +1594,7 @@ Storage.nwSaveTeam = function (team) {
|
|||
this.nwDeleteTeam(team);
|
||||
}
|
||||
team.filename = filename;
|
||||
fs.writeFile(this.dir + 'Teams/' + filename, Storage.exportTeam(team.team).replace(/\n/g, '\r\n'));
|
||||
fs.writeFile(this.dir + 'Teams/' + filename, Storage.exportTeam(team.team).replace(/\n/g, '\r\n'), function () {});
|
||||
};
|
||||
|
||||
Storage.nwSaveTeams = function () {
|
||||
|
|
@ -1630,7 +1630,7 @@ Storage.nwDoSaveAllTeams = function () {
|
|||
filename = $.trim(filename).replace(/[\\\/]+/g, '');
|
||||
|
||||
team.filename = filename;
|
||||
fs.writeFile(this.dir + 'Teams/' + filename, Storage.exportTeam(team.team).replace(/\n/g, '\r\n'));
|
||||
fs.writeFile(this.dir + 'Teams/' + filename, Storage.exportTeam(team.team).replace(/\n/g, '\r\n'), function () {});
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user