ffi: Add is_read field to NotificationItem

This commit is contained in:
Mauro
2023-04-28 18:04:42 +02:00
committed by GitHub
parent 396e0a3567
commit 034aa04076
2 changed files with 3 additions and 0 deletions

View File

@@ -22,6 +22,7 @@ dictionary NotificationItem {
boolean is_noisy;
boolean is_direct;
boolean is_encrypted;
boolean is_read;
};
interface TimelineEvent {};

View File

@@ -18,6 +18,7 @@ pub struct NotificationItem {
pub is_noisy: bool,
pub is_direct: bool,
pub is_encrypted: bool,
pub is_read: bool,
}
impl NotificationItem {
@@ -45,6 +46,7 @@ impl NotificationItem {
is_noisy,
is_direct: room.is_direct().await?,
is_encrypted: room.is_encrypted().await?,
is_read: notification.read,
};
Ok(item)
}