mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-05-07 14:44:01 +00:00
feat(ui/views/App/Assistant/AssistantCreateLinphoneSipAccount): view done
This commit is contained in:
parent
9a3aa8e338
commit
eafc4be014
11 changed files with 232 additions and 62 deletions
|
|
@ -35,6 +35,25 @@
|
|||
<translation>BACK</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantCreateLinphoneSipAccount</name>
|
||||
<message>
|
||||
<source>createLinphoneSipAccountDescription</source>
|
||||
<translation>How would you like to create your account?</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>createLinphoneSipAccountTitle</source>
|
||||
<translation>CREATE A LINPHONE ACCOUNT</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>withPhoneNumber</source>
|
||||
<translation>WITH A PHONE NUMBER</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>withEmailAddress</source>
|
||||
<translation>WITH AN EMAIL ADDRESS</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantFetchRemoteConfiguration</name>
|
||||
<message>
|
||||
|
|
@ -52,10 +71,6 @@
|
|||
</context>
|
||||
<context>
|
||||
<name>AssistantHome</name>
|
||||
<message>
|
||||
<source>createSipAccount</source>
|
||||
<translation>CREATE A LINPHONE ACCOUNT</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>useLinphoneSipAccount</source>
|
||||
<translation>USE A LINPHONE ACCOUNT</translation>
|
||||
|
|
@ -76,6 +91,10 @@
|
|||
<source>homeDescription</source>
|
||||
<translation>This assistant will help you to configure and use your linphone account.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>createLinphoneSipAccount</source>
|
||||
<translation>CREATE A LINPHONE ACCOUNT</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantUseOtherSipAccount</name>
|
||||
|
|
|
|||
|
|
@ -35,6 +35,25 @@
|
|||
<translation>RETOUR</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantCreateLinphoneSipAccount</name>
|
||||
<message>
|
||||
<source>createLinphoneSipAccountDescription</source>
|
||||
<translation>Comment souhaitez-vous créer votre compte ?</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>createLinphoneSipAccountTitle</source>
|
||||
<translation>CRÉER UN COMPTE LINPHONE</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>withPhoneNumber</source>
|
||||
<translation>AVEC UN NUMÉRO DE TÉLÉPHONE</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>withEmailAddress</source>
|
||||
<translation>AVER UNE ADRESSE E-MAIL</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantFetchRemoteConfiguration</name>
|
||||
<message>
|
||||
|
|
@ -52,10 +71,6 @@
|
|||
</context>
|
||||
<context>
|
||||
<name>AssistantHome</name>
|
||||
<message>
|
||||
<source>createSipAccount</source>
|
||||
<translation>CRÉER UN COMPTE LINPHONE</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>useLinphoneSipAccount</source>
|
||||
<translation>UTILISER UN COMPTE LINPHONE</translation>
|
||||
|
|
@ -76,6 +91,10 @@
|
|||
<source>homeDescription</source>
|
||||
<translation>Cet assistant va vous aider à configurer et utiliser votre compte SIP.</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>createLinphoneSipAccount</source>
|
||||
<translation>CRÉER UN COMPTE LINPHONE</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>AssistantUseOtherSipAccount</name>
|
||||
|
|
|
|||
|
|
@ -310,6 +310,7 @@
|
|||
<file>ui/scripts/Utils/uri-tools.js</file>
|
||||
<file>ui/scripts/Utils/utils.js</file>
|
||||
<file>ui/views/App/Assistant/AssistantAbstractView.qml</file>
|
||||
<file>ui/views/App/Assistant/AssistantCreateLinphoneSipAccount.qml</file>
|
||||
<file>ui/views/App/Assistant/AssistantFetchRemoteConfiguration.qml</file>
|
||||
<file>ui/views/App/Assistant/AssistantHome.qml</file>
|
||||
<file>ui/views/App/Assistant/AssistantUseOtherSipAccount.qml</file>
|
||||
|
|
@ -337,6 +338,7 @@
|
|||
<file>ui/views/App/Settings/SettingsVideo.qml</file>
|
||||
<file>ui/views/App/Settings/SettingsWindow.qml</file>
|
||||
<file>ui/views/App/Styles/Assistant/AssistantAbstractViewStyle.qml</file>
|
||||
<file>ui/views/App/Styles/Assistant/AssistantCreateLinphoneSipAccountStyle.qml</file>
|
||||
<file>ui/views/App/Styles/Assistant/AssistantHomeStyle.qml</file>
|
||||
<file>ui/views/App/Styles/AssistantWindowStyle.qml</file>
|
||||
<file>ui/views/App/Styles/Calls/CallStyle.qml</file>
|
||||
|
|
|
|||
|
|
@ -16,17 +16,71 @@ ColumnLayout {
|
|||
property alias mainActionLabel: mainActionButton.text
|
||||
property var mainAction
|
||||
|
||||
property alias description: description.text
|
||||
property alias title: title.text
|
||||
|
||||
default property alias _content: content.data
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
height: stack.height
|
||||
width: stack.width
|
||||
|
||||
spacing: AssistantAbstractViewStyle.spacing
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
// Info.
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
Column {
|
||||
Layout.fillWidth: true
|
||||
spacing: AssistantAbstractViewStyle.info.spacing
|
||||
|
||||
Text {
|
||||
id: title
|
||||
|
||||
color: AssistantAbstractViewStyle.info.title.color
|
||||
elide: Text.ElideRight
|
||||
|
||||
font {
|
||||
pointSize: AssistantAbstractViewStyle.info.title.fontSize
|
||||
bold: true
|
||||
}
|
||||
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
width: parent.width
|
||||
}
|
||||
|
||||
Text {
|
||||
id: description
|
||||
|
||||
color: AssistantAbstractViewStyle.info.description.color
|
||||
elide: Text.ElideRight
|
||||
|
||||
font.pointSize: AssistantAbstractViewStyle.info.description.fontSize
|
||||
|
||||
horizontalAlignment: Text.AlignHCenter
|
||||
visible: text.length > 0
|
||||
width: parent.width
|
||||
}
|
||||
}
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
// Content.
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
Item {
|
||||
id: content
|
||||
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
Layout.fillHeight: true
|
||||
Layout.fillWidth: true
|
||||
Layout.preferredWidth: AssistantAbstractViewStyle.content.width
|
||||
}
|
||||
|
||||
// --------------------------------------------------------------------------
|
||||
// Nav buttons.
|
||||
// --------------------------------------------------------------------------
|
||||
|
||||
Row {
|
||||
Layout.alignment: Qt.AlignHCenter
|
||||
spacing: AssistantAbstractViewStyle.buttons.spacing
|
||||
|
|
@ -39,6 +93,8 @@ ColumnLayout {
|
|||
TextButtonB {
|
||||
id: mainActionButton
|
||||
|
||||
visible: !!view.mainAction
|
||||
|
||||
onClicked: view.mainAction()
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,30 @@
|
|||
import QtQuick 2.7
|
||||
|
||||
import Common 1.0
|
||||
|
||||
import App.Styles 1.0
|
||||
|
||||
// =============================================================================
|
||||
|
||||
AssistantAbstractView {
|
||||
description: qsTr('createLinphoneSipAccountDescription')
|
||||
title: qsTr('createLinphoneSipAccountTitle')
|
||||
|
||||
Column {
|
||||
anchors.centerIn: parent
|
||||
spacing: AssistantCreateLinphoneSipAccountStyle.buttons.spacing
|
||||
width: AssistantCreateLinphoneSipAccountStyle.buttons.button.width
|
||||
|
||||
TextButtonA {
|
||||
height: AssistantCreateLinphoneSipAccountStyle.buttons.button.height
|
||||
width: parent.width
|
||||
text: qsTr('withPhoneNumber')
|
||||
}
|
||||
|
||||
TextButtonA {
|
||||
height: AssistantCreateLinphoneSipAccountStyle.buttons.button.height
|
||||
width: parent.width
|
||||
text: qsTr('withEmailAddress')
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -10,10 +10,13 @@ AssistantAbstractView {
|
|||
mainActionEnabled: url.text.length > 0
|
||||
mainActionLabel: qsTr('confirmAction')
|
||||
|
||||
title: qsTr('fetchRemoteConfigurationTitle')
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Form {
|
||||
anchors.fill: parent
|
||||
orientation: Qt.Vertical
|
||||
title: qsTr('fetchRemoteConfigurationTitle')
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
|
|
|
|||
|
|
@ -82,8 +82,8 @@ ColumnLayout {
|
|||
|
||||
model: ListModel {
|
||||
ListElement {
|
||||
$text: qsTr('createSipAccount')
|
||||
$view: 'AssistantCreateSipAccount'
|
||||
$text: qsTr('createLinphoneSipAccount')
|
||||
$view: 'AssistantCreateLinphoneSipAccount'
|
||||
}
|
||||
|
||||
ListElement {
|
||||
|
|
|
|||
|
|
@ -8,62 +8,65 @@ AssistantAbstractView {
|
|||
})
|
||||
|
||||
mainActionEnabled: username.text.length &&
|
||||
sipDomain.text.length &&
|
||||
password.text.length
|
||||
sipDomain.text.length &&
|
||||
password.text.length
|
||||
|
||||
mainActionLabel: qsTr('confirmAction')
|
||||
|
||||
title: qsTr('useOtherSipAccountTitle')
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
Form {
|
||||
anchors.fill: parent
|
||||
orientation: Qt.Vertical
|
||||
title: qsTr('useOtherSipAccountTitle')
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('usernameLabel')
|
||||
|
||||
TextField {
|
||||
TextField {
|
||||
id: username
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('displayNameLabel')
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('displayNameLabel')
|
||||
|
||||
TextField {}
|
||||
}
|
||||
}
|
||||
TextField {}
|
||||
}
|
||||
}
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('sipDomainLabel')
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('sipDomainLabel')
|
||||
|
||||
TextField {
|
||||
id: sipDomain
|
||||
}
|
||||
}
|
||||
}
|
||||
TextField {
|
||||
id: sipDomain
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('passwordLabel')
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('passwordLabel')
|
||||
|
||||
TextField {
|
||||
id: password
|
||||
}
|
||||
}
|
||||
}
|
||||
TextField {
|
||||
id: password
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('transportLabel')
|
||||
FormLine {
|
||||
FormGroup {
|
||||
label: qsTr('transportLabel')
|
||||
|
||||
ExclusiveButtons {
|
||||
texts: [ 'UDP', 'TCP', 'TLS' ]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
ExclusiveButtons {
|
||||
texts: [ 'UDP', 'TCP', 'TLS' ]
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,10 +1,32 @@
|
|||
pragma Singleton
|
||||
import QtQuick 2.7
|
||||
|
||||
import Common 1.0
|
||||
|
||||
// =============================================================================
|
||||
|
||||
QtObject {
|
||||
property int spacing: 20
|
||||
|
||||
property QtObject buttons: QtObject {
|
||||
property int spacing: 10
|
||||
}
|
||||
|
||||
property QtObject content: QtObject {
|
||||
property int width: 340
|
||||
}
|
||||
|
||||
property QtObject info: QtObject {
|
||||
property int spacing: 20
|
||||
|
||||
property QtObject description: QtObject {
|
||||
property color color: Colors.g
|
||||
property int fontSize: 10
|
||||
}
|
||||
|
||||
property QtObject title: QtObject {
|
||||
property color color: Colors.g
|
||||
property int fontSize: 11
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -0,0 +1,15 @@
|
|||
pragma Singleton
|
||||
import QtQuick 2.7
|
||||
|
||||
// =============================================================================
|
||||
|
||||
QtObject {
|
||||
property QtObject buttons: QtObject {
|
||||
property int spacing: 10
|
||||
|
||||
property QtObject button: QtObject {
|
||||
property int height: 40
|
||||
property int width: 258
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -4,21 +4,22 @@ module App.Styles
|
|||
|
||||
# Views styles -----------------------------------------------------------------
|
||||
|
||||
singleton AssistantWindowStyle 1.0 AssistantWindowStyle.qml
|
||||
singleton InviteFriendsWindowStyle 1.0 InviteFriendsWindowStyle.qml
|
||||
singleton ManageAccountsWindowStyle 1.0 ManageAccountsWindowStyle.qml
|
||||
singleton AssistantWindowStyle 1.0 AssistantWindowStyle.qml
|
||||
singleton InviteFriendsWindowStyle 1.0 InviteFriendsWindowStyle.qml
|
||||
singleton ManageAccountsWindowStyle 1.0 ManageAccountsWindowStyle.qml
|
||||
|
||||
singleton AssistantHomeStyle 1.0 Assistant/AssistantHomeStyle.qml
|
||||
singleton AssistantAbstractViewStyle 1.0 Assistant/AssistantAbstractViewStyle.qml
|
||||
singleton AssistantHomeStyle 1.0 Assistant/AssistantHomeStyle.qml
|
||||
singleton AssistantAbstractViewStyle 1.0 Assistant/AssistantAbstractViewStyle.qml
|
||||
singleton AssistantCreateLinphoneSipAccountStyle 1.0 Assistant/AssistantCreateLinphoneSipAccountStyle.qml
|
||||
|
||||
singleton CallStyle 1.0 Calls/CallStyle.qml
|
||||
singleton CallsWindowStyle 1.0 Calls/CallsWindowStyle.qml
|
||||
singleton CallStyle 1.0 Calls/CallStyle.qml
|
||||
singleton CallsWindowStyle 1.0 Calls/CallsWindowStyle.qml
|
||||
|
||||
singleton ContactEditStyle 1.0 Main/ContactEditStyle.qml
|
||||
singleton ContactsStyle 1.0 Main/ContactsStyle.qml
|
||||
singleton ConversationStyle 1.0 Main/ConversationStyle.qml
|
||||
singleton HomeStyle 1.0 Main/HomeStyle.qml
|
||||
singleton MainWindowMenuBarStyle 1.0 Main/MainWindowMenuBarStyle.qml
|
||||
singleton MainWindowStyle 1.0 Main/MainWindowStyle.qml
|
||||
singleton ContactEditStyle 1.0 Main/ContactEditStyle.qml
|
||||
singleton ContactsStyle 1.0 Main/ContactsStyle.qml
|
||||
singleton ConversationStyle 1.0 Main/ConversationStyle.qml
|
||||
singleton HomeStyle 1.0 Main/HomeStyle.qml
|
||||
singleton MainWindowMenuBarStyle 1.0 Main/MainWindowMenuBarStyle.qml
|
||||
singleton MainWindowStyle 1.0 Main/MainWindowStyle.qml
|
||||
|
||||
singleton SettingsWindowStyle 1.0 Settings/SettingsWindowStyle.qml
|
||||
singleton SettingsWindowStyle 1.0 Settings/SettingsWindowStyle.qml
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue