mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-01-22 22:28:08 +00:00
feat(ui/views/App/ManageAccounts): refactoring, use now a vertical form
This commit is contained in:
parent
455424887d
commit
83bf254d39
3 changed files with 18 additions and 35 deletions
|
|
@ -17,6 +17,7 @@ Column {
|
|||
|
||||
ColumnLayout {
|
||||
spacing: FormStyle.header.spacing
|
||||
visible: parent.title.length > 0
|
||||
width: parent.width
|
||||
|
||||
Text {
|
||||
|
|
|
|||
|
|
@ -1,5 +1,4 @@
|
|||
import QtQuick 2.7
|
||||
import QtQuick.Layouts 1.3
|
||||
|
||||
import Common 1.0
|
||||
import Linphone 1.0
|
||||
|
|
@ -31,39 +30,31 @@ DialogPlus {
|
|||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Column {
|
||||
Form {
|
||||
orientation: Qt.Vertical
|
||||
|
||||
anchors {
|
||||
fill: parent
|
||||
left: parent.left
|
||||
leftMargin: ManageAccountsStyle.leftMargin
|
||||
right: parent.right
|
||||
rightMargin: ManageAccountsStyle.rightMargin
|
||||
}
|
||||
|
||||
spacing: ManageAccountsStyle.input.spacing
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('selectAccountLabel')
|
||||
|
||||
Text {
|
||||
color: ManageAccountsStyle.input.legend.color
|
||||
elide: Text.ElideRight
|
||||
ComboBox {
|
||||
currentIndex: Utils.findIndex(AccountSettingsModel.accounts, function (account) {
|
||||
return account.sipAddress === AccountSettingsModel.sipAddress
|
||||
})
|
||||
|
||||
font {
|
||||
bold: true
|
||||
pointSize: ManageAccountsStyle.input.legend.fontSize
|
||||
model: AccountSettingsModel.accounts
|
||||
textRole: 'sipAddress'
|
||||
|
||||
onActivated: AccountSettingsModel.setDefaultProxyConfig(model[index].proxyConfig)
|
||||
}
|
||||
}
|
||||
|
||||
text: qsTr('selectAccountLabel')
|
||||
}
|
||||
|
||||
ComboBox {
|
||||
id: email
|
||||
|
||||
currentIndex: Utils.findIndex(AccountSettingsModel.accounts, function (account) {
|
||||
return account.sipAddress === AccountSettingsModel.sipAddress
|
||||
})
|
||||
|
||||
model: AccountSettingsModel.accounts
|
||||
textRole: 'sipAddress'
|
||||
width: parent.width
|
||||
|
||||
onActivated: AccountSettingsModel.setDefaultProxyConfig(model[index].proxyConfig)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -10,13 +10,4 @@ QtObject {
|
|||
property int leftMargin: 35
|
||||
property int rightMargin: 35
|
||||
property int width: 480
|
||||
|
||||
property QtObject input: QtObject {
|
||||
property int spacing: 6
|
||||
|
||||
property QtObject legend: QtObject {
|
||||
property color color: Colors.j
|
||||
property int fontSize: 10
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue