Seperate sending of notifs from sounds
This commit is contained in:
parent
8bb98c3044
commit
ebcf9dd68e
2 changed files with 7 additions and 3 deletions
|
@ -335,8 +335,12 @@ export default class ElectronPlatform extends VectorBasePlatform {
|
|||
return true;
|
||||
}
|
||||
|
||||
async maySendNotifications(): Promise<boolean> {
|
||||
return this._ipcCall('getMaySendNotifications');
|
||||
maySendNotifications(): boolean {
|
||||
return true;
|
||||
}
|
||||
|
||||
async isDoNotDisturbEnabled(): Promise<boolean> {
|
||||
return this._ipcCall('getDoNotDisturbEnabled');
|
||||
}
|
||||
|
||||
displayNotification(title: string, msg: string, avatarUrl: string, room: Room): Notification {
|
||||
|
|
|
@ -50,7 +50,7 @@ export default class WebPlatform extends VectorBasePlatform {
|
|||
* Returns true if the application currently has permission
|
||||
* to display notifications. Otherwise false.
|
||||
*/
|
||||
async maySendNotifications(): Promise<boolean> {
|
||||
maySendNotifications(): boolean {
|
||||
return window.Notification.permission === 'granted';
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue