Rename drawAttention to restoreFromTray

This commit is contained in:
vslg 2020-09-05 15:25:50 -03:00
parent 438b368be6
commit 4382edc8b0
2 changed files with 4 additions and 4 deletions

View File

@ -17,7 +17,7 @@ SystemTrayIcon {
onCountChanged: { onCountChanged: {
if (count) { if (count) {
window.drawAttention() window.restoreFromTray()
py.importModule("os", () => { py.importModule("os", () => {
py.call("os.remove", [get(0, "filePath")]) py.call("os.remove", [get(0, "filePath")])
}) })
@ -34,7 +34,7 @@ SystemTrayIcon {
if (reason === SystemTrayIcon.MiddleClick) if (reason === SystemTrayIcon.MiddleClick)
Qt.quit() Qt.quit()
else if (reason !== SystemTrayIcon.Context) else if (reason !== SystemTrayIcon.Context)
window.visible ? window.hide() : window.drawAttention() window.visible ? window.hide() : window.restoreFromTray()
} }
menu: Menu { menu: Menu {
@ -46,7 +46,7 @@ SystemTrayIcon {
onTriggered: onTriggered:
window.visible ? window.visible ?
window.hide() : window.hide() :
window.drawAttention() window.restoreFromTray()
} }
MenuItem { MenuItem {

View File

@ -65,7 +65,7 @@ ApplicationWindow {
) )
} }
function drawAttention() { function restoreFromTray() {
window.show() window.show()
window.raise() window.raise()
window.requestActivate() window.requestActivate()