From 94c2617dfe241a5eb762968432eeb8c02a0ceaf0 Mon Sep 17 00:00:00 2001 From: Gaelle Braud Date: Wed, 18 Oct 2023 16:46:07 +0200 Subject: [PATCH] fixes --- Linphone/core/App.cpp | 6 - Linphone/data/CMakeLists.txt | 22 +- Linphone/data/image/address-book.svg | 1 + .../data/image/arrow-bend-up-left-bold.svg | 1 + .../data/image/arrow-bend-up-right-bold.svg | 1 + Linphone/data/image/arrow-clockwise.svg | 1 + Linphone/data/image/arrow-right-fill.svg | 1 + Linphone/data/image/backspace-fill.svg | 1 + Linphone/data/image/bell-ringing.svg | 1 + Linphone/data/image/bell-simple-slash.svg | 1 + Linphone/data/image/bell-simple.svg | 1 + Linphone/data/image/bluetooth.svg | 1 + Linphone/data/image/calendar-blank.svg | 1 + Linphone/data/image/calendar.svg | 1 + Linphone/data/image/camera-rotate.svg | 1 + Linphone/data/image/camera.svg | 1 + Linphone/data/image/caret-down.svg | 1 + Linphone/data/image/caret-left.svg | 1 + Linphone/data/image/caret-right.svg | 1 + Linphone/data/image/caret-up.svg | 1 + Linphone/data/image/cell-signal-full.svg | 1 + Linphone/data/image/cell-signal-low.svg | 1 + Linphone/data/image/chat-dots.svg | 1 + Linphone/data/image/chat-teardrop-text.svg | 1 + Linphone/data/image/chat-text.svg | 1 + Linphone/data/image/check-square-offset.svg | 1 + Linphone/data/image/check.svg | 1 + Linphone/data/image/checks.svg | 1 + Linphone/data/image/clock-countdown.svg | 1 + Linphone/data/image/clock.svg | 1 + Linphone/data/image/copy.svg | 1 + Linphone/data/image/detective.svg | 1 + Linphone/data/image/dots-three-vertical.svg | 1 + Linphone/data/image/down-arrow.svg | 3 - Linphone/data/image/ear.svg | 1 + Linphone/data/image/envelope-simple-open.svg | 1 + Linphone/data/image/envelope-simple.svg | 1 + Linphone/data/image/eye-slash.svg | 1 + Linphone/data/image/eye.svg | 1 + Linphone/data/image/file-text.svg | 1 + Linphone/data/image/funnel.svg | 1 + Linphone/data/image/gear.svg | 1 + Linphone/data/image/globe-hemisphere-west.svg | 1 + Linphone/data/image/headset.svg | 1 + Linphone/data/image/heart-fill.svg | 1 + Linphone/data/image/heart.svg | 1 + Linphone/data/image/hide.svg | 3 - Linphone/data/image/in_progress.svg | 5 + Linphone/data/image/incoming_call.svg | 3 + Linphone/data/image/incoming_call_missed.svg | 3 + .../data/image/incoming_call_rejected.svg | 3 + Linphone/data/image/info-logo.svg | 3 - Linphone/data/image/info.svg | 1 + Linphone/data/image/keyboard.svg | 1 + Linphone/data/image/linphone.svg | 6 + .../{login-image.svg => login_image.svg} | 0 Linphone/data/image/magnifying-glass.svg | 1 + Linphone/data/image/media_encryption_srtp.svg | 6 + .../data/image/media_encryption_zrtp_pq.svg | 6 + Linphone/data/image/microphone-slash.svg | 1 + Linphone/data/image/microphone-stage.svg | 1 + Linphone/data/image/microphone.svg | 1 + Linphone/data/image/more.svg | 3 + Linphone/data/image/mountains.svg | 14 ++ Linphone/data/image/not_trusted.svg | 13 ++ Linphone/data/image/open_source.svg | 3 + Linphone/data/image/outgoing_call.svg | 3 + Linphone/data/image/outgoing_call_missed.svg | 3 + .../data/image/outgoing_call_rejected.svg | 3 + Linphone/data/image/paper-plane-tilt.svg | 1 + Linphone/data/image/paperclip.svg | 1 + Linphone/data/image/pause.svg | 1 + Linphone/data/image/pencil-simple.svg | 1 + Linphone/data/image/phone-call.svg | 1 + Linphone/data/image/phone-disconnect.svg | 1 + Linphone/data/image/phone-plus.svg | 1 + Linphone/data/image/phone.svg | 1 + Linphone/data/image/play.svg | 1 + Linphone/data/image/plus-circle.svg | 1 + Linphone/data/image/profil.svg | 3 - Linphone/data/image/qr-code.svg | 1 + Linphone/data/image/question.svg | 1 + Linphone/data/image/record-fill.svg | 1 + Linphone/data/image/return-arrow.svg | 3 - Linphone/data/image/secured.svg | 10 + Linphone/data/image/share-network.svg | 1 + Linphone/data/image/show.svg | 3 - Linphone/data/image/sign-out.svg | 1 + Linphone/data/image/slideshow.svg | 1 + Linphone/data/image/smiley.svg | 1 + Linphone/data/image/speaker-high.svg | 1 + Linphone/data/image/speaker-slash.svg | 1 + Linphone/data/image/trash-simple.svg | 1 + Linphone/data/image/trusted.svg | 6 + Linphone/data/image/user-circle-gear.svg | 1 + Linphone/data/image/user-circle.svg | 1 + Linphone/data/image/user-plus.svg | 1 + Linphone/data/image/user-square.svg | 1 + Linphone/data/image/users-three.svg | 1 + Linphone/data/image/users.svg | 1 + Linphone/data/image/verif_page_image.svg | 47 +++++ Linphone/data/image/video-camera-slash.svg | 1 + Linphone/data/image/video-camera.svg | 1 + Linphone/data/image/warning-circle.svg | 1 + Linphone/data/image/welcome-linphone-logo.svg | 4 - Linphone/data/image/welcome-lock.svg | 6 - Linphone/data/image/welcome-opensource.svg | 3 - Linphone/data/image/wifi-high.svg | 1 + Linphone/data/image/wifi-low.svg | 1 + Linphone/data/image/wrench.svg | 1 + Linphone/data/image/x.svg | 1 + Linphone/view/App/Main.qml | 15 ++ Linphone/view/CMakeLists.txt | 9 +- Linphone/view/Item/CheckBox.qml | 26 +++ Linphone/view/Item/ComboBox.qml | 118 +++++++++-- Linphone/view/Item/DigitInput.qml | 39 ++++ Linphone/view/Item/Form/LoginForm.qml | 2 +- Linphone/view/Item/FormComboBoxCell.qml | 77 ------- Linphone/view/Item/FormTextInputCell.qml | 62 ------ Linphone/view/Item/PhoneNumberComboBox.qml | 149 +++++++++++++ Linphone/view/Item/PhoneNumberInput.qml | 56 +++++ Linphone/view/Item/TabBar.qml | 64 ++++++ Linphone/view/Item/Text.qml | 1 + Linphone/view/Item/TextInput.qml | 17 +- Linphone/view/Page/Login/LoginItem.qml | 59 ++++++ Linphone/view/Page/Login/LoginLayout.qml | 4 +- Linphone/view/Page/Login/LoginPage.qml | 7 +- .../view/Page/Login/RegisterCheckingPage.qml | 112 ++++++++++ Linphone/view/Page/Login/RegisterPage.qml | 196 ++++++++++++++++++ Linphone/view/Page/Login/SIPLoginPage.qml | 21 +- Linphone/view/Page/Login/WelcomePage.qml | 12 +- Linphone/view/Style/AppIcons.qml | 22 +- Linphone/view/Style/DefaultStyle.qml | 18 +- 133 files changed, 1128 insertions(+), 236 deletions(-) create mode 100644 Linphone/data/image/address-book.svg create mode 100644 Linphone/data/image/arrow-bend-up-left-bold.svg create mode 100644 Linphone/data/image/arrow-bend-up-right-bold.svg create mode 100644 Linphone/data/image/arrow-clockwise.svg create mode 100644 Linphone/data/image/arrow-right-fill.svg create mode 100644 Linphone/data/image/backspace-fill.svg create mode 100644 Linphone/data/image/bell-ringing.svg create mode 100644 Linphone/data/image/bell-simple-slash.svg create mode 100644 Linphone/data/image/bell-simple.svg create mode 100644 Linphone/data/image/bluetooth.svg create mode 100644 Linphone/data/image/calendar-blank.svg create mode 100644 Linphone/data/image/calendar.svg create mode 100644 Linphone/data/image/camera-rotate.svg create mode 100644 Linphone/data/image/camera.svg create mode 100644 Linphone/data/image/caret-down.svg create mode 100644 Linphone/data/image/caret-left.svg create mode 100644 Linphone/data/image/caret-right.svg create mode 100644 Linphone/data/image/caret-up.svg create mode 100644 Linphone/data/image/cell-signal-full.svg create mode 100644 Linphone/data/image/cell-signal-low.svg create mode 100644 Linphone/data/image/chat-dots.svg create mode 100644 Linphone/data/image/chat-teardrop-text.svg create mode 100644 Linphone/data/image/chat-text.svg create mode 100644 Linphone/data/image/check-square-offset.svg create mode 100644 Linphone/data/image/check.svg create mode 100644 Linphone/data/image/checks.svg create mode 100644 Linphone/data/image/clock-countdown.svg create mode 100644 Linphone/data/image/clock.svg create mode 100644 Linphone/data/image/copy.svg create mode 100644 Linphone/data/image/detective.svg create mode 100644 Linphone/data/image/dots-three-vertical.svg delete mode 100644 Linphone/data/image/down-arrow.svg create mode 100644 Linphone/data/image/ear.svg create mode 100644 Linphone/data/image/envelope-simple-open.svg create mode 100644 Linphone/data/image/envelope-simple.svg create mode 100644 Linphone/data/image/eye-slash.svg create mode 100644 Linphone/data/image/eye.svg create mode 100644 Linphone/data/image/file-text.svg create mode 100644 Linphone/data/image/funnel.svg create mode 100644 Linphone/data/image/gear.svg create mode 100644 Linphone/data/image/globe-hemisphere-west.svg create mode 100644 Linphone/data/image/headset.svg create mode 100644 Linphone/data/image/heart-fill.svg create mode 100644 Linphone/data/image/heart.svg delete mode 100644 Linphone/data/image/hide.svg create mode 100644 Linphone/data/image/in_progress.svg create mode 100644 Linphone/data/image/incoming_call.svg create mode 100644 Linphone/data/image/incoming_call_missed.svg create mode 100644 Linphone/data/image/incoming_call_rejected.svg delete mode 100644 Linphone/data/image/info-logo.svg create mode 100644 Linphone/data/image/info.svg create mode 100644 Linphone/data/image/keyboard.svg create mode 100644 Linphone/data/image/linphone.svg rename Linphone/data/image/{login-image.svg => login_image.svg} (100%) create mode 100644 Linphone/data/image/magnifying-glass.svg create mode 100644 Linphone/data/image/media_encryption_srtp.svg create mode 100644 Linphone/data/image/media_encryption_zrtp_pq.svg create mode 100644 Linphone/data/image/microphone-slash.svg create mode 100644 Linphone/data/image/microphone-stage.svg create mode 100644 Linphone/data/image/microphone.svg create mode 100644 Linphone/data/image/more.svg create mode 100644 Linphone/data/image/mountains.svg create mode 100644 Linphone/data/image/not_trusted.svg create mode 100644 Linphone/data/image/open_source.svg create mode 100644 Linphone/data/image/outgoing_call.svg create mode 100644 Linphone/data/image/outgoing_call_missed.svg create mode 100644 Linphone/data/image/outgoing_call_rejected.svg create mode 100644 Linphone/data/image/paper-plane-tilt.svg create mode 100644 Linphone/data/image/paperclip.svg create mode 100644 Linphone/data/image/pause.svg create mode 100644 Linphone/data/image/pencil-simple.svg create mode 100644 Linphone/data/image/phone-call.svg create mode 100644 Linphone/data/image/phone-disconnect.svg create mode 100644 Linphone/data/image/phone-plus.svg create mode 100644 Linphone/data/image/phone.svg create mode 100644 Linphone/data/image/play.svg create mode 100644 Linphone/data/image/plus-circle.svg delete mode 100644 Linphone/data/image/profil.svg create mode 100644 Linphone/data/image/qr-code.svg create mode 100644 Linphone/data/image/question.svg create mode 100644 Linphone/data/image/record-fill.svg delete mode 100644 Linphone/data/image/return-arrow.svg create mode 100644 Linphone/data/image/secured.svg create mode 100644 Linphone/data/image/share-network.svg delete mode 100644 Linphone/data/image/show.svg create mode 100644 Linphone/data/image/sign-out.svg create mode 100644 Linphone/data/image/slideshow.svg create mode 100644 Linphone/data/image/smiley.svg create mode 100644 Linphone/data/image/speaker-high.svg create mode 100644 Linphone/data/image/speaker-slash.svg create mode 100644 Linphone/data/image/trash-simple.svg create mode 100644 Linphone/data/image/trusted.svg create mode 100644 Linphone/data/image/user-circle-gear.svg create mode 100644 Linphone/data/image/user-circle.svg create mode 100644 Linphone/data/image/user-plus.svg create mode 100644 Linphone/data/image/user-square.svg create mode 100644 Linphone/data/image/users-three.svg create mode 100644 Linphone/data/image/users.svg create mode 100644 Linphone/data/image/verif_page_image.svg create mode 100644 Linphone/data/image/video-camera-slash.svg create mode 100644 Linphone/data/image/video-camera.svg create mode 100644 Linphone/data/image/warning-circle.svg delete mode 100644 Linphone/data/image/welcome-linphone-logo.svg delete mode 100644 Linphone/data/image/welcome-lock.svg delete mode 100644 Linphone/data/image/welcome-opensource.svg create mode 100644 Linphone/data/image/wifi-high.svg create mode 100644 Linphone/data/image/wifi-low.svg create mode 100644 Linphone/data/image/wrench.svg create mode 100644 Linphone/data/image/x.svg create mode 100644 Linphone/view/Item/CheckBox.qml create mode 100644 Linphone/view/Item/DigitInput.qml delete mode 100644 Linphone/view/Item/FormComboBoxCell.qml delete mode 100644 Linphone/view/Item/FormTextInputCell.qml create mode 100644 Linphone/view/Item/PhoneNumberComboBox.qml create mode 100644 Linphone/view/Item/PhoneNumberInput.qml create mode 100644 Linphone/view/Item/TabBar.qml create mode 100644 Linphone/view/Page/Login/LoginItem.qml create mode 100644 Linphone/view/Page/Login/RegisterCheckingPage.qml create mode 100644 Linphone/view/Page/Login/RegisterPage.qml diff --git a/Linphone/core/App.cpp b/Linphone/core/App.cpp index 867c6fdb..e37f0b8a 100644 --- a/Linphone/core/App.cpp +++ b/Linphone/core/App.cpp @@ -108,12 +108,6 @@ void App::initCppInterfaces() { LinphoneEnums::registerMetaTypes(); } -void App::registerToolTypes() { - qmlRegisterSingletonType( - "ConstantsCpp", 1, 0, "ConstantsCpp", - [](QQmlEngine *engine, QJSEngine *) -> QObject * { return new Constants(engine); }); -} - //------------------------------------------------------------ void App::clean() { diff --git a/Linphone/data/CMakeLists.txt b/Linphone/data/CMakeLists.txt index 333e4d4d..ed63eabe 100644 --- a/Linphone/data/CMakeLists.txt +++ b/Linphone/data/CMakeLists.txt @@ -1,18 +1,20 @@ list(APPEND _LINPHONEAPP_RC_FILES data/assistant/use-app-sip-account.rc data/assistant/create-app-sip-account.rc data/assistant/use-other-sip-account.rc - "data/image/info-logo.svg" + "data/image/info.svg" "data/image/belledonne.svg" - "data/image/profil.svg" + "data/image/user-circle.svg" "data/image/logo.svg" - "data/image/login-image.svg" - "data/image/show.svg" - "data/image/welcome-linphone-logo.svg" - "data/image/welcome-lock.svg" - "data/image/welcome-opensource.svg" - "data/image/hide.svg" - "data/image/down-arrow.svg" - "data/image/return-arrow.svg" + "data/image/login_image.svg" + "data/image/eye-slash.svg" + "data/image/linphone.svg" + "data/image/secured.svg" + "data/image/open_source.svg" + "data/image/eye.svg" + "data/image/caret-down.svg" + "data/image/caret-left.svg" + "data/image/verif_page_image.svg" + "data/image/check.svg" ) set(_LINPHONEAPP_RC_FILES ${_LINPHONEAPP_RC_FILES} PARENT_SCOPE) diff --git a/Linphone/data/image/address-book.svg b/Linphone/data/image/address-book.svg new file mode 100644 index 00000000..11cabcde --- /dev/null +++ b/Linphone/data/image/address-book.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/arrow-bend-up-left-bold.svg b/Linphone/data/image/arrow-bend-up-left-bold.svg new file mode 100644 index 00000000..e22cf2ed --- /dev/null +++ b/Linphone/data/image/arrow-bend-up-left-bold.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/arrow-bend-up-right-bold.svg b/Linphone/data/image/arrow-bend-up-right-bold.svg new file mode 100644 index 00000000..42532ea0 --- /dev/null +++ b/Linphone/data/image/arrow-bend-up-right-bold.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/arrow-clockwise.svg b/Linphone/data/image/arrow-clockwise.svg new file mode 100644 index 00000000..a8c631b3 --- /dev/null +++ b/Linphone/data/image/arrow-clockwise.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/arrow-right-fill.svg b/Linphone/data/image/arrow-right-fill.svg new file mode 100644 index 00000000..fb031f4b --- /dev/null +++ b/Linphone/data/image/arrow-right-fill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/backspace-fill.svg b/Linphone/data/image/backspace-fill.svg new file mode 100644 index 00000000..580b7f30 --- /dev/null +++ b/Linphone/data/image/backspace-fill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/bell-ringing.svg b/Linphone/data/image/bell-ringing.svg new file mode 100644 index 00000000..0d7b4de7 --- /dev/null +++ b/Linphone/data/image/bell-ringing.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/bell-simple-slash.svg b/Linphone/data/image/bell-simple-slash.svg new file mode 100644 index 00000000..89c649e7 --- /dev/null +++ b/Linphone/data/image/bell-simple-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/bell-simple.svg b/Linphone/data/image/bell-simple.svg new file mode 100644 index 00000000..1c026c3b --- /dev/null +++ b/Linphone/data/image/bell-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/bluetooth.svg b/Linphone/data/image/bluetooth.svg new file mode 100644 index 00000000..c1133c92 --- /dev/null +++ b/Linphone/data/image/bluetooth.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/calendar-blank.svg b/Linphone/data/image/calendar-blank.svg new file mode 100644 index 00000000..81024d31 --- /dev/null +++ b/Linphone/data/image/calendar-blank.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/calendar.svg b/Linphone/data/image/calendar.svg new file mode 100644 index 00000000..5caacdbe --- /dev/null +++ b/Linphone/data/image/calendar.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/camera-rotate.svg b/Linphone/data/image/camera-rotate.svg new file mode 100644 index 00000000..74261586 --- /dev/null +++ b/Linphone/data/image/camera-rotate.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/camera.svg b/Linphone/data/image/camera.svg new file mode 100644 index 00000000..7a8d0ac4 --- /dev/null +++ b/Linphone/data/image/camera.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/caret-down.svg b/Linphone/data/image/caret-down.svg new file mode 100644 index 00000000..5b5218a2 --- /dev/null +++ b/Linphone/data/image/caret-down.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/caret-left.svg b/Linphone/data/image/caret-left.svg new file mode 100644 index 00000000..17831184 --- /dev/null +++ b/Linphone/data/image/caret-left.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/caret-right.svg b/Linphone/data/image/caret-right.svg new file mode 100644 index 00000000..e291c0eb --- /dev/null +++ b/Linphone/data/image/caret-right.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/caret-up.svg b/Linphone/data/image/caret-up.svg new file mode 100644 index 00000000..27a7d970 --- /dev/null +++ b/Linphone/data/image/caret-up.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/cell-signal-full.svg b/Linphone/data/image/cell-signal-full.svg new file mode 100644 index 00000000..8a04f8fe --- /dev/null +++ b/Linphone/data/image/cell-signal-full.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/cell-signal-low.svg b/Linphone/data/image/cell-signal-low.svg new file mode 100644 index 00000000..fac7f934 --- /dev/null +++ b/Linphone/data/image/cell-signal-low.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/chat-dots.svg b/Linphone/data/image/chat-dots.svg new file mode 100644 index 00000000..481d876d --- /dev/null +++ b/Linphone/data/image/chat-dots.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/chat-teardrop-text.svg b/Linphone/data/image/chat-teardrop-text.svg new file mode 100644 index 00000000..d07e384d --- /dev/null +++ b/Linphone/data/image/chat-teardrop-text.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/chat-text.svg b/Linphone/data/image/chat-text.svg new file mode 100644 index 00000000..6be649cb --- /dev/null +++ b/Linphone/data/image/chat-text.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/check-square-offset.svg b/Linphone/data/image/check-square-offset.svg new file mode 100644 index 00000000..518a1dc5 --- /dev/null +++ b/Linphone/data/image/check-square-offset.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/check.svg b/Linphone/data/image/check.svg new file mode 100644 index 00000000..2e308611 --- /dev/null +++ b/Linphone/data/image/check.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/checks.svg b/Linphone/data/image/checks.svg new file mode 100644 index 00000000..11d157d0 --- /dev/null +++ b/Linphone/data/image/checks.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/clock-countdown.svg b/Linphone/data/image/clock-countdown.svg new file mode 100644 index 00000000..548aeabc --- /dev/null +++ b/Linphone/data/image/clock-countdown.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/clock.svg b/Linphone/data/image/clock.svg new file mode 100644 index 00000000..18f1a5b9 --- /dev/null +++ b/Linphone/data/image/clock.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/copy.svg b/Linphone/data/image/copy.svg new file mode 100644 index 00000000..f371da50 --- /dev/null +++ b/Linphone/data/image/copy.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/detective.svg b/Linphone/data/image/detective.svg new file mode 100644 index 00000000..7eb7f87d --- /dev/null +++ b/Linphone/data/image/detective.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/dots-three-vertical.svg b/Linphone/data/image/dots-three-vertical.svg new file mode 100644 index 00000000..00e6090f --- /dev/null +++ b/Linphone/data/image/dots-three-vertical.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/down-arrow.svg b/Linphone/data/image/down-arrow.svg deleted file mode 100644 index 05e85884..00000000 --- a/Linphone/data/image/down-arrow.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/ear.svg b/Linphone/data/image/ear.svg new file mode 100644 index 00000000..15ff6531 --- /dev/null +++ b/Linphone/data/image/ear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/envelope-simple-open.svg b/Linphone/data/image/envelope-simple-open.svg new file mode 100644 index 00000000..5c826c63 --- /dev/null +++ b/Linphone/data/image/envelope-simple-open.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/envelope-simple.svg b/Linphone/data/image/envelope-simple.svg new file mode 100644 index 00000000..ada3da40 --- /dev/null +++ b/Linphone/data/image/envelope-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/eye-slash.svg b/Linphone/data/image/eye-slash.svg new file mode 100644 index 00000000..aadbe3ca --- /dev/null +++ b/Linphone/data/image/eye-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/eye.svg b/Linphone/data/image/eye.svg new file mode 100644 index 00000000..61b22527 --- /dev/null +++ b/Linphone/data/image/eye.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/file-text.svg b/Linphone/data/image/file-text.svg new file mode 100644 index 00000000..0b256101 --- /dev/null +++ b/Linphone/data/image/file-text.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/funnel.svg b/Linphone/data/image/funnel.svg new file mode 100644 index 00000000..8ae63bc9 --- /dev/null +++ b/Linphone/data/image/funnel.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/gear.svg b/Linphone/data/image/gear.svg new file mode 100644 index 00000000..2781afab --- /dev/null +++ b/Linphone/data/image/gear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/globe-hemisphere-west.svg b/Linphone/data/image/globe-hemisphere-west.svg new file mode 100644 index 00000000..61c122a7 --- /dev/null +++ b/Linphone/data/image/globe-hemisphere-west.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/headset.svg b/Linphone/data/image/headset.svg new file mode 100644 index 00000000..40e5e753 --- /dev/null +++ b/Linphone/data/image/headset.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/heart-fill.svg b/Linphone/data/image/heart-fill.svg new file mode 100644 index 00000000..04ca5ba3 --- /dev/null +++ b/Linphone/data/image/heart-fill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/heart.svg b/Linphone/data/image/heart.svg new file mode 100644 index 00000000..89f2caf8 --- /dev/null +++ b/Linphone/data/image/heart.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/hide.svg b/Linphone/data/image/hide.svg deleted file mode 100644 index 8c58de05..00000000 --- a/Linphone/data/image/hide.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/in_progress.svg b/Linphone/data/image/in_progress.svg new file mode 100644 index 00000000..0738d048 --- /dev/null +++ b/Linphone/data/image/in_progress.svg @@ -0,0 +1,5 @@ + + + + + diff --git a/Linphone/data/image/incoming_call.svg b/Linphone/data/image/incoming_call.svg new file mode 100644 index 00000000..5dab3838 --- /dev/null +++ b/Linphone/data/image/incoming_call.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/incoming_call_missed.svg b/Linphone/data/image/incoming_call_missed.svg new file mode 100644 index 00000000..4faa85b7 --- /dev/null +++ b/Linphone/data/image/incoming_call_missed.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/incoming_call_rejected.svg b/Linphone/data/image/incoming_call_rejected.svg new file mode 100644 index 00000000..c64a80eb --- /dev/null +++ b/Linphone/data/image/incoming_call_rejected.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/info-logo.svg b/Linphone/data/image/info-logo.svg deleted file mode 100644 index fa7f3a77..00000000 --- a/Linphone/data/image/info-logo.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/info.svg b/Linphone/data/image/info.svg new file mode 100644 index 00000000..2f26d80a --- /dev/null +++ b/Linphone/data/image/info.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/keyboard.svg b/Linphone/data/image/keyboard.svg new file mode 100644 index 00000000..e7aa36dd --- /dev/null +++ b/Linphone/data/image/keyboard.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/linphone.svg b/Linphone/data/image/linphone.svg new file mode 100644 index 00000000..005da361 --- /dev/null +++ b/Linphone/data/image/linphone.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/Linphone/data/image/login-image.svg b/Linphone/data/image/login_image.svg similarity index 100% rename from Linphone/data/image/login-image.svg rename to Linphone/data/image/login_image.svg diff --git a/Linphone/data/image/magnifying-glass.svg b/Linphone/data/image/magnifying-glass.svg new file mode 100644 index 00000000..39a3b251 --- /dev/null +++ b/Linphone/data/image/magnifying-glass.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/media_encryption_srtp.svg b/Linphone/data/image/media_encryption_srtp.svg new file mode 100644 index 00000000..37df36fc --- /dev/null +++ b/Linphone/data/image/media_encryption_srtp.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/Linphone/data/image/media_encryption_zrtp_pq.svg b/Linphone/data/image/media_encryption_zrtp_pq.svg new file mode 100644 index 00000000..23acb259 --- /dev/null +++ b/Linphone/data/image/media_encryption_zrtp_pq.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/Linphone/data/image/microphone-slash.svg b/Linphone/data/image/microphone-slash.svg new file mode 100644 index 00000000..406de1e8 --- /dev/null +++ b/Linphone/data/image/microphone-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/microphone-stage.svg b/Linphone/data/image/microphone-stage.svg new file mode 100644 index 00000000..dd4ba119 --- /dev/null +++ b/Linphone/data/image/microphone-stage.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/microphone.svg b/Linphone/data/image/microphone.svg new file mode 100644 index 00000000..36f7b4e0 --- /dev/null +++ b/Linphone/data/image/microphone.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/more.svg b/Linphone/data/image/more.svg new file mode 100644 index 00000000..56ffcc06 --- /dev/null +++ b/Linphone/data/image/more.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/mountains.svg b/Linphone/data/image/mountains.svg new file mode 100644 index 00000000..fdb0ecf8 --- /dev/null +++ b/Linphone/data/image/mountains.svg @@ -0,0 +1,14 @@ + + + + + + + + + + + + + + diff --git a/Linphone/data/image/not_trusted.svg b/Linphone/data/image/not_trusted.svg new file mode 100644 index 00000000..b16dc774 --- /dev/null +++ b/Linphone/data/image/not_trusted.svg @@ -0,0 +1,13 @@ + + + + + + + + + + + + + diff --git a/Linphone/data/image/open_source.svg b/Linphone/data/image/open_source.svg new file mode 100644 index 00000000..5f9b9ae0 --- /dev/null +++ b/Linphone/data/image/open_source.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/outgoing_call.svg b/Linphone/data/image/outgoing_call.svg new file mode 100644 index 00000000..21bb7c7d --- /dev/null +++ b/Linphone/data/image/outgoing_call.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/outgoing_call_missed.svg b/Linphone/data/image/outgoing_call_missed.svg new file mode 100644 index 00000000..a5433e0d --- /dev/null +++ b/Linphone/data/image/outgoing_call_missed.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/outgoing_call_rejected.svg b/Linphone/data/image/outgoing_call_rejected.svg new file mode 100644 index 00000000..39fa5aea --- /dev/null +++ b/Linphone/data/image/outgoing_call_rejected.svg @@ -0,0 +1,3 @@ + + + diff --git a/Linphone/data/image/paper-plane-tilt.svg b/Linphone/data/image/paper-plane-tilt.svg new file mode 100644 index 00000000..73f7dedd --- /dev/null +++ b/Linphone/data/image/paper-plane-tilt.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/paperclip.svg b/Linphone/data/image/paperclip.svg new file mode 100644 index 00000000..8ed52588 --- /dev/null +++ b/Linphone/data/image/paperclip.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/pause.svg b/Linphone/data/image/pause.svg new file mode 100644 index 00000000..2ba53b7c --- /dev/null +++ b/Linphone/data/image/pause.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/pencil-simple.svg b/Linphone/data/image/pencil-simple.svg new file mode 100644 index 00000000..35cfc71c --- /dev/null +++ b/Linphone/data/image/pencil-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/phone-call.svg b/Linphone/data/image/phone-call.svg new file mode 100644 index 00000000..abba91e8 --- /dev/null +++ b/Linphone/data/image/phone-call.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/phone-disconnect.svg b/Linphone/data/image/phone-disconnect.svg new file mode 100644 index 00000000..5e42636c --- /dev/null +++ b/Linphone/data/image/phone-disconnect.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/phone-plus.svg b/Linphone/data/image/phone-plus.svg new file mode 100644 index 00000000..e9bad66d --- /dev/null +++ b/Linphone/data/image/phone-plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/phone.svg b/Linphone/data/image/phone.svg new file mode 100644 index 00000000..ac3ff5a1 --- /dev/null +++ b/Linphone/data/image/phone.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/play.svg b/Linphone/data/image/play.svg new file mode 100644 index 00000000..9df4f4c2 --- /dev/null +++ b/Linphone/data/image/play.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/plus-circle.svg b/Linphone/data/image/plus-circle.svg new file mode 100644 index 00000000..051b34cd --- /dev/null +++ b/Linphone/data/image/plus-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/profil.svg b/Linphone/data/image/profil.svg deleted file mode 100644 index 82555575..00000000 --- a/Linphone/data/image/profil.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/qr-code.svg b/Linphone/data/image/qr-code.svg new file mode 100644 index 00000000..2d6248f0 --- /dev/null +++ b/Linphone/data/image/qr-code.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/question.svg b/Linphone/data/image/question.svg new file mode 100644 index 00000000..6d8013ce --- /dev/null +++ b/Linphone/data/image/question.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/record-fill.svg b/Linphone/data/image/record-fill.svg new file mode 100644 index 00000000..72d18e99 --- /dev/null +++ b/Linphone/data/image/record-fill.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/return-arrow.svg b/Linphone/data/image/return-arrow.svg deleted file mode 100644 index bff67614..00000000 --- a/Linphone/data/image/return-arrow.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/secured.svg b/Linphone/data/image/secured.svg new file mode 100644 index 00000000..212c4e52 --- /dev/null +++ b/Linphone/data/image/secured.svg @@ -0,0 +1,10 @@ + + + + + + + + + + diff --git a/Linphone/data/image/share-network.svg b/Linphone/data/image/share-network.svg new file mode 100644 index 00000000..02d8619a --- /dev/null +++ b/Linphone/data/image/share-network.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/show.svg b/Linphone/data/image/show.svg deleted file mode 100644 index d23a9e93..00000000 --- a/Linphone/data/image/show.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/sign-out.svg b/Linphone/data/image/sign-out.svg new file mode 100644 index 00000000..ffd423ee --- /dev/null +++ b/Linphone/data/image/sign-out.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/slideshow.svg b/Linphone/data/image/slideshow.svg new file mode 100644 index 00000000..d52a4aea --- /dev/null +++ b/Linphone/data/image/slideshow.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/smiley.svg b/Linphone/data/image/smiley.svg new file mode 100644 index 00000000..cc071182 --- /dev/null +++ b/Linphone/data/image/smiley.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/speaker-high.svg b/Linphone/data/image/speaker-high.svg new file mode 100644 index 00000000..1633bdcc --- /dev/null +++ b/Linphone/data/image/speaker-high.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/speaker-slash.svg b/Linphone/data/image/speaker-slash.svg new file mode 100644 index 00000000..17f3c6a8 --- /dev/null +++ b/Linphone/data/image/speaker-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/trash-simple.svg b/Linphone/data/image/trash-simple.svg new file mode 100644 index 00000000..0c2db485 --- /dev/null +++ b/Linphone/data/image/trash-simple.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/trusted.svg b/Linphone/data/image/trusted.svg new file mode 100644 index 00000000..f39d5a03 --- /dev/null +++ b/Linphone/data/image/trusted.svg @@ -0,0 +1,6 @@ + + + + + + diff --git a/Linphone/data/image/user-circle-gear.svg b/Linphone/data/image/user-circle-gear.svg new file mode 100644 index 00000000..c406aac6 --- /dev/null +++ b/Linphone/data/image/user-circle-gear.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/user-circle.svg b/Linphone/data/image/user-circle.svg new file mode 100644 index 00000000..761ce7d9 --- /dev/null +++ b/Linphone/data/image/user-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/user-plus.svg b/Linphone/data/image/user-plus.svg new file mode 100644 index 00000000..9602ea86 --- /dev/null +++ b/Linphone/data/image/user-plus.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/user-square.svg b/Linphone/data/image/user-square.svg new file mode 100644 index 00000000..71c8534f --- /dev/null +++ b/Linphone/data/image/user-square.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/users-three.svg b/Linphone/data/image/users-three.svg new file mode 100644 index 00000000..ba001446 --- /dev/null +++ b/Linphone/data/image/users-three.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/users.svg b/Linphone/data/image/users.svg new file mode 100644 index 00000000..353aca80 --- /dev/null +++ b/Linphone/data/image/users.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/verif_page_image.svg b/Linphone/data/image/verif_page_image.svg new file mode 100644 index 00000000..348f6f08 --- /dev/null +++ b/Linphone/data/image/verif_page_image.svg @@ -0,0 +1,47 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/Linphone/data/image/video-camera-slash.svg b/Linphone/data/image/video-camera-slash.svg new file mode 100644 index 00000000..942e907f --- /dev/null +++ b/Linphone/data/image/video-camera-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/video-camera.svg b/Linphone/data/image/video-camera.svg new file mode 100644 index 00000000..0383a7c7 --- /dev/null +++ b/Linphone/data/image/video-camera.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/warning-circle.svg b/Linphone/data/image/warning-circle.svg new file mode 100644 index 00000000..a04e6ff7 --- /dev/null +++ b/Linphone/data/image/warning-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/welcome-linphone-logo.svg b/Linphone/data/image/welcome-linphone-logo.svg deleted file mode 100644 index 6f6b71ba..00000000 --- a/Linphone/data/image/welcome-linphone-logo.svg +++ /dev/null @@ -1,4 +0,0 @@ - - - - diff --git a/Linphone/data/image/welcome-lock.svg b/Linphone/data/image/welcome-lock.svg deleted file mode 100644 index e3eadede..00000000 --- a/Linphone/data/image/welcome-lock.svg +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - diff --git a/Linphone/data/image/welcome-opensource.svg b/Linphone/data/image/welcome-opensource.svg deleted file mode 100644 index 11a62d80..00000000 --- a/Linphone/data/image/welcome-opensource.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/wifi-high.svg b/Linphone/data/image/wifi-high.svg new file mode 100644 index 00000000..200030e0 --- /dev/null +++ b/Linphone/data/image/wifi-high.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/wifi-low.svg b/Linphone/data/image/wifi-low.svg new file mode 100644 index 00000000..d8b0173b --- /dev/null +++ b/Linphone/data/image/wifi-low.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/wrench.svg b/Linphone/data/image/wrench.svg new file mode 100644 index 00000000..71b09f56 --- /dev/null +++ b/Linphone/data/image/wrench.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/x.svg b/Linphone/data/image/x.svg new file mode 100644 index 00000000..52756cbd --- /dev/null +++ b/Linphone/data/image/x.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/view/App/Main.qml b/Linphone/view/App/Main.qml index d6db0bb4..1b55140c 100644 --- a/Linphone/view/App/Main.qml +++ b/Linphone/view/App/Main.qml @@ -28,12 +28,27 @@ Window { id: loginPage LoginPage { onUseSIPButtonClicked: mainWindowStackView.push(sipLoginPage) + onGoToRegister: mainWindowStackView.replace(registerPage) } } Component { id: sipLoginPage SIPLoginPage { onReturnToLogin: mainWindowStackView.pop() + onGoToRegister: mainWindowStackView.replace(registerPage) + } + } + Component { + id: registerPage + RegisterPage { + onReturnToLogin: mainWindowStackView.replace(loginPage) + onRegisterCalled: mainWindowStackView.push(checkingPage) + } + } + Component { + id: checkingPage + RegisterCheckingPage { + onReturnToRegister: mainWindowStackView.pop() } } } diff --git a/Linphone/view/CMakeLists.txt b/Linphone/view/CMakeLists.txt index 37e2788c..c96fb1b8 100644 --- a/Linphone/view/CMakeLists.txt +++ b/Linphone/view/CMakeLists.txt @@ -5,15 +5,22 @@ list(APPEND _LINPHONEAPP_QML_FILES view/Item/Button.qml view/Item/Carousel.qml + view/Item/CheckBox.qml view/Item/ComboBox.qml + view/Item/DigitInput.qml + view/Item/PhoneNumberComboBox.qml + view/Item/PhoneNumberInput.qml view/Item/RectangleTest.qml + view/Item/TabBar.qml view/Item/Text.qml view/Item/TextInput.qml - + view/Item/Form/LoginForm.qml view/Page/Login/LoginPage.qml + view/Page/Login/RegisterPage.qml view/Page/Login/SIPLoginPage.qml + view/Page/Login/RegisterCheckingPage.qml view/Page/Login/WelcomePage.qml # Prototypes diff --git a/Linphone/view/Item/CheckBox.qml b/Linphone/view/Item/CheckBox.qml new file mode 100644 index 00000000..fb6d435a --- /dev/null +++ b/Linphone/view/Item/CheckBox.qml @@ -0,0 +1,26 @@ +import QtQuick 2.7 +import QtQuick.Controls 2.2 as Control +import Linphone + +Control.CheckBox { + id: checkbox + + indicator: Rectangle { + implicitWidth: 18 + implicitHeight: 18 + x: (parent.width - width) / 2 + y: (parent.height - height) / 2 + radius: 3 + border.color: DefaultStyle.checkboxBorderColor + border.width: DefaultStyle.checkboxBorderWidth + // color: checkbox.checked ? DefaultStyle.checkboxBorderColor : "transparent" + + Text { + anchors.centerIn: parent + text: "\u2714" + font.pointSize: 18 + color: DefaultStyle.checkboxBorderColor + visible: checkbox.checked + } + } +} diff --git a/Linphone/view/Item/ComboBox.qml b/Linphone/view/Item/ComboBox.qml index bcf9b94e..68ccd04d 100644 --- a/Linphone/view/Item/ComboBox.qml +++ b/Linphone/view/Item/ComboBox.qml @@ -7,10 +7,12 @@ ColumnLayout { id: cellLayout property string label: "" property int backgroundWidth: 200 - property variant modelList: [] + // Usage : each item of the model list must be {text: ..., img: ...} + property var modelList: [] + readonly property string currentText: chosenItemText.text - Layout.bottomMargin: 8 Text { + visible: label.length > 0 verticalAlignment: Text.AlignVCenter text: cellLayout.label color: DefaultStyle.formItemLabelColor @@ -23,42 +25,127 @@ ColumnLayout { ComboBox { id: combobox model: cellLayout.modelList + width: cellLayout.backgroundWidth background: Loader { sourceComponent: backgroundRectangle } - contentItem: Text { - leftPadding: 10 - text: combobox.displayText - font.family: DefaultStyle.defaultFont - font.pointSize: DefaultStyle.formItemLabelSize - color: DefaultStyle.formItemLabelColor - verticalAlignment: Text.AlignVCenter - elide: Text.ElideRight + contentItem: Item { + anchors.left: parent.left + anchors.right: indic.right + anchors.leftMargin: 10 + Image { + id: chosenItemImg + sourceSize.width: 20 + width: 20 + fillMode: Image.PreserveAspectFit + anchors.leftMargin: 20 + anchors.verticalCenter: parent.verticalCenter + } + + Text { + id: chosenItemText + anchors.left: chosenItemImg.right + anchors.leftMargin: 10 + anchors.rightMargin: 20 + anchors.right: parent.right + elide: Text.ElideRight + anchors.verticalCenter: parent.verticalCenter + } + + Component.onCompleted: { + if (cellLayout.modelList[combobox.currentIndex].img) + chosenItemImg.source = cellLayout.modelList[combobox.currentIndex].img + if (cellLayout.modelList[combobox.currentIndex].text) + chosenItemText.text = cellLayout.modelList[combobox.currentIndex].text + } } + indicator: Image { + id: indic x: combobox.width - width - combobox.rightPadding y: combobox.topPadding + (combobox.availableHeight - height) / 2 source: AppIcons.downArrow - // width: 12 - // height: 8 } popup: Popup { + id: listPopup y: combobox.height - 1 width: combobox.width implicitHeight: contentItem.implicitHeight padding: 1 contentItem: ListView { + id: listView clip: true implicitHeight: contentHeight - model: combobox.popup.visible ? combobox.delegateModel : null - currentIndex: combobox.highlightedIndex + model: combobox.model + currentIndex: combobox.highlightedIndex >= 0 ? combobox.highlightedIndex : 0 + highlightFollowsCurrentItem: true + highlight: highlight + + delegate: Item { + width:combobox.width; + height: combobox.height; + Image { + id: delegateImg; + sourceSize.width: 20 + width: 20 + anchors.left: parent.left + anchors.leftMargin: 10 + anchors.verticalCenter: parent.verticalCenter + fillMode: Image.PreserveAspectFit + source: modelData.img ? modelData.img : "" + } + + Text { + text: modelData.text ? modelData.text : modelData ? modelData : "" + anchors.leftMargin: 10 + anchors.rightMargin: 10 + elide: Text.ElideRight + anchors.verticalCenter: parent.verticalCenter + anchors.left: delegateImg.right + anchors.right: parent.right + } + + MouseArea { + anchors.fill: parent; + hoverEnabled: true + Rectangle { + anchors.fill: parent + opacity: 0.1 + radius: 15 + color: DefaultStyle.comboBoxHoverColor + visible: parent.containsMouse + } + onPressed: { + combobox.state = "" + chosenItemText.text = modelData.text ? modelData.text : modelData ? modelData : "" + chosenItemImg.source = modelData.img ? modelData.img : "" + listView.currentIndex = index + listPopup.close() + } + } + } ScrollIndicator.vertical: ScrollIndicator { } } + onOpened: { + listView.positionViewAtIndex(listView.currentIndex, ListView.Center) + } + + Component { + id: highlight + Rectangle { + width: listView.width + height: listView.height + color: DefaultStyle.comboBoxHighlightColor + radius: 15 + y: listView.currentItem? listView.currentItem.y : 0 + } + } + background: Loader { sourceComponent: backgroundRectangle } @@ -68,9 +155,8 @@ ColumnLayout { Rectangle { implicitWidth: cellLayout.backgroundWidth implicitHeight: 30 - radius: 20 + radius: 15 color: DefaultStyle.formItemBackgroundColor - opacity: 0.7 } } } diff --git a/Linphone/view/Item/DigitInput.qml b/Linphone/view/Item/DigitInput.qml new file mode 100644 index 00000000..814aa21d --- /dev/null +++ b/Linphone/view/Item/DigitInput.qml @@ -0,0 +1,39 @@ +import QtQuick 2.7 +import QtQuick.Controls 2.2 as Control +import Linphone + +Control.TextField { + id: numberInput + property int inputSize: 50 + color: activeFocus ? DefaultStyle.digitInputFocusedColor : DefaultStyle.digitInputColor + rightPadding: inputSize / 4 + leftPadding: inputSize / 4 + validator: IntValidator{bottom: 0; top: 9} + + // just reserve the space for the background + placeholderText: "0" + placeholderTextColor: "transparent" + + // horizontalAlignment: Control.TextField.AlignHCenter + font.family: DefaultStyle.defaultFont + font.pointSize: inputSize / 1.5 + + background: Rectangle { + // id: background + border.color: numberInput.activeFocus ? DefaultStyle.digitInputFocusedColor : DefaultStyle.digitInputColor + radius: numberInput.inputSize / 8 + } + // cursorDelegate: Rectangle { + // visible: numberInput.activeFocus + // // width: numberInput.cursorRectangle.width + // // height: numberInput.cursorRectangle.height - inputSize/5 + // x: background.x + // y: background.height - inputSize/8 + // transform: Rotation {angle: -90} + // // anchors.bottom: parent.bottom + // // anchors.left: parent.left + // // anchors.bottomMargin: inputSize/8 + // // transform: [/*Translate {x: numberInput.cursorRectangle.height},*/ Rotation {angle: -90}] + // color: numberInput.activeFocus ? DefaultStyle.digitInputFocusedColor : DefaultStyle.digitInputColor + // } +} diff --git a/Linphone/view/Item/Form/LoginForm.qml b/Linphone/view/Item/Form/LoginForm.qml index f69d178e..f07dc991 100644 --- a/Linphone/view/Item/Form/LoginForm.qml +++ b/Linphone/view/Item/Form/LoginForm.qml @@ -67,4 +67,4 @@ ColumnLayout { Item { Layout.fillHeight: true } -} \ No newline at end of file +} diff --git a/Linphone/view/Item/FormComboBoxCell.qml b/Linphone/view/Item/FormComboBoxCell.qml deleted file mode 100644 index bcf9b94e..00000000 --- a/Linphone/view/Item/FormComboBoxCell.qml +++ /dev/null @@ -1,77 +0,0 @@ -import QtQuick -import QtQuick.Controls -import QtQuick.Layouts 1.0 -import Linphone - -ColumnLayout { - id: cellLayout - property string label: "" - property int backgroundWidth: 200 - property variant modelList: [] - - Layout.bottomMargin: 8 - Text { - verticalAlignment: Text.AlignVCenter - text: cellLayout.label - color: DefaultStyle.formItemLabelColor - font { - pointSize: DefaultStyle.formItemLabelSize - bold: true - } - } - - ComboBox { - id: combobox - model: cellLayout.modelList - background: Loader { - sourceComponent: backgroundRectangle - } - contentItem: Text { - leftPadding: 10 - text: combobox.displayText - font.family: DefaultStyle.defaultFont - font.pointSize: DefaultStyle.formItemLabelSize - color: DefaultStyle.formItemLabelColor - verticalAlignment: Text.AlignVCenter - elide: Text.ElideRight - } - - indicator: Image { - x: combobox.width - width - combobox.rightPadding - y: combobox.topPadding + (combobox.availableHeight - height) / 2 - source: AppIcons.downArrow - // width: 12 - // height: 8 - } - - popup: Popup { - y: combobox.height - 1 - width: combobox.width - implicitHeight: contentItem.implicitHeight - padding: 1 - - contentItem: ListView { - clip: true - implicitHeight: contentHeight - model: combobox.popup.visible ? combobox.delegateModel : null - currentIndex: combobox.highlightedIndex - - ScrollIndicator.vertical: ScrollIndicator { } - } - - background: Loader { - sourceComponent: backgroundRectangle - } - } - Component { - id: backgroundRectangle - Rectangle { - implicitWidth: cellLayout.backgroundWidth - implicitHeight: 30 - radius: 20 - color: DefaultStyle.formItemBackgroundColor - opacity: 0.7 - } - } - } -} \ No newline at end of file diff --git a/Linphone/view/Item/FormTextInputCell.qml b/Linphone/view/Item/FormTextInputCell.qml deleted file mode 100644 index 9a117a33..00000000 --- a/Linphone/view/Item/FormTextInputCell.qml +++ /dev/null @@ -1,62 +0,0 @@ -import QtQuick -import QtQuick.Controls -import QtQuick.Layouts 1.0 -import Linphone - -ColumnLayout { - id: cellLayout - Layout.bottomMargin: 8 - - property string label: "" - property string defaultText : "" - property bool mandatory: false - property bool hidden: false - property int textInputWidth: 200 - readonly property string inputText: textField.text - - Text { - verticalAlignment: Text.AlignVCenter - text: cellLayout.label + (cellLayout.mandatory ? "*" : "") - color: DefaultStyle.formItemLabelColor - font { - pointSize: DefaultStyle.formItemLabelSize - bold: true - } - } - - Rectangle { - implicitWidth: cellLayout.textInputWidth - implicitHeight: 30 - // anchors.fill: parent - radius: 20 - color: DefaultStyle.formItemBackgroundColor - opacity: 0.7 - TextField { - id: textField - anchors.left: parent.left - anchors.right: eyeButton.visible ? eyeButton.left : parent.right - anchors.verticalCenter: parent.verticalCenter - placeholderText: cellLayout.defaultText - echoMode: (cellLayout.hidden && !eyeButton.checked) ? TextInput.Password : TextInput.Normal - font.family: DefaultStyle.defaultFont - font.pointSize: DefaultStyle.formTextInputSize - color: DefaultStyle.formItemLabelColor - background: Item { - opacity: 0. - } - } - Button { - id: eyeButton - visible: cellLayout.hidden - checkable: true - background: Rectangle { - color: "transparent" - } - anchors.right: parent.right - contentItem: Image { - fillMode: Image.PreserveAspectFit - source: eyeButton.checked ? AppIcons.eyeHide : AppIcons.eyeShow - } - } - } -} \ No newline at end of file diff --git a/Linphone/view/Item/PhoneNumberComboBox.qml b/Linphone/view/Item/PhoneNumberComboBox.qml new file mode 100644 index 00000000..a665d5f9 --- /dev/null +++ b/Linphone/view/Item/PhoneNumberComboBox.qml @@ -0,0 +1,149 @@ +import QtQuick +import QtQuick.Controls as Control +import QtQuick.Layouts 1.0 +import Linphone + +ColumnLayout { + id: cellLayout + property string label: "" + property int backgroundWidth: 100 + readonly property string currentText: combobox.model.getAt(combobox.currentIndex) ? combobox.model.getAt(combobox.currentIndex).countryCallingCode : "" + + Text { + visible: label.length > 0 + verticalAlignment: Text.AlignVCenter + text: cellLayout.label + color: DefaultStyle.formItemLabelColor + font { + pointSize: DefaultStyle.formItemLabelSize + bold: true + } + } + + Control.ComboBox { + id: combobox + model: PhoneNumberProxy{} + background: Loader { + sourceComponent: backgroundRectangle + } + contentItem: Item { + anchors.fill: parent + anchors.leftMargin: 5 + Text { + id: chosenItemFlag + text: combobox.model.getAt(combobox.currentIndex) ? combobox.model.getAt(combobox.currentIndex).flag : "" + font.family: 'Noto Color Emoji' + anchors.leftMargin: 5 + anchors.verticalCenter: parent.verticalCenter + } + Text { + id: chosenItemCountry + leftPadding: 5 + text: combobox.model.getAt(combobox.currentIndex) ? "+" + combobox.model.getAt(combobox.currentIndex).countryCallingCode : "" + font.family: DefaultStyle.defaultFont + font.pointSize: DefaultStyle.formItemLabelSize + color: DefaultStyle.formItemLabelColor + anchors.right: parent.right + anchors.left: chosenItemFlag.right + anchors.verticalCenter: parent.verticalCenter + anchors.leftMargin: 5 + elide: Text.ElideRight + } + Item { + Layout.fillWidth: true + } + + } + + indicator: Image { + anchors.verticalCenter: parent.verticalCenter + anchors.right: parent.right + source: AppIcons.downArrow + } + + popup: Control.Popup { + id: listPopup + y: combobox.height - 1 + width: combobox.width + implicitHeight: contentItem.implicitHeight + implicitWidth: contentItem.implicitWidth + padding: 1 + + contentItem: ListView { + id: listView + clip: true + implicitHeight: contentHeight + implicitWidth: contentWidth + model: PhoneNumberProxy{} + currentIndex: combobox.highlightedIndex >= 0 ? combobox.highlightedIndex : 0 + highlightFollowsCurrentItem: true + highlight: highlight + + delegate: Item { + width:combobox.width; + height: combobox.height; + anchors.leftMargin: 5 + Text { + id: delegateImg; + text: $modelData.flag + font.family: 'Noto Color Emoji' + anchors.leftMargin: 5 + } + + Text { + text: "+" + $modelData.countryCallingCode + anchors.top: parent.top + anchors.left: delegateImg.right + anchors.leftMargin: 5 + } + + MouseArea { + anchors.fill: parent + hoverEnabled: true + Rectangle { + anchors.fill: parent + opacity: 0.1 + radius: 15 + color: DefaultStyle.comboBoxHoverColor + visible: parent.containsMouse + } + onPressed: { + listView.currentIndex = index + combobox.currentIndex = index + listPopup.close() + } + } + } + Control.ScrollIndicator.vertical: Control.ScrollIndicator { } + } + + onOpened: { + listView.positionViewAtIndex(listView.currentIndex, ListView.Center) + } + + Component { + id: highlight + Rectangle { + width: listView.width + height: listView.height + color: DefaultStyle.comboBoxHighlightColor + radius: 15 + y: listView.currentItem? listView.currentItem.y : 0 + } + } + + background: Loader { + sourceComponent: backgroundRectangle + } + } + Component { + id: backgroundRectangle + Rectangle { + implicitWidth: cellLayout.backgroundWidth + implicitHeight: 30 + radius: 15 + color: DefaultStyle.formItemBackgroundColor + } + } + } +} \ No newline at end of file diff --git a/Linphone/view/Item/PhoneNumberInput.qml b/Linphone/view/Item/PhoneNumberInput.qml new file mode 100644 index 00000000..c320e231 --- /dev/null +++ b/Linphone/view/Item/PhoneNumberInput.qml @@ -0,0 +1,56 @@ +import QtQuick +import QtQuick.Controls +import QtQuick.Layouts 1.0 +import Linphone + +ColumnLayout { + id: cellLayout + + property string label: "" + property string defaultText : "" + property bool mandatory: false + property int textInputWidth: 200 + readonly property string phoneNumber: textField.inputText + readonly property string countryCode: combobox.currentText + + Text { + visible: label.length > 0 + verticalAlignment: Text.AlignVCenter + text: cellLayout.label + (cellLayout.mandatory ? "*" : "") + color: DefaultStyle.formItemLabelColor + font { + pointSize: DefaultStyle.formItemLabelSize + bold: true + } + } + + Rectangle { + implicitWidth: cellLayout.textInputWidth + implicitHeight: 30 + radius: 20 + color: DefaultStyle.formItemBackgroundColor + RowLayout { + anchors.fill: parent + PhoneNumberComboBox { + id: combobox + backgroundWidth: 100 + } + Rectangle { + + width: 1 + Layout.fillHeight: true + Layout.topMargin: 5 + Layout.bottomMargin: 5 + color: DefaultStyle.defaultTextColor + } + TextInput { + id: textField + Layout.fillWidth: true + defaultText: cellLayout.defaultText + inputMethodHints: Qt.ImhDigitsOnly + fillWidth: true + validator: IntValidator{} + } + } + } +} \ No newline at end of file diff --git a/Linphone/view/Item/TabBar.qml b/Linphone/view/Item/TabBar.qml new file mode 100644 index 00000000..31dd3a5a --- /dev/null +++ b/Linphone/view/Item/TabBar.qml @@ -0,0 +1,64 @@ +import QtQuick 2.7 +import QtQuick.Layouts 1.3 +import QtQuick.Controls 2.2 as Control +import Linphone + +Control.TabBar { + id: bar + spacing: 40 + + function appendTab(label) { + var newTab = tab.createObject(bar, {title: label, index: bar.count}) + } + + background: Item { + anchors.fill: parent + + Rectangle { + id: barBG + height: 4 + color: DefaultStyle.lightGrayColor + anchors.bottom: parent.bottom + width: parent.width + } + + Rectangle { + height: 4 + color: DefaultStyle.orangeColor + anchors.bottom: parent.bottom + x: bar.currentItem ? bar.currentItem.x : 0 + width: bar.currentItem ? bar.currentItem.width : 0 + clip: true + Behavior on x { NumberAnimation {duration: 100}} + } + } + + Component { + id: tab + Control.TabButton { + property string title + property int index + width: txtMeter. advanceWidth + + background: Item { + visible: false + } + + contentItem: Text { + id: tabText + anchors.fill: parent + font.bold: true + font.pointSize: DefaultStyle.tabButtonTextSize + text: txtMeter.text + bottomPadding: 5 + width: txtMeter.advanceWidth + } + + TextMetrics { + id: txtMeter + font: tabText.font + text: title + } + } + } +} \ No newline at end of file diff --git a/Linphone/view/Item/Text.qml b/Linphone/view/Item/Text.qml index 7289ebee..bbe13b4f 100644 --- a/Linphone/view/Item/Text.qml +++ b/Linphone/view/Item/Text.qml @@ -6,5 +6,6 @@ Text { property double scaleLettersFactor: 1. font.family: DefaultStyle.defaultFont font.pointSize: DefaultStyle.defaultFontPointSize + color: DefaultStyle.defaultTextColor transform: Scale { yScale: scaleLettersFactor} } diff --git a/Linphone/view/Item/TextInput.qml b/Linphone/view/Item/TextInput.qml index 9a117a33..4550a869 100644 --- a/Linphone/view/Item/TextInput.qml +++ b/Linphone/view/Item/TextInput.qml @@ -5,16 +5,19 @@ import Linphone ColumnLayout { id: cellLayout - Layout.bottomMargin: 8 property string label: "" property string defaultText : "" property bool mandatory: false property bool hidden: false property int textInputWidth: 200 + property var inputMethodHints: Qt.ImhNone + property var validator: RegularExpressionValidator{} readonly property string inputText: textField.text + property bool fillWidth: false Text { + visible: label.length > 0 verticalAlignment: Text.AlignVCenter text: cellLayout.label + (cellLayout.mandatory ? "*" : "") color: DefaultStyle.formItemLabelColor @@ -25,9 +28,12 @@ ColumnLayout { } Rectangle { + Component.onCompleted: { + if (cellLayout.fillWidth) + Layout.fillWidth = true + } implicitWidth: cellLayout.textInputWidth implicitHeight: 30 - // anchors.fill: parent radius: 20 color: DefaultStyle.formItemBackgroundColor opacity: 0.7 @@ -41,6 +47,13 @@ ColumnLayout { font.family: DefaultStyle.defaultFont font.pointSize: DefaultStyle.formTextInputSize color: DefaultStyle.formItemLabelColor + inputMethodHints: cellLayout.inputMethodHints + selectByMouse: true + validator: cellLayout.validator + // MouseArea { + // anchors.fill: parent + // // acceptedButtons: Qt.NoButton + // } background: Item { opacity: 0. } diff --git a/Linphone/view/Page/Login/LoginItem.qml b/Linphone/view/Page/Login/LoginItem.qml new file mode 100644 index 00000000..33343b34 --- /dev/null +++ b/Linphone/view/Page/Login/LoginItem.qml @@ -0,0 +1,59 @@ +import QtQuick 2.15 +import QtQuick.Layouts 1.0 +import QtQuick.Controls as Control +import Linphone + +RowLayout { + Layout.alignment: Qt.AlignBottom + ColumnLayout { + FormTextInputCell { + id: username + label: "Username" + mandatory: true + textInputWidth: 250 + } + FormTextInputCell { + id: password + label: "Password" + mandatory: true + hidden: true + textInputWidth: 250 + } + + RowLayout { + id: lastFormLineLayout + Button { + text: 'Log in' + Layout.rightMargin: 20 + onClicked: { + console.debug("[LoginItem] User: Log in") + LoginPageCpp.login(username.inputText, password.inputText); + } + } + Text { + color: DefaultStyle.grayColor + text: "Forgotten password?" + font.underline: true + font.pointSize: DefaultStyle.defaultTextSize + } + + } + Button { + Layout.topMargin: 40 + inversedColors: true + text: "Use SIP Account" + onClicked: { + console.debug("[LoginItem] User: click use Sip") + root.useSIP()} + } + } + Item { + Layout.fillWidth: true + } + Image { + Layout.rightMargin: 40 + Layout.preferredWidth: 300 + fillMode: Image.PreserveAspectFit + source: AppIcons.loginImage + } +} diff --git a/Linphone/view/Page/Login/LoginLayout.qml b/Linphone/view/Page/Login/LoginLayout.qml index 6f89c9b1..4dd1930c 100644 --- a/Linphone/view/Page/Login/LoginLayout.qml +++ b/Linphone/view/Page/Login/LoginLayout.qml @@ -32,7 +32,7 @@ Item { fillMode: Image.PreserveAspectFit source: AppIcons.info } - onClicked: console.debug("[LoginLayout] open about popup") + onClicked: console.debug("[LoginLayout] Userr: open about popup") } Text { @@ -60,7 +60,7 @@ Item { Image { Layout.minimumHeight: 80 Layout.fillWidth: true - source: AppIcons.belldonne + source: AppIcons.belledonne fillMode: Image.Stretch } diff --git a/Linphone/view/Page/Login/LoginPage.qml b/Linphone/view/Page/Login/LoginPage.qml index 203b2535..5cc94eab 100644 --- a/Linphone/view/Page/Login/LoginPage.qml +++ b/Linphone/view/Page/Login/LoginPage.qml @@ -6,6 +6,7 @@ import Linphone LoginLayout { id: mainItem signal useSIPButtonClicked() + signal goToRegister() titleContent: RowLayout { Image { @@ -14,7 +15,6 @@ LoginLayout { } Text { text: "Login" - color: DefaultStyle.titleColor font.pointSize: DefaultStyle.title2FontPointSize font.bold: true scaleLettersFactor: 1.1 @@ -25,13 +25,16 @@ LoginLayout { Text { Layout.rightMargin: 15 text: "No account yet ?" - color: DefaultStyle.defaultTextColor font.pointSize: DefaultStyle.defaultTextSize } Button { Layout.alignment: Qt.AlignRight inversedColors: true text: "Register" + onClicked: { + console.debug("[LoginPage] User: go to register") + mainItem.goToRegister() + } } } diff --git a/Linphone/view/Page/Login/RegisterCheckingPage.qml b/Linphone/view/Page/Login/RegisterCheckingPage.qml new file mode 100644 index 00000000..731437d6 --- /dev/null +++ b/Linphone/view/Page/Login/RegisterCheckingPage.qml @@ -0,0 +1,112 @@ +import QtQuick 2.15 +import QtQuick.Layouts 1.3 +import QtQuick.Controls as Control +import Linphone + +LoginLayout { + + id: mainItem + signal returnToRegister() + property string phoneNumber + property string email + + titleContent: RowLayout { + Control.Button { + background: Rectangle { + color: "transparent" + } + contentItem: Image { + source: AppIcons.returnArrow + fillMode: Image.PreserveAspectFit + } + onClicked: { + console.debug("[RegisterCheckingPage] User: return to register") + mainItem.returnToRegister() + } + } + Image { + fillMode: Image.PreserveAspectFit + source: AppIcons.profile + } + Text { + text: { + var completeString = (mainItem.email.length > 0) ? "email" : "phone number" + text = "Register | Register with your " + completeString + } + font.pointSize: DefaultStyle.title2FontPointSize + font.bold: true + scaleLettersFactor: 1.1 + } + Item { + Layout.fillWidth: true + } + } + + centerContent: ColumnLayout { + Layout.fillWidth: true + Layout.fillHeight: true + Text { + Layout.alignment: Qt.AlignTop + font.bold: true + text: { + var completeString = (mainItem.email.length > 0) ? ("email" + mainItem.email) : ("phone number" + mainItem.phoneNumber) + text = "We have sent a verification code on your " + completeString + "
Please enter the verification code below:" + } + } + RowLayout { + Layout.fillWidth: true + Layout.margins: 10 + ColumnLayout { + RowLayout { + // Layout.fillWidth: true + DigitInput { + id: first + onTextEdited: if (text.length > 0 ) second.forceActiveFocus() + Layout.margins: 10 + } + DigitInput { + id: second + onTextEdited: if (text.length > 0 ) third.forceActiveFocus() + Layout.margins: 10 + } + DigitInput { + id: third + onTextEdited: if (text.length > 0 ) fourth.forceActiveFocus() + Layout.margins: 10 + } + DigitInput { + id: fourth + Layout.margins: 10 + // onTextEdited: validate() + } + } + RowLayout { + // Layout.topMargin: 10 + Text { + Layout.rightMargin: 15 + text: "Didn't receive the code ?" + font.pointSize: DefaultStyle.defaultTextSize + } + Button { + Layout.alignment: Qt.AlignRight + inversedColors: true + text: "Resend a code" + onClicked: { + console.debug("[RegisterCheckingPage] User: Resend code") + } + } + } + } + Item { + Layout.fillWidth: true + } + Image { + Layout.rightMargin: 40 + Layout.preferredWidth: 300 + fillMode: Image.PreserveAspectFit + source: AppIcons.verif_page_image + } + } + } +} + diff --git a/Linphone/view/Page/Login/RegisterPage.qml b/Linphone/view/Page/Login/RegisterPage.qml new file mode 100644 index 00000000..068b5683 --- /dev/null +++ b/Linphone/view/Page/Login/RegisterPage.qml @@ -0,0 +1,196 @@ +import QtQuick 2.15 +import QtQuick.Layouts 1.3 +import QtQuick.Controls as Control +import Linphone + +LoginLayout { + + id: registerPage + signal returnToLogin() + signal registerCalled() + readonly property string countryCode: phoneNumberInput.countryCode + readonly property string phoneNumber: phoneNumberInput.phoneNumber + readonly property string email: emailInput.inputText + + titleContent: RowLayout { + Image { + fillMode: Image.PreserveAspectFit + source: AppIcons.profile + } + Text { + text: "Register" + font.pointSize: DefaultStyle.title2FontPointSize + font.bold: true + scaleLettersFactor: 1.1 + } + Item { + Layout.fillWidth: true + } + Text { + Layout.rightMargin: 15 + text: "Already have an account ?" + font.pointSize: DefaultStyle.defaultTextSize + } + Button { + Layout.alignment: Qt.AlignRight + inversedColors: true + text: "Log in" + onClicked: { + console.debug("[LoginItem] User: return") + returnToLogin()} + } + } + + centerContent: ColumnLayout { + TabBar { + Layout.fillWidth: true + id: bar + Component.onCompleted: { + appendTab(qsTr("Register with phone number")) + appendTab(qsTr("Register with email")) + + } + } + StackLayout { + currentIndex: bar.currentIndex + RowLayout { + ColumnLayout { + Layout.fillWidth: true + Layout.fillHeight: true + RowLayout { + TextInput { + label: "Username" + mandatory: true + textInputWidth: 250 + } + ComboBox { + label: " " + modelList: [{text:"@sip.linphone.org"}] + } + } + PhoneNumberInput { + id: phoneNumberInput + label: "Phone number" + mandatory: true + defaultText: "Phone number" + textInputWidth: 250 + } + RowLayout { + TextInput { + label: "Password" + mandatory: true + hidden: true + textInputWidth: 250 + } + TextInput { + label: "Confirm password" + mandatory: true + hidden: true + textInputWidth: 250 + } + } + RowLayout { + CheckBox { + } + Text { + text: "I would like to suscribe to the newsletter" + } + } + RowLayout { + CheckBox { + } + Text { + text: "I accept the Terms and Conditions : Read the Terms and Conditions.
I accept the Privacy policy : Read the Privacy policy." + } + } + Button { + text: "Register" + onClicked:{ + console.log("[RegisterPage] User: Call register") + registerPage.registerCalled() + } + } + } + Item { + Layout.fillWidth: true + } + Image { + Layout.rightMargin: 40 + Layout.preferredWidth: 300 + fillMode: Image.PreserveAspectFit + source: AppIcons.loginImage + } + } + RowLayout { + ColumnLayout { + Layout.fillWidth: true + Layout.fillHeight: true + RowLayout { + TextInput { + label: "Username" + mandatory: true + textInputWidth: 250 + } + ComboBox { + // if we don't set a label this item is offset + // due to the invisibility of the upper label + label: " " + modelList: [{text:"@sip.linphone.org"}] + } + } + TextInput { + id: emailInput + label: "Email" + mandatory: true + textInputWidth: 250 + } + RowLayout { + TextInput { + label: "Password" + mandatory: true + hidden: true + textInputWidth: 250 + } + TextInput { + label: "Confirm password" + mandatory: true + hidden: true + textInputWidth: 250 + } + } + RowLayout { + CheckBox { + } + Text { + text: "I would like to suscribe to the newsletter" + } + } + RowLayout { + CheckBox { + } + Text { + text: "I accept the Terms and Conditions : Read the Terms and Conditions.
I accept the Privacy policy : Read the Privacy policy." + } + } + Button { + text: "Register" + onClicked:{ + console.log("[RegisterPage] User: Call register") + registerPage.registerCalled() + } + } + } + Item { + Layout.fillWidth: true + } + Image { + Layout.rightMargin: 40 + Layout.preferredWidth: 300 + fillMode: Image.PreserveAspectFit + source: AppIcons.loginImage + } + } + } + } +} + diff --git a/Linphone/view/Page/Login/SIPLoginPage.qml b/Linphone/view/Page/Login/SIPLoginPage.qml index 544a5a1c..b406e87b 100644 --- a/Linphone/view/Page/Login/SIPLoginPage.qml +++ b/Linphone/view/Page/Login/SIPLoginPage.qml @@ -8,6 +8,7 @@ LoginLayout { id: sipLoginPage signal returnToLogin() + signal goToRegister() titleContent: RowLayout { Control.Button { @@ -18,7 +19,10 @@ LoginLayout { source: AppIcons.returnArrow fillMode: Image.PreserveAspectFit } - onClicked: sipLoginPage.returnToLogin() + onClicked: { + console.debug("[LoginItem] User: return") + sipLoginPage.returnToLogin() + } } Image { fillMode: Image.PreserveAspectFit @@ -26,7 +30,6 @@ LoginLayout { } Text { text: "Use a SIP Account" - color: DefaultStyle.titleColor font.pointSize: DefaultStyle.title2FontPointSize font.bold: true scaleLettersFactor: 1.1 @@ -37,13 +40,16 @@ LoginLayout { Text { Layout.rightMargin: 15 text: "No account yet ?" - color: DefaultStyle.defaultTextColor font.pointSize: DefaultStyle.defaultTextSize } Button { Layout.alignment: Qt.AlignRight inversedColors: true text: "Register" + onClicked: { + console.debug("[SIPLoginPage] User: go to register page") + sipLoginPage.goToRegister() + } } } @@ -92,6 +98,8 @@ LoginLayout { text: 'I prefere create an account' inversedColors: true onClicked: { + console.debug("[LoginItem] User: click register") + sipLoginPage.goToRegister() } } @@ -136,7 +144,11 @@ LoginLayout { ComboBox { label: "Transport" backgroundWidth: 250 - modelList: ["TCP", "UDP", "TLS"] + modelList:[ + {text:"TCP"}, + {text:"UDP"}, + {text:"TLS"} + ] } Button { @@ -144,6 +156,7 @@ LoginLayout { text: 'Log in' onClicked: { + console.debug("[LoginItem] User: Log in") LoginPageCpp.login(username.inputText, password.inputText); } } diff --git a/Linphone/view/Page/Login/WelcomePage.qml b/Linphone/view/Page/Login/WelcomePage.qml index 179aa11e..9e642c38 100644 --- a/Linphone/view/Page/Login/WelcomePage.qml +++ b/Linphone/view/Page/Login/WelcomePage.qml @@ -44,9 +44,11 @@ LoginLayout { contentItem: Text { text: "Skip" font.underline: true - color: DefaultStyle.defaultTextColor } - onClicked: welcomePage.startButtonPressed(); + onClicked: { + console.debug("[LoginItem] User: Click skip") + welcomePage.startButtonPressed() + } } } centerContent: ColumnLayout { @@ -73,14 +75,12 @@ LoginLayout { text: "Linphone" font.bold: true font.pixelSize: 20 - color: DefaultStyle.defaultTextColor scaleLettersFactor: 1.1 } Text { Layout.maximumWidth: 361 wrapMode: Text.WordWrap font.pixelSize: 11 - color: DefaultStyle.defaultTextColor text: "Une application de communication sécurisée,
open source et française. " } } @@ -95,13 +95,11 @@ LoginLayout { text: "Sécurisé" font.bold: true font.pixelSize: 20 - color: DefaultStyle.defaultTextColor } Text { Layout.maximumWidth: 361 wrapMode: Text.WordWrap font.pixelSize: 11 - color: DefaultStyle.defaultTextColor text: "Vos communications sont en sécurité grâce aux
Chiffrement de bout en bout." } } @@ -116,13 +114,11 @@ LoginLayout { text: "Open Source" font.bold: true font.pixelSize: 20 - color: DefaultStyle.defaultTextColor } Text { Layout.maximumWidth: 361 wrapMode: Text.WordWrap font.pixelSize: 11 - color: DefaultStyle.defaultTextColor text: "Une application open source et un service gratuit depuis 2001" } } diff --git a/Linphone/view/Style/AppIcons.qml b/Linphone/view/Style/AppIcons.qml index ed0d5ae5..2696f13f 100644 --- a/Linphone/view/Style/AppIcons.qml +++ b/Linphone/view/Style/AppIcons.qml @@ -2,15 +2,17 @@ pragma Singleton import QtQuick 2.15 QtObject { - property string welcomeLinphoneLogo: "image://internal/welcome-linphone-logo.svg" - property string welcomeLock: "image://internal/welcome-lock.svg" - property string welcomeOpenSource: "image://internal/welcome-opensource.svg" - property string eyeHide: "image://internal/hide.svg" - property string eyeShow: "image://internal/show.svg" - property string downArrow: "image://internal/down-arrow.svg" - property string returnArrow: "image://internal/return-arrow.svg" - property string info: "image://internal/info-logo.svg" - property string loginImage: "image://internal/login-image.svg" + property string welcomeLinphoneLogo: "image://internal/linphone.svg" + property string welcomeLock: "image://internal/secured.svg" + property string welcomeOpenSource: "image://internal/open_source.svg" + property string eyeHide: "image://internal/eye.svg" + property string eyeShow: "image://internal/eye-slash.svg" + property string downArrow: "image://internal/caret-down.svg" + property string returnArrow: "image://internal/caret-left.svg" + property string info: "image://internal/info.svg" + property string loginImage: "image://internal/login_image.svg" property string belledonne: "image://internal/belledonne.svg" - property string profile: "image://internal/profil.svg" + property string profile: "image://internal/user-circle.svg" + property string verif_page_image: "image://internal/verif_page_image.svg" + property string check: "image://internal/check.svg" } diff --git a/Linphone/view/Style/DefaultStyle.qml b/Linphone/view/Style/DefaultStyle.qml index a4e3cf24..93fce568 100644 --- a/Linphone/view/Style/DefaultStyle.qml +++ b/Linphone/view/Style/DefaultStyle.qml @@ -9,19 +9,29 @@ QtObject { property color buttonInversedBackground: "white" property color buttonTextColor: "white" property color buttonInversedTextColor: "#FE5E00" + property color checkboxBorderColor: "#FE5E00" + property double checkboxBorderWidth: 2 property int buttonTextSize: 10 - property color darkBlueColor: "#22334D" + property int tabButtonTextSize: 11 property color titleColor: "#22334D" - property color darkGrayColor: "#4E6074" property color defaultTextColor: "#4E6074" property int defaultTextSize: 8 property color formItemLabelColor: "#4E6074" property int formItemLabelSize: 8 property int formTextInputSize: 10 - property color grayColor: "#6C7A87" - property color lightGrayColor: "#EDEDED" property color carouselLightGrayColor: "#DFECF2" property color formItemBackgroundColor: "#EDEDED" + property color comboBoxHighlightColor: "#C0D1D9" + property color comboBoxHoverColor: "#6C7A87" + + property color digitInputFocusedColor: "#FE5E00" + property color digitInputColor: "#6C7A87" + + property color darkBlueColor: "#22334D" + property color darkGrayColor: "#4E6074" + property color grayColor: "#6C7A87" + property color lightGrayColor: "#EDEDED" + property int defaultFontPointSize: 10 property int title1FontPointSize: 40 property int title2FontPointSize: 20