Skip to content

Commit

Permalink
Added static data
Browse files Browse the repository at this point in the history
  • Loading branch information
purry03 committed Aug 20, 2022
1 parent b4fe5d0 commit e646a7a
Showing 1 changed file with 8 additions and 6 deletions.
14 changes: 8 additions & 6 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,12 +12,14 @@ let navBarIsHidden = false;
$('#minimize').on("click", (event, data) => {
if (navBarIsHidden) {
$("nav").show();
ipcRenderer.send('resize-original')
navBarIsHidden = false;
ipcRenderer.send('resize-original');
$("#minimize").html("-");
navBarIsHidden = false;
}
else {
$("nav").hide();
ipcRenderer.send('resize-reduced')
ipcRenderer.send('resize-reduced');
$("#minimize").html("+");
navBarIsHidden = true;
}
});
Expand All @@ -31,16 +33,16 @@ ipcRenderer.on("system", (event, system) => {
})

ipcRenderer.on("statics", (event, statics) => {
console.log(statics);
$(".statics").html(statics);
$(".statics").html(statics.toString().toUpperCase());
})

ipcRenderer.on("onlineStatus", (event, isOnline) => {
if (isOnline) {
$(".trackingStatus").css("background-color", "green");
$(".trackingStatus").attr("title", "Online");
}
else {
$(".trackingStatus").css("background-color", "red");

$(".trackingStatus").attr("title", "Offline");
}
})

0 comments on commit e646a7a

Please sign in to comment.