Bruno Windels
d87d34030a
fix dm detection and conf call code with lazy loading
2018-07-25 16:10:49 +02:00
Bruno Windels
7ea913ccec
fall back to synced membership when own membership is not yet available (due to lazy loading)
2018-07-25 16:10:49 +02:00
Bruno Windels
8529bc55e3
use helper method for knowing whether a user was kicked
...
mainly for readability, but also to discourage grabbing into the member
because of lazy loading changes
2018-07-25 16:10:49 +02:00
Luke Barnard
fae7af1a62
Do proper null-checks on decypted events to fix NPEs
...
Previously we assumed that a decrypted event has a room_id
but this isn't necessarily true for to_device events.
It makes sense to ignore events that aren't associated with
rooms anyway given that the list we're updating only contains
rooms!
2018-02-23 15:04:04 +00:00
Luke Barnard
9e969e33b7
Reorder the RoomListStore lists on Event.decrypted
2018-02-23 10:32:33 +00:00
Luke Barnard
644ddbf9b9
Regenerate room lists on Room event
...
To make sure that we handle rooms that our
client has not seen previously, we regenerate
the room list when the room is stored -
which is indicated by the js-sdk by the
Room event.
2018-02-20 17:57:46 +00:00
Luke Barnard
32130fbc28
Don't regenerate RoomListStore state for notifs/scrollback/etc.
...
Only do so for the live timeline of rooms.
2018-02-19 09:56:03 +00:00
Luke Barnard
94a0a90457
Make RoomListStore aware of Room.timeline events
...
so that we can do reorderings of lists ordered by most recent event.
No optimisations here; we only update for timeline events
on live timelines that could update the "unread count".
2018-02-16 14:16:50 +00:00
Luke Barnard
3020c8cd94
Fix custom tags not being ordered manually
...
Actually fixes vector-im/riot-web#6135 unlike #1748 , which
incorrectly assumed that custom tags would be included in
listOrders.
This fix makes sure that the `default` case in the `switch`
is actually used.
2018-02-14 11:23:29 +00:00
Luke Barnard
f16bc93fee
If a tag is unrecognised, assume manual ordering
...
(as we did previously)
Fixes https://github.com/vector-im/riot-web/issues/6135
2018-02-13 16:09:17 +00:00
Luke Barnard
322012cf88
Add comment to explain hacky optimism
2018-02-12 18:46:36 +00:00
lukebarnard
9b0df19149
Make RoomListStore aware of sub list orderings
...
so that it can do optimistic updates of ordered lists.
2018-02-08 16:20:37 +00:00
lukebarnard
dd0e981d72
Handle indication from server that a room has no more tags
2018-02-06 12:00:23 +00:00
lukebarnard
8d0d0b43ff
Handle first tag added/last tag removed
...
This is a special case because untagged rooms should
appear in im.vector.fake.recent and tagged rooms
should not.
2018-02-06 12:00:06 +00:00
lukebarnard
c665c1170b
Regenerate room lists when we get RoomMember.membership
2018-02-05 18:27:50 +00:00
lukebarnard
9982efbd8f
Regenerate room lists when we get m.direct
2018-02-05 18:06:29 +00:00
lukebarnard
330ce0f02e
On failure, regenerate state from sdk
...
Instead of using history, which could be unpredictable
2018-02-05 17:34:05 +00:00
lukebarnard
4820a195ab
Remove logging
2018-01-26 09:15:03 +01:00
lukebarnard
701abb6a21
Move management of room lists to RoomListStore
...
this is part maintenance to make RoomList clearer and part
allowing room list state to be modified via a dispatch.
2018-01-25 22:16:03 +01:00