Avoid destroying the tray icon in linux (#227)
This commit is contained in:
parent
cc801ce0d7
commit
d7b5f0a26b
|
@ -86,7 +86,9 @@ export class TrayMain {
|
||||||
}
|
}
|
||||||
|
|
||||||
removeTray(showWindow = true) {
|
removeTray(showWindow = true) {
|
||||||
if (this.tray != null) {
|
// Due to https://github.com/electron/electron/issues/17622
|
||||||
|
// we cannot destroy the tray icon on linux.
|
||||||
|
if (this.tray != null && process.platform !== 'linux') {
|
||||||
this.tray.destroy();
|
this.tray.destroy();
|
||||||
this.tray = null;
|
this.tray = null;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue