mirror of
https://github.com/Nheko-Reborn/nheko.git
synced 2024-11-26 13:08:48 +03:00
Close currently open room when it is tapped again
This commit is contained in:
parent
9f742fe23d
commit
cc6693af8a
1 changed files with 6 additions and 1 deletions
|
@ -190,7 +190,12 @@ Page {
|
||||||
|
|
||||||
TapHandler {
|
TapHandler {
|
||||||
margin: -Nheko.paddingSmall
|
margin: -Nheko.paddingSmall
|
||||||
onSingleTapped: Rooms.setCurrentRoom(roomId)
|
onSingleTapped: {
|
||||||
|
if (!Rooms.currentRoom || Rooms.currentRoom.roomId !== roomId)
|
||||||
|
Rooms.setCurrentRoom(roomId);
|
||||||
|
else
|
||||||
|
Rooms.resetCurrentRoom();
|
||||||
|
}
|
||||||
onLongPressed: {
|
onLongPressed: {
|
||||||
if (!isInvite)
|
if (!isInvite)
|
||||||
roomContextMenu.show(roomId, tags);
|
roomContextMenu.show(roomId, tags);
|
||||||
|
|
Loading…
Reference in a new issue