Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 6 additions & 6 deletions src/home/rooms_list.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,16 +123,16 @@ pub enum RoomsListUpdate {
/// The Html-formatted text preview of the latest message.
latest_message_text: String,
},
/// Update the number of unread messages for the given room.
/// Update the number of unread messages and mentions for the given room.
UpdateNumUnreadMessages {
room_id: OwnedRoomId,
count: UnreadMessageCount,
unread_messages: UnreadMessageCount,
unread_mentions: u64,
},
/// Update the displayable name for the given room.
UpdateRoomName {
room_id: OwnedRoomId,
new_room_name: String,
new_room_name: Option<String>,
},
/// Update the avatar (image) for the given room.
UpdateRoomAvatar {
Expand Down Expand Up @@ -449,9 +449,9 @@ impl RoomsList {
error!("Error: couldn't find room {room_id} to update latest event");
}
}
RoomsListUpdate::UpdateNumUnreadMessages { room_id, count , unread_mentions} => {
RoomsListUpdate::UpdateNumUnreadMessages { room_id, unread_messages, unread_mentions } => {
if let Some(room) = self.all_joined_rooms.get_mut(&room_id) {
(room.num_unread_messages, room.num_unread_mentions) = match count {
(room.num_unread_messages, room.num_unread_mentions) = match unread_messages {
UnreadMessageCount::Unknown => (0, 0),
UnreadMessageCount::Known(count) => (count, unread_mentions),
};
Expand All @@ -462,7 +462,7 @@ impl RoomsList {
RoomsListUpdate::UpdateRoomName { room_id, new_room_name } => {
if let Some(room) = self.all_joined_rooms.get_mut(&room_id) {
let was_displayed = (self.display_filter)(room);
room.room_name = Some(new_room_name);
room.room_name = new_room_name;
let should_display = (self.display_filter)(room);
match (was_displayed, should_display) {
// No need to update the displayed rooms list.
Expand Down
2 changes: 1 addition & 1 deletion src/room/room_input_bar.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! The RoomInputBar widget contains all components related to sending messages/content to a room.
//!
//! The RoomInputBar must be capped to a maximum height of 75% of the containing RoomScreen's height.
//! The RoomInputBar is capped to a maximum height of 62.5% of the containing RoomScreen's height.
//!
//! The widgets included in the RoomInputBar are:
//! * a preview of the message the user is replying to.
Expand Down
Loading