优化通知提示

master 2.1.2
宇天 2020-12-18 15:11:54 +08:00
parent 17261cd567
commit 59b5e4da96
2 changed files with 6 additions and 1 deletions

View File

@ -29,6 +29,11 @@ Anot({
var time = +Anot.ss('last_update') || 0 var time = +Anot.ss('last_update') || 0
var now = Date.now() var now = Date.now()
// 有触发小窗口显示时, 更新通知提醒
if (Anot.ls('notify') === '1') {
app.dispatch('notify')
}
this.reloadGays() this.reloadGays()
setTimeout(() => { setTimeout(() => {
// 如果离上次更新超过15分钟, 则自动更新 // 如果离上次更新超过15分钟, 则自动更新

View File

@ -130,7 +130,7 @@ ipcMain.on('app', (ev, conn) => {
var t1 = Date.now() var t1 = Date.now()
var t2 = new Date() var t2 = new Date()
t2.setHours(14) t2.setHours(14)
t2.setMinutes(0) t2.setMinutes(30)
t2.setSeconds(0) t2.setSeconds(0)
if (t2.getTime() - t1 > 0) { if (t2.getTime() - t1 > 0) {