Refactor hoverActions positioning

The positions are still bad, but the calculation is slightly less ugly
This commit is contained in:
Tobias Fella
2021-04-09 22:51:28 +02:00
parent 71fcc20943
commit 41b53b5245
2 changed files with 2 additions and 6 deletions

View File

@@ -140,7 +140,8 @@ Kirigami.ScrollablePage {
property bool showEdit: event && (event.author.id === Controller.activeConnection.localUserId && (event.eventType === "emote" || event.eventType === "message"))
property var bubble
property var hovered: bubble && bubble.hovered
x: bubble.x + Kirigami.Units.largeSpacing + Math.max(bubble.width - childWidth, 0)
y: bubble.mapToItem(page, 0, -Kirigami.Units.largeSpacing - hoverActions.childHeight * 1.5).y
visible: (hovered || hoverHandler.hovered) && !Kirigami.Settings.isMobile
property var updateFunction