Page Menu
Home
Phorge
Search
Configure Global Search
Log In
Files
F112653
D86.1732340391.diff
No One
Temporary
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Award Token
Flag For Later
Size
1 KB
Referenced Files
None
Subscribers
None
D86.1732340391.diff
View Options
diff --git a/src/contents/ui/event-types/Simple.qml b/src/contents/ui/event-types/Simple.qml
--- a/src/contents/ui/event-types/Simple.qml
+++ b/src/contents/ui/event-types/Simple.qml
@@ -65,7 +65,7 @@
TapHandler {
onTapped: {
- activateUserPage(sender, room);
+ activateUserPage(sender, room, event.sender);
}
}
}
diff --git a/src/contents/ui/main.qml b/src/contents/ui/main.qml
--- a/src/contents/ui/main.qml
+++ b/src/contents/ui/main.qml
@@ -181,9 +181,9 @@
});
}
- function activateUserPage(user, room) {
+ function activateUserPage(user, room, userId) {
pageStack.push(Qt.resolvedUrl("qrc:///UserPage.qml"), {
- userId: user.userId,
+ userId: userId || user.userId,
user,
room
});
diff --git a/src/tests/quick-tests/tst_EventView.qml b/src/tests/quick-tests/tst_EventView.qml
--- a/src/tests/quick-tests/tst_EventView.qml
+++ b/src/tests/quick-tests/tst_EventView.qml
@@ -534,5 +534,13 @@
obj.isGapped = false;
verify(item.paginateBackRequested.calledTimes() === 0);
}
+
+ function test_avatarClick() {
+ const avatar = findChild(eventViewText, 'senderAvatar');
+ mouseClick(avatar);
+ tryVerify(() => item.activateUserPage.calledTimes() === 1);
+ // verify that the user id is passed
+ verify(item.activateUserPage.lastArgs()[2] === '@foo:tusooa.xyz');
+ }
}
}
File Metadata
Details
Attached
Mime Type
text/plain
Expires
Fri, Nov 22, 9:39 PM (12 h, 14 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
39124
Default Alt Text
D86.1732340391.diff (1 KB)
Attached To
Mode
D86: Fix loading room page when no such member event is in local state
Attached
Detach File
Event Timeline
Log In to Comment