From 20ec85a0290daa8f20f7c17b742bc21ff3e36eac Mon Sep 17 00:00:00 2001 From: Ronan Abhamon Date: Thu, 8 Dec 2016 14:05:08 +0100 Subject: [PATCH] fix(ui/views/App/MainWindow/ContactEdit): display correctly inputs (no overflow) --- tests/ui/modules/Common/Form/TransparentTextInput.qml | 6 ++++++ tests/ui/views/App/MainWindow/ContactEdit.qml | 9 +++++---- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/tests/ui/modules/Common/Form/TransparentTextInput.qml b/tests/ui/modules/Common/Form/TransparentTextInput.qml index 32fada42b..6b93e52c6 100644 --- a/tests/ui/modules/Common/Form/TransparentTextInput.qml +++ b/tests/ui/modules/Common/Form/TransparentTextInput.qml @@ -18,6 +18,12 @@ Item { // ----------------------------------------------------------------- + onActiveFocusChanged: { + if (activeFocus) { + textInput.focus = true + } + } + Rectangle { anchors.fill: parent color: textInput.activeFocus && !readOnly diff --git a/tests/ui/views/App/MainWindow/ContactEdit.qml b/tests/ui/views/App/MainWindow/ContactEdit.qml index 9c9994dc4..36ba424e0 100644 --- a/tests/ui/views/App/MainWindow/ContactEdit.qml +++ b/tests/ui/views/App/MainWindow/ContactEdit.qml @@ -145,6 +145,8 @@ ColumnLayout { // ----------------------------------------------------------------- Flickable { + id: flick + Layout.fillHeight: true Layout.fillWidth: true ScrollBar.vertical: ForceScrollBar {} @@ -152,18 +154,17 @@ ColumnLayout { boundsBehavior: Flickable.StopAtBounds clip: true contentHeight: infoList.height + contentWidth: width - ScrollBar.vertical.width - leftMargin - rightMargin flickableDirection: Flickable.VerticalFlick leftMargin: 40 - rightMargin: 40 + rightMargin: 20 topMargin: 40 ColumnLayout { id: infoList - anchors.left: parent.left - anchors.right: parent.right - + width: flick.contentWidth ListForm { defaultData: _contact.sipAddresses placeholder: qsTr('sipAccountsInput')