mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-17 11:28:07 +00:00
Update meeting title while typing.
Take account sip address on losing focus when saving contact.
This commit is contained in:
parent
4181d19631
commit
ae82cd0ea6
2 changed files with 20 additions and 11 deletions
|
|
@ -69,16 +69,25 @@ MainRightPanel {
|
|||
anchors.fill: parent
|
||||
contact: mainItem.contact
|
||||
button.text: mainItem.saveButtonText
|
||||
|
||||
button.onClicked: {
|
||||
if (contact.core.givenName.length === 0) {
|
||||
givenName.errorMessage = qsTr("Veuillez saisir un prénom")
|
||||
return
|
||||
} else if (addressesList.count === 0 && phoneNumberList.count === 0) {
|
||||
addressesErrorText.setText(qsTr("Veuillez saisir une adresse ou un numéro de téléphone"))
|
||||
return
|
||||
|
||||
// Let some time to GUI to set fields on losing focus.
|
||||
Timer{
|
||||
id: saveDelay
|
||||
interval: 200
|
||||
onTriggered:{
|
||||
if (mainItem.contact.core.givenName.length === 0) {
|
||||
givenName.errorMessage = qsTr("Veuillez saisir un prénom")
|
||||
return
|
||||
} else if (addressesList.count === 0 && phoneNumberList.count === 0) {
|
||||
addressesErrorText.setText(qsTr("Veuillez saisir une adresse ou un numéro de téléphone"))
|
||||
return
|
||||
}
|
||||
mainItem.contact.core.save()
|
||||
}
|
||||
mainItem.contact.core.save()
|
||||
}
|
||||
button.onClicked: {
|
||||
button.forceActiveFocus()
|
||||
saveDelay.restart()
|
||||
}
|
||||
bannerContent: [
|
||||
IconLabelButton {
|
||||
|
|
@ -397,7 +406,7 @@ MainRightPanel {
|
|||
Layout.fillWidth: true
|
||||
wrapMode: Text.WordWrap
|
||||
elide: Text.ElideRight
|
||||
onTextChanged: if(text.length > 0) editionLayout.ensureVisible(this)
|
||||
onTextChanged: if(addressesErrorText.text.length > 0) editionLayout.ensureVisible(this)
|
||||
}
|
||||
Item{Layout.fillHeight: true}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -374,7 +374,7 @@ AbstractMainPage {
|
|||
KeyNavigation.down: conferenceEdit
|
||||
KeyNavigation.up: conferenceEdit
|
||||
onActiveFocusChanged: if(activeFocus==true) selectAll()
|
||||
onEditingFinished: mainItem.selectedConference.core.subject = text
|
||||
onTextEdited: mainItem.selectedConference.core.subject = text
|
||||
Component.onCompleted: {
|
||||
text = mainItem.selectedConference.core.subject
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue