fix contact edition fields

try to remove avatar shadow effect in lists to improve performances
This commit is contained in:
Gaelle Braud 2025-02-10 16:25:24 +01:00 committed by gaelle
parent 38a718ca0a
commit 5144df7896
10 changed files with 17 additions and 6 deletions

View file

@ -122,6 +122,7 @@ ListView {
width: 45 * DefaultStyle.dp
height: 45 * DefaultStyle.dp
isConference: modelData.core.isConference
shadowEnabled: false
}
ColumnLayout {
Layout.fillHeight: true

View file

@ -33,6 +33,7 @@ ListView {
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData.core.remoteAddress
isConference: modelData.core.isConference
shadowEnabled: false
}
ColumnLayout {
spacing: 0

View file

@ -16,6 +16,7 @@ Loader{
property FriendGui contact: null
property CallGui call: null
property bool isConference: false
property bool shadowEnabled: true
property string _address: account
? account.core?.identityAddress || ""
: call
@ -65,9 +66,11 @@ Loader{
anchors.fill: parent
MultiEffect {
source: stackView
visible: mainItem.shadowEnabled
enabled: mainItem.shadowEnabled
shadowEnabled: mainItem.shadowEnabled
anchors.fill: stackView
shadowEnabled: true
source: stackView
shadowBlur: 0.1
shadowColor: DefaultStyle.grey_1000
shadowOpacity: 0.1

View file

@ -67,6 +67,7 @@ FocusScope {
Layout.preferredHeight: 45 * DefaultStyle.dp
Layout.leftMargin: 5 * DefaultStyle.dp
contact: searchResultItem
shadowEnabled: false
}
ColumnLayout {
spacing: 0

View file

@ -47,6 +47,7 @@ ListView {
Layout.preferredWidth: 45 * DefaultStyle.dp
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData.core.address
shadowEnabled: false
}
Text {
text: modelData.core.displayName

View file

@ -52,6 +52,7 @@ ListView {
Layout.preferredWidth: 45 * DefaultStyle.dp
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData.core.sipAddress
shadowEnabled: false
}
Text {
text: modelData.core.displayName

View file

@ -197,7 +197,7 @@ MainRightPanel {
id: givenNameEdit
Layout.preferredHeight: 49 * DefaultStyle.dp
initialText: contact.core.givenName
onTextChanged: {
onTextEdited: {
contact.core.givenName = givenNameEdit.text
}
backgroundColor: DefaultStyle.grey_0
@ -212,7 +212,7 @@ MainRightPanel {
contentItem: TextField {
id: nameTextField
initialText: contact.core.familyName
onEditingFinished: contact.core.familyName = text
onTextEdited: contact.core.familyName = text
backgroundColor: DefaultStyle.grey_0
KeyNavigation.up: givenNameEdit
KeyNavigation.down: companyTextField
@ -224,7 +224,7 @@ MainRightPanel {
contentItem: TextField {
id: companyTextField
initialText: contact.core.organization
onEditingFinished: contact.core.organization = text
onTextEdited: contact.core.organization = text
backgroundColor: DefaultStyle.grey_0
KeyNavigation.up: nameTextField
KeyNavigation.down: jobTextField
@ -236,7 +236,7 @@ MainRightPanel {
contentItem: TextField {
id: jobTextField
initialText: contact.core.job
onEditingFinished: contact.core.job = text
onTextEdited: contact.core.job = text
backgroundColor: DefaultStyle.grey_0
KeyNavigation.up: companyTextField
Keys.onPressed: (event) => {

View file

@ -49,6 +49,7 @@ FocusScope{
Layout.preferredWidth: 45 * DefaultStyle.dp
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData
shadowEnabled: false
}
Text {
Layout.fillWidth: true

View file

@ -283,6 +283,7 @@ FocusScope {
Layout.preferredWidth: 45 * DefaultStyle.dp
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData.address
shadowEnabled: false
}
Text {
property var displayNameObj: UtilsCpp.getDisplayName(modelData.address)

View file

@ -765,6 +765,7 @@ AbstractMainPage {
Layout.preferredWidth: 45 * DefaultStyle.dp
Layout.preferredHeight: 45 * DefaultStyle.dp
_address: modelData.address
shadowEnabled: false
}
Text {
property var displayNameObj: UtilsCpp.getDisplayName(modelData.address)