Add upload avatar hover overlay

Also fix name colors and always use fit-crop mode for avatars.
This commit is contained in:
miruka
2019-07-15 20:10:43 -04:00
parent 83cc148cdc
commit 73ecbaad10
6 changed files with 44 additions and 6 deletions

View File

@@ -16,6 +16,8 @@ HRectangle {
property var toolTipImageUrl: imageUrl
property alias fillMode: avatarImage.fillMode
readonly property alias hovered: hoverHandler.hovered
onImageUrlChanged: if (imageUrl) { avatarImage.source = imageUrl }
onToolTipImageUrlChanged: if (imageUrl) {
@@ -45,7 +47,7 @@ HRectangle {
z: 2
sourceSize.width: params.width
sourceSize.height: params.height
fillMode: params.fillMode
fillMode: Image.PreserveAspectCrop
HoverHandler {
id: hoverHandler

View File

@@ -36,7 +36,7 @@ Item {
)
title: "Select file"
modality: Qt.WindowModal
modality: Qt.NonModal
onVisibleChanged: if (visible) {
selectedFile = Qt.binding(() => Qt.resolvedUrl(currentFile))