diff --git a/Linphone/view/Control/Form/Login/LoginForm.qml b/Linphone/view/Control/Form/Login/LoginForm.qml index cf2e1f5d..14ac0b67 100644 --- a/Linphone/view/Control/Form/Login/LoginForm.qml +++ b/Linphone/view/Control/Form/Login/LoginForm.qml @@ -7,12 +7,12 @@ import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle ColumnLayout { id: mainItem - spacing: Math.round(10 * DefaultStyle.dp) + spacing: Math.round(8 * DefaultStyle.dp) FormItemLayout { id: username Layout.preferredWidth: Math.round(346 * DefaultStyle.dp) - //: "Nom d'utilisateur" : username + //: Nom d'utilisateur : username label: qsTr("username") mandatory: true enableErrorText: true @@ -28,7 +28,7 @@ ColumnLayout { FormItemLayout { id: password width: Math.round(346 * DefaultStyle.dp) - //: "Mot de passe" + //: Mot de passe label: qsTr("password") mandatory: true enableErrorText: true diff --git a/Linphone/view/Page/Form/Login/LoginPage.qml b/Linphone/view/Page/Form/Login/LoginPage.qml index 4c5e9048..e98d5113 100644 --- a/Linphone/view/Page/Form/Login/LoginPage.qml +++ b/Linphone/view/Page/Form/Login/LoginPage.qml @@ -52,7 +52,8 @@ LoginLayout { RowLayout { visible: !SettingsCpp.assistantHideCreateAccount spacing: Math.round(20 * DefaultStyle.dp) - Layout.rightMargin: Math.round(51 * DefaultStyle.dp) + Layout.rightMargin: Math.round((51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp) + Text { Layout.rightMargin: Math.round(15 * DefaultStyle.dp) //: "Pas encore de compte ?" @@ -77,7 +78,6 @@ LoginLayout { anchors.left: parent.left anchors.top: parent.top anchors.leftMargin: Math.round(127 * DefaultStyle.dp) - anchors.topMargin: Math.round(70 * DefaultStyle.dp) anchors.bottom: parent.bottom ColumnLayout { id: content diff --git a/Linphone/view/Page/Form/Login/SIPLoginPage.qml b/Linphone/view/Page/Form/Login/SIPLoginPage.qml index 6ffaac94..8833cc4a 100644 --- a/Linphone/view/Page/Form/Login/SIPLoginPage.qml +++ b/Linphone/view/Page/Form/Login/SIPLoginPage.qml @@ -185,7 +185,7 @@ LoginLayout { width: Math.round(361 * DefaultStyle.dp) ColumnLayout { - spacing: Math.round(16 * DefaultStyle.dp) + spacing: Math.round(8 * DefaultStyle.dp) FormItemLayout { id: username //: "Nom d'utilisateur" @@ -284,7 +284,7 @@ LoginLayout { BigButton { id: connectionButton - Layout.topMargin: Math.round(32 * DefaultStyle.dp) + Layout.topMargin: Math.round(15 * DefaultStyle.dp) style: ButtonStyle.main contentItem: StackLayout { id: connectionButtonContent @@ -368,7 +368,6 @@ LoginLayout { anchors.top: parent.top anchors.left: parent.left anchors.bottom: parent.bottom - anchors.topMargin: Math.round(70 * DefaultStyle.dp) anchors.leftMargin: Math.round(127 * DefaultStyle.dp) width: Math.round(361 * DefaultStyle.dp) }, diff --git a/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml b/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml index 32a25085..ea24aaec 100644 --- a/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml +++ b/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml @@ -62,7 +62,6 @@ LoginLayout { ColumnLayout { anchors.left: parent.left anchors.top: parent.top - anchors.topMargin: Math.round(51 * DefaultStyle.dp) anchors.leftMargin: Math.round(127 * DefaultStyle.dp) spacing: Math.round(104 * DefaultStyle.dp) Text { diff --git a/Linphone/view/Page/Form/Register/RegisterPage.qml b/Linphone/view/Page/Form/Register/RegisterPage.qml index 5e921abb..5d340c39 100644 --- a/Linphone/view/Page/Form/Register/RegisterPage.qml +++ b/Linphone/view/Page/Form/Register/RegisterPage.qml @@ -66,7 +66,7 @@ LoginLayout { }, RowLayout { spacing: Math.round(20 * DefaultStyle.dp) - Layout.rightMargin: Math.round(51 * DefaultStyle.dp) + Layout.rightMargin: Math.round((51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp) Text { Layout.rightMargin: Math.round(15 * DefaultStyle.dp) color: DefaultStyle.main2_700 @@ -90,14 +90,15 @@ LoginLayout { centerContent: [ ColumnLayout { + id: registerForm anchors.fill: parent - anchors.topMargin: Math.round(51 * DefaultStyle.dp) anchors.leftMargin: Math.round(127 * DefaultStyle.dp) - anchors.rightMargin: Math.round(127 * DefaultStyle.dp) spacing: Math.round(50 * DefaultStyle.dp) + TabBar { Layout.fillWidth: true id: bar + Layout.rightMargin: Math.round((127 - ((127/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp) // "S'inscrire avec un numéro de téléphone" model: [qsTr("assistant_account_register_with_phone_number"), // "S'inscrire avec un email" @@ -106,11 +107,27 @@ LoginLayout { Flickable { Layout.fillWidth: true Layout.fillHeight: true + + contentHeight: contentLayout.height + + Control.ScrollBar.vertical: ScrollBar { + id: scrollbar + z: 1 + active: true + interactive: true + visible: parent.contentHeight > parent.height + policy: Control.ScrollBar.AsNeeded + anchors.rightMargin: 8 * DefaultStyle.dp + anchors.right: parent.right + } + ColumnLayout { + id: contentLayout anchors.left: parent.left anchors.right: parent.right - spacing: Math.round(22 * DefaultStyle.dp) + spacing: Math.round(8 * DefaultStyle.dp) ColumnLayout { + id: formLayout spacing: Math.round(24 * DefaultStyle.dp) RowLayout { Layout.preferredHeight: usernameItem.height @@ -296,6 +313,7 @@ LoginLayout { }, Image { z: -1 +// visible: registerForm.x+registerForm.width < x anchors.top: parent.top anchors.right: parent.right anchors.topMargin: Math.round(129 * DefaultStyle.dp) diff --git a/Linphone/view/Page/Layout/Login/LoginLayout.qml b/Linphone/view/Page/Layout/Login/LoginLayout.qml index daf49234..f038457c 100644 --- a/Linphone/view/Page/Layout/Login/LoginLayout.qml +++ b/Linphone/view/Page/Layout/Login/LoginLayout.qml @@ -125,11 +125,11 @@ Rectangle { ColumnLayout { id: contentLayout anchors.fill: parent - spacing: 0 - RowLayout { + spacing: 0 + RowLayout { Layout.fillWidth: true - Layout.preferredHeight: Math.round(102 * DefaultStyle.dp) - Layout.rightMargin: Math.round(42 * DefaultStyle.dp) + Layout.topMargin: Math.round((25 - ((25/(DefaultStyle.defaultHeight - mainWindow.minimumHeight))*(DefaultStyle.defaultHeight-mainWindow.height))) * DefaultStyle.dp) + Layout.rightMargin: Math.round((42 - ((42/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp) spacing: 0 Item { Layout.fillWidth: true @@ -149,14 +149,17 @@ Rectangle { RowLayout { id: titleLayout - Layout.preferredHeight: Math.round(131 * DefaultStyle.dp) Layout.fillWidth: true + Layout.topMargin: Math.round((40 - ((40/(DefaultStyle.defaultHeight - mainWindow.minimumHeight))*(DefaultStyle.defaultHeight-mainWindow.height))) * DefaultStyle.dp) spacing: 0 } Item { id: centerLayout Layout.fillHeight: true Layout.fillWidth: true + Layout.topMargin: Math.round((70 - ((70/(DefaultStyle.defaultHeight - mainWindow.minimumHeight))*(DefaultStyle.defaultHeight-mainWindow.height))) * DefaultStyle.dp) + Layout.alignment: Qt.AlignBottom + } Image { id: bottomMountains diff --git a/Linphone/view/Page/Window/Main/MainWindow.qml b/Linphone/view/Page/Window/Main/MainWindow.qml index d03f0fa1..af856075 100644 --- a/Linphone/view/Page/Window/Main/MainWindow.qml +++ b/Linphone/view/Page/Window/Main/MainWindow.qml @@ -13,10 +13,16 @@ AbstractWindow { title: applicationName // TODO : handle this bool when security mode is implemented property bool firstConnection: true + property int initialWidth + property int initialHeight + Component.onCompleted: { + initialWidth = width + initialHeight = height + } color: DefaultStyle.grey_0 - // minimumWidth: 1020 - // minimumHeight: 700 + minimumWidth: Math.round(1020 * DefaultStyle.dp) + minimumHeight: Math.round(735 * DefaultStyle.dp) signal callCreated() property var accountProxy