-
Notifications
You must be signed in to change notification settings - Fork 103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SDA-4070 Presence status on macOS #1738
Conversation
* | ||
* @param count {number} | ||
*/ | ||
public updateSystemTrayPresence = (): void => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding sys tray presence (req. for macOS, windows benefits from it)
|
||
// Flags can be read more here https://www.electronjs.org/docs/latest/api/browser-window#winsetthumbarbuttonsbuttons-windows | ||
|
||
export class PresenceStatus { | ||
private presenceStatus: IStatusBadge = { | ||
status: EPresenceStatus.AVAILABLE, | ||
status: EPresenceStatus.NO_PRESENCE, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
By default, no presence is set. We wait the client to provide current user presence.
@@ -37,9 +38,19 @@ export class PresenceStatus { | |||
|
|||
public getCurrentTray = () => this.tray.current; | |||
|
|||
public destroyCurrentTray = () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
destroying tray icon while closing SDA.
@@ -71,7 +82,15 @@ export class PresenceStatus { | |||
place === 'tray' ? 'out-of-office-tray.png' : 'out-of-office.png' | |||
}`; | |||
break; | |||
|
|||
case EPresenceStatus.IN_A_MEETING: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Adding support for meetings
@@ -455,6 +458,12 @@ export class WindowHandler { | |||
mainEvents.publish('maximize'); | |||
} | |||
this.mainWindow.show(); | |||
initSysTray(); | |||
if (isMac) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
macOS: listening for theme changes (light & dark)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, let's have this be a thing 🧐
* SDA-4070 Presence status on macOS * bugfix * SDA-4070 Presence status on macOS * SDA-4070 Presence status on macOS
* SDA-4070 Presence status on macOS * bugfix * SDA-4070 Presence status on macOS * SDA-4070 Presence status on macOS
Description
Adding presence status capabilities on macOS