Make ChangeAvatar support room avatars and tweak RoomAvatar respond to componentWillReceiveProps
This commit is contained in:
parent
03dfd57a79
commit
5a760b71d0
3 changed files with 31 additions and 5 deletions
|
@ -28,6 +28,7 @@ module.exports = {
|
|||
cli.on("Room", this.onRoom);
|
||||
cli.on("Room.timeline", this.onRoomTimeline);
|
||||
cli.on("Room.name", this.onRoomName);
|
||||
cli.on("RoomState.events", this.onRoomStateEvents);
|
||||
|
||||
var rooms = this.getRoomList();
|
||||
this.setState({
|
||||
|
@ -84,6 +85,10 @@ module.exports = {
|
|||
this.refreshRoomList();
|
||||
},
|
||||
|
||||
onRoomStateEvents: function(ev, state) {
|
||||
this.refreshRoomList();
|
||||
},
|
||||
|
||||
refreshRoomList: function() {
|
||||
var rooms = this.getRoomList();
|
||||
this.setState({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue