forked from mystiq/hydrogen-web
don't open a room when already open
This commit is contained in:
parent
4fb3010676
commit
5d1bc61f61
1 changed files with 6 additions and 4 deletions
|
@ -44,11 +44,13 @@ export class RoomTileViewModel extends ViewModel {
|
||||||
}
|
}
|
||||||
|
|
||||||
open() {
|
open() {
|
||||||
|
if (!this._isOpen) {
|
||||||
this._isOpen = true;
|
this._isOpen = true;
|
||||||
this._wasUnreadWhenOpening = this._room.isUnread;
|
this._wasUnreadWhenOpening = this._room.isUnread;
|
||||||
this.emitChange("isOpen");
|
this.emitChange("isOpen");
|
||||||
this._emitOpen(this._room, this);
|
this._emitOpen(this._room, this);
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
compare(other) {
|
compare(other) {
|
||||||
const myRoom = this._room;
|
const myRoom = this._room;
|
||||||
|
|
Loading…
Reference in a new issue