Merge pull request #347 from kamathmanu/avatarFullViewSupport
Add support for viewing avatar images in full size
This commit is contained in:
commit
95667edb14
@ -49,6 +49,12 @@ Rectangle {
|
|||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MouseArea {
|
||||||
|
id: mouseArea
|
||||||
|
|
||||||
|
anchors.fill: parent
|
||||||
|
onClicked: TimelineManager.openImageOverlay(TimelineManager.timeline.avatarUrl(userid), TimelineManager.timeline.data.id)
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
@ -363,6 +363,9 @@ TimelineViewManager::toggleCameraView()
|
|||||||
void
|
void
|
||||||
TimelineViewManager::openImageOverlay(QString mxcUrl, QString eventId) const
|
TimelineViewManager::openImageOverlay(QString mxcUrl, QString eventId) const
|
||||||
{
|
{
|
||||||
|
if (mxcUrl.isEmpty()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
QQuickImageResponse *imgResponse =
|
QQuickImageResponse *imgResponse =
|
||||||
imgProvider->requestImageResponse(mxcUrl.remove("mxc://"), QSize());
|
imgProvider->requestImageResponse(mxcUrl.remove("mxc://"), QSize());
|
||||||
connect(imgResponse, &QQuickImageResponse::finished, this, [this, eventId, imgResponse]() {
|
connect(imgResponse, &QQuickImageResponse::finished, this, [this, eventId, imgResponse]() {
|
||||||
|
Loading…
Reference in New Issue
Block a user