* send main window to tray icon * MARK: sendToTray
()
| 1099 | * MARK: sendToTray |
| 1100 | */ |
| 1101 | sendToTray () { |
| 1102 | if ( this.tray ) { |
| 1103 | if ( serveIPC.isFirstMinimize ) { |
| 1104 | this.tray.displayBalloon({ |
| 1105 | icon : serveIPC.icon.tray, |
| 1106 | title : this.l10n.syncStringLookup('minimize_message_title'), |
| 1107 | content : this.l10n.syncStringLookup('minimize_message'), |
| 1108 | }) |
| 1109 | |
| 1110 | setTimeout(() => { |
| 1111 | if ( this.tray && !this.tray.isDestroyed() ) { this.tray.removeBalloon() } |
| 1112 | }, 5000) |
| 1113 | } |
| 1114 | |
| 1115 | serveIPC.isFirstMinimize = false |
| 1116 | this.win.main.hide() |
| 1117 | } |
| 1118 | } |
| 1119 | |
| 1120 | // MARK: reset win URL |
| 1121 | setWindowURL(page, query = null) { |
no test coverage detected