fix(ChatMessagesView): Loading spinner and scroll to bottom button overlap

- remove the extra spinner (ok'ed by John and Benj)
- use the more modern StatusIcon, w/o the unconditional ColorOverlay
- some minor cleanup

Closes: #7645
This commit is contained in:
Lukáš Tinkl 2022-10-03 14:16:44 +02:00 committed by Iuri Matias
parent 66f288ec97
commit 550b8fd04a
4 changed files with 7 additions and 33 deletions

View File

@ -168,19 +168,6 @@ ColumnLayout {
+ chatInput.anchors.topMargin + chatInput.anchors.topMargin
+ chatInput.anchors.bottomMargin + chatInput.anchors.bottomMargin
Loader {
id: loadingMessagesIndicator
active: root.rootStore.loadingHistoryMessagesInProgress
visible: root.rootStore.loadingHistoryMessagesInProgress
sourceComponent: LoadingAnimation { }
anchors {
right: parent.right
bottom: chatInput.top
rightMargin: Style.current.padding
bottomMargin: Style.current.padding
}
}
StatusChatInput { StatusChatInput {
id: chatInput id: chatInput

View File

@ -213,22 +213,16 @@ Item {
anchors.leftMargin: Style.current.halfPadding anchors.leftMargin: Style.current.halfPadding
} }
SVGImage { StatusIcon {
id: arrowImage id: arrowImage
width: 24 width: 24
height: 24 height: 24
anchors.verticalCenter: parent.verticalCenter anchors.verticalCenter: parent.verticalCenter
anchors.left: nbMessages.right anchors.left: nbMessages.right
source: Style.svg("leave_chat") icon: "arrow-down"
anchors.leftMargin: nbMessages.visible ? scrollDownButton.buttonPadding : 0 anchors.leftMargin: nbMessages.visible ? scrollDownButton.buttonPadding : 0
rotation: -90
ColorOverlay {
anchors.fill: parent
source: parent
color: Style.current.pillButtonTextColor color: Style.current.pillButtonTextColor
} }
}
MouseArea { MouseArea {
cursorShape: Qt.PointingHandCursor cursorShape: Qt.PointingHandCursor

View File

@ -1,8 +1,6 @@
import QtQuick 2.13 import QtQuick 2.13
import QtQuick.Controls 2.13 import QtQuick.Controls 2.13
import QtGraphicalEffects 1.13
import QtQuick.Layouts 1.13 import QtQuick.Layouts 1.13
import QtMultimedia 5.13
import QtQuick.Dialogs 1.3 import QtQuick.Dialogs 1.3
import DotherSide 0.1 import DotherSide 0.1

View File

@ -1,11 +1,11 @@
import QtQuick 2.13 import QtQuick 2.13
import QtQuick.Controls 2.13 import QtQuick.Controls 2.13
import QtGraphicalEffects 1.13
import utils 1.0 import utils 1.0
import shared 1.0 import shared 1.0
import shared.panels 1.0 import shared.panels 1.0
import StatusQ.Core 0.1
import StatusQ.Core.Utils 0.1 as StatusQUtils import StatusQ.Core.Utils 0.1 as StatusQUtils
Rectangle { Rectangle {
@ -108,18 +108,13 @@ Rectangle {
anchors.topMargin: 4 anchors.topMargin: 4
anchors.right: parent.right anchors.right: parent.right
anchors.rightMargin: 4 anchors.rightMargin: 4
contentItem: SVGImage { contentItem: StatusIcon {
id: iconImg id: iconImg
source: Style.svg("close") source: Style.svg("close")
color: Style.current.textColor
sourceSize: Qt.size(width, height)
width: closeBtn.width width: closeBtn.width
height: closeBtn.height height: closeBtn.height
ColorOverlay {
anchors.fill: iconImg
source: iconImg
color: Style.current.textColor
antialiasing: true
}
} }
background: Rectangle { background: Rectangle {
color: "transparent" color: "transparent"