From db35d67a707073b6e8843d3855390a942d04582b Mon Sep 17 00:00:00 2001 From: Gaelle Braud Date: Thu, 9 Jan 2025 14:55:43 +0100 Subject: [PATCH] UI fixes: - button style + icons - try to fix mac text edition error - disabled color considering lightness - fix #LINQT-1524 avatar secured border - fix #LINQT-1525 padding add participant form - fix #LINQT-1537 more options menu in call - fix #LINQT-1538 floating header in parameters - fix #LINQT-1539 display name in conf info participants list - fix #LINQT-1462 rm waiting time --- .../core/conference/ConferenceInfoCore.cpp | 9 +- Linphone/data/image/Display mode.svg | 3 - Linphone/data/image/address-book.svg | 2 +- .../data/image/arrow-bend-up-left-bold.svg | 1 - .../data/image/arrow-bend-up-right-bold.svg | 1 - Linphone/data/image/arrow-clockwise.svg | 2 +- Linphone/data/image/arrow-right-fill.svg | 1 - Linphone/data/image/arrows-merge.svg | 2 +- Linphone/data/image/bell-dnd.svg | 4 +- Linphone/data/image/bell-mwi.svg | 3 - Linphone/data/image/bell-ringing.svg | 1 - Linphone/data/image/bell-simple-slash.svg | 1 - Linphone/data/image/bell-simple.svg | 2 +- Linphone/data/image/bell-slash.svg | 1 + Linphone/data/image/bluetooth.svg | 2 +- Linphone/data/image/calendar-blank.svg | 2 +- Linphone/data/image/calendar.svg | 3 - Linphone/data/image/camera-rotate.svg | 2 +- Linphone/data/image/camera.svg | 2 +- Linphone/data/image/caret-down.svg | 2 +- Linphone/data/image/caret-left.svg | 2 +- Linphone/data/image/caret-right.svg | 2 +- Linphone/data/image/caret-up.svg | 2 +- Linphone/data/image/chat-dots.svg | 2 +- Linphone/data/image/chat-teardrop-slash.svg | 2 +- Linphone/data/image/chat-teardrop-text.svg | 2 +- Linphone/data/image/chat-text.svg | 2 +- Linphone/data/image/check.svg | 2 +- Linphone/data/image/checks.svg | 2 +- Linphone/data/image/clock-countdown.svg | 2 +- Linphone/data/image/clock.svg | 2 +- Linphone/data/image/copy.svg | 2 +- Linphone/data/image/debug.svg | 3 - Linphone/data/image/desktop.svg | 4 +- Linphone/data/image/detective.svg | 2 +- Linphone/data/image/device-mobile-camera.svg | 1 + Linphone/data/image/dialer-selected.svg | 3 - Linphone/data/image/dialer.svg | 3 - Linphone/data/image/dots-three-vertical.svg | 2 +- Linphone/data/image/ear.svg | 2 +- Linphone/data/image/empty.svg | 3 - Linphone/data/image/envelope-simple-open.svg | 2 +- Linphone/data/image/envelope-simple.svg | 2 +- Linphone/data/image/eye-slash.svg | 2 +- Linphone/data/image/eye.svg | 2 +- Linphone/data/image/file-text.svg | 2 +- Linphone/data/image/fullscreen.svg | 4 +- Linphone/data/image/funnel.svg | 2 +- Linphone/data/image/gear.svg | 2 +- Linphone/data/image/globe-hemisphere-west.svg | 2 +- Linphone/data/image/hand-waving.svg | 4 +- Linphone/data/image/headset.svg | 2 +- Linphone/data/image/heart.svg | 2 +- .../data/image/incoming_call_rejected.svg | 3 - Linphone/data/image/info.svg | 2 +- Linphone/data/image/keyboard.svg | 2 +- Linphone/data/image/magnifying-glass.svg | 2 +- Linphone/data/image/microphone-slash.svg | 2 +- Linphone/data/image/microphone-stage.svg | 2 +- Linphone/data/image/microphone.svg | 2 +- Linphone/data/image/mobile.svg | 3 - Linphone/data/image/monitor-arrow-up.svg | 2 +- Linphone/data/image/more.svg | 3 - Linphone/data/image/note.svg | 4 +- Linphone/data/image/numpad.svg | 1 + .../data/image/outgoing_call_rejected.svg | 3 - Linphone/data/image/package.svg | 1 + Linphone/data/image/paper-plane-tilt.svg | 2 +- Linphone/data/image/paperclip.svg | 2 +- Linphone/data/image/pause.svg | 2 +- Linphone/data/image/pencil-simple.svg | 2 +- Linphone/data/image/picture-in-picture.svg | 1 + Linphone/data/image/pip.svg | 3 - Linphone/data/image/play.svg | 2 +- Linphone/data/image/plus-circle.svg | 2 +- Linphone/data/image/power.svg | 4 +- Linphone/data/image/qr-code.svg | 2 +- Linphone/data/image/resource-package.svg | 3 - Linphone/data/image/settings.svg | 3 - Linphone/data/image/share-network.svg | 2 +- Linphone/data/image/shield-warning.svg | 4 +- Linphone/data/image/sign-out.svg | 2 +- Linphone/data/image/slideshow.svg | 2 +- Linphone/data/image/smiley-sad.svg | 4 +- Linphone/data/image/smiley.svg | 4 +- Linphone/data/image/speaker-high.svg | 2 +- Linphone/data/image/speaker-slash.svg | 2 +- Linphone/data/image/squares-four.svg | 4 +- Linphone/data/image/trash-simple.svg | 2 +- Linphone/data/image/user-circle-gear.svg | 2 +- Linphone/data/image/user-circle.svg | 2 +- Linphone/data/image/user-plus.svg | 2 +- Linphone/data/image/user-square.svg | 2 +- Linphone/data/image/users-three.svg | 2 +- Linphone/data/image/users.svg | 2 +- Linphone/data/image/video-camera-slash.svg | 2 +- Linphone/data/image/video-camera.svg | 2 +- Linphone/data/image/voicemail.svg | 4 +- Linphone/data/image/warning-circle.svg | 2 +- Linphone/data/image/waveform.svg | 4 +- Linphone/data/image/wifi-high.svg | 1 - Linphone/data/image/wifi-low.svg | 1 - Linphone/data/image/wrench.svg | 2 +- Linphone/data/image/x-circle.svg | 1 + Linphone/data/image/x.svg | 2 +- Linphone/view/CMakeLists.txt | 2 +- Linphone/view/Control/Button/BigButton.qml | 17 ++ Linphone/view/Control/Button/Button.qml | 66 +++-- Linphone/view/Control/Button/CheckBox.qml | 29 +- .../view/Control/Button/CheckableButton.qml | 25 +- Linphone/view/Control/Button/ComboBox.qml | 25 +- .../Button/CountryIndicatorCombobox.qml | 5 +- .../view/Control/Button/IconLabelButton.qml | 114 +++----- Linphone/view/Control/Button/MediumButton.qml | 6 +- Linphone/view/Control/Button/MenuButton.qml | 18 -- Linphone/view/Control/Button/PopupButton.qml | 16 +- Linphone/view/Control/Button/RoundButton.qml | 20 ++ Linphone/view/Control/Button/SmallButton.qml | 2 + .../Container/Call/CallHistoryLayout.qml | 64 ++-- .../Control/Container/Call/CallLayout.qml | 11 +- .../Container/Contact/ContactLayout.qml | 5 +- .../view/Control/Container/VerticalTabBar.qml | 4 +- .../Control/Display/Call/CallListView.qml | 15 +- .../view/Control/Display/Contact/Avatar.qml | 19 +- .../Display/Contact/ContactListItem.qml | 57 +--- .../Display/Contact/ContactListView.qml | 4 +- .../Display/Meeting/MeetingListView.qml | 10 +- .../Participant/ParticipantListView.qml | 17 +- Linphone/view/Control/Display/ProgressBar.qml | 5 +- Linphone/view/Control/Display/Sticker.qml | 32 +- Linphone/view/Control/Display/Text.qml | 1 + .../view/Control/Form/Login/LoginForm.qml | 24 +- .../Form/Settings/EncryptionSettings.qml | 5 +- .../Form/Settings/ScreencastSettings.qml | 1 + Linphone/view/Control/Input/Calendar.qml | 4 +- Linphone/view/Control/Input/NumericPad.qml | 49 ++-- Linphone/view/Control/Input/SearchBar.qml | 25 +- Linphone/view/Control/Input/TextField.qml | 4 +- .../Popup/Dialog/AuthenticationDialog.qml | 7 +- Linphone/view/Control/Popup/Dialog/Dialog.qml | 17 +- .../Popup/Dialog/ZrtpAuthenticationDialog.qml | 86 ++---- .../Control/Popup/Loading/LoadingPopup.qml | 3 +- .../Notification/NotificationReceivedCall.qml | 12 +- .../view/Control/Popup/NumericPadPopup.qml | 9 +- Linphone/view/Page/Form/Call/NewCallForm.qml | 6 +- .../view/Page/Form/Contact/ContactEdition.qml | 27 +- Linphone/view/Page/Form/Login/LoginPage.qml | 33 +-- .../view/Page/Form/Login/SIPLoginPage.qml | 50 +--- .../Page/Form/Meeting/AddParticipantsForm.qml | 2 +- .../view/Page/Form/Meeting/MeetingForm.qml | 38 +-- .../Form/Register/RegisterCheckingPage.qml | 21 +- .../view/Page/Form/Register/RegisterPage.qml | 19 +- .../Page/Form/Security/SecurityModePage.qml | 15 +- .../Form/Settings/AbstractSettingsMenu.qml | 6 +- .../view/Page/Layout/Login/LoginLayout.qml | 18 +- Linphone/view/Page/Layout/Main/MainLayout.qml | 70 ++--- .../Settings/AbstractSettingsLayout.qml | 81 ++--- .../Settings/AccountSettingsGeneralLayout.qml | 42 ++- .../Settings/AdvancedSettingsLayout.qml | 1 + .../Layout/Settings/CarddavSettingsLayout.qml | 5 +- .../ContactsSettingsProviderLayout.qml | 7 +- .../Layout/Settings/DebugSettingsLayout.qml | 8 +- .../Layout/Settings/LdapSettingsLayout.qml | 3 +- Linphone/view/Page/Main/AbstractMainPage.qml | 12 +- Linphone/view/Page/Main/Call/CallPage.qml | 91 ++---- .../view/Page/Main/Call/CallSettingsPanel.qml | 18 +- Linphone/view/Page/Main/Call/WaitingRoom.qml | 26 +- .../view/Page/Main/Contact/ContactPage.qml | 123 +++----- Linphone/view/Page/Main/Help/HelpPage.qml | 14 +- .../view/Page/Main/Meeting/MeetingPage.qml | 136 +++------ Linphone/view/Page/Main/Start/WelcomePage.qml | 17 +- Linphone/view/Page/Window/AbstractWindow.qml | 14 +- .../view/Page/Window/Call/CallsWindow.qml | 125 ++++---- Linphone/view/Page/Window/Main/MainWindow.qml | 9 +- Linphone/view/Style/AppIcons.qml | 22 +- Linphone/view/Style/ButtonStyle.qml | 276 ++++++++++++++++++ Linphone/view/Style/DefaultStyle.qml | 9 + Linphone/view/Style/Typography.qml | 29 +- Linphone/view/Test/ItemsTest.qml | 4 - 179 files changed, 1153 insertions(+), 1301 deletions(-) delete mode 100644 Linphone/data/image/Display mode.svg delete mode 100644 Linphone/data/image/arrow-bend-up-left-bold.svg delete mode 100644 Linphone/data/image/arrow-bend-up-right-bold.svg delete mode 100644 Linphone/data/image/arrow-right-fill.svg delete mode 100644 Linphone/data/image/bell-mwi.svg delete mode 100644 Linphone/data/image/bell-ringing.svg delete mode 100644 Linphone/data/image/bell-simple-slash.svg create mode 100644 Linphone/data/image/bell-slash.svg delete mode 100644 Linphone/data/image/calendar.svg delete mode 100644 Linphone/data/image/debug.svg create mode 100644 Linphone/data/image/device-mobile-camera.svg delete mode 100644 Linphone/data/image/dialer-selected.svg delete mode 100644 Linphone/data/image/dialer.svg delete mode 100644 Linphone/data/image/empty.svg delete mode 100644 Linphone/data/image/incoming_call_rejected.svg delete mode 100644 Linphone/data/image/mobile.svg delete mode 100644 Linphone/data/image/more.svg create mode 100644 Linphone/data/image/numpad.svg delete mode 100644 Linphone/data/image/outgoing_call_rejected.svg create mode 100644 Linphone/data/image/package.svg create mode 100644 Linphone/data/image/picture-in-picture.svg delete mode 100644 Linphone/data/image/pip.svg delete mode 100644 Linphone/data/image/resource-package.svg delete mode 100644 Linphone/data/image/settings.svg delete mode 100644 Linphone/data/image/wifi-high.svg delete mode 100644 Linphone/data/image/wifi-low.svg create mode 100644 Linphone/data/image/x-circle.svg create mode 100644 Linphone/view/Control/Button/BigButton.qml delete mode 100644 Linphone/view/Control/Button/MenuButton.qml create mode 100644 Linphone/view/Control/Button/RoundButton.qml create mode 100644 Linphone/view/Style/ButtonStyle.qml diff --git a/Linphone/core/conference/ConferenceInfoCore.cpp b/Linphone/core/conference/ConferenceInfoCore.cpp index f15998487..a3fa4eb62 100644 --- a/Linphone/core/conference/ConferenceInfoCore.cpp +++ b/Linphone/core/conference/ConferenceInfoCore.cpp @@ -388,7 +388,7 @@ void ConferenceInfoCore::addParticipant(const QString &address) { } QVariantMap participant; auto displayNameObj = Utils::getDisplayName(address); - participant["displayName"] = displayNameObj ? displayNameObj->getValue() : ""; + participant["displayNameObj"] = QVariant::fromValue(displayNameObj); participant["address"] = address; participant["role"] = (int)LinphoneEnums::ParticipantRole::Listener; mParticipants.append(participant); @@ -404,7 +404,7 @@ void ConferenceInfoCore::addParticipants(const QStringList &addresses) { if (found == mParticipants.end()) { QVariantMap participant; auto displayNameObj = Utils::getDisplayName(address); - participant["displayName"] = displayNameObj ? displayNameObj->getValue() : ""; + participant["displayNameObj"] = QVariant::fromValue(displayNameObj); participant["address"] = address; participant["role"] = (int)LinphoneEnums::ParticipantRole::Listener; mParticipants.append(participant); @@ -450,9 +450,8 @@ void ConferenceInfoCore::resetParticipants(const QStringList &adresses) { for (auto &address : adresses) { QVariantMap participant; QString name; - auto nameObj = Utils::getDisplayName(address); - if (nameObj) name = nameObj->getValue().toString(); - participant["displayName"] = name; + auto displayNameObj = Utils::getDisplayName(address); + participant["displayNameObj"] = QVariant::fromValue(displayNameObj); participant["address"] = address; participant["role"] = (int)LinphoneEnums::ParticipantRole::Listener; mParticipants.append(participant); diff --git a/Linphone/data/image/Display mode.svg b/Linphone/data/image/Display mode.svg deleted file mode 100644 index a03e362f2..000000000 --- a/Linphone/data/image/Display mode.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/address-book.svg b/Linphone/data/image/address-book.svg index 11cabcde0..9dc0b9ec9 100644 --- a/Linphone/data/image/address-book.svg +++ b/Linphone/data/image/address-book.svg @@ -1 +1 @@ - \ No newline at end of file + \ 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 deleted file mode 100644 index e22cf2edb..000000000 --- a/Linphone/data/image/arrow-bend-up-left-bold.svg +++ /dev/null @@ -1 +0,0 @@ - \ 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 deleted file mode 100644 index 42532ea02..000000000 --- a/Linphone/data/image/arrow-bend-up-right-bold.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/arrow-clockwise.svg b/Linphone/data/image/arrow-clockwise.svg index a8c631b3e..6a0db9e6d 100644 --- a/Linphone/data/image/arrow-clockwise.svg +++ b/Linphone/data/image/arrow-clockwise.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/arrow-right-fill.svg b/Linphone/data/image/arrow-right-fill.svg deleted file mode 100644 index fb031f4b7..000000000 --- a/Linphone/data/image/arrow-right-fill.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/arrows-merge.svg b/Linphone/data/image/arrows-merge.svg index de0f25b86..9bd183b23 100644 --- a/Linphone/data/image/arrows-merge.svg +++ b/Linphone/data/image/arrows-merge.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/bell-dnd.svg b/Linphone/data/image/bell-dnd.svg index 249f53324..2cf5166aa 100644 --- a/Linphone/data/image/bell-dnd.svg +++ b/Linphone/data/image/bell-dnd.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/bell-mwi.svg b/Linphone/data/image/bell-mwi.svg deleted file mode 100644 index 2270c7b47..000000000 --- a/Linphone/data/image/bell-mwi.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/bell-ringing.svg b/Linphone/data/image/bell-ringing.svg deleted file mode 100644 index 0d7b4de7d..000000000 --- a/Linphone/data/image/bell-ringing.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/bell-simple-slash.svg b/Linphone/data/image/bell-simple-slash.svg deleted file mode 100644 index 89c649e7a..000000000 --- a/Linphone/data/image/bell-simple-slash.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/bell-simple.svg b/Linphone/data/image/bell-simple.svg index 1c026c3b7..24fab4f08 100644 --- a/Linphone/data/image/bell-simple.svg +++ b/Linphone/data/image/bell-simple.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/bell-slash.svg b/Linphone/data/image/bell-slash.svg new file mode 100644 index 000000000..9e4cec690 --- /dev/null +++ b/Linphone/data/image/bell-slash.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/bluetooth.svg b/Linphone/data/image/bluetooth.svg index c1133c92f..4645d77c9 100644 --- a/Linphone/data/image/bluetooth.svg +++ b/Linphone/data/image/bluetooth.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/calendar-blank.svg b/Linphone/data/image/calendar-blank.svg index 81024d312..93d0645c8 100644 --- a/Linphone/data/image/calendar-blank.svg +++ b/Linphone/data/image/calendar-blank.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/calendar.svg b/Linphone/data/image/calendar.svg deleted file mode 100644 index d566f699a..000000000 --- a/Linphone/data/image/calendar.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/camera-rotate.svg b/Linphone/data/image/camera-rotate.svg index 742615869..545638c5f 100644 --- a/Linphone/data/image/camera-rotate.svg +++ b/Linphone/data/image/camera-rotate.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/camera.svg b/Linphone/data/image/camera.svg index 7a8d0ac40..cf6dbbf65 100644 --- a/Linphone/data/image/camera.svg +++ b/Linphone/data/image/camera.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/caret-down.svg b/Linphone/data/image/caret-down.svg index 5b5218a2f..42f37b716 100644 --- a/Linphone/data/image/caret-down.svg +++ b/Linphone/data/image/caret-down.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/caret-left.svg b/Linphone/data/image/caret-left.svg index 178311847..a3a1e39a6 100644 --- a/Linphone/data/image/caret-left.svg +++ b/Linphone/data/image/caret-left.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/caret-right.svg b/Linphone/data/image/caret-right.svg index e291c0ebe..81658b07c 100644 --- a/Linphone/data/image/caret-right.svg +++ b/Linphone/data/image/caret-right.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/caret-up.svg b/Linphone/data/image/caret-up.svg index 27a7d9701..dacc592b1 100644 --- a/Linphone/data/image/caret-up.svg +++ b/Linphone/data/image/caret-up.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/chat-dots.svg b/Linphone/data/image/chat-dots.svg index 481d876d2..9f33c69f8 100644 --- a/Linphone/data/image/chat-dots.svg +++ b/Linphone/data/image/chat-dots.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/chat-teardrop-slash.svg b/Linphone/data/image/chat-teardrop-slash.svg index 9a0498463..5faa914e3 100644 --- a/Linphone/data/image/chat-teardrop-slash.svg +++ b/Linphone/data/image/chat-teardrop-slash.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/chat-teardrop-text.svg b/Linphone/data/image/chat-teardrop-text.svg index d07e384d6..c13e529da 100644 --- a/Linphone/data/image/chat-teardrop-text.svg +++ b/Linphone/data/image/chat-teardrop-text.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/chat-text.svg b/Linphone/data/image/chat-text.svg index 6be649cbe..46a7b966d 100644 --- a/Linphone/data/image/chat-text.svg +++ b/Linphone/data/image/chat-text.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/check.svg b/Linphone/data/image/check.svg index 2e308611c..a8d374215 100644 --- a/Linphone/data/image/check.svg +++ b/Linphone/data/image/check.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/checks.svg b/Linphone/data/image/checks.svg index 11d157d02..ffef6e7b9 100644 --- a/Linphone/data/image/checks.svg +++ b/Linphone/data/image/checks.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/clock-countdown.svg b/Linphone/data/image/clock-countdown.svg index 548aeabcd..c59988986 100644 --- a/Linphone/data/image/clock-countdown.svg +++ b/Linphone/data/image/clock-countdown.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/clock.svg b/Linphone/data/image/clock.svg index 18f1a5b97..00079cec2 100644 --- a/Linphone/data/image/clock.svg +++ b/Linphone/data/image/clock.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/copy.svg b/Linphone/data/image/copy.svg index f371da500..1b1334c76 100644 --- a/Linphone/data/image/copy.svg +++ b/Linphone/data/image/copy.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/debug.svg b/Linphone/data/image/debug.svg deleted file mode 100644 index 44aeb17bc..000000000 --- a/Linphone/data/image/debug.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/desktop.svg b/Linphone/data/image/desktop.svg index d4b44c70f..520150f68 100644 --- a/Linphone/data/image/desktop.svg +++ b/Linphone/data/image/desktop.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/detective.svg b/Linphone/data/image/detective.svg index 7eb7f87d2..9afe89dea 100644 --- a/Linphone/data/image/detective.svg +++ b/Linphone/data/image/detective.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/device-mobile-camera.svg b/Linphone/data/image/device-mobile-camera.svg new file mode 100644 index 000000000..ae8b87922 --- /dev/null +++ b/Linphone/data/image/device-mobile-camera.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/dialer-selected.svg b/Linphone/data/image/dialer-selected.svg deleted file mode 100644 index a63e133c0..000000000 --- a/Linphone/data/image/dialer-selected.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/dialer.svg b/Linphone/data/image/dialer.svg deleted file mode 100644 index af811b613..000000000 --- a/Linphone/data/image/dialer.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/dots-three-vertical.svg b/Linphone/data/image/dots-three-vertical.svg index 00e6090fb..7da8986ee 100644 --- a/Linphone/data/image/dots-three-vertical.svg +++ b/Linphone/data/image/dots-three-vertical.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/ear.svg b/Linphone/data/image/ear.svg index 15ff6531c..f92ecfe6a 100644 --- a/Linphone/data/image/ear.svg +++ b/Linphone/data/image/ear.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/empty.svg b/Linphone/data/image/empty.svg deleted file mode 100644 index 08951ccad..000000000 --- a/Linphone/data/image/empty.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/envelope-simple-open.svg b/Linphone/data/image/envelope-simple-open.svg index 5c826c63b..42d30e72f 100644 --- a/Linphone/data/image/envelope-simple-open.svg +++ b/Linphone/data/image/envelope-simple-open.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/envelope-simple.svg b/Linphone/data/image/envelope-simple.svg index ada3da40b..cf757ac7e 100644 --- a/Linphone/data/image/envelope-simple.svg +++ b/Linphone/data/image/envelope-simple.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/eye-slash.svg b/Linphone/data/image/eye-slash.svg index aadbe3ca5..6dc0e47a4 100644 --- a/Linphone/data/image/eye-slash.svg +++ b/Linphone/data/image/eye-slash.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/eye.svg b/Linphone/data/image/eye.svg index 61b225273..36ed4da10 100644 --- a/Linphone/data/image/eye.svg +++ b/Linphone/data/image/eye.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/file-text.svg b/Linphone/data/image/file-text.svg index 0b256101e..05971352c 100644 --- a/Linphone/data/image/file-text.svg +++ b/Linphone/data/image/file-text.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/fullscreen.svg b/Linphone/data/image/fullscreen.svg index ec1742d5f..7b7db6217 100644 --- a/Linphone/data/image/fullscreen.svg +++ b/Linphone/data/image/fullscreen.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/funnel.svg b/Linphone/data/image/funnel.svg index 8ae63bc99..7d2375e67 100644 --- a/Linphone/data/image/funnel.svg +++ b/Linphone/data/image/funnel.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/gear.svg b/Linphone/data/image/gear.svg index 2781afab4..ec3561d42 100644 --- a/Linphone/data/image/gear.svg +++ b/Linphone/data/image/gear.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/globe-hemisphere-west.svg b/Linphone/data/image/globe-hemisphere-west.svg index 61c122a7e..6bdba5060 100644 --- a/Linphone/data/image/globe-hemisphere-west.svg +++ b/Linphone/data/image/globe-hemisphere-west.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/hand-waving.svg b/Linphone/data/image/hand-waving.svg index 2c6a61a85..de80a5fd2 100644 --- a/Linphone/data/image/hand-waving.svg +++ b/Linphone/data/image/hand-waving.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/headset.svg b/Linphone/data/image/headset.svg index 40e5e753e..d58fe7a6b 100644 --- a/Linphone/data/image/headset.svg +++ b/Linphone/data/image/headset.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/heart.svg b/Linphone/data/image/heart.svg index 89f2caf8e..3975961fd 100644 --- a/Linphone/data/image/heart.svg +++ b/Linphone/data/image/heart.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/incoming_call_rejected.svg b/Linphone/data/image/incoming_call_rejected.svg deleted file mode 100644 index c64a80ebd..000000000 --- a/Linphone/data/image/incoming_call_rejected.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/info.svg b/Linphone/data/image/info.svg index 992048dd0..40cce74f7 100644 --- a/Linphone/data/image/info.svg +++ b/Linphone/data/image/info.svg @@ -1 +1 @@ - + \ No newline at end of file diff --git a/Linphone/data/image/keyboard.svg b/Linphone/data/image/keyboard.svg index e7aa36dd0..df814890d 100644 --- a/Linphone/data/image/keyboard.svg +++ b/Linphone/data/image/keyboard.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/magnifying-glass.svg b/Linphone/data/image/magnifying-glass.svg index 39a3b251d..bf4e50589 100644 --- a/Linphone/data/image/magnifying-glass.svg +++ b/Linphone/data/image/magnifying-glass.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/microphone-slash.svg b/Linphone/data/image/microphone-slash.svg index 406de1e82..499a98121 100644 --- a/Linphone/data/image/microphone-slash.svg +++ b/Linphone/data/image/microphone-slash.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/microphone-stage.svg b/Linphone/data/image/microphone-stage.svg index dd4ba119d..b1d068d30 100644 --- a/Linphone/data/image/microphone-stage.svg +++ b/Linphone/data/image/microphone-stage.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/microphone.svg b/Linphone/data/image/microphone.svg index 36f7b4e0a..3e4760320 100644 --- a/Linphone/data/image/microphone.svg +++ b/Linphone/data/image/microphone.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/mobile.svg b/Linphone/data/image/mobile.svg deleted file mode 100644 index 342967e8f..000000000 --- a/Linphone/data/image/mobile.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/monitor-arrow-up.svg b/Linphone/data/image/monitor-arrow-up.svg index 913ab4917..062a0a6fb 100644 --- a/Linphone/data/image/monitor-arrow-up.svg +++ b/Linphone/data/image/monitor-arrow-up.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/more.svg b/Linphone/data/image/more.svg deleted file mode 100644 index 56ffcc063..000000000 --- a/Linphone/data/image/more.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/note.svg b/Linphone/data/image/note.svg index a175c6ca2..a5378aa7a 100644 --- a/Linphone/data/image/note.svg +++ b/Linphone/data/image/note.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/numpad.svg b/Linphone/data/image/numpad.svg new file mode 100644 index 000000000..37177cbf2 --- /dev/null +++ b/Linphone/data/image/numpad.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/outgoing_call_rejected.svg b/Linphone/data/image/outgoing_call_rejected.svg deleted file mode 100644 index 39fa5aeac..000000000 --- a/Linphone/data/image/outgoing_call_rejected.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/package.svg b/Linphone/data/image/package.svg new file mode 100644 index 000000000..b682ceb2e --- /dev/null +++ b/Linphone/data/image/package.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/paper-plane-tilt.svg b/Linphone/data/image/paper-plane-tilt.svg index 73f7dedd3..ca4a82964 100644 --- a/Linphone/data/image/paper-plane-tilt.svg +++ b/Linphone/data/image/paper-plane-tilt.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/paperclip.svg b/Linphone/data/image/paperclip.svg index 8ed525881..74d8cab2a 100644 --- a/Linphone/data/image/paperclip.svg +++ b/Linphone/data/image/paperclip.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/pause.svg b/Linphone/data/image/pause.svg index 2ba53b7c4..50c7d8648 100644 --- a/Linphone/data/image/pause.svg +++ b/Linphone/data/image/pause.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/pencil-simple.svg b/Linphone/data/image/pencil-simple.svg index 35cfc71c7..ceb292bbf 100644 --- a/Linphone/data/image/pencil-simple.svg +++ b/Linphone/data/image/pencil-simple.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/picture-in-picture.svg b/Linphone/data/image/picture-in-picture.svg new file mode 100644 index 000000000..4a7ab8304 --- /dev/null +++ b/Linphone/data/image/picture-in-picture.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/pip.svg b/Linphone/data/image/pip.svg deleted file mode 100644 index e2eb960f3..000000000 --- a/Linphone/data/image/pip.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/play.svg b/Linphone/data/image/play.svg index 9df4f4c24..f1e0c9b70 100644 --- a/Linphone/data/image/play.svg +++ b/Linphone/data/image/play.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/plus-circle.svg b/Linphone/data/image/plus-circle.svg index 051b34cda..0365c1a4e 100644 --- a/Linphone/data/image/plus-circle.svg +++ b/Linphone/data/image/plus-circle.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/power.svg b/Linphone/data/image/power.svg index caf9f7361..cc2e04a20 100644 --- a/Linphone/data/image/power.svg +++ b/Linphone/data/image/power.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/qr-code.svg b/Linphone/data/image/qr-code.svg index 2d6248f02..d5cd44274 100644 --- a/Linphone/data/image/qr-code.svg +++ b/Linphone/data/image/qr-code.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/resource-package.svg b/Linphone/data/image/resource-package.svg deleted file mode 100644 index 3003b374f..000000000 --- a/Linphone/data/image/resource-package.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/settings.svg b/Linphone/data/image/settings.svg deleted file mode 100644 index 4ea4c6c7c..000000000 --- a/Linphone/data/image/settings.svg +++ /dev/null @@ -1,3 +0,0 @@ - - - diff --git a/Linphone/data/image/share-network.svg b/Linphone/data/image/share-network.svg index 02d8619a1..835f930ac 100644 --- a/Linphone/data/image/share-network.svg +++ b/Linphone/data/image/share-network.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/shield-warning.svg b/Linphone/data/image/shield-warning.svg index 41c778b3f..dae911b15 100644 --- a/Linphone/data/image/shield-warning.svg +++ b/Linphone/data/image/shield-warning.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/sign-out.svg b/Linphone/data/image/sign-out.svg index ffd423eec..f50cba64f 100644 --- a/Linphone/data/image/sign-out.svg +++ b/Linphone/data/image/sign-out.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/slideshow.svg b/Linphone/data/image/slideshow.svg index d52a4aeaa..20021de5c 100644 --- a/Linphone/data/image/slideshow.svg +++ b/Linphone/data/image/slideshow.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/smiley-sad.svg b/Linphone/data/image/smiley-sad.svg index 8c61c87c5..2838fb64c 100644 --- a/Linphone/data/image/smiley-sad.svg +++ b/Linphone/data/image/smiley-sad.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/smiley.svg b/Linphone/data/image/smiley.svg index 8126d53e1..c37a7d61e 100644 --- a/Linphone/data/image/smiley.svg +++ b/Linphone/data/image/smiley.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/speaker-high.svg b/Linphone/data/image/speaker-high.svg index 1633bdcc0..fa3369e2e 100644 --- a/Linphone/data/image/speaker-high.svg +++ b/Linphone/data/image/speaker-high.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/speaker-slash.svg b/Linphone/data/image/speaker-slash.svg index 17f3c6a80..99bbbb6db 100644 --- a/Linphone/data/image/speaker-slash.svg +++ b/Linphone/data/image/speaker-slash.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/squares-four.svg b/Linphone/data/image/squares-four.svg index d7f16bd54..85f5689ef 100644 --- a/Linphone/data/image/squares-four.svg +++ b/Linphone/data/image/squares-four.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/trash-simple.svg b/Linphone/data/image/trash-simple.svg index 0c2db4850..6e48d22fc 100644 --- a/Linphone/data/image/trash-simple.svg +++ b/Linphone/data/image/trash-simple.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/user-circle-gear.svg b/Linphone/data/image/user-circle-gear.svg index c406aac63..5b383bc57 100644 --- a/Linphone/data/image/user-circle-gear.svg +++ b/Linphone/data/image/user-circle-gear.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/user-circle.svg b/Linphone/data/image/user-circle.svg index 761ce7d97..797854dd3 100644 --- a/Linphone/data/image/user-circle.svg +++ b/Linphone/data/image/user-circle.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/user-plus.svg b/Linphone/data/image/user-plus.svg index 9602ea863..e4fa5fe01 100644 --- a/Linphone/data/image/user-plus.svg +++ b/Linphone/data/image/user-plus.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/user-square.svg b/Linphone/data/image/user-square.svg index 71c8534fd..df927af30 100644 --- a/Linphone/data/image/user-square.svg +++ b/Linphone/data/image/user-square.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/users-three.svg b/Linphone/data/image/users-three.svg index ba001446a..1a4a36da6 100644 --- a/Linphone/data/image/users-three.svg +++ b/Linphone/data/image/users-three.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/users.svg b/Linphone/data/image/users.svg index 353aca80f..634aa8ecb 100644 --- a/Linphone/data/image/users.svg +++ b/Linphone/data/image/users.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/video-camera-slash.svg b/Linphone/data/image/video-camera-slash.svg index 942e907f3..d200d4db8 100644 --- a/Linphone/data/image/video-camera-slash.svg +++ b/Linphone/data/image/video-camera-slash.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/video-camera.svg b/Linphone/data/image/video-camera.svg index 0383a7c7b..3a84c247a 100644 --- a/Linphone/data/image/video-camera.svg +++ b/Linphone/data/image/video-camera.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/voicemail.svg b/Linphone/data/image/voicemail.svg index 6facd31ac..11c1a213c 100644 --- a/Linphone/data/image/voicemail.svg +++ b/Linphone/data/image/voicemail.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/warning-circle.svg b/Linphone/data/image/warning-circle.svg index a04e6ff79..1b69e522a 100644 --- a/Linphone/data/image/warning-circle.svg +++ b/Linphone/data/image/warning-circle.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/waveform.svg b/Linphone/data/image/waveform.svg index 89edf217a..ab8d0faff 100644 --- a/Linphone/data/image/waveform.svg +++ b/Linphone/data/image/waveform.svg @@ -1,3 +1 @@ - - - + \ No newline at end of file diff --git a/Linphone/data/image/wifi-high.svg b/Linphone/data/image/wifi-high.svg deleted file mode 100644 index 200030e09..000000000 --- a/Linphone/data/image/wifi-high.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/wifi-low.svg b/Linphone/data/image/wifi-low.svg deleted file mode 100644 index d8b0173bc..000000000 --- a/Linphone/data/image/wifi-low.svg +++ /dev/null @@ -1 +0,0 @@ - \ No newline at end of file diff --git a/Linphone/data/image/wrench.svg b/Linphone/data/image/wrench.svg index 71b09f566..993653c87 100644 --- a/Linphone/data/image/wrench.svg +++ b/Linphone/data/image/wrench.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/data/image/x-circle.svg b/Linphone/data/image/x-circle.svg new file mode 100644 index 000000000..689353fdd --- /dev/null +++ b/Linphone/data/image/x-circle.svg @@ -0,0 +1 @@ + \ No newline at end of file diff --git a/Linphone/data/image/x.svg b/Linphone/data/image/x.svg index 52756cbd9..707720548 100644 --- a/Linphone/data/image/x.svg +++ b/Linphone/data/image/x.svg @@ -1 +1 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/Linphone/view/CMakeLists.txt b/Linphone/view/CMakeLists.txt index 232d12b7a..11de544e5 100644 --- a/Linphone/view/CMakeLists.txt +++ b/Linphone/view/CMakeLists.txt @@ -7,8 +7,8 @@ list(APPEND _LINPHONEAPP_QML_FILES view/Control/Button/ComboBox.qml view/Control/Button/HelpIconLabelButton.qml view/Control/Button/IconLabelButton.qml - view/Control/Button/MenuButton.qml view/Control/Button/BigButton.qml + view/Control/Button/RoundButton.qml view/Control/Button/MediumButton.qml view/Control/Button/SmallButton.qml view/Control/Button/CountryIndicatorCombobox.qml diff --git a/Linphone/view/Control/Button/BigButton.qml b/Linphone/view/Control/Button/BigButton.qml new file mode 100644 index 000000000..f6f57e8d3 --- /dev/null +++ b/Linphone/view/Control/Button/BigButton.qml @@ -0,0 +1,17 @@ +import QtQuick +import QtQuick.Controls.Basic as Control +import QtQuick.Effects +import QtQuick.Layouts +import Linphone + +Button { + id: mainItem + textSize: Typography.b1.pixelSize + textWeight: Typography.b1.weight + leftPadding: 20 * DefaultStyle.dp + rightPadding: 20 * DefaultStyle.dp + topPadding: 11 * DefaultStyle.dp + bottomPadding: 11 * DefaultStyle.dp + icon.width: 24 * DefaultStyle.dp + icon.height: 24 * DefaultStyle.dp +} \ No newline at end of file diff --git a/Linphone/view/Control/Button/Button.qml b/Linphone/view/Control/Button/Button.qml index b00393e6a..efdf5cb68 100644 --- a/Linphone/view/Control/Button/Button.qml +++ b/Linphone/view/Control/Button/Button.qml @@ -8,24 +8,33 @@ Control.Button { id: mainItem property int capitalization property QtObject style - property color color: style ? style.color.normal : DefaultStyle.main1_500_main - readonly property color pressedColor: style && style.color.pressed || Qt.darker(color, 1.3) - readonly property color hoveredColor: style && style.color.hovered || Qt.darker(color, 1.1) - property color textColor: style && style.text.normal || DefaultStyle.grey_0 - property color pressedTextColor: style && style.text.pressed || textColor - property color borderColor: style && style.borderColor || "transparent" - property bool inversedColors: false + property color color: style?.color?.normal || DefaultStyle.main1_500_main + property color hoveredColor: style?.color?.hovered || Qt.darker(color, 1.05) + property color pressedColor: style?.color?.pressed || Qt.darker(color, 1.1) + property color textColor: style?.text?.normal || DefaultStyle.grey_0 + property color hoveredTextColor: style?.text?.hovered || Qt.darker(textColor, 1.05) + property color pressedTextColor: style?.text?.pressed || Qt.darker(textColor, 1.1) + property color borderColor: style?.borderColor || "transparent" + ToolTip.visible: hovered && ToolTip.text != "" + ToolTip.delay: 1000 + property color disabledFilterColor: color.hslLightness > 0.5 + ? DefaultStyle.grey_0 + : DefaultStyle.grey_400 property int textSize: 18 * DefaultStyle.dp property int textWeight: 600 * DefaultStyle.dp property var textHAlignment: Text.AlignHCenter property int radius: 48 * DefaultStyle.dp property bool underline: false property bool hasNavigationFocus: enabled && (activeFocus || hovered) - property var contentImageColor: style && style.image.normal || DefaultStyle.main2_600 - property var pressedImageColor: style && style.image.pressed || DefaultStyle.main2_600 + property bool shadowEnabled: false + property var contentImageColor: style?.image?.normal || DefaultStyle.main2_600 + property var hoveredImageColor: style?.image?.pressed || Qt.darker(contentImageColor, 1.05) + property var pressedImageColor: style?.image?.pressed || Qt.darker(contentImageColor, 1.1) property bool asynchronous: true - hoverEnabled: true + spacing: 5 * DefaultStyle.dp + hoverEnabled: enabled activeFocusOnTab: true + icon.source: style?.iconSource MouseArea { id: mouseArea anchors.fill: parent @@ -50,25 +59,31 @@ Control.Button { radius: mainItem.radius border.color: mainItem.borderColor } - Rectangle { - id: disableShadow - color: "white" - opacity: 0.2 - visible: !mainItem.enabled - } MultiEffect { - enabled: mainItem.hasNavigationFocus + enabled: mainItem.shadowEnabled anchors.fill: buttonBackground source: buttonBackground - visible: mainItem.hasNavigationFocus + visible: mainItem.shadowEnabled // Crash : https://bugreports.qt.io/browse/QTBUG-124730 - shadowEnabled: mainItem.hasNavigationFocus + shadowEnabled: true shadowColor: DefaultStyle.grey_1000 shadowBlur: 0.1 shadowOpacity: mainItem.shadowEnabled ? 0.5 : 0.0 } } } + + Rectangle { + id: disableShadow + z: 1 + // color: buttonBackground.color == "transparent" ? "transparent" : "white" + color: disabledFilterColor + opacity: 0.5 + visible: !mainItem.enabled && mainItem.color != "transparent" + radius: mainItem.radius + width: mainItem.width + height: mainItem.height + } component ButtonText: Text { id: buttonText @@ -80,18 +95,21 @@ Control.Button { maximumLineCount: 1 color: pressed ? mainItem.pressedTextColor - : mainItem.textColor + : mainItem.hovered + ? mainItem.hoveredTextColor + : mainItem.textColor font { pixelSize: mainItem.textSize weight: mainItem.textWeight family: DefaultStyle.defaultFont capitalization: mainItem.capitalization underline: mainItem.underline - bold: mainItem.font.bold + bold: mainItem.style === ButtonStyle.noBackground && (mainItem.hovered || mainItem.pressed) } TextMetrics { id: textMetrics text: mainItem.text + font.bold: true } } @@ -99,7 +117,11 @@ Control.Button { imageSource: mainItem.icon.source imageWidth: mainItem.icon.width imageHeight: mainItem.icon.height - colorizationColor: mainItem.pressed ? mainItem.pressedImageColor : mainItem.contentImageColor + colorizationColor: mainItem.pressed + ? mainItem.pressedImageColor + : mainItem.hovered + ? mainItem.hoveredImageColor + : mainItem.contentImageColor } contentItem: Control.StackView{ diff --git a/Linphone/view/Control/Button/CheckBox.qml b/Linphone/view/Control/Button/CheckBox.qml index bc13e5663..6f6ab78c5 100644 --- a/Linphone/view/Control/Button/CheckBox.qml +++ b/Linphone/view/Control/Button/CheckBox.qml @@ -5,7 +5,7 @@ import QtQuick.Effects Control.CheckBox { id: mainItem - property bool shadowEnabled: mainItem.activeFocus || mainItem.hovered + hoverEnabled: enabled indicator: Item{ implicitWidth: 20 * DefaultStyle.dp implicitHeight: 20 * DefaultStyle.dp @@ -15,26 +15,23 @@ Control.CheckBox { id: backgroundArea anchors.fill: parent radius: 3 * DefaultStyle.dp - border.color: DefaultStyle.main1_500_main - border.width: 2.2 * DefaultStyle.dp - // color: mainItem.checked ? DefaultStyle.main1_500_main : "transparent" + border.color: mainItem.hovered || mainItem.activeFocus ? DefaultStyle.main1_600 : DefaultStyle.main1_500_main + border.width: 2 * DefaultStyle.dp + color: mainItem.checked ? DefaultStyle.main1_500_main : "transparent" EffectImage { visible: mainItem.checked imageSource: AppIcons.check - colorizationColor: DefaultStyle.main1_500_main + colorizationColor: DefaultStyle.grey_0 anchors.fill: parent } } - MultiEffect { - enabled: mainItem.shadowEnabled - anchors.fill: backgroundArea - source: backgroundArea - visible: mainItem.shadowEnabled - // Crash : https://bugreports.qt.io/browse/QTBUG-124730 - shadowEnabled: true //mainItem.shadowEnabled - shadowColor: DefaultStyle.grey_1000 - shadowBlur: 0.1 - shadowOpacity: mainItem.shadowEnabled ? 0.5 : 0.0 - } + } + + MouseArea { + id: mouseArea + anchors.fill: parent + hoverEnabled: true + cursorShape: containsMouse ? Qt.PointingHandCursor : Qt.ArrowCursor + acceptedButtons: Qt.NoButton } } diff --git a/Linphone/view/Control/Button/CheckableButton.qml b/Linphone/view/Control/Button/CheckableButton.qml index 4780f8947..4c2db4b43 100644 --- a/Linphone/view/Control/Button/CheckableButton.qml +++ b/Linphone/view/Control/Button/CheckableButton.qml @@ -1,4 +1,5 @@ import QtQuick +import QtQml import QtQuick.Layouts import QtQuick.Effects import QtQuick.Controls.Basic as Control @@ -8,21 +9,29 @@ Button { id: mainItem property string iconUrl property string checkedIconUrl - property color color: DefaultStyle.grey_500 - property color checkedColor: color - property color backgroundColor: mainItem.enabled - ? mainItem.pressed || mainItem.checked - ? mainItem.checkedColor - : mainItem.color - : DefaultStyle.grey_600 + style: ButtonStyle.checkable + color: style?.color?.normal || DefaultStyle.grey_500 + pressedColor: checkedIconUrl ? color : style?.color?.pressed || DefaultStyle.grey_500 + hoveredColor: checked ? Qt.darker(pressedColor, 1.05) : style?.color?.hovered || DefaultStyle.grey_500 + property color backgroundColor: hovered + ? hoveredColor + : checked + ? pressedColor + : color checkable: true background: Rectangle { anchors.fill: parent color: mainItem.backgroundColor radius: mainItem.width /2 + Rectangle { + anchors.fill: parent + visible: !mainItem.enabled + opacity: 0.2 + color: DefaultStyle.grey_600 + } } icon.source: checkedIconUrl && mainItem.checked ? checkedIconUrl : iconUrl icon.width: width * 0.58 icon.height: width * 0.58 - contentImageColor: enabled ? DefaultStyle.grey_0 : DefaultStyle.grey_500 + contentImageColor: style?.image?.normal || DefaultStyle.grey_0 } diff --git a/Linphone/view/Control/Button/ComboBox.qml b/Linphone/view/Control/Button/ComboBox.qml index e1cfa2d93..c710bab58 100644 --- a/Linphone/view/Control/Button/ComboBox.qml +++ b/Linphone/view/Control/Button/ComboBox.qml @@ -18,7 +18,7 @@ Control.ComboBox { property bool shadowEnabled: mainItem.activeFocus || mainItem.hovered property string flagRole// Specific case if flag is shown (special font) - onConstantImageSourceChanged: if (constantImageSource) selectedItemImg.source = constantImageSource + onConstantImageSourceChanged: if (constantImageSource) selectedItemImg.imageSource = constantImageSource onCurrentIndexChanged: { var item = model[currentIndex] if (!item) item = model.getAt(currentIndex) @@ -31,7 +31,7 @@ Control.ComboBox { ? item : "" if(mainItem.flagRole) selectedItemFlag.text = item[mainItem.flagRole] - selectedItemImg.source = constantImageSource + selectedItemImg.imageSource = constantImageSource ? constantImageSource : item.img ? item.img @@ -74,13 +74,14 @@ Control.ComboBox { anchors.leftMargin: 10 * DefaultStyle.dp anchors.rightMargin: indicImage.width + 10 * DefaultStyle.dp spacing: 5 * DefaultStyle.dp - Image { + EffectImage { id: selectedItemImg Layout.preferredWidth: visible ? 24 * DefaultStyle.dp : 0 + Layout.preferredHeight: visible ? 24 * DefaultStyle.dp : 0 Layout.leftMargin: mainItem.leftMargin - source: mainItem.constantImageSource ? mainItem.constantImageSource : "" - visible: source != "" - sourceSize.width: 24 * DefaultStyle.dp + imageSource: mainItem.constantImageSource ? mainItem.constantImageSource : "" + colorizationColor: DefaultStyle.main2_600 + visible: imageSource != "" fillMode: Image.PreserveAspectFit } Text { @@ -114,13 +115,13 @@ Control.ComboBox { } - indicator: Image { + indicator: EffectImage { id: indicImage z: 1 anchors.right: parent.right anchors.rightMargin: 10 * DefaultStyle.dp anchors.verticalCenter: parent.verticalCenter - source: AppIcons.downArrow + imageSource: AppIcons.downArrow width: 14 * DefaultStyle.dp fillMode: Image.PreserveAspectFit } @@ -169,13 +170,13 @@ Control.ComboBox { // anchors.right: listView.right RowLayout{ anchors.fill: parent - Image { + EffectImage { id: delegateImg Layout.preferredWidth: visible ? 20 * DefaultStyle.dp : 0 Layout.leftMargin: 10 * DefaultStyle.dp - visible: source != "" - sourceSize.width: 20 * DefaultStyle.dp - source: typeof(modelData) != "undefined" && modelData.img ? modelData.img : "" + visible: imageSource != "" + imageWidth: 20 * DefaultStyle.dp + imageSource: typeof(modelData) != "undefined" && modelData.img ? modelData.img : "" fillMode: Image.PreserveAspectFit } diff --git a/Linphone/view/Control/Button/CountryIndicatorCombobox.qml b/Linphone/view/Control/Button/CountryIndicatorCombobox.qml index 079ebab98..cd649b684 100644 --- a/Linphone/view/Control/Button/CountryIndicatorCombobox.qml +++ b/Linphone/view/Control/Button/CountryIndicatorCombobox.qml @@ -89,10 +89,11 @@ ColumnLayout { } } - indicator: Image { + indicator: EffectImage { anchors.verticalCenter: parent.verticalCenter anchors.right: parent.right - source: AppIcons.downArrow + imageSource: AppIcons.downArrow + colorizationColor: DefaultStyle.main2_600 } popup: Control.Popup { diff --git a/Linphone/view/Control/Button/IconLabelButton.qml b/Linphone/view/Control/Button/IconLabelButton.qml index 684a9f99c..25b8ba609 100644 --- a/Linphone/view/Control/Button/IconLabelButton.qml +++ b/Linphone/view/Control/Button/IconLabelButton.qml @@ -3,83 +3,55 @@ import QtQuick.Effects import QtQuick.Layouts import Linphone -Item{ +Button { id: mainItem - property string iconSource - property string text - property color color: DefaultStyle.main2_600 - property int iconSize: 17 * DefaultStyle.dp - property int textSize: 14 * DefaultStyle.dp - property int textWeight: 400 * DefaultStyle.dp - property color backgroundColor: DefaultStyle.grey_0 - readonly property color backgroundPressedColor: Qt.darker(backgroundColor, 1.1) - property int radius: 5 * DefaultStyle.dp - property bool shadowEnabled: mainItem.activeFocus// || containsMouse - property alias containsMouse: mouseArea.containsMouse + icon.width: 24 * DefaultStyle.dp + icon.height: 24 * DefaultStyle.dp + textSize: 14 * DefaultStyle.dp + textWeight: 400 * DefaultStyle.dp + radius: 5 * DefaultStyle.dp + shadowEnabled: mainItem.activeFocus || hovered + style: ButtonStyle.hoveredBackground - signal clicked(var mouse) - - implicitWidth: content.implicitWidth - activeFocusOnTab: true - - Keys.onPressed: (event)=> { - if (event.key == Qt.Key_Space || event.key == Qt.Key_Enter || event.key == Qt.Key_Return) { - mainItem.clicked(undefined) - event.accepted = true; + contentItem: RowLayout { + EffectImage { + imageSource: mainItem.icon.source + imageWidth: mainItem.icon.width + imageHeight: mainItem.icon.height + colorizationColor: mainItem.pressed + ? mainItem.pressedImageColor + : mainItem.hovered + ? mainItem.hoveredImageColor + : mainItem.contentImageColor + Layout.preferredWidth: mainItem.icon.width + Layout.preferredHeight: mainItem.icon.height } - } - Rectangle{ - anchors.fill: parent - id: buttonBackground - color: mainItem.shadowEnabled - ? mainItem.backgroundPressedColor - : mainItem.containsMouse - ? DefaultStyle.main2_100 - : mainItem.backgroundColor - radius: mainItem.radius - }/* - MultiEffect { - enabled: mainItem.shadowEnabled - anchors.fill: buttonBackground - source: buttonBackground - visible: mainItem.shadowEnabled - // Crash : https://bugreports.qt.io/browse/QTBUG-124730 - shadowEnabled: true //mainItem.shadowEnabled - shadowColor: DefaultStyle.grey_1000 - shadowBlur: 0.1 - shadowOpacity: mainItem.shadowEnabled ? 0.5 : 0.0 - }*/ - - MouseArea { - id: mouseArea - anchors.verticalCenter: parent.verticalCenter - width: content.implicitWidth - height: mainItem.height - hoverEnabled: true - cursorShape: containsMouse ? Qt.PointingHandCursor : Qt.ArrowCursor - - onClicked: function(mouse){mainItem.clicked(mouse)} - RowLayout { - id: content - anchors.verticalCenter: parent.verticalCenter - EffectImage { - Layout.preferredWidth: mainItem.iconSize - Layout.preferredHeight: mainItem.iconSize - width: mainItem.iconSize - height: mainItem.iconSize - imageSource: mainItem.iconSource - colorizationColor: mainItem.color + Text{ + horizontalAlignment: mainItem.textHAlignment + verticalAlignment: Text.AlignLeft + Layout.preferredWidth: textMetrics.advanceWidth + wrapMode: Text.WrapAnywhere + text: mainItem.text + maximumLineCount: 1 + color: pressed + ? mainItem.pressedTextColor + : mainItem.hovered + ? mainItem.hoveredTextColor + : mainItem.textColor + font { + pixelSize: mainItem.textSize + weight: mainItem.textWeight + family: DefaultStyle.defaultFont + capitalization: mainItem.capitalization + underline: mainItem.underline + bold: mainItem.style === ButtonStyle.noBackground && (mainItem.hovered || mainItem.pressed) } - Text { - width: implicitWidth - Layout.fillWidth: true + TextMetrics { + id: textMetrics text: mainItem.text - color: mainItem.color - font { - pixelSize: mainItem.textSize - weight: mainItem.textWeight - } + font.bold: true } } + Item{Layout.fillWidth: true} } } diff --git a/Linphone/view/Control/Button/MediumButton.qml b/Linphone/view/Control/Button/MediumButton.qml index c98cb1bd8..cd7ee3f7d 100644 --- a/Linphone/view/Control/Button/MediumButton.qml +++ b/Linphone/view/Control/Button/MediumButton.qml @@ -6,10 +6,12 @@ import Linphone Button { id: mainItem - textSize: Typography.b3.pixelSize - textWeight: Typography.b3.weight + textSize: Typography.b2.pixelSize + textWeight: Typography.b2.weight leftPadding: 16 * DefaultStyle.dp rightPadding: 16 * DefaultStyle.dp topPadding: 10 * DefaultStyle.dp bottomPadding: 10 * DefaultStyle.dp + icon.width: 16 * DefaultStyle.dp + icon.height: 16 * DefaultStyle.dp } diff --git a/Linphone/view/Control/Button/MenuButton.qml b/Linphone/view/Control/Button/MenuButton.qml deleted file mode 100644 index e7a4a1952..000000000 --- a/Linphone/view/Control/Button/MenuButton.qml +++ /dev/null @@ -1,18 +0,0 @@ -import QtQuick -import QtQuick.Controls.Basic as Control -import QtQuick.Effects -import QtQuick.Layouts -import Linphone - -Button { - id: mainItem - background: Item{} - icon.width: 32 * DefaultStyle.dp - icon.height: 32 * DefaultStyle.dp - textColor: down || checked ? DefaultStyle.main1_500_main : DefaultStyle.main2_500main - contentImageColor: down || checked ? DefaultStyle.main1_500_main : DefaultStyle.main2_500main - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - textHAlignment: Text.AlignLeft - spacing: 5 * DefaultStyle.dp -} diff --git a/Linphone/view/Control/Button/PopupButton.qml b/Linphone/view/Control/Button/PopupButton.qml index 2730334a3..96af03f9d 100644 --- a/Linphone/view/Control/Button/PopupButton.qml +++ b/Linphone/view/Control/Button/PopupButton.qml @@ -6,9 +6,16 @@ import Linphone Button { id: mainItem property alias popup: popup - property var contentImageColor - property bool shadowEnabled: mainItem.activeFocus || hovered + property bool shadowEnabled: mainItem.activeFocus || hovered property alias popupBackgroundColor: popupBackground.color + property color backgroundColor: checked + ? pressedColor + : hovered + ? hoveredColor + : color + color: style?.color?.normal || "transparent" + hoveredColor: style?.color?.hovered || DefaultStyle.grey_100 + pressedColor: style?.color?.pressed || DefaultStyle.main2_300 checked: popup.visible implicitWidth: 24 * DefaultStyle.dp implicitHeight: 24 * DefaultStyle.dp @@ -18,7 +25,7 @@ Button { rightPadding: 0 topPadding: 0 bottomPadding: 0 - icon.source: AppIcons.more + icon.source: AppIcons.verticalDots icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp function close() { @@ -80,8 +87,7 @@ Button { Rectangle { id: buttonBackground anchors.fill: parent - visible: mainItem.checked || mainItem.shadowEnabled - color: mainItem.checked ? DefaultStyle.main2_300 : DefaultStyle.grey_100 + color: mainItem.backgroundColor radius: 40 * DefaultStyle.dp } MultiEffect { diff --git a/Linphone/view/Control/Button/RoundButton.qml b/Linphone/view/Control/Button/RoundButton.qml new file mode 100644 index 000000000..8fd4c86a1 --- /dev/null +++ b/Linphone/view/Control/Button/RoundButton.qml @@ -0,0 +1,20 @@ +import QtQuick +import QtQuick.Controls.Basic as Control +import QtQuick.Effects +import QtQuick.Layouts +import Linphone + +Button { + id: mainItem + textSize: Typography.p1s.pixelSize + textWeight: Typography.p1s.weight + topPadding: 16 * DefaultStyle.dp + bottomPadding: 16 * DefaultStyle.dp + leftPadding: 16 * DefaultStyle.dp + rightPadding: 16 * DefaultStyle.dp + icon.width: 24 * DefaultStyle.dp + icon.height: 24 * DefaultStyle.dp + radius: 40 * DefaultStyle.dp + width: 24 * DefaultStyle.dp + height: 24 * DefaultStyle.dp +} \ No newline at end of file diff --git a/Linphone/view/Control/Button/SmallButton.qml b/Linphone/view/Control/Button/SmallButton.qml index a5b040836..485211430 100644 --- a/Linphone/view/Control/Button/SmallButton.qml +++ b/Linphone/view/Control/Button/SmallButton.qml @@ -12,4 +12,6 @@ Button { rightPadding: 12 * DefaultStyle.dp topPadding: 6 * DefaultStyle.dp bottomPadding: 6 * DefaultStyle.dp + icon.height: 14 * DefaultStyle.dp + icon.width: 14 * DefaultStyle.dp } diff --git a/Linphone/view/Control/Container/Call/CallHistoryLayout.qml b/Linphone/view/Control/Container/Call/CallHistoryLayout.qml index 3f285a1f7..ced906248 100644 --- a/Linphone/view/Control/Container/Call/CallHistoryLayout.qml +++ b/Linphone/view/Control/Container/Call/CallHistoryLayout.qml @@ -45,11 +45,8 @@ ColumnLayout { leftPadding: 16 * DefaultStyle.dp rightPadding: 16 * DefaultStyle.dp contentImageColor: DefaultStyle.main2_600 - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } + radius: 40 * DefaultStyle.dp + style: ButtonStyle.grey } Text { Layout.alignment: Qt.AlignHCenter @@ -77,6 +74,7 @@ ColumnLayout { _address: mainItem.conferenceInfo ? mainItem.conferenceInfo.core.subject : mainItem.contactAddress || mainItem.contactName + secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncrypted } Item { id: rightButton @@ -90,32 +88,35 @@ ColumnLayout { ColumnLayout { Layout.alignment: Qt.AlignHCenter Layout.preferredWidth: 360 * DefaultStyle.dp - spacing: 2 * DefaultStyle.dp + spacing: 5 * DefaultStyle.dp - Text { - Layout.preferredWidth: implicitWidth - Layout.alignment: Qt.AlignHCenter - horizontalAlignment: Text.AlignHCenter - elide: Text.ElideRight - text: mainItem.contactName - maximumLineCount: 1 - font { - pixelSize: 14 * DefaultStyle.dp - weight: 400 * DefaultStyle.dp - capitalization: Font.Capitalize + ColumnLayout { + spacing: 2 * DefaultStyle.dp + Text { + Layout.preferredWidth: implicitWidth + Layout.alignment: Qt.AlignHCenter + horizontalAlignment: Text.AlignHCenter + elide: Text.ElideRight + text: mainItem.contactName + maximumLineCount: 1 + font { + pixelSize: 14 * DefaultStyle.dp + weight: 400 * DefaultStyle.dp + capitalization: Font.Capitalize + } } - } - Text { - Layout.alignment: Qt.AlignHCenter - Layout.fillWidth: true - horizontalAlignment: Text.AlignHCenter - visible: mainItem.specificAddress != "" - text: SettingsCpp.onlyDisplaySipUriUsername ? UtilsCpp.getUsername(mainItem.specificAddress) : mainItem.specificAddress - elide: Text.ElideMiddle - maximumLineCount: 1 - font { - pixelSize: 12 * DefaultStyle.dp - weight: 300 * DefaultStyle.dp + Text { + Layout.alignment: Qt.AlignHCenter + Layout.fillWidth: true + horizontalAlignment: Text.AlignHCenter + visible: mainItem.specificAddress != "" + text: SettingsCpp.onlyDisplaySipUriUsername ? UtilsCpp.getUsername(mainItem.specificAddress) : mainItem.specificAddress + elide: Text.ElideMiddle + maximumLineCount: 1 + font { + pixelSize: 12 * DefaultStyle.dp + weight: 300 * DefaultStyle.dp + } } } Text { @@ -150,12 +151,11 @@ ColumnLayout { spacing: 72 * DefaultStyle.dp Layout.fillWidth: true Layout.preferredHeight: childrenRect.height - Button { + MediumButton { visible: mainItem.isConference && !SettingsCpp.disableMeetingsFeature Layout.alignment: Qt.AlignHCenter text: qsTr("Rejoindre la réunion") - color: DefaultStyle.main2_200 - textColor: DefaultStyle.main2_600 + style: ButtonStyle.grey onClicked: { if (mainItem.conferenceInfo) { var callsWindow = UtilsCpp.getCallsWindow() diff --git a/Linphone/view/Control/Container/Call/CallLayout.qml b/Linphone/view/Control/Container/Call/CallLayout.qml index ed36de6b5..4885dfd3e 100644 --- a/Linphone/view/Control/Container/Call/CallLayout.qml +++ b/Linphone/view/Control/Container/Call/CallLayout.qml @@ -15,7 +15,7 @@ Item { property ConferenceGui conference: call && call.core.conference property bool callTerminatedByUser: false property bool callStarted: call? call.core.isStarted : false - readonly property var callState: call?.core.state + readonly property var callState: call?.core.state property int conferenceLayout: call ? call.core.conferenceVideoLayout : LinphoneEnums.ConferenceLayout.ActiveSpeaker property int participantDeviceCount: conference ? conference.core.participantDeviceCount : -1 onParticipantDeviceCountChanged: { @@ -97,16 +97,12 @@ Item { } Item { Layout.fillWidth: true - Button { - color: "transparent" + BigButton { + color: pressed ? DefaultStyle.main2_200 : "transparent" borderColor: DefaultStyle.main2_400 icon.source: AppIcons.shareNetwork contentImageColor: DefaultStyle.main2_400 text: qsTr("Share invitation") - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp anchors.centerIn: parent textColor: DefaultStyle.main2_400 onClicked: { @@ -150,7 +146,6 @@ Item { // } // } // Button { - // inversedColors: true // text: qsTr("Share invitation") // icon.source: AppIcons.shareNetwork // color: DefaultStyle.main2_400 diff --git a/Linphone/view/Control/Container/Contact/ContactLayout.qml b/Linphone/view/Control/Container/Contact/ContactLayout.qml index bd3ef1e05..7bb9c7534 100644 --- a/Linphone/view/Control/Container/Contact/ContactLayout.qml +++ b/Linphone/view/Control/Container/Contact/ContactLayout.qml @@ -71,11 +71,10 @@ ColumnLayout { Layout.preferredWidth: childrenRect.width Layout.preferredHeight: childrenRect.height } - Button { + MediumButton { id: rightButton Layout.alignment: Qt.AlignHCenter - width: childrenRect.width - height: childrenRect.height + style: ButtonStyle.main } } StackLayout { diff --git a/Linphone/view/Control/Container/VerticalTabBar.qml b/Linphone/view/Control/Container/VerticalTabBar.qml index 6260c9768..2a9fb7a44 100644 --- a/Linphone/view/Control/Container/VerticalTabBar.qml +++ b/Linphone/view/Control/Container/VerticalTabBar.qml @@ -128,6 +128,7 @@ Control.TabBar { weight: mainItem.currentIndex === index ? 800 * DefaultStyle.dp : 400 * DefaultStyle.dp pixelSize: 9 * DefaultStyle.dp underline: tabButton.activeFocus || tabButton.hovered + bold: true } color: DefaultStyle.grey_0 Layout.fillWidth: true @@ -151,8 +152,7 @@ Control.TabBar { mainItem.setCurrentIndex(TabBar.index) } - background: Item { - } + background: Item {} } } } diff --git a/Linphone/view/Control/Display/Call/CallListView.qml b/Linphone/view/Control/Display/Call/CallListView.qml index 43d867532..854d53b68 100644 --- a/Linphone/view/Control/Display/Call/CallListView.qml +++ b/Linphone/view/Control/Display/Call/CallListView.qml @@ -65,11 +65,10 @@ ListView { Layout.alignment: Qt.AlignVCenter visible: mainItem.isTransferList && mainItem.currentRemoteAddress !== modelData.core.remoteAddress icon.source: AppIcons.transferCall - contentImageColor: down ? DefaultStyle.main1_500_main : DefaultStyle.main2_500main + style: ButtonStyle.noBackground onClicked: { mainItem.transferCallToAnotherRequested(modelData) } - background: Item {} } Button { id: pausingButton @@ -93,24 +92,19 @@ ListView { TextMetrics { id: pauseMeter text: pausingButton.text + font.bold: true } } - Button { + SmallButton { id: endCallButton Layout.preferredWidth: 38 * DefaultStyle.dp Layout.preferredHeight: 28 * DefaultStyle.dp - leftPadding: 10 * DefaultStyle.dp - rightPadding: 10 * DefaultStyle.dp - topPadding: 5 * DefaultStyle.dp - bottomPadding: 5 * DefaultStyle.dp - color: DefaultStyle.danger_500main + style: ButtonStyle.phoneRed KeyNavigation.left: pausingButton KeyNavigation.right: pausingButton - icon.source: AppIcons.endCall contentImageColor: DefaultStyle.grey_0 icon.width: 18 * DefaultStyle.dp icon.height: 18 * DefaultStyle.dp - textColor: DefaultStyle.danger_500main onClicked: { mainWindow.callTerminatedByUser = true mainWindow.endCall(modelData) @@ -118,6 +112,7 @@ ListView { TextMetrics { id: endMeter text: endCallButton.text + font.bold: true } } } diff --git a/Linphone/view/Control/Display/Contact/Avatar.qml b/Linphone/view/Control/Display/Contact/Avatar.qml index 3bc71c84d..0a258c95f 100644 --- a/Linphone/view/Control/Display/Contact/Avatar.qml +++ b/Linphone/view/Control/Display/Contact/Avatar.qml @@ -40,13 +40,15 @@ Loader{ property var avatarObj: UtilsCpp.findAvatarByAddress(_address) property string computedAvatarUri: avatarObj ? avatarObj.value : '' + // To get the secured property for a specific address, + // override it as secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncrypted property var securityLevelObj: UtilsCpp.getFriendAddressSecurityLevel(_address) property var securityLevel: securityLevelObj ? securityLevelObj.value : LinphoneEnums.SecurityLevel.None property bool secured: call && call.core.encryption === LinphoneEnums.MediaEncryption.Zrtp ? call.core.tokenVerified : contact ? contact.core.devices.length != 0 && contact.core.verifiedDeviceCount === contact.core.devices.length - : securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncrypted + : false property bool securityBreach: securityLevel === LinphoneEnums.SecurityLevel.Unsafe @@ -90,18 +92,16 @@ Loader{ z: 1 color: "transparent" border { - width: 3 * DefaultStyle.dp + width: 2 * DefaultStyle.dp color: mainItem.secured ? DefaultStyle.info_500_main : DefaultStyle.danger_500main } - Image { + EffectImage { x: parent.width / 7 anchors.bottom: parent.bottom width: parent.width / 4.5 height: width asynchronous: true - source: mainItem.secured ? AppIcons.trusted : AppIcons.notTrusted - sourceSize.width: width - sourceSize.height: height + imageSource: mainItem.secured ? AppIcons.trusted : AppIcons.notTrusted fillMode: Image.PreserveAspectFit } @@ -163,14 +163,13 @@ Loader{ capitalization: Font.AllUppercase } } - Image { + EffectImage { id: initialImg visible: initialItem.initials == '' width: stackView.width/2 height: width - source: mainItem.isConference ? AppIcons.usersThree : AppIcons.profile - sourceSize.width: width - sourceSize.height: height + colorizationColor: DefaultStyle.main2_600 + imageSource: mainItem.isConference ? AppIcons.usersThree : AppIcons.profile anchors.centerIn: parent } } diff --git a/Linphone/view/Control/Display/Contact/ContactListItem.qml b/Linphone/view/Control/Display/Contact/ContactListItem.qml index 04d88531e..e5402bc63 100644 --- a/Linphone/view/Control/Display/Contact/ContactListItem.qml +++ b/Linphone/view/Control/Display/Contact/ContactListItem.qml @@ -96,6 +96,7 @@ FocusScope { z: 1 visible: actionButtons || friendPopup.visible || mainItem.multiSelectionEnabled spacing: visible ? 16 * DefaultStyle.dp : 0 + Layout.rightMargin: visible ? 10 * DefaultStyle.dp : 0 EffectImage { id: isSelectedCheck visible: mainItem.multiSelectionEnabled && (mainItem.selectedContacts.indexOf(searchResultItem.core.defaultAddress) != -1) @@ -106,7 +107,6 @@ FocusScope { } RowLayout{ id: actionButtons - Layout.rightMargin: 10 * DefaultStyle.dp visible: mainItem.showActions spacing: visible ? 10 * DefaultStyle.dp : 0 Button { @@ -117,12 +117,8 @@ FocusScope { icon.height: 24 * DefaultStyle.dp icon.source: AppIcons.phone focus: visible - contentImageColor: DefaultStyle.main2_500main - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } + radius: 40 * DefaultStyle.dp + style: ButtonStyle.grey onClicked: UtilsCpp.createCall(searchResultItem.core.defaultFullAddress) KeyNavigation.left: chatButton KeyNavigation.right: videoCallButton @@ -135,12 +131,8 @@ FocusScope { icon.height: 24 * DefaultStyle.dp icon.source: AppIcons.videoCamera focus: visible && !callButton.visible - contentImageColor: DefaultStyle.main2_500main - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } + radius: 40 * DefaultStyle.dp + style: ButtonStyle.grey onClicked: UtilsCpp.createCall(searchResultItem.core.defaultFullAddress, {'localVideoEnabled': true}) KeyNavigation.left: callButton KeyNavigation.right: chatButton @@ -154,12 +146,8 @@ FocusScope { icon.height: 24 * DefaultStyle.dp icon.source: AppIcons.chatTeardropText focus: visible && !callButton.visible && !videoCallButton.visible - contentImageColor: DefaultStyle.main2_500main - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } + radius: 40 * DefaultStyle.dp + style: ButtonStyle.grey KeyNavigation.left: videoCallButton KeyNavigation.right: callButton } @@ -167,39 +155,29 @@ FocusScope { PopupButton { id: friendPopup z: 1 - // Layout.rightMargin: 13 * DefaultStyle.dp - Layout.alignment: Qt.AlignVCenter - Layout.rightMargin: 8 * DefaultStyle.dp popup.x: 0 popup.padding: 10 * DefaultStyle.dp visible: mainItem.showContactMenu && (contactArea.containsMouse || hovered || popup.opened) popup.contentItem: ColumnLayout { - Button { + IconLabelButton { visible: searchResultItem.core.isStored text: searchResultItem.core.starred ? qsTr("Enlever des favoris") : qsTr("Mettre en favori") icon.source: searchResultItem.core.starred ? AppIcons.heartFill : AppIcons.heart - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp textColor: DefaultStyle.main2_500main + hoveredImageColor: searchResultItem.core.starred ? DefaultStyle.main1_700 : DefaultStyle.danger_700 contentImageColor: searchResultItem.core.starred ? DefaultStyle.danger_500main : DefaultStyle.main2_600 onClicked: { searchResultItem.core.lSetStarred(!searchResultItem.core.starred) friendPopup.close() } - background: Item{} + style: ButtonStyle.noBackground } - Button { + IconLabelButton { text: qsTr("Partager") icon.source: AppIcons.shareNetwork - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp textColor: DefaultStyle.main2_500main onClicked: { var vcard = searchResultItem.core.getVCard() @@ -209,24 +187,19 @@ FocusScope { else mainWindow.showInformationPopup(qsTr("VCard créée"), qsTr("VCard du contact enregistrée dans %1").arg(filepath)) UtilsCpp.shareByEmail(qsTr("Partage de contact"), vcard, filepath) } - background: Item{} + style: ButtonStyle.noBackground + } - Button { + IconLabelButton { text: qsTr("Supprimer") icon.source: AppIcons.trashCan - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - textColor: DefaultStyle.danger_500main - contentImageColor: DefaultStyle.danger_500main visible: !searchResultItem.core.readOnly onClicked: { mainItem.contactDeletionRequested(searchResultItem) friendPopup.close() } - background: Item{} + style: ButtonStyle.noBackgroundRed } } } diff --git a/Linphone/view/Control/Display/Contact/ContactListView.qml b/Linphone/view/Control/Display/Contact/ContactListView.qml index 4c045f2a8..1b7e24d40 100644 --- a/Linphone/view/Control/Display/Contact/ContactListView.qml +++ b/Linphone/view/Control/Display/Contact/ContactListView.qml @@ -147,7 +147,7 @@ ListView { } Button { id: headerExpandButton - background: Item{} + style: ButtonStyle.noBackground icon.source: mainItem.expanded ? AppIcons.upArrow : AppIcons.downArrow Layout.fillHeight: true Layout.preferredWidth: height @@ -171,7 +171,7 @@ ListView { showInitials: mainItem.showInitials && isStored showDefaultAddress: mainItem.showDefaultAddress showActions: mainItem.showActions - showContactMenu: searchResultItem.core.isStored + showContactMenu: mainItem.showContactMenu && searchResultItem.core.isStored highlightText: mainItem.highlightText displayNameCapitalization: mainItem.displayNameCapitalization diff --git a/Linphone/view/Control/Display/Meeting/MeetingListView.qml b/Linphone/view/Control/Display/Meeting/MeetingListView.qml index 94fdf34f8..45a149a3c 100644 --- a/Linphone/view/Control/Display/Meeting/MeetingListView.qml +++ b/Linphone/view/Control/Display/Meeting/MeetingListView.qml @@ -235,13 +235,17 @@ ListView { ColumnLayout { anchors.fill: parent anchors.left: parent.left - anchors.leftMargin: 15 * DefaultStyle.dp + anchors.leftMargin: 16 * DefaultStyle.dp + anchors.rightMargin: 16 * DefaultStyle.dp + anchors.topMargin: 10 * DefaultStyle.dp + anchors.bottomMargin: 10 * DefaultStyle.dp spacing: 2 * DefaultStyle.dp visible: itemDelegate.haveModel RowLayout { spacing: 8 * DefaultStyle.dp - Image { - source: AppIcons.usersThree + EffectImage { + imageSource: AppIcons.usersThree + colorizationColor: DefaultStyle.main2_600 Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp } diff --git a/Linphone/view/Control/Display/Participant/ParticipantListView.qml b/Linphone/view/Control/Display/Participant/ParticipantListView.qml index 0cdd90c98..6b63b63e5 100644 --- a/Linphone/view/Control/Display/Participant/ParticipantListView.qml +++ b/Linphone/view/Control/Display/Participant/ParticipantListView.qml @@ -81,13 +81,12 @@ ListView { //TODO : Utilser checked et onToggled (pas compris) onToggled: participantModel.setParticipantAdminStatus(modelData.core, position === 1) } - Button { + SmallButton { Layout.preferredWidth: 20 * DefaultStyle.dp Layout.preferredHeight: 20 * DefaultStyle.dp color: DefaultStyle.main2_100 + style: ButtonStyle.hoveredBackground icon.source: AppIcons.closeX - icon.width: 14 * DefaultStyle.dp - icon.height: 14 * DefaultStyle.dp onClicked: participantModel.removeParticipant(modelData.core) } } @@ -99,22 +98,14 @@ ListView { visible: mainItem.isMeAdmin height: 74 * DefaultStyle.dp width: mainItem.width - Button { + MediumButton { anchors.centerIn: parent - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp height: 40 * DefaultStyle.dp icon.source: AppIcons.plusCircle icon.width: 16 * DefaultStyle.dp icon.height: 16 * DefaultStyle.dp - contentImageColor: DefaultStyle.main1_500_main - color: DefaultStyle.main1_100 text: qsTr("Ajouter des participants") - textColor: DefaultStyle.main1_500_main - textSize: 15 * DefaultStyle.dp - textWeight: 600 * DefaultStyle.dp + style: ButtonStyle.secondary onClicked: mainItem.addParticipantRequested() } } diff --git a/Linphone/view/Control/Display/ProgressBar.qml b/Linphone/view/Control/Display/ProgressBar.qml index 5b18aa53f..a82ee21a9 100644 --- a/Linphone/view/Control/Display/ProgressBar.qml +++ b/Linphone/view/Control/Display/ProgressBar.qml @@ -19,8 +19,9 @@ ProgressBar { id: textSize text: mainItem.innerText font { - pixelSize: 10 * DefaultStyle.dp - weight: 700 * DefaultStyle.dp + pixelSize: 10 * DefaultStyle.dp + weight: 700 * DefaultStyle.dp + bold: true } } diff --git a/Linphone/view/Control/Display/Sticker.qml b/Linphone/view/Control/Display/Sticker.qml index 4d91889d8..6fc02e99a 100644 --- a/Linphone/view/Control/Display/Sticker.qml +++ b/Linphone/view/Control/Display/Sticker.qml @@ -59,10 +59,6 @@ Item { property bool displayAll : !!mainItem.call property bool mutedStatus: participantDevice ? participantDevice.core.isMuted : false clip: false - onCallChanged: { - waitingTime.seconds = 0 - waitingTimer.restart() - } Rectangle { id: background color: noCameraLayout.visible ? mainItem.color : 'transparent' @@ -89,32 +85,8 @@ Item { BusyIndicator { indicatorColor: DefaultStyle.main2_100 Layout.alignment: Qt.AlignHCenter - indicatorHeight: 27 * DefaultStyle.dp - indicatorWidth: 27 * DefaultStyle.dp - } - Timer { - id: waitingTimer - interval: 1000 - repeat: true - onTriggered: waitingTime.seconds += 1 - } - Text { - id: waitingTime - property var isMeObj: UtilsCpp.isMe(mainItem.remoteAddress) - visible: isMeObj ? !isMeObj.value : false - property int seconds - text: UtilsCpp.formatElapsedTime(seconds) - color: DefaultStyle.grey_0 - Layout.alignment: Qt.AlignHCenter - horizontalAlignment: Text.AlignHCenter - Layout.topMargin: 25 * DefaultStyle.dp - font { - pixelSize: 30 * DefaultStyle.dp - weight: 300 * DefaultStyle.dp - } - Component.onCompleted: { - waitingTimer.restart() - } + indicatorHeight: 42 * DefaultStyle.dp + indicatorWidth: 42 * DefaultStyle.dp } } Item{ diff --git a/Linphone/view/Control/Display/Text.qml b/Linphone/view/Control/Display/Text.qml index 82bbdae0e..395495300 100644 --- a/Linphone/view/Control/Display/Text.qml +++ b/Linphone/view/Control/Display/Text.qml @@ -10,6 +10,7 @@ Quick.Text { family: DefaultStyle.defaultFont pixelSize: 10 * DefaultStyle.dp weight: 400 * DefaultStyle.dp + bold: true } color: DefaultStyle.main2_600 wrapMode: Quick.Text.Wrap diff --git a/Linphone/view/Control/Form/Login/LoginForm.qml b/Linphone/view/Control/Form/Login/LoginForm.qml index 77e9c9c95..618802076 100644 --- a/Linphone/view/Control/Form/Login/LoginForm.qml +++ b/Linphone/view/Control/Form/Login/LoginForm.qml @@ -60,12 +60,9 @@ ColumnLayout { RowLayout { Layout.topMargin: 7 * DefaultStyle.dp spacing: 29 * DefaultStyle.dp - Button { + BigButton { id: connectionButton - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main contentItem: StackLayout { id: connectionButtonContent currentIndex: 0 @@ -125,20 +122,11 @@ ColumnLayout { } onPressed: connectionButton.trigger() } - Button { + SmallButton { id: forgottenButton - background: Item { - visible: false - } - contentItem: Text { - color: DefaultStyle.main2_500main - text: qsTr("Mot de passe oublié ?") - font{ - underline: true - pixelSize: 13 * DefaultStyle.dp - weight: 600 * DefaultStyle.dp - } - } + style: ButtonStyle.noBackground + text: qsTr("Mot de passe oublié ?") + underline: true onClicked: Qt.openUrlExternally(ConstantsCpp.PasswordRecoveryUrl) } diff --git a/Linphone/view/Control/Form/Settings/EncryptionSettings.qml b/Linphone/view/Control/Form/Settings/EncryptionSettings.qml index e04240bad..86e233bee 100644 --- a/Linphone/view/Control/Form/Settings/EncryptionSettings.qml +++ b/Linphone/view/Control/Form/Settings/EncryptionSettings.qml @@ -91,9 +91,6 @@ ColumnLayout { Layout.bottomMargin: 13 * DefaultStyle.dp Layout.leftMargin: 16 * DefaultStyle.dp Layout.rightMargin: 16 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main } } \ No newline at end of file diff --git a/Linphone/view/Control/Form/Settings/ScreencastSettings.qml b/Linphone/view/Control/Form/Settings/ScreencastSettings.qml index 39266f188..f679ab85d 100644 --- a/Linphone/view/Control/Form/Settings/ScreencastSettings.qml +++ b/Linphone/view/Control/Form/Settings/ScreencastSettings.qml @@ -161,5 +161,6 @@ ColumnLayout { ? qsTr("Stop") : qsTr("Partager") onClicked: mainItem.conference.core.lToggleScreenSharing() + style: ButtonStyle.main } } diff --git a/Linphone/view/Control/Input/Calendar.qml b/Linphone/view/Control/Input/Calendar.qml index 830c1157c..b533cc6a7 100644 --- a/Linphone/view/Control/Input/Calendar.qml +++ b/Linphone/view/Control/Input/Calendar.qml @@ -60,7 +60,7 @@ ListView { Layout.preferredHeight: 20 * DefaultStyle.dp icon.width: width icon.height: height - background: Item{} + style: ButtonStyle.noBackground icon.source: AppIcons.leftArrow onClicked: if (mainItem.currentIndex > 0) mainItem.currentIndex = mainItem.currentIndex - 1 } @@ -70,7 +70,7 @@ ListView { Layout.preferredHeight: 20 * DefaultStyle.dp icon.width: width icon.height: height - background: Item{} + style: ButtonStyle.noBackground icon.source: AppIcons.rightArrow onClicked: if (mainItem.currentIndex < mainItem.count) mainItem.currentIndex = mainItem.currentIndex + 1 } diff --git a/Linphone/view/Control/Input/NumericPad.qml b/Linphone/view/Control/Input/NumericPad.qml index bf8b87aa8..4937bfead 100644 --- a/Linphone/view/Control/Input/NumericPad.qml +++ b/Linphone/view/Control/Input/NumericPad.qml @@ -107,35 +107,24 @@ FocusScope{ Repeater { id: numPadRepeater model: 9 - Button { + BigButton { id: numPadButton Layout.Layout.alignment: Qt.AlignHCenter required property int index implicitWidth: 60 * DefaultStyle.dp implicitHeight: 60 * DefaultStyle.dp onClicked: { - mainItem.buttonPressed(innerText.text) + mainItem.buttonPressed(text) } KeyNavigation.left: numPadGrid.getButtonAt(index - 1) KeyNavigation.right: numPadGrid.getButtonAt(index + 1) KeyNavigation.up: numPadGrid.getButtonAt(index - 3) KeyNavigation.down: numPadGrid.getButtonAt(index + 3) - background: Rectangle { - anchors.fill: parent - color: numPadButton.down || numPadButton.shadowEnabled? DefaultStyle.numericPadPressedButtonColor : DefaultStyle.grey_0 - radius: 71 * DefaultStyle.dp - } - contentItem: Text { - id: innerText - horizontalAlignment: Text.AlignHCenter - verticalAlignment: Text.AlignVCenter - anchors.centerIn: parent - text: index + 1 - font { - pixelSize: 32 * DefaultStyle.dp - weight: 400 * DefaultStyle.dp - } - } + style: ButtonStyle.numericPad + radius: 71 * DefaultStyle.dp + text: index + 1 + textSize: 32 * DefaultStyle.dp + textWeight: 400 * DefaultStyle.dp } } Repeater { @@ -145,7 +134,7 @@ FocusScope{ {pressText: "0", longPressText: "+"}, {pressText: "#"} ] - Button { + BigButton { id: digitButton Layout.Layout.alignment: Qt.AlignHCenter implicitWidth: 60 * DefaultStyle.dp @@ -158,16 +147,14 @@ FocusScope{ KeyNavigation.right: numPadGrid.getButtonAt((index + 1)+9) KeyNavigation.up: numPadGrid.getButtonAt((index - 3)+9) KeyNavigation.down: numPadGrid.getButtonAt((index + 3)+9) + radius: 71 * DefaultStyle.dp + style: ButtonStyle.numericPad - background: Rectangle { - anchors.fill: parent - color: digitButton.down || digitButton.shadowEnabled? DefaultStyle.numericPadPressedButtonColor : DefaultStyle.grey_0 - radius: 71 * DefaultStyle.dp - } contentItem: Item { anchors.fill: parent Text { id: pressText + color: digitButton.pressed ? digitButton.style.text.pressed : digitButton.style.text.normal height: contentHeight anchors.left: parent.left anchors.right: parent.right @@ -181,6 +168,7 @@ FocusScope{ height: contentHeight anchors.left: parent.left anchors.right: parent.right + color: digitButton.pressed ? digitButton.style.text.pressed : digitButton.style.text.normal y: digitButton.height/2 horizontalAlignment: Text.AlignHCenter visible: modelData.longPressText ? modelData.longPressText.length > 0 : false @@ -200,10 +188,10 @@ FocusScope{ implicitWidth: 75 * DefaultStyle.dp implicitHeight: 55 * DefaultStyle.dp Layout.Layout.alignment: Qt.AlignHCenter - icon.source: AppIcons.phone icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp - contentImageColor: DefaultStyle.grey_0 + radius: 71 * DefaultStyle.dp + style: ButtonStyle.phoneGreen onClicked: mainItem.launchCall() @@ -211,12 +199,6 @@ FocusScope{ KeyNavigation.right: eraseButton KeyNavigation.up: numPadGrid.getButtonAt(10) KeyNavigation.down: numPadGrid.getButtonAt(1) - - background: Rectangle { - anchors.fill: parent - color: DefaultStyle.success_500main - radius: 71 * DefaultStyle.dp - } } Button { id: eraseButton @@ -227,8 +209,11 @@ FocusScope{ bottomPadding: 5 * DefaultStyle.dp Layout.Layout.alignment: Qt.AlignHCenter icon.source: AppIcons.backspaceFill + style: ButtonStyle.noBackground icon.width: 38 * DefaultStyle.dp icon.height: 38 * DefaultStyle.dp + Layout.Layout.preferredWidth: 38 * DefaultStyle.dp + Layout.Layout.preferredHeight: 38 * DefaultStyle.dp onClicked: mainItem.wipe() diff --git a/Linphone/view/Control/Input/SearchBar.qml b/Linphone/view/Control/Input/SearchBar.qml index cde6a2dc5..2979f41f2 100644 --- a/Linphone/view/Control/Input/SearchBar.qml +++ b/Linphone/view/Control/Input/SearchBar.qml @@ -47,13 +47,14 @@ FocusScope { color: DefaultStyle.grey_100 border.color: textField.activeFocus ? mainItem.focusedBorderColor : mainItem.borderColor } - Image { + EffectImage { id: magnifier visible: mainItem.magnifierVisible + colorizationColor: DefaultStyle.main2_500main anchors.left: parent.left anchors.verticalCenter: parent.verticalCenter anchors.leftMargin: 10 * DefaultStyle.dp - source: AppIcons.magnifier + imageSource: AppIcons.magnifier width: 20 * DefaultStyle.dp height: 20 * DefaultStyle.dp } @@ -99,17 +100,15 @@ FocusScope { id: dialerButton visible: numericPadPopup != undefined && textField.text.length === 0 checked: numericPadPopup?.visible || false - background: Rectangle { - color: "transparent" - } - icon.source: dialerButton.checked ? AppIcons.dialerSelected : AppIcons.dialer + style: ButtonStyle.noBackground + icon.source: AppIcons.dialer + contentImageColor: dialerButton.checked ? DefaultStyle.main1_500_main : DefaultStyle.main2_600 + hoveredImageColor: contentImageColor width: 24 * DefaultStyle.dp height: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp anchors.verticalCenter: parent.verticalCenter anchors.right: parent.right - anchors.rightMargin: 15 * DefaultStyle.dp + anchors.rightMargin: 20 * DefaultStyle.dp onClicked: { if(!checked){ mainItem.openNumericPadRequested() @@ -120,18 +119,14 @@ FocusScope { Button { id: clearTextButton visible: textField.text.length > 0 && mainItem.enabled - background: Rectangle { - color: "transparent" - } width: 24 * DefaultStyle.dp height: 24 * DefaultStyle.dp + style: ButtonStyle.noBackground icon.source: AppIcons.closeX - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp anchors.top: parent.top anchors.bottom: parent.bottom anchors.right: parent.right - anchors.rightMargin: 15 * DefaultStyle.dp + anchors.rightMargin: 20 * DefaultStyle.dp onClicked: { textField.clear() } diff --git a/Linphone/view/Control/Input/TextField.qml b/Linphone/view/Control/Input/TextField.qml index 8704fa412..a497078f1 100644 --- a/Linphone/view/Control/Input/TextField.qml +++ b/Linphone/view/Control/Input/TextField.qml @@ -165,9 +165,7 @@ Control.TextField { z: 1 visible: mainItem.hidden checkable: true - background: Rectangle { - color: "transparent" - } + background: Item{} icon.source: eyeButton.checked ? AppIcons.eyeShow : AppIcons.eyeHide width: 20 * DefaultStyle.dp height: 20 * DefaultStyle.dp diff --git a/Linphone/view/Control/Popup/Dialog/AuthenticationDialog.qml b/Linphone/view/Control/Popup/Dialog/AuthenticationDialog.qml index dfbaa46db..0726a7efb 100644 --- a/Linphone/view/Control/Popup/Dialog/AuthenticationDialog.qml +++ b/Linphone/view/Control/Popup/Dialog/AuthenticationDialog.qml @@ -87,19 +87,20 @@ Dialog { } buttons: [ - Button { + MediumButton { id: cancelButton Layout.topMargin: 10 * DefaultStyle.dp text: qsTr("Annuler") - inversedColors: true + style: ButtonStyle.secondary onClicked: mainItem.rejected() KeyNavigation.up: passwordEdit KeyNavigation.right: connectButton }, - Button { + MediumButton { id: connectButton Layout.topMargin: 10 * DefaultStyle.dp text: qsTr("Se connecter") + style: ButtonStyle.main KeyNavigation.up: passwordEdit KeyNavigation.right: cancelButton onClicked: { diff --git a/Linphone/view/Control/Popup/Dialog/Dialog.qml b/Linphone/view/Control/Popup/Dialog/Dialog.qml index 723b92ade..f1160d5a2 100644 --- a/Linphone/view/Control/Popup/Dialog/Dialog.qml +++ b/Linphone/view/Control/Popup/Dialog/Dialog.qml @@ -110,16 +110,11 @@ Popup { // Default buttons only visible if no other children // have been set - Button { + MediumButton { id:firstButtonId visible: mainItem.buttons.length === 2 text: mainItem.firstButtonText - textSize: 15 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - inversedColors: !mainItem.firstButtonAccept + style: mainItem.firstButtonAccept ? ButtonStyle.main : ButtonStyle.secondary focus: !mainItem.firstButtonAccept onClicked: { if(mainItem.firstButtonAccept) @@ -131,15 +126,11 @@ Popup { KeyNavigation.left: secondButtonId KeyNavigation.right: secondButtonId } - Button { + MediumButton { id: secondButtonId visible: mainItem.buttons.length === 2 text: mainItem.secondButtonText - textSize: 15 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: mainItem.firstButtonAccept ? ButtonStyle.secondary : ButtonStyle.main focus: !mainItem.secondButtonAccept onClicked: { if(mainItem.secondButtonAccept) diff --git a/Linphone/view/Control/Popup/Dialog/ZrtpAuthenticationDialog.qml b/Linphone/view/Control/Popup/Dialog/ZrtpAuthenticationDialog.qml index e7eeb2cfe..0db0c2d13 100644 --- a/Linphone/view/Control/Popup/Dialog/ZrtpAuthenticationDialog.qml +++ b/Linphone/view/Control/Popup/Dialog/ZrtpAuthenticationDialog.qml @@ -82,15 +82,11 @@ Dialog { anchors.topMargin: 10 * DefaultStyle.dp anchors.rightMargin: 17 * DefaultStyle.dp background: Item{} - contentItem: Text { - text: qsTr("Passer") - color: DefaultStyle.grey_0 - font { - pixelSize: 13 * DefaultStyle.dp - weight: 600 * DefaultStyle.dp - underline: true - } - } + textSize: 13 * DefaultStyle.dp + textWeight: 600 * DefaultStyle.dp + text: qsTr("Passer") + textColor: DefaultStyle.grey_0 + underline: true onClicked: { call.core.lSkipZrtpAuthentication() mainItem.close() @@ -182,40 +178,20 @@ Dialog { property var modelList Repeater { model: mainItem.call && mainItem.call.core.remoteTokens || "" - Item { + Button { + Layout.Layout.preferredWidth: 70 * DefaultStyle.dp + Layout.Layout.preferredHeight: 70 * DefaultStyle.dp width: 70 * DefaultStyle.dp height: 70 * DefaultStyle.dp - Rectangle { - id: code - anchors.fill: parent - color: DefaultStyle.grey_0 - radius: 71 * DefaultStyle.dp - Text { - anchors.fill: parent - verticalAlignment: Text.AlignVCenter - horizontalAlignment: Text.AlignHCenter - text: modelData - font { - pixelSize: 32 * DefaultStyle.dp - weight: 400 * DefaultStyle.dp - } - } - MouseArea { - anchors.fill: parent - hoverEnabled: true - cursorShape: containsMouse ? Qt.PointingHandCursor : Qt.ArrowCursor - onClicked: { - console.log("CHECK TOKEN", modelData) - if(mainItem.call) mainItem.call.core.lCheckAuthenticationTokenSelected(modelData) - } - } - } - MultiEffect { - source: code - anchors.fill: code - shadowEnabled: true - shadowOpacity: 0.1 - shadowBlur: 0.1 + color: DefaultStyle.grey_0 + textSize: 32 * DefaultStyle.dp + textWeight: 400 * DefaultStyle.dp + text: modelData + radius: 71 * DefaultStyle.dp + textColor: DefaultStyle.main2_600 + onClicked: { + console.log("CHECK TOKEN", modelData) + if(mainItem.call) mainItem.call.core.lCheckAuthenticationTokenSelected(modelData) } } } @@ -252,36 +228,26 @@ Dialog { buttons: Layout.ColumnLayout { Layout.Layout.alignment: Qt.AlignHCenter - Button { + MediumButton { Layout.Layout.alignment: Qt.AlignHCenter + Layout.Layout.preferredWidth: 247 * DefaultStyle.dp text: qsTr("Aucune correspondance") - color: DefaultStyle.danger_500main - inversedColors: true - textSize: 15 * DefaultStyle.dp + color: DefaultStyle.grey_0 + borderColor: DefaultStyle.danger_500main + textColor: DefaultStyle.danger_500main visible: !mainItem.securityError - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp - width: 247 * DefaultStyle.dp onClicked: { if(mainItem.call) mainItem.call.core.lCheckAuthenticationTokenSelected(" ") } } - Button { - Layout.Layout.preferredWidth: 247 * DefaultStyle.dp + MediumButton { + Layout.Layout.preferredWidth: 247 * DefaultStyle.dp + Layout.Layout.alignment: Qt.AlignHCenter visible: mainItem.securityError - leftPadding: (247 * DefaultStyle.dp - contentItem.implicitWidth) /2 - rightPadding: (247 * DefaultStyle.dp - contentItem.implicitWidth) /2 - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp - color: DefaultStyle.danger_500main + style: ButtonStyle.phoneRed onClicked: mainItem.call.core.lTerminate() spacing: 15 * DefaultStyle.dp - icon.source: AppIcons.endCall - contentImageColor: DefaultStyle.grey_0 text: qsTr("Raccrocher") - textColor: DefaultStyle.grey_0 } } } \ No newline at end of file diff --git a/Linphone/view/Control/Popup/Loading/LoadingPopup.qml b/Linphone/view/Control/Popup/Loading/LoadingPopup.qml index a3e0247c7..19fcc38c7 100644 --- a/Linphone/view/Control/Popup/Loading/LoadingPopup.qml +++ b/Linphone/view/Control/Popup/Loading/LoadingPopup.qml @@ -32,10 +32,11 @@ Popup { text: mainItem.text font.pixelSize: 14 * DefaultStyle.dp } - Button { + MediumButton { visible: mainItem.cancelButtonVisible Layout.alignment: Qt.AlignHCenter text: qsTr("Annuler") + style: ButtonStyle.main onClicked: { if (callback) mainItem.callback() mainItem.close() diff --git a/Linphone/view/Control/Popup/Notification/NotificationReceivedCall.qml b/Linphone/view/Control/Popup/Notification/NotificationReceivedCall.qml index aceedc47b..660b751ca 100644 --- a/Linphone/view/Control/Popup/Notification/NotificationReceivedCall.qml +++ b/Linphone/view/Control/Popup/Notification/NotificationReceivedCall.qml @@ -99,17 +99,13 @@ Notification { spacing: 26 * DefaultStyle.dp Button { spacing: 6 * DefaultStyle.dp - color: DefaultStyle.success_500main - borderColor: color + style: ButtonStyle.phoneGreen Layout.preferredWidth: 118 * DefaultStyle.dp Layout.preferredHeight: 32 * DefaultStyle.dp asynchronous: false - icon.source: AppIcons.phone icon.width: 19 * DefaultStyle.dp icon.height: 19 * DefaultStyle.dp - contentImageColor: DefaultStyle.grey_0 text: qsTr("Répondre") - textColor: DefaultStyle.grey_0 textSize: 14 * DefaultStyle.dp textWeight: 500 * DefaultStyle.dp onClicked: { @@ -120,17 +116,13 @@ Notification { } Button { spacing: 6 * DefaultStyle.dp - color: DefaultStyle.danger_500main - borderColor: color + style: ButtonStyle.phoneRed Layout.preferredWidth: 118 * DefaultStyle.dp Layout.preferredHeight: 32 * DefaultStyle.dp asynchronous: false - icon.source: AppIcons.endCall icon.width: 19 * DefaultStyle.dp icon.height: 19 * DefaultStyle.dp - contentImageColor: DefaultStyle.grey_0 text: qsTr("Refuser") - textColor: DefaultStyle.grey_0 textSize: 14 * DefaultStyle.dp textWeight: 500 * DefaultStyle.dp onClicked: { diff --git a/Linphone/view/Control/Popup/NumericPadPopup.qml b/Linphone/view/Control/Popup/NumericPadPopup.qml index 50ed7af59..4afd28622 100644 --- a/Linphone/view/Control/Popup/NumericPadPopup.qml +++ b/Linphone/view/Control/Popup/NumericPadPopup.qml @@ -51,22 +51,17 @@ Control.Popup { anchors.fill: parent onClicked: numPad.forceActiveFocus() } - Button { + BigButton { id: closeButton visible: mainItem.closeButtonVisible anchors.top: parent.top anchors.right: parent.right anchors.topMargin: 10 * DefaultStyle.dp anchors.rightMargin: 10 * DefaultStyle.dp - background: Item { - anchors.fill: parent - visible: false - } icon.source: AppIcons.closeX - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp + style: ButtonStyle.noBackground onClicked: mainItem.close() } } diff --git a/Linphone/view/Page/Form/Call/NewCallForm.qml b/Linphone/view/Page/Form/Call/NewCallForm.qml index ab28aab87..d115eb947 100644 --- a/Linphone/view/Page/Form/Call/NewCallForm.qml +++ b/Linphone/view/Page/Form/Call/NewCallForm.qml @@ -115,16 +115,16 @@ FocusScope { font { pixelSize: 16 * DefaultStyle.dp weight: 800 * DefaultStyle.dp - underline: grouCallButton.shadowEnabled } } Item { Layout.fillWidth: true } - Image { - source: AppIcons.rightArrow + EffectImage { + imageSource: AppIcons.rightArrow Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp + colorizationColor: DefaultStyle.main2_500main } } } diff --git a/Linphone/view/Page/Form/Contact/ContactEdition.qml b/Linphone/view/Page/Form/Contact/ContactEdition.qml index aa0a86c8b..b08989593 100644 --- a/Linphone/view/Page/Form/Contact/ContactEdition.qml +++ b/Linphone/view/Page/Form/Contact/ContactEdition.qml @@ -86,15 +86,14 @@ MainRightPanel { IconLabelButton { id: addPictureButton Layout.preferredWidth: width - Layout.preferredHeight: 17 * DefaultStyle.dp visible: !mainItem.contact || mainItem.contact.core.pictureUri.length === 0 - iconSource: AppIcons.camera - iconSize: 17 * DefaultStyle.dp - backgroundColor: "transparent" + icon.source: AppIcons.camera text: qsTr("Ajouter une image") - color: DefaultStyle.main2_700 textSize: 16 * DefaultStyle.dp textWeight: 800 * DefaultStyle.dp + textColor: DefaultStyle.main2_700 + hoveredTextColor: DefaultStyle.main2_800 + pressedTextColor: DefaultStyle.main2_900 KeyNavigation.down: editButton.visible ? editButton : givenNameEdit onClicked: fileDialog.open() }, @@ -105,12 +104,11 @@ MainRightPanel { IconLabelButton { id: editButton Layout.preferredWidth: width - Layout.preferredHeight: 17 * DefaultStyle.dp - iconSource: AppIcons.pencil - iconSize: 17 * DefaultStyle.dp - backgroundColor: "transparent" + icon.source: AppIcons.pencil text: qsTr("Modifier") - color: DefaultStyle.main2_700 + textColor: DefaultStyle.main2_700 + hoveredTextColor: DefaultStyle.main2_800 + pressedTextColor: DefaultStyle.main2_900 textSize: 16 * DefaultStyle.dp textWeight: 800 * DefaultStyle.dp KeyNavigation.right: removeButton @@ -129,13 +127,12 @@ MainRightPanel { } IconLabelButton { id: removeButton - Layout.preferredHeight: 17 * DefaultStyle.dp Layout.preferredWidth: width - iconSize: 17 * DefaultStyle.dp - iconSource: AppIcons.trashCan - backgroundColor: "transparent" + icon.source: AppIcons.trashCan text: qsTr("Supprimer") - color: DefaultStyle.main2_700 + textColor: DefaultStyle.main2_700 + hoveredTextColor: DefaultStyle.main2_800 + pressedTextColor: DefaultStyle.main2_900 textSize: 16 * DefaultStyle.dp textWeight: 800 * DefaultStyle.dp KeyNavigation.left: editButton diff --git a/Linphone/view/Page/Form/Login/LoginPage.qml b/Linphone/view/Page/Form/Login/LoginPage.qml index 656ead44c..9874da42a 100644 --- a/Linphone/view/Page/Form/Login/LoginPage.qml +++ b/Linphone/view/Page/Form/Login/LoginPage.qml @@ -19,15 +19,11 @@ LoginLayout { Button { enabled: mainItem.showBackButton opacity: mainItem.showBackButton ? 1.0 : 0 - Layout.preferredHeight: 27 * DefaultStyle.dp - Layout.preferredWidth: 27 * DefaultStyle.dp Layout.leftMargin: 79 * DefaultStyle.dp icon.source: AppIcons.leftArrow - icon.width: width - icon.height: height - background: Rectangle { - color: "transparent" - } + icon.width: 24 * DefaultStyle.dp + icon.height: 24 * DefaultStyle.dp + style: ButtonStyle.noBackground onClicked: { console.debug("[LoginLayout] User: return") mainItem.goBack() @@ -36,9 +32,10 @@ LoginLayout { RowLayout { spacing: 15 * DefaultStyle.dp Layout.leftMargin: 21 * DefaultStyle.dp - Image { + EffectImage { fillMode: Image.PreserveAspectFit - source: AppIcons.profile + imageSource: AppIcons.profile + colorizationColor: DefaultStyle.main2_600 Layout.preferredHeight: 34 * DefaultStyle.dp Layout.preferredWidth: 34 * DefaultStyle.dp } @@ -63,12 +60,9 @@ LoginLayout { font.pixelSize: 14 * DefaultStyle.dp font.weight: 400 * DefaultStyle.dp } - Button { + BigButton { Layout.alignment: Qt.AlignRight - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main text: qsTr("S'inscrire") onClicked: { console.debug("[LoginPage] User: go to register") @@ -91,21 +85,21 @@ LoginLayout { id: loginForm onConnectionSucceed: mainItem.connectionSucceed() } - Button { - inversedColors: true + BigButton { Layout.preferredWidth: loginForm.width Layout.preferredHeight: 47 * DefaultStyle.dp Layout.topMargin: 39 * DefaultStyle.dp visible: !SettingsCpp.assistantHideThirdPartyAccount text: qsTr("Compte SIP tiers") + style: ButtonStyle.secondary onClicked: {mainItem.useSIPButtonClicked()} } - Button { - inversedColors: true + BigButton { Layout.preferredWidth: loginForm.width Layout.preferredHeight: 47 * DefaultStyle.dp Layout.topMargin: 25 * DefaultStyle.dp text: qsTr("Configuration distante") + style: ButtonStyle.secondary onClicked: {fetchConfigDialog.open()} } } @@ -136,10 +130,11 @@ LoginLayout { firstButton.text: 'Annuler' firstButtonAccept: false - firstButton.inversedColors: true + firstButton.style: ButtonStyle.secondary secondButton.text: 'Valider' secondButtonAccept: true + secondButton.style: ButtonStyle.main onAccepted:{ UtilsCpp.useFetchConfig(configUrl.text) } diff --git a/Linphone/view/Page/Form/Login/SIPLoginPage.qml b/Linphone/view/Page/Form/Login/SIPLoginPage.qml index 5e2e47702..b7b7d650b 100644 --- a/Linphone/view/Page/Form/Login/SIPLoginPage.qml +++ b/Linphone/view/Page/Form/Login/SIPLoginPage.qml @@ -22,23 +22,18 @@ LoginLayout { Layout.preferredHeight: 24 * DefaultStyle.dp Layout.preferredWidth: 24 * DefaultStyle.dp icon.source: AppIcons.leftArrow - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - background: Item { - anchors.fill: parent - } + style: ButtonStyle.noBackground onClicked: { console.debug("[SIPLoginPage] User: return") mainItem.goBack() } } - Image { + EffectImage { fillMode: Image.PreserveAspectFit source: AppIcons.profile Layout.preferredHeight: 34 * DefaultStyle.dp Layout.preferredWidth: 34 * DefaultStyle.dp - sourceSize.width: 34 * DefaultStyle.dp - sourceSize.height: 34 * DefaultStyle.dp + colorizationColor: DefaultStyle.main2_600 } Text { text: qsTr("Compte SIP tiers") @@ -64,13 +59,10 @@ LoginLayout { weight: 400 * DefaultStyle.dp } } - Button { + BigButton { Layout.alignment: Qt.AlignRight text: qsTr("S'inscrire") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main onClicked: { console.debug("[SIPLoginPage] User: go to register page") mainItem.goToRegister() @@ -128,17 +120,12 @@ LoginLayout { text: "Pour les activer dans un projet commercial, veuillez nous contacter. " } } - Button { + SmallButton { id: openLinkButton Layout.alignment: Qt.AlignCenter Layout.topMargin: 18 * DefaultStyle.dp text: "linphone.org/contact" - textSize: 13 * DefaultStyle.dp - inversedColors: true - leftPadding: 12 * DefaultStyle.dp - rightPadding: 12 * DefaultStyle.dp - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp + style: ButtonStyle.secondary onClicked: { Qt.openUrlExternally(ConstantsCpp.ContactUrl) } @@ -148,16 +135,11 @@ LoginLayout { } ColumnLayout { spacing: 20 * DefaultStyle.dp - Button { + BigButton { id: createAccountButton - // Layout.topMargin: 85 * DefaultStyle.dp + style: ButtonStyle.secondary Layout.fillWidth: true - inversedColors: true text: qsTr("Créer un compte linphone") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp onClicked: { console.debug("[SIPLoginPage] User: click register") mainItem.goToRegister() @@ -165,14 +147,11 @@ LoginLayout { KeyNavigation.up: openLinkButton KeyNavigation.down: continueButton } - Button { + BigButton { id: continueButton Layout.fillWidth: true text: qsTr("Je comprends") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main onClicked: { rootStackView.replace(secondItem) } @@ -297,13 +276,10 @@ LoginLayout { } } - Button { + BigButton { id: connectionButton Layout.topMargin: 32 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main contentItem: StackLayout { id: connectionButtonContent currentIndex: 0 diff --git a/Linphone/view/Page/Form/Meeting/AddParticipantsForm.qml b/Linphone/view/Page/Form/Meeting/AddParticipantsForm.qml index 8dc9594b8..a23f54d73 100644 --- a/Linphone/view/Page/Form/Meeting/AddParticipantsForm.qml +++ b/Linphone/view/Page/Form/Meeting/AddParticipantsForm.qml @@ -111,7 +111,7 @@ FocusScope{ weight: 800 * DefaultStyle.dp } } - AllContactListView{ + AllContactListView{ id: contactList Layout.fillWidth: true Layout.fillHeight: true diff --git a/Linphone/view/Page/Form/Meeting/MeetingForm.qml b/Linphone/view/Page/Form/Meeting/MeetingForm.qml index 0b96fffb0..901b78751 100644 --- a/Linphone/view/Page/Form/Meeting/MeetingForm.qml +++ b/Linphone/view/Page/Form/Meeting/MeetingForm.qml @@ -25,35 +25,6 @@ FocusScope { startDate.calendar.selectedDate = mainItem.conferenceInfoGui.core.dateTime } - component CheckableButton: Button { - id: checkableButton - checkable: true - autoExclusive: true - contentImageColor: checked ? DefaultStyle.grey_0 : DefaultStyle.main1_500_main - inversedColors: !checked - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - contentItem: RowLayout { - spacing: 8 * DefaultStyle.dp - EffectImage { - imageSource: checkableButton.icon.source - colorizationColor: checkableButton.checked ? DefaultStyle.grey_0 : DefaultStyle.main1_500_main - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp - } - Text { - text: checkableButton.text - color: checkableButton.checked ? DefaultStyle.grey_0 : DefaultStyle.main1_500_main - font { - pixelSize: 16 * DefaultStyle.dp - weight: 400 * DefaultStyle.dp - } - } - } - } - RowLayout { visible: mainItem.isCreation && !SettingsCpp.disableBroadcastFeature Layout.topMargin: 20 * DefaultStyle.dp @@ -67,6 +38,8 @@ FocusScope { enabled: false text: qsTr("Réunion") checked: true + autoExclusive: true + style: ButtonStyle.secondary } CheckableButton { Layout.preferredWidth: 151 * DefaultStyle.dp @@ -75,6 +48,8 @@ FocusScope { icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp text: qsTr("Broadcast") + autoExclusive: true + style: ButtonStyle.secondary } } Section { @@ -104,7 +79,7 @@ FocusScope { clear() else selectAll() } - onEditingFinished: mainItem.conferenceInfoGui.core.subject = text + onTextEdited: mainItem.conferenceInfoGui.core.subject = text KeyNavigation.down: startDate } } @@ -240,6 +215,7 @@ FocusScope { placeholderTextColor: DefaultStyle.main2_600 placeholderWeight: 700 * DefaultStyle.dp color: DefaultStyle.main2_600 + Component.onCompleted: text = conferenceInfoGui.core.description font { pixelSize: 14 * DefaultStyle.dp weight: 400 * DefaultStyle.dp @@ -310,7 +286,7 @@ FocusScope { _address: modelData.address } Text { - text: modelData.displayName + text: modelData.displayName || modelData.displayNameObj?.value || "" font.pixelSize: 14 * DefaultStyle.dp font.capitalization: Font.Capitalize } diff --git a/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml b/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml index 662d34586..181d64241 100644 --- a/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml +++ b/Linphone/view/Page/Form/Register/RegisterCheckingPage.qml @@ -22,19 +22,18 @@ LoginLayout { Layout.preferredHeight: 24 * DefaultStyle.dp Layout.preferredWidth: 24 * DefaultStyle.dp icon.source: AppIcons.leftArrow - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - background: Rectangle { - color: "transparent" - } + style: ButtonStyle.noBackground onClicked: { console.debug("[RegisterCheckingPage] User: return to register") mainItem.returnToRegister() } } - Image { + EffectImage { fillMode: Image.PreserveAspectFit - source: AppIcons.profile + imageSource: AppIcons.profile + Layout.preferredHeight: 34 * DefaultStyle.dp + Layout.preferredWidth: 34 * DefaultStyle.dp + colorizationColor: DefaultStyle.main2_600 } Text { wrapMode: Text.NoWrap @@ -146,12 +145,8 @@ LoginLayout { font.pixelSize: 14 * DefaultStyle.dp font.weight: 400 * DefaultStyle.dp } - Button { - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - inversedColors: true + BigButton { + style: ButtonStyle.secondary text: "Resend a code" onClicked: { console.debug("[RegisterCheckingPage] User: Resend code") diff --git a/Linphone/view/Page/Form/Register/RegisterPage.qml b/Linphone/view/Page/Form/Register/RegisterPage.qml index b61cd891e..f57b3aadb 100644 --- a/Linphone/view/Page/Form/Register/RegisterPage.qml +++ b/Linphone/view/Page/Form/Register/RegisterPage.qml @@ -33,9 +33,12 @@ LoginLayout { RowLayout { spacing: 21 * DefaultStyle.dp Layout.leftMargin: 119 * DefaultStyle.dp - Image { + EffectImage { fillMode: Image.PreserveAspectFit - source: AppIcons.profile + imageSource: AppIcons.profile + Layout.preferredHeight: 34 * DefaultStyle.dp + Layout.preferredWidth: 34 * DefaultStyle.dp + colorizationColor: DefaultStyle.main2_600 } Text { Layout.preferredWidth: width @@ -63,11 +66,8 @@ LoginLayout { weight: 400 * DefaultStyle.dp } } - Button { - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + BigButton { + style: ButtonStyle.main text: qsTr("Connexion") onClicked: { console.debug("[RegisterPage] User: return") @@ -291,10 +291,7 @@ LoginLayout { // } Button { enabled: termsCheckBox.checked - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main text: qsTr("Créer") onClicked:{ if (usernameInput.text.length === 0) { diff --git a/Linphone/view/Page/Form/Security/SecurityModePage.qml b/Linphone/view/Page/Form/Security/SecurityModePage.qml index 1eefc77aa..6258b45e8 100644 --- a/Linphone/view/Page/Form/Security/SecurityModePage.qml +++ b/Linphone/view/Page/Form/Security/SecurityModePage.qml @@ -8,9 +8,12 @@ LoginLayout { signal modeSelected(int index) titleContent: RowLayout { - Image { + EffectImage { fillMode: Image.PreserveAspectFit - source: AppIcons.profile + imageSource: AppIcons.profile + colorizationColor: DefaultStyle.main2_600 + Layout.preferredHeight: 34 * DefaultStyle.dp + Layout.preferredWidth: 34 * DefaultStyle.dp } ColumnLayout { Text { @@ -55,15 +58,13 @@ LoginLayout { } } } - Button { + BigButton { id: continueButton property int selectedIndex: 0 Layout.alignment: Qt.AlignHCenter - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - leftPadding: 100 * DefaultStyle.dp - rightPadding: 100 * DefaultStyle.dp + Layout.preferredWidth: 360 * DefaultStyle.dp text: qsTr("Continuer") + style: ButtonStyle.main onClicked: mainItem.modeSelected(selectedIndex) } Item { diff --git a/Linphone/view/Page/Form/Settings/AbstractSettingsMenu.qml b/Linphone/view/Page/Form/Settings/AbstractSettingsMenu.qml index 447d1f6c5..1c5432f97 100644 --- a/Linphone/view/Page/Form/Settings/AbstractSettingsMenu.qml +++ b/Linphone/view/Page/Form/Settings/AbstractSettingsMenu.qml @@ -38,15 +38,11 @@ AbstractMainPage { Layout.preferredHeight: 24 * DefaultStyle.dp Layout.preferredWidth: 24 * DefaultStyle.dp icon.source: AppIcons.leftArrow - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp + style: ButtonStyle.noBackground focus: true onClicked: { mainItem.goBackRequested() } - background: Item { - anchors.fill: parent - } } Text { text: titleText diff --git a/Linphone/view/Page/Layout/Login/LoginLayout.qml b/Linphone/view/Page/Layout/Login/LoginLayout.qml index 8862dd92f..fe2b7ffe0 100644 --- a/Linphone/view/Page/Layout/Login/LoginLayout.qml +++ b/Linphone/view/Page/Layout/Login/LoginLayout.qml @@ -105,13 +105,10 @@ Rectangle { Layout.preferredHeight: 10 * DefaultStyle.dp } } - Button { + MediumButton { Layout.alignment: Qt.AlignRight | Qt.AlignBottom text: qsTr("Fermer") - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp + style: ButtonStyle.main onClicked: aboutPopup.close() } } @@ -129,19 +126,16 @@ Rectangle { Item { Layout.fillWidth: true } - Button { + BigButton { id: aboutButton Layout.alignment: Qt.AlignRight | Qt.AlignVCenter - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp icon.source: AppIcons.info text: qsTr("À propos") - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp + textSize: Typography.p1.pixelSize + textWeight: Typography.p1.weight textColor: DefaultStyle.main2_500main onClicked: aboutPopup.open() - - background: Item{} + style: ButtonStyle.noBackground } } diff --git a/Linphone/view/Page/Layout/Main/MainLayout.qml b/Linphone/view/Page/Layout/Main/MainLayout.qml index 90f5b7781..23f5c920f 100644 --- a/Linphone/view/Page/Layout/Main/MainLayout.qml +++ b/Linphone/view/Page/Layout/Main/MainLayout.qml @@ -94,12 +94,12 @@ Item { y: contentItem.height/2 property var currentCall: callsModel.currentCall ? callsModel.currentCall : null property string remoteName: currentCall ? currentCall.core.remoteName : "" - contentItem: Button { + contentItem: MediumButton { + style: ButtonStyle.toast text: currentCallNotif.currentCall ? currentCallNotif.currentCall.core.conference ? ("Réunion en cours : ") + currentCallNotif.currentCall.core.conference.core.subject : (("Appel en cours : ") + currentCallNotif.remoteName) : "appel en cours" - color: DefaultStyle.success_500main onClicked: { var callsWindow = UtilsCpp.getCallsWindow(currentCallNotif.currentCall) UtilsCpp.smartShowWindow(callsWindow) @@ -184,24 +184,6 @@ Item { } KeyNavigation.down: contactList //contactLoader.item?.count > 0 || !contactLoader.item?.footerItem? contactLoader.item : contactLoader.item?.footerItem KeyNavigation.up: contactList//contactLoader.item?.footerItem ? contactLoader.item?.footerItem : contactLoader.item - - component MagicSearchButton: Button { - id: button - width: 45 * DefaultStyle.dp - height: 45 * DefaultStyle.dp - topPadding: 16 * DefaultStyle.dp - bottomPadding: 16 * DefaultStyle.dp - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_500main - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } - } Popup { id: listPopup @@ -290,12 +272,12 @@ Item { } popup.contentItem: ColumnLayout { IconLabelButton { - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true focus: visible - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Désactiver ne pas déranger") - iconSource: AppIcons.bellDnd + icon.source: AppIcons.bellDnd onClicked: { deactivateDndButton.popup.close() SettingsCpp.dnd = false @@ -394,23 +376,23 @@ Item { IconLabelButton { id: accountButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true visible: !SettingsCpp.hideAccountSettings - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Mon compte") - iconSource: AppIcons.manageProfile + icon.source: AppIcons.manageProfile onClicked: openAccountSettings(accountProxy.defaultAccount ? accountProxy.defaultAccount : accountProxy.firstAccount()) KeyNavigation.up: visibleChildren.length != 0 ? settingsMenuButton.getPreviousItem(0) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsMenuButton.getNextItem(0) : null } IconLabelButton { id: dndButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: SettingsCpp.dnd ? qsTr("Désactiver ne pas déranger") : qsTr("Activer ne pas déranger") - iconSource: AppIcons.bellDnd + icon.source: AppIcons.bellDnd onClicked: { settingsMenuButton.popup.close() SettingsCpp.dnd = !SettingsCpp.dnd @@ -420,45 +402,45 @@ Item { } IconLabelButton { id: settingsButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true visible: !SettingsCpp.hideSettings - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Paramètres") - iconSource: AppIcons.settings + icon.source: AppIcons.settings onClicked: openContextualMenuComponent(settingsPageComponent) KeyNavigation.up: visibleChildren.length != 0 ? settingsMenuButton.getPreviousItem(2) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsMenuButton.getNextItem(2) : null } IconLabelButton { id: recordsButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true visible: !SettingsCpp.disableCallRecordings - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Enregistrements") - iconSource: AppIcons.micro + icon.source: AppIcons.micro KeyNavigation.up: visibleChildren.length != 0 ? settingsMenuButton.getPreviousItem(3) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsMenuButton.getNextItem(3) : null } IconLabelButton { id: helpButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Aide") - iconSource: AppIcons.question + icon.source: AppIcons.question onClicked: openContextualMenuComponent(helpPageComponent) KeyNavigation.up: visibleChildren.length != 0 ? settingsMenuButton.getPreviousItem(4) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsMenuButton.getNextItem(4) : null } IconLabelButton { id: quitButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Quitter Linphone") - iconSource: AppIcons.power + icon.source: AppIcons.power onClicked: { settingsMenuButton.popup.close() UtilsCpp.getMainWindow().showConfirmationLambdaPopup("", @@ -483,12 +465,12 @@ Item { } IconLabelButton { id: addAccountButton - Layout.preferredHeight: 32 * DefaultStyle.dp Layout.fillWidth: true visible: SettingsCpp.maxAccount == 0 || SettingsCpp.maxAccount > accountProxy.count - iconSize: 32 * DefaultStyle.dp + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Ajouter un compte") - iconSource: AppIcons.plusCircle + icon.source: AppIcons.plusCircle onClicked: mainItem.addAccountRequest() KeyNavigation.up: visibleChildren.length != 0 ? settingsMenuButton.getPreviousItem(7) : null KeyNavigation.down: visibleChildren.length != 0 ? settingsMenuButton.getNextItem(7) : null diff --git a/Linphone/view/Page/Layout/Settings/AbstractSettingsLayout.qml b/Linphone/view/Page/Layout/Settings/AbstractSettingsLayout.qml index b65d3f8cf..6a656a989 100644 --- a/Linphone/view/Page/Layout/Settings/AbstractSettingsLayout.qml +++ b/Linphone/view/Page/Layout/Settings/AbstractSettingsLayout.qml @@ -33,30 +33,18 @@ Rectangle { Component.onCompleted: { setResponsivityFlags() } - Control.ScrollView { - id: scrollView - height: parent.height - width: parent.width - 2 * 45 * DefaultStyle.dp - anchors.centerIn: parent - contentHeight: (contentRepeater.height + header.height) + 20 * DefaultStyle.dp - contentWidth: parent.width - 2 * 45 * DefaultStyle.dp - Control.ScrollBar.vertical: ScrollBar { - active: scrollView.contentHeight > container.height - visible: scrollView.contentHeight > container.height - interactive: true - policy: Control.ScrollBar.AsNeeded - anchors.top: parent.top - anchors.bottom: parent.bottom - anchors.right: parent.right - anchors.rightMargin: -15 * DefaultStyle.dp + Control.Control { + id: header + anchors.left: parent.left + anchors.right: parent.right + leftPadding: 45 * DefaultStyle.dp + rightPadding: 45 * DefaultStyle.dp + z: 1 + background: Rectangle { + anchors.fill: parent + color: DefaultStyle.grey_0 } - Control.ScrollBar.horizontal: ScrollBar { - active: false - } - ColumnLayout { - id: header - width: parent.width - spacing: 10 * DefaultStyle.dp + contentItem: ColumnLayout { RowLayout { Layout.fillWidth: true Layout.topMargin: 20 * DefaultStyle.dp @@ -67,17 +55,13 @@ Rectangle { Layout.preferredHeight: 24 * DefaultStyle.dp Layout.preferredWidth: 24 * DefaultStyle.dp icon.source: AppIcons.leftArrow - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp focus: true visible: mainItem.container.depth > 1 Layout.rightMargin: 41 * DefaultStyle.dp + style: ButtonStyle.noBackground onClicked: { mainItem.container.pop() } - background: Item { - anchors.fill: parent - } } Text { text: titleText @@ -92,26 +76,55 @@ Rectangle { sourceComponent: mainItem.topbarOptionalComponent Layout.rightMargin: 34 * DefaultStyle.dp } - Button { + MediumButton { id: saveButton + style: ButtonStyle.main text: qsTr("Enregistrer") Layout.rightMargin: 6 * DefaultStyle.dp visible: mainItem.saveButtonVisible - textSize: 15 * DefaultStyle.dp - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - topPadding: 10 * DefaultStyle.dp - bottomPadding: 10 * DefaultStyle.dp onClicked: { mainItem.save() } } } + Rectangle { + Layout.fillWidth: true + height: 1 * DefaultStyle.dp + color: DefaultStyle.main2_500main + } + } + } + Control.ScrollView { + id: scrollView + anchors.top: header.bottom + anchors.topMargin: 16 * DefaultStyle.dp + anchors.bottom: parent.bottom + anchors.left: parent.left + anchors.right: parent.right + leftPadding: 45 * DefaultStyle.dp + rightPadding: 45 * DefaultStyle.dp + Control.ScrollBar.vertical: ScrollBar { + active: scrollView.contentHeight > scrollView.height + visible: scrollView.contentHeight > scrollView.height + interactive: true + policy: Control.ScrollBar.AsNeeded + anchors.top: parent.top + anchors.bottom: parent.bottom + anchors.right: parent.right + anchors.rightMargin: 15 * DefaultStyle.dp + } + Control.ScrollBar.horizontal: ScrollBar { + active: false + } + ColumnLayout { + width: parent.width + spacing: 10 * DefaultStyle.dp Repeater { id: contentRepeater model: mainItem.contentModel delegate: ColumnLayout { Rectangle { + visible: index !== 0 Layout.topMargin: (modelData.hideTopSeparator ? 0 : 16) * DefaultStyle.dp Layout.bottomMargin: 16 * DefaultStyle.dp Layout.fillWidth: true diff --git a/Linphone/view/Page/Layout/Settings/AccountSettingsGeneralLayout.qml b/Linphone/view/Page/Layout/Settings/AccountSettingsGeneralLayout.qml index 4c0f3e567..f556013d9 100644 --- a/Linphone/view/Page/Layout/Settings/AccountSettingsGeneralLayout.qml +++ b/Linphone/view/Page/Layout/Settings/AccountSettingsGeneralLayout.qml @@ -46,13 +46,13 @@ AbstractSettingsLayout { IconLabelButton { visible: model.core.pictureUri.length === 0 Layout.preferredWidth: width - Layout.preferredHeight: 17 * DefaultStyle.dp - iconSource: AppIcons.camera - iconSize: 17 * DefaultStyle.dp + icon.source: AppIcons.camera + icon.width: 17 * DefaultStyle.dp + icon.height: 17 * DefaultStyle.dp text: qsTr("Ajouter une image") + style: ButtonStyle.noBackground onClicked: fileDialog.open() Layout.alignment: Qt.AlignHCenter - color: DefaultStyle.main2_600 } RowLayout { visible: model.core.pictureUri.length > 0 @@ -60,20 +60,20 @@ AbstractSettingsLayout { spacing: 5 * DefaultStyle.dp IconLabelButton { Layout.preferredWidth: width - Layout.preferredHeight: 17 * DefaultStyle.dp - iconSource: AppIcons.pencil - iconSize: 17 * DefaultStyle.dp + icon.source: AppIcons.pencil + icon.width: 17 * DefaultStyle.dp + icon.height: 17 * DefaultStyle.dp text: qsTr("Modifier l'image") - color: DefaultStyle.main2_600 + style: ButtonStyle.noBackground onClicked: fileDialog.open() } IconLabelButton { Layout.preferredWidth: width - Layout.preferredHeight: 17 * DefaultStyle.dp - iconSource: AppIcons.trashCan - iconSize: 17 * DefaultStyle.dp + icon.source: AppIcons.trashCan + icon.width: 17 * DefaultStyle.dp + icon.height: 17 * DefaultStyle.dp text: qsTr("Supprimer l'image") - color: DefaultStyle.main2_600 + style: ButtonStyle.noBackground onClicked: model.core.pictureUri = "" } } @@ -108,11 +108,8 @@ AbstractSettingsLayout { } IconLabelButton { Layout.alignment: Qt.AlignRight - Layout.preferredWidth: 20 * DefaultStyle.dp - Layout.preferredHeight: 20 * DefaultStyle.dp - iconSize: 24 * DefaultStyle.dp - iconSource: AppIcons.copy - color: DefaultStyle.main2_600 + icon.source: AppIcons.copy + style: ButtonStyle.noBackground onClicked: UtilsCpp.copyToClipboard(model.core.identityAddress) } } @@ -184,16 +181,11 @@ AbstractSettingsLayout { Item { Layout.fillWidth: true } - Button { - background: Item{} + BigButton { + style: ButtonStyle.noBackgroundRed Layout.alignment: Qt.AlignRight Layout.rightMargin: 5 * DefaultStyle.dp - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp icon.source: AppIcons.trashCan - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - contentImageColor: DefaultStyle.danger_500main onClicked: { var mainWin = UtilsCpp.getMainWindow() mainWin.showConfirmationLambdaPopup("", @@ -280,7 +272,7 @@ AbstractSettingsLayout { icon.source: AppIcons.trashCan icon.width: 16 * DefaultStyle.dp icon.height: 16 * DefaultStyle.dp - contentImageColor: DefaultStyle.main1_500_main + style: ButtonStyle.tertiary onClicked: { var mainWin = UtilsCpp.getMainWindow() mainWin.showConfirmationLambdaPopup("", diff --git a/Linphone/view/Page/Layout/Settings/AdvancedSettingsLayout.qml b/Linphone/view/Page/Layout/Settings/AdvancedSettingsLayout.qml index 434fcdfcd..141666d84 100644 --- a/Linphone/view/Page/Layout/Settings/AdvancedSettingsLayout.qml +++ b/Linphone/view/Page/Layout/Settings/AdvancedSettingsLayout.qml @@ -81,6 +81,7 @@ AbstractSettingsLayout { Layout.topMargin: -20 * DefaultStyle.dp Layout.alignment: Qt.AlignRight text: qsTr("Télécharger et appliquer") + style: ButtonStyle.tertiary onClicked: { var url = configUri.value() if (UtilsCpp.isValidURL(url)) diff --git a/Linphone/view/Page/Layout/Settings/CarddavSettingsLayout.qml b/Linphone/view/Page/Layout/Settings/CarddavSettingsLayout.qml index 27123ea4b..3d3fdd1f8 100644 --- a/Linphone/view/Page/Layout/Settings/CarddavSettingsLayout.qml +++ b/Linphone/view/Page/Layout/Settings/CarddavSettingsLayout.qml @@ -40,12 +40,11 @@ AbstractSettingsLayout { id: topBar RowLayout { spacing: 20 * DefaultStyle.dp - Button { - background: Item{} + BigButton { + style: ButtonStyle.noBackground icon.source: AppIcons.trashCan icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_600 visible: !isNew onClicked: { var mainWin = UtilsCpp.getMainWindow() diff --git a/Linphone/view/Page/Layout/Settings/ContactsSettingsProviderLayout.qml b/Linphone/view/Page/Layout/Settings/ContactsSettingsProviderLayout.qml index 973005907..8bb88e43e 100644 --- a/Linphone/view/Page/Layout/Settings/ContactsSettingsProviderLayout.qml +++ b/Linphone/view/Page/Layout/Settings/ContactsSettingsProviderLayout.qml @@ -108,14 +108,11 @@ RowLayout { Item { Layout.fillWidth: true } - Button { + MediumButton { Layout.preferredHeight: 47 * DefaultStyle.dp Layout.alignment: Qt.AlignRight | Qt.AlignHCenter text: qsTr("Ajouter") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main visible: mainItem.showAddButton onClicked: { mainItem.owner.container.push(mainItem.settingsLayout, { diff --git a/Linphone/view/Page/Layout/Settings/DebugSettingsLayout.qml b/Linphone/view/Page/Layout/Settings/DebugSettingsLayout.qml index 5d454ca84..78e9aff0e 100644 --- a/Linphone/view/Page/Layout/Settings/DebugSettingsLayout.qml +++ b/Linphone/view/Page/Layout/Settings/DebugSettingsLayout.qml @@ -35,15 +35,17 @@ AbstractSettingsLayout { id: shareLogs text: qsTr("Les traces de débogage ont été téléversées. Comment souhaitez-vous partager le lien ? ") buttons: [ - Button { + BigButton { text: qsTr("Presse-papier") + style: ButtonStyle.main onClicked: { shareLogs.close() UtilsCpp.copyToClipboard(mainItem.logsUrl) } }, - Button { + BigButton { text: qsTr("E-Mail") + style: ButtonStyle.main onClicked: { shareLogs.close() if(!Qt.openUrlExternally( @@ -75,12 +77,14 @@ AbstractSettingsLayout { spacing: 20 * DefaultStyle.dp Layout.alignment: Qt.AlignRight MediumButton { + style: ButtonStyle.tertiary text: qsTr("Supprimer les traces") onClicked: { deleteLogs.open() } } MediumButton { + style: ButtonStyle.tertiary text: qsTr("Partager les traces") enabled: SettingsCpp.logsEnabled || SettingsCpp.fullLogsEnabled onClicked: { diff --git a/Linphone/view/Page/Layout/Settings/LdapSettingsLayout.qml b/Linphone/view/Page/Layout/Settings/LdapSettingsLayout.qml index 1258d116d..41ced1d51 100644 --- a/Linphone/view/Page/Layout/Settings/LdapSettingsLayout.qml +++ b/Linphone/view/Page/Layout/Settings/LdapSettingsLayout.qml @@ -36,11 +36,10 @@ AbstractSettingsLayout { RowLayout { spacing: 20 * DefaultStyle.dp Button { - background: Item{} + style: ButtonStyle.noBackground icon.source: AppIcons.trashCan icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_600 visible: !isNew onClicked: { var mainWin = UtilsCpp.getMainWindow() diff --git a/Linphone/view/Page/Main/AbstractMainPage.qml b/Linphone/view/Page/Main/AbstractMainPage.qml index 6626807cd..df61300a7 100644 --- a/Linphone/view/Page/Main/AbstractMainPage.qml +++ b/Linphone/view/Page/Main/AbstractMainPage.qml @@ -169,19 +169,11 @@ FocusScope { weight: 800 * DefaultStyle.dp } } - Button { + BigButton { Layout.alignment: Qt.AlignHCenter - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp icon.source: mainItem.newItemIconSource - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - contentImageColor: DefaultStyle.grey_0 + style: ButtonStyle.main text: mainItem.noItemButtonText - textSize: 18 * DefaultStyle.dp - textWeight: 600 * DefaultStyle.dp spacing: 8 * DefaultStyle.dp onPressed: mainItem.noItemButtonPressed() } diff --git a/Linphone/view/Page/Main/Call/CallPage.qml b/Linphone/view/Page/Main/Call/CallPage.qml index f3e5a688e..2958718a5 100644 --- a/Linphone/view/Page/Main/Call/CallPage.qml +++ b/Linphone/view/Page/Main/Call/CallPage.qml @@ -82,6 +82,7 @@ AbstractMainPage { Loader { id: titleLoader anchors.left: parent.left + anchors.leftMargin: 45 * DefaultStyle.dp anchors.right: parent.right asynchronous: false onActiveFocusChanged:{ @@ -137,7 +138,6 @@ AbstractMainPage { spacing: 16 * DefaultStyle.dp Text { text: qsTr("Appels") - Layout.leftMargin: 45 * DefaultStyle.dp color: DefaultStyle.main2_700 font.pixelSize: 29 * DefaultStyle.dp font.weight: 800 * DefaultStyle.dp @@ -151,18 +151,15 @@ AbstractMainPage { height: 24 * DefaultStyle.dp focus: true popup.x: 0 - popup.padding: 20 * DefaultStyle.dp KeyNavigation.right: newCallButton KeyNavigation.down: listStackView popup.contentItem: ColumnLayout { IconLabelButton { - Layout.preferredHeight: 24 * DefaultStyle.dp Layout.fillWidth: true focus: visible - iconSize: 24 * DefaultStyle.dp text: qsTr("Supprimer l'historique") - iconSource: AppIcons.trashCan - color: DefaultStyle.danger_500main + icon.source: AppIcons.trashCan + style: ButtonStyle.hoveredBackgroundRed onClicked: { removeHistory.close() deleteHistoryPopup.open() @@ -320,8 +317,8 @@ AbstractMainPage { RowLayout { z: 1 anchors.fill: parent - anchors.leftMargin: 5 * DefaultStyle.dp - anchors.rightMargin: 5 * DefaultStyle.dp + anchors.leftMargin: 10 * DefaultStyle.dp + anchors.rightMargin: 15 * DefaultStyle.dp spacing: 10 * DefaultStyle.dp Avatar { id: historyAvatar @@ -391,17 +388,12 @@ AbstractMainPage { } } } - Button { + BigButton { padding: 0 - background: Item { - visible: false - } + style: ButtonStyle.noBackground icon.source: AppIcons.phone - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_600 + // Layout.preferredWidth: 24 * DefaultStyle.dp + // Layout.preferredHeight: 24 * DefaultStyle.dp focus: true activeFocusOnTab: false onClicked: { @@ -461,15 +453,12 @@ AbstractMainPage { height: parent.height RowLayout { anchors.fill: parent + spacing: 10 * DefaultStyle.dp Button { - Layout.leftMargin: 45 * DefaultStyle.dp - background: Item { - } Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp + style: ButtonStyle.noBackground icon.source: AppIcons.leftArrow - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp focus: true KeyNavigation.down: listStackView onClicked: { @@ -539,14 +528,11 @@ AbstractMainPage { visible: !SettingsCpp.disableMeetingsFeature Button { id: backGroupCallButton - background: Item{} + style: ButtonStyle.noBackgroundOrange icon.source: AppIcons.leftArrow - contentImageColor: DefaultStyle.main1_500_main Layout.leftMargin: 21 * DefaultStyle.dp Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp KeyNavigation.down: listStackView KeyNavigation.right: groupCallButton KeyNavigation.left: groupCallButton @@ -578,16 +564,12 @@ AbstractMainPage { Layout.fillWidth: true } } - Button { + SmallButton { id: groupCallButton enabled: mainItem.selectedParticipantsCount.length != 0 Layout.rightMargin: 21 * DefaultStyle.dp - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - leftPadding: 12 * DefaultStyle.dp - rightPadding: 12 * DefaultStyle.dp text: qsTr("Lancer") - textSize: 13 * DefaultStyle.dp + style: ButtonStyle.main KeyNavigation.down: listStackView KeyNavigation.left: backGroupCallButton KeyNavigation.right: backGroupCallButton @@ -686,7 +668,6 @@ AbstractMainPage { buttonContent: PopupButton { id: detailOptions anchors.right: parent.right - anchors.rightMargin: 30 * DefaultStyle.dp anchors.verticalCenter: parent.verticalCenter popup.x: width property var friendGuiObj: UtilsCpp.findFriendByAddress(contactDetail.contactAddress) @@ -703,17 +684,12 @@ AbstractMainPage { ColumnLayout { id: detailsButtons anchors.fill: parent - Button { + IconLabelButton { + Layout.fillWidth: true text: detailOptions.friendGui ? qsTr("Voir le contact") : qsTr("Ajouter aux contacts") icon.source: AppIcons.plusCircle - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - textColor: DefaultStyle.main2_500main - contentImageColor: DefaultStyle.main2_600 - background: Item {} + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp visible: SettingsCpp.syncLdapContacts || !detailOptions.friendGui?.core?.isLdap onClicked: { detailOptions.close() @@ -721,18 +697,12 @@ AbstractMainPage { else mainItem.createContactRequested(contactDetail.contactName, contactDetail.contactAddress) } } - Button { + IconLabelButton { + Layout.fillWidth: true text: qsTr("Copier l'adresse SIP") icon.source: AppIcons.copy - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - textColor: DefaultStyle.main2_500main - contentImageColor: DefaultStyle.main2_600 - background: Item {} - + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp onClicked: { detailOptions.close() var success = UtilsCpp.copyToClipboard(mainItem.selectedRowHistoryGui && mainItem.selectedRowHistoryGui.core.remoteAddress) @@ -740,7 +710,7 @@ AbstractMainPage { else UtilsCpp.showInformationPopup(qsTr("Erreur"), qsTr("Erreur lors de la copie de l'adresse"), false) } } - // Button { + // IconLabelButton { // background: Item {} // enabled: false // contentItem: IconLabel { @@ -755,18 +725,13 @@ AbstractMainPage { color: DefaultStyle.main2_400 } - Button { + IconLabelButton { + Layout.fillWidth: true text: qsTr("Supprimer l'historique") icon.source: AppIcons.trashCan - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - textColor: DefaultStyle.danger_500main - contentImageColor: DefaultStyle.danger_500main - background: Item {} - + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp + style: ButtonStyle.hoveredBackgroundRed Connections { target: deleteForUserPopup function onAccepted() { diff --git a/Linphone/view/Page/Main/Call/CallSettingsPanel.qml b/Linphone/view/Page/Main/Call/CallSettingsPanel.qml index 52e851e2a..db775a980 100644 --- a/Linphone/view/Page/Main/Call/CallSettingsPanel.qml +++ b/Linphone/view/Page/Main/Call/CallSettingsPanel.qml @@ -68,17 +68,13 @@ Control.Page { RowLayout { id: customButtonLayout } - Button { + RoundButton { id: closeButton visible: mainItem.closeButtonVisible background: Item { visible: false } icon.source: AppIcons.closeX - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp onClicked: mainItem.visible = false } } @@ -86,11 +82,10 @@ Control.Page { Layout.alignment: Qt.AlignVCenter spacing: 10 * DefaultStyle.dp Button { - background: Item{} + style: ButtonStyle.noBackgroundOrange icon.source: AppIcons.leftArrow icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp - contentImageColor: DefaultStyle.main1_500_main onClicked: mainItem.returnRequested() } ColumnLayout { @@ -121,15 +116,10 @@ Control.Page { Layout.fillWidth: true Layout.fillHeight: true } - Button { + SmallButton { + style: ButtonStyle.main text: mainItem.headerValidateButtonText - textSize: 13 * DefaultStyle.dp - textWeight: 600 * DefaultStyle.dp onClicked: mainItem.validateRequested() - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - leftPadding: 12 * DefaultStyle.dp - rightPadding: 12 * DefaultStyle.dp } } } diff --git a/Linphone/view/Page/Main/Call/WaitingRoom.qml b/Linphone/view/Page/Main/Call/WaitingRoom.qml index 476a6b416..454fbafd2 100644 --- a/Linphone/view/Page/Main/Call/WaitingRoom.qml +++ b/Linphone/view/Page/Main/Call/WaitingRoom.qml @@ -67,10 +67,7 @@ RowLayout { CheckableButton { id: settingsButton visible: stackLayout.currentIndex === 0 - icon.source: AppIcons.more - color: DefaultStyle.grey_500 - checkedColor: DefaultStyle.main2_100 - contentImageColor: checked ? DefaultStyle.grey_500 : DefaultStyle.grey_0 + icon.source: AppIcons.verticalDots Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 24 * DefaultStyle.dp @@ -119,25 +116,19 @@ RowLayout { } ColumnLayout { spacing: 5 * DefaultStyle.dp - Button { + BigButton { Layout.preferredWidth: 292 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp text: qsTr("Rejoindre") + style: ButtonStyle.main onClicked: { settingsButton.checked = false stackLayout.currentIndex = 1 mainItem.joinConfRequested(mainItem.conferenceInfo.core.uri) } } - Button { + BigButton { Layout.preferredWidth: 292 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp - inversedColors: true + style: ButtonStyle.secondary text: qsTr("Annuler") onClicked: { mainItem.cancelJoiningRequested() @@ -174,13 +165,10 @@ RowLayout { Layout.preferredWidth: 48 * DefaultStyle.dp Layout.preferredHeight: 48 * DefaultStyle.dp } - Button { + BigButton { Layout.preferredWidth: 292 * DefaultStyle.dp Layout.alignment: Qt.AlignHCenter - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main text: qsTr("Annuler") onClicked: { settingsButton.checked = false diff --git a/Linphone/view/Page/Main/Contact/ContactPage.qml b/Linphone/view/Page/Main/Contact/ContactPage.qml index 7a3b60fde..6e3f55d4e 100644 --- a/Linphone/view/Page/Main/Contact/ContactPage.qml +++ b/Linphone/view/Page/Main/Contact/ContactPage.qml @@ -100,21 +100,14 @@ AbstractMainPage { Item{Layout.fillWidth: true} RowLayout { spacing: 15 * DefaultStyle.dp - Button { - inversedColors: true + BigButton { + style: ButtonStyle.secondary text: qsTr("Annuler") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp onClicked: verifyDevicePopup.close() } - Button { + BigButton { + style: ButtonStyle.main text: qsTr("Appeler") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp onClicked: { SettingsCpp.setDisplayDeviceCheckConfirmation(!neverDisplayAgainCheckbox.checked) UtilsCpp.createCall(verifyDevicePopup.deviceAddress, {}, LinphoneEnums.MediaEncryption.Zrtp) @@ -138,6 +131,7 @@ AbstractMainPage { } EffectImage { imageSource: AppIcons.arrowRight + colorizationColor: DefaultStyle.main2_600 Layout.preferredWidth: 45 * DefaultStyle.dp Layout.preferredHeight: 45 * DefaultStyle.dp } @@ -150,6 +144,7 @@ AbstractMainPage { } buttons: Button { text: qsTr("Ok") + style: ButtonStyle.main leftPadding: 30 * DefaultStyle.dp rightPadding: 30 * DefaultStyle.dp onClicked: trustInfoDialog.close() @@ -187,10 +182,10 @@ AbstractMainPage { background: Item { } icon.source: AppIcons.plusCircle - Layout.preferredWidth: 30 * DefaultStyle.dp - Layout.preferredHeight: 30 * DefaultStyle.dp - icon.width: 30 * DefaultStyle.dp - icon.height: 30 * DefaultStyle.dp + Layout.preferredWidth: 28 * DefaultStyle.dp + Layout.preferredHeight: 28 * DefaultStyle.dp + icon.width: 28 * DefaultStyle.dp + icon.height: 28 * DefaultStyle.dp onClicked: { mainItem.createContact("", "") } @@ -276,27 +271,20 @@ AbstractMainPage { weight: 800 * DefaultStyle.dp } } - Button { + RoundButton { visible: contactDetailLayout.icon != undefined icon.source: contactDetailLayout.icon contentImageColor: DefaultStyle.main1_500_main - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp background: Item{} onClicked: contactDetailLayout.titleIconClicked() } Item{Layout.fillWidth: true} - Button { + RoundButton { id: expandButton - background: Item{} + style: ButtonStyle.noBackground checkable: true checked: true icon.source: checked ? AppIcons.upArrow : AppIcons.downArrow - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_600 KeyNavigation.down: contentControl } } @@ -316,13 +304,8 @@ AbstractMainPage { contact: mainItem.selectedContact button.color: DefaultStyle.main1_100 button.text: qsTr("Modifier") + button.style: ButtonStyle.tertiary button.icon.source: AppIcons.pencil - button.textColor: DefaultStyle.main1_500_main - button.contentImageColor: DefaultStyle.main1_500_main - button.leftPadding: 16 * DefaultStyle.dp - button.rightPadding: 16 * DefaultStyle.dp - button.topPadding: 10 * DefaultStyle.dp - button.bottomPadding: 10 * DefaultStyle.dp button.onClicked: mainItem.editContact(mainItem.selectedContact) button.visible: !mainItem.selectedContact?.core.readOnly property string contactAddress: contact ? contact.core.defaultAddress : "" @@ -337,21 +320,12 @@ AbstractMainPage { property alias button: button property string label spacing: 8 * DefaultStyle.dp - Button { + RoundButton { id: button Layout.alignment: Qt.AlignHCenter Layout.preferredWidth: 56 * DefaultStyle.dp Layout.preferredHeight: 56 * DefaultStyle.dp - topPadding: 16 * DefaultStyle.dp - bottomPadding: 16 * DefaultStyle.dp - leftPadding: 16 * DefaultStyle.dp - rightPadding: 16 * DefaultStyle.dp - contentImageColor: DefaultStyle.main2_600 - background: Rectangle { - anchors.fill: parent - radius: 40 * DefaultStyle.dp - color: DefaultStyle.main2_200 - } + style: ButtonStyle.grey } Text { Layout.alignment: Qt.AlignHCenter @@ -493,15 +467,9 @@ AbstractMainPage { Item { Layout.fillWidth: true } - Button { + RoundButton { background: Item{} - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp icon.source: AppIcons.phone - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp onClicked: { UtilsCpp.createCall(listViewModelData.address) } @@ -534,7 +502,7 @@ AbstractMainPage { height: 50 * DefaultStyle.dp visible: companyText.text.length != 0 Text { - text: qsTr("Company :") + text: qsTr("Société :") font { pixelSize: 13 * DefaultStyle.dp weight: 700 * DefaultStyle.dp @@ -553,7 +521,7 @@ AbstractMainPage { height: 50 * DefaultStyle.dp visible: jobText.text.length != 0 Text { - text: qsTr("Job :") + text: qsTr("Poste :") font { pixelSize: 13 * DefaultStyle.dp weight: 700 * DefaultStyle.dp @@ -576,22 +544,19 @@ AbstractMainPage { label: qsTr("Medias") Layout.fillWidth: true content: Button { - background: Rectangle { - anchors.fill: parent - color: DefaultStyle.grey_0 - radius: 15 * DefaultStyle.dp - } + background: Item{} contentItem: RowLayout { - Image { + EffectImage { Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp source: AppIcons.shareNetwork + colorizationColor: DefaultStyle.main2_600 } Text { - text: qsTr("Show media shared") + text: qsTr("Afficher les medias partagés") font { - pixelSize: 14 * DefaultStyle.dp - weight: 400 * DefaultStyle.dp + pixelSize: Typography.p1.pixelSize + weight: Typography.p1.weight } } Item{Layout.fillWidth: true} @@ -656,21 +621,12 @@ AbstractMainPage { height: 22 * DefaultStyle.dp } - Button { - Layout.preferredHeight: 30 * DefaultStyle.dp + SmallButton { + // Layout.preferredHeight: 30 * DefaultStyle.dp visible: listViewModelData.securityLevel != LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified - color: DefaultStyle.main1_100 icon.source: AppIcons.warningCircle - icon.height: 14 * DefaultStyle.dp - icon.width: 14 * DefaultStyle.dp - contentImageColor: DefaultStyle.main1_500_main - textColor: DefaultStyle.main1_500_main - textSize: 13 * DefaultStyle.dp + style: ButtonStyle.tertiary text: qsTr("Vérifier") - // leftPadding: 12 * DefaultStyle.dp - // rightPadding: 12 * DefaultStyle.dp - // topPadding: 6 * DefaultStyle.dp - // bottomPadding: 6 * DefaultStyle.dp onClicked: { if (SettingsCpp.getDisplayDeviceCheckConfirmation()) { verifyDevicePopup.deviceName = deviceDelegate.deviceName @@ -695,11 +651,11 @@ AbstractMainPage { IconLabelButton { Layout.fillWidth: true Layout.preferredHeight: 50 * DefaultStyle.dp - iconSize: 24 * DefaultStyle.dp - iconSource: AppIcons.pencil + icon.source: AppIcons.pencil text: qsTr("Éditer") onClicked: mainItem.editContact(mainItem.selectedContact) visible: !mainItem.selectedContact?.core.readOnly + style: ButtonStyle.noBackground } Rectangle { Layout.fillWidth: true @@ -709,9 +665,9 @@ AbstractMainPage { IconLabelButton { Layout.fillWidth: true Layout.preferredHeight: 50 * DefaultStyle.dp - iconSize: 24 * DefaultStyle.dp - iconSource: mainItem.selectedContact && mainItem.selectedContact.core.starred ? AppIcons.heartFill : AppIcons.heart + icon.source: mainItem.selectedContact && mainItem.selectedContact.core.starred ? AppIcons.heartFill : AppIcons.heart text: mainItem.selectedContact && mainItem.selectedContact.core.starred ? qsTr("Retirer des favoris") : qsTr("Ajouter aux favoris") + style: ButtonStyle.noBackground onClicked: if (mainItem.selectedContact) mainItem.selectedContact.core.lSetStarred(!mainItem.selectedContact.core.starred) } Rectangle { @@ -722,9 +678,9 @@ AbstractMainPage { IconLabelButton { Layout.fillWidth: true Layout.preferredHeight: 50 * DefaultStyle.dp - iconSize: 24 * DefaultStyle.dp - iconSource: AppIcons.shareNetwork + icon.source: AppIcons.shareNetwork text: qsTr("Partager") + style: ButtonStyle.noBackground onClicked: { if (mainItem.selectedContact) { var vcard = mainItem.selectedContact.core.getVCard() @@ -744,8 +700,7 @@ AbstractMainPage { // IconLabelButton { // Layout.fillWidth: true // Layout.preferredHeight: 50 * DefaultStyle.dp - // iconSize: 24 * DefaultStyle.dp - // iconSource: AppIcons.bellSlash + // icon.source: AppIcons.bellSlash // text: qsTr("Mettre en sourdine") // onClicked: console.log("TODO : mute contact") // } @@ -757,8 +712,7 @@ AbstractMainPage { // IconLabelButton { // Layout.fillWidth: true // Layout.preferredHeight: 50 * DefaultStyle.dp - // iconSize: 24 * DefaultStyle.dp - // iconSource: AppIcons.empty + // icon.source: AppIcons.empty // text: qsTr("Bloquer") // onClicked: console.log("TODO : block contact") // } @@ -770,14 +724,13 @@ AbstractMainPage { IconLabelButton { Layout.fillWidth: true Layout.preferredHeight: 50 * DefaultStyle.dp - iconSize: 24 * DefaultStyle.dp - iconSource: AppIcons.trashCan - color: DefaultStyle.danger_500main + icon.source: AppIcons.trashCan text: qsTr("Supprimer ce contact") visible: !mainItem.selectedContact?.core.readOnly onClicked: { mainItem.deleteContact(mainItem.selectedContact) } + style: ButtonStyle.noBackgroundRed } } diff --git a/Linphone/view/Page/Main/Help/HelpPage.qml b/Linphone/view/Page/Main/Help/HelpPage.qml index 2a39814e0..8c8245150 100644 --- a/Linphone/view/Page/Main/Help/HelpPage.qml +++ b/Linphone/view/Page/Main/Help/HelpPage.qml @@ -25,14 +25,10 @@ AbstractMainPage { Layout.rightMargin: leftPanel.sideMargin spacing: 5 * DefaultStyle.dp Button { - Layout.preferredHeight: 24 * DefaultStyle.dp - Layout.preferredWidth: 24 * DefaultStyle.dp icon.source: AppIcons.leftArrow - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp - background: Item { - anchors.fill: parent - } + style: ButtonStyle.noBackground + icon.width: 24 * DefaultStyle.dp + icon.height: 24 * DefaultStyle.dp onClicked: { mainItem.goBack() } @@ -53,7 +49,7 @@ AbstractMainPage { Layout.fillWidth: true text: qsTr("À propos de Linphone") color: DefaultStyle.main2_600 - font: Typography.h3m + font: Typography.h4 } ColumnLayout { Layout.fillWidth: true @@ -105,7 +101,7 @@ AbstractMainPage { Layout.fillWidth: true text: qsTr("À propos de Linphone") color: DefaultStyle.main2_600 - font: Typography.h3m + font: Typography.h4 } HelpIconLabelButton { id: troubleShooting diff --git a/Linphone/view/Page/Main/Meeting/MeetingPage.qml b/Linphone/view/Page/Main/Meeting/MeetingPage.qml index 64cbedac8..14b1f38a5 100644 --- a/Linphone/view/Page/Main/Meeting/MeetingPage.qml +++ b/Linphone/view/Page/Main/Meeting/MeetingPage.qml @@ -74,37 +74,27 @@ AbstractMainPage { // width: 278 * DefaultStyle.dp text: cancel ? qsTr("Souhaitez-vous annuler et supprimer cette réunion ?") : qsTr("Souhaitez-vous supprimer cette réunion ?") buttons: [ - Button { + BigButton { visible: cancelAndDeleteConfDialog.cancel + style: ButtonStyle.main text: qsTr("Annuler et supprimer") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp onClicked: { cancelAndDeleteConfDialog.cancelRequested() cancelAndDeleteConfDialog.accepted() cancelAndDeleteConfDialog.close() } }, - Button { + BigButton { text: cancelAndDeleteConfDialog.cancel ? qsTr("Supprimer seulement") : qsTr("Supprimer") - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main onClicked: { cancelAndDeleteConfDialog.accepted() cancelAndDeleteConfDialog.close() } }, - Button { + BigButton { text: qsTr("Retour") - inversedColors: true - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.secondary onClicked: { cancelAndDeleteConfDialog.rejected() cancelAndDeleteConfDialog.close() @@ -152,8 +142,7 @@ AbstractMainPage { } Item{Layout.fillWidth: true} Button { - background: Item { - } + background: Item {} icon.source: AppIcons.plusCircle Layout.preferredWidth: 28 * DefaultStyle.dp Layout.preferredHeight: 28 * DefaultStyle.dp @@ -232,15 +221,11 @@ AbstractMainPage { spacing: 5 * DefaultStyle.dp Button { id: backButton - background: Item{} + style: ButtonStyle.noBackground icon.source: AppIcons.leftArrow - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp + focus: true icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - focus: true KeyNavigation.right: createButton KeyNavigation.down: meetingSetup onClicked: { @@ -258,13 +243,10 @@ AbstractMainPage { Layout.fillWidth: true } Item {Layout.fillWidth: true} - Button { + SmallButton { id: createButton - Layout.preferredWidth: 57 * DefaultStyle.dp - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - textSize: 13 * DefaultStyle.dp text: qsTr("Créer") + style: ButtonStyle.main KeyNavigation.left: backButton KeyNavigation.down: meetingSetup @@ -356,11 +338,10 @@ AbstractMainPage { Layout.preferredWidth: overridenRightPanelStackView.width Button { id: backButton - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp + icon.source: AppIcons.leftArrow icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp - icon.source: AppIcons.leftArrow + style: ButtonStyle.noBackground KeyNavigation.left: saveButton KeyNavigation.right: titleText KeyNavigation.down: conferenceEdit @@ -369,7 +350,6 @@ AbstractMainPage { conferenceEdit.conferenceInfoGui.core.undo() overridenRightPanelStackView.pop() } - background: Item{} } RowLayout { spacing: 8 * DefaultStyle.dp @@ -398,15 +378,11 @@ AbstractMainPage { text = mainItem.selectedConference.core.subject } } - Button { + SmallButton { id: saveButton - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - leftPadding: 12 * DefaultStyle.dp - rightPadding: 12 * DefaultStyle.dp + style: ButtonStyle.main focus: true text: qsTr("Enregistrer") - textSize: 13 * DefaultStyle.dp KeyNavigation.left: titleText KeyNavigation.right: backButton KeyNavigation.down: conferenceEdit @@ -484,11 +460,8 @@ AbstractMainPage { spacing: 5 * DefaultStyle.dp Button { id: removeButton - background: Item{} + style: ButtonStyle.noBackgroundOrange icon.source: AppIcons.leftArrow - contentImageColor: DefaultStyle.main1_500_main - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp icon.width: 24 * DefaultStyle.dp icon.height: 24 * DefaultStyle.dp KeyNavigation.right: addButton @@ -496,7 +469,7 @@ AbstractMainPage { onClicked: container.pop() } ColumnLayout { - spacing: 3 * DefaultStyle.dp + spacing: 8 * DefaultStyle.dp Text { text: qsTr("Ajouter des participants") color: DefaultStyle.main1_500_main @@ -518,17 +491,13 @@ AbstractMainPage { Layout.fillWidth: true } } - Button { + SmallButton { id: addButton enabled: addParticipantLayout.selectedParticipantsCount.length != 0 Layout.rightMargin: 21 * DefaultStyle.dp - topPadding: 6 * DefaultStyle.dp - bottomPadding: 6 * DefaultStyle.dp - leftPadding: 12 * DefaultStyle.dp - rightPadding: 12 * DefaultStyle.dp focus: enabled + style: ButtonStyle.main text: qsTr("Ajouter") - textSize: 13 * DefaultStyle.dp KeyNavigation.left: removeButton KeyNavigation.down: addParticipantLayout onClicked: { @@ -582,14 +551,10 @@ AbstractMainPage { Item { Layout.fillWidth: true } - Button { + RoundButton { id: editButton property var isMeObj: UtilsCpp.isMe(mainItem.selectedConference?.core?.organizerAddress) visible: mainItem.selectedConference && isMeObj && isMeObj.value || false - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp icon.source: AppIcons.pencil contentImageColor: DefaultStyle.main1_500_main KeyNavigation.left: leftPanelStackView.currentItem @@ -609,21 +574,12 @@ AbstractMainPage { KeyNavigation.up: joinButton KeyNavigation.down: shareNetworkButton - popup.contentItem: Button { - color: DefaultStyle.danger_500main - borderColor: deletePopup.popupBackgroundColor - textColor: DefaultStyle.danger_500main - contentImageColor: DefaultStyle.danger_500main - inversedColors: true + popup.contentItem: IconLabelButton { + style: ButtonStyle.hoveredBackgroundRed property var isMeObj: UtilsCpp.isMe(mainItem.selectedConference?.core?.organizerAddress) property bool canCancel: isMeObj && isMeObj.value && mainItem.selectedConference?.core?.state !== LinphoneEnums.ConferenceInfoState.Cancelled icon.source: AppIcons.trashCan - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - spacing: 10 * DefaultStyle.dp - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp - text: qsTr("Delete this meeting") + text: qsTr("Supprimer cette réunion") onClicked: { if (mainItem.selectedConference) { @@ -642,7 +598,6 @@ AbstractMainPage { mainItem.selectedConference.core.lDeleteConferenceInfo() } } - background: Item{} } } } @@ -654,22 +609,20 @@ AbstractMainPage { RowLayout { spacing: 8 * DefaultStyle.dp Layout.fillWidth: true - Image { + EffectImage { Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp - source: AppIcons.videoCamera + colorizationColor: DefaultStyle.main2_600 + imageSource: AppIcons.videoCamera } - Button { + SmallButton { id: linkButton Layout.fillWidth: true - font.bold: shadowEnabled - text: mainItem.selectedConference && mainItem.selectedConference.core ? mainItem.selectedConference.core.uri : "" - textSize: 14 * DefaultStyle.dp - textWeight: 400 * DefaultStyle.dp + text: mainItem.selectedConference ? mainItem.selectedConference.core?.uri : "" + textSize: Typography.p1.pixelSize + textWeight: Typography.p1.weight underline: true - inversedColors: true - color: DefaultStyle.main2_600 - background: Item{} + style: ButtonStyle.noBackground Keys.onPressed: (event)=> { if (event.key == Qt.Key_Space || event.key == Qt.Key_Enter || event.key == Qt.Key_Return) { clicked(undefined) @@ -685,12 +638,8 @@ AbstractMainPage { UtilsCpp.createCall(mainItem.selectedConference.core.uri) } } - Button { + RoundButton { id: shareNetworkButton - Layout.preferredWidth: 24 * DefaultStyle.dp - Layout.preferredHeight: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp background: Item{} icon.source: AppIcons.shareNetwork KeyNavigation.left: linkButton @@ -705,10 +654,11 @@ AbstractMainPage { } RowLayout { spacing: 8 * DefaultStyle.dp - Image { + EffectImage { Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp - source: AppIcons.clock + imageSource: AppIcons.clock + colorizationColor: DefaultStyle.main2_600 } Text { text: mainItem.selectedConference && mainItem.selectedConference.core @@ -725,10 +675,11 @@ AbstractMainPage { } RowLayout { spacing: 8 * DefaultStyle.dp - Image { + EffectImage { Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp - source: AppIcons.globe + imageSource: AppIcons.globe + colorizationColor: DefaultStyle.main2_600 } Text { text: qsTr("Time zone: ") + (mainItem.selectedConference && mainItem.selectedConference.core ? (mainItem.selectedConference.core.timeZoneModel.displayName + ", " + mainItem.selectedConference.core.timeZoneModel.countryName) : "") @@ -789,12 +740,13 @@ AbstractMainPage { Layout.preferredHeight: participantList.height width: 393 * DefaultStyle.dp spacing: 8 * DefaultStyle.dp - Image { + EffectImage { Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp Layout.alignment: Qt.AlignLeft | Qt.AlignTop Layout.topMargin: 20 * DefaultStyle.dp - source: AppIcons.usersTwo + imageSource: AppIcons.usersTwo + colorizationColor: DefaultStyle.main2_600 } ListView { id: participantList @@ -811,7 +763,7 @@ AbstractMainPage { _address: modelData.address } Text { - text: modelData.displayName + text: modelData.displayName || modelData.displayNameObj?.value || "" maximumLineCount: 1 Layout.fillWidth: true font { @@ -832,13 +784,11 @@ AbstractMainPage { } } } - Button { + BigButton { id: joinButton visible: mainItem.selectedConference && mainItem.selectedConference.core?.state !== LinphoneEnums.ConferenceInfoState.Cancelled Layout.fillWidth: true text: qsTr("Rejoindre la réunion") - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp focus: true KeyNavigation.up: shareNetworkButton KeyNavigation.down: deletePopup diff --git a/Linphone/view/Page/Main/Start/WelcomePage.qml b/Linphone/view/Page/Main/Start/WelcomePage.qml index dbb278474..05f2bd4d5 100644 --- a/Linphone/view/Page/Main/Start/WelcomePage.qml +++ b/Linphone/view/Page/Main/Start/WelcomePage.qml @@ -36,18 +36,14 @@ LoginLayout { Item { Layout.fillWidth: true }, - Button { + SmallButton { visible: carousel.currentIndex < (carousel.itemsCount - 1) flat: true Layout.rightMargin: 50 * DefaultStyle.dp Layout.alignment: Qt.AlignVCenter | Layout.AlignRight - background: Item { - } + style: ButtonStyle.noBackground text: qsTr("Passer") - textColor: DefaultStyle.main2_600 underline: true - textSize: 13 * DefaultStyle.dp - textWeight: 600 * DefaultStyle.dp onClicked: { console.debug("[WelcomePage] User: Click skip") mainItem.startButtonPressed() @@ -106,14 +102,11 @@ LoginLayout { } } - Button { + BigButton { Layout.leftMargin: 509 * DefaultStyle.dp - leftPadding: 20 * DefaultStyle.dp - rightPadding: 20 * DefaultStyle.dp - topPadding: 11 * DefaultStyle.dp - bottomPadding: 11 * DefaultStyle.dp + style: ButtonStyle.main text: carousel.currentIndex < (carousel.itemsCount - 1) ? qsTr("Suivant") : qsTr("Commencer") - onClicked: { + onClicked: { if (carousel.currentIndex < carousel.itemsCount - 1) carousel.goToSlide(carousel.currentIndex + 1); else mainItem.startButtonPressed(); } diff --git a/Linphone/view/Page/Window/AbstractWindow.qml b/Linphone/view/Page/Window/AbstractWindow.qml index 11388d426..37d809c1d 100644 --- a/Linphone/view/Page/Window/AbstractWindow.qml +++ b/Linphone/view/Page/Window/AbstractWindow.qml @@ -78,20 +78,12 @@ ApplicationWindow { weight: 800 * DefaultStyle.dp } } - Button { + RoundButton { + Layout.alignment: Qt.AlignVCenter + style: ButtonStyle.noBackground Layout.preferredWidth: 24 * DefaultStyle.dp Layout.preferredHeight: 24 * DefaultStyle.dp - Layout.alignment: Qt.AlignVCenter - background: Item{} icon.source:AppIcons.closeX - width: 24 * DefaultStyle.dp - height: 24 * DefaultStyle.dp - icon.width: 24 * DefaultStyle.dp - icon.height: 24 * DefaultStyle.dp - contentItem: Image { - anchors.fill: parent - source: AppIcons.closeX - } onClicked: startCallPopup.close() } } diff --git a/Linphone/view/Page/Window/Call/CallsWindow.qml b/Linphone/view/Page/Window/Call/CallsWindow.qml index b197fa318..0427e54e3 100644 --- a/Linphone/view/Page/Window/Call/CallsWindow.qml +++ b/Linphone/view/Page/Window/Call/CallsWindow.qml @@ -217,6 +217,7 @@ AbstractWindow { id: zrtpValidation call: mainWindow.call modal: true + closePolicy: Popup.NoAutoClose } Timer { id: autoCloseZrtpToast @@ -528,9 +529,10 @@ AbstractWindow { : "" } } - Button { + BigButton { visible: mainWindow.call && mainWindow.call.core.recording text: qsTr("Arrêter l'enregistrement") + style: ButtonStyle.main onPressed: mainWindow.call.core.lStopRecording() } } @@ -1047,26 +1049,21 @@ AbstractWindow { children[i].enabled = false } } - Button { + BigButton { Layout.row: 0 - icon.source: AppIcons.endCall icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp + ToolTip.text: qsTr("Terminer l'appel") Layout.preferredWidth: 75 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp - contentImageColor: DefaultStyle.grey_0 - checkable: false + radius: 71 * DefaultStyle.dp + style: ButtonStyle.phoneRed Layout.column: mainWindow.callState == LinphoneEnums.CallState.OutgoingInit || mainWindow.callState == LinphoneEnums.CallState.OutgoingProgress || mainWindow.callState == LinphoneEnums.CallState.OutgoingRinging || mainWindow.callState == LinphoneEnums.CallState.OutgoingEarlyMedia || mainWindow.callState == LinphoneEnums.CallState.IncomingReceived ? 0 : bottomButtonsLayout.columns - 1 - background: Rectangle { - anchors.fill: parent - color: DefaultStyle.danger_500main - radius: 71 * DefaultStyle.dp - } onClicked: { mainWindow.callTerminatedByUser = true mainWindow.endCall(mainWindow.call) @@ -1084,6 +1081,7 @@ AbstractWindow { Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp + ToolTip.text: checked ? qsTr("Reprendre l'appel") : qsTr("Mettre l'appel en pause") background: Rectangle { anchors.fill: parent radius: 71 * DefaultStyle.dp @@ -1110,7 +1108,8 @@ AbstractWindow { Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp - contentImageColor: enabled ? DefaultStyle.grey_0 : DefaultStyle.grey_500 + contentImageColor: DefaultStyle.grey_0 + ToolTip.text: qsTr("Transférer l'appel") onCheckedChanged: { console.log("checked transfer changed", checked) if (checked) { @@ -1133,6 +1132,7 @@ AbstractWindow { Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp + ToolTip.text: qsTr("Initier un nouvel appel") onCheckedChanged: { console.log("checked newcall changed", checked) if (checked) { @@ -1155,6 +1155,7 @@ AbstractWindow { icon.source: AppIcons.callList icon.width: 32 * DefaultStyle.dp icon.height: 32 * DefaultStyle.dp + ToolTip.text: qsTr("Afficher la liste d'appels") onCheckedChanged: { if (checked) { rightPanel.visible = true @@ -1183,6 +1184,7 @@ AbstractWindow { enabled: mainWindow.conferenceInfo || (mainWindow.callState === LinphoneEnums.CallState.Connected || mainWindow.callState === LinphoneEnums.CallState.StreamsRunning) iconUrl: AppIcons.videoCamera checkedIconUrl: AppIcons.videoCameraSlash + ToolTip.text: mainWindow.localVideoEnabled ? qsTr("Désactiver la vidéo") :qsTr("Activer la vidéo") checked: !mainWindow.localVideoEnabled Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp @@ -1192,6 +1194,7 @@ AbstractWindow { } CheckableButton { iconUrl: AppIcons.microphone + ToolTip.text: mainWindow.call && mainWindow.call.core.microphoneMuted ? qsTr("Activer le son") :qsTr("Désactiver le son") checkedIconUrl: AppIcons.microphoneSlash checked: mainWindow.call && mainWindow.call.core.microphoneMuted Layout.preferredWidth: 55 * DefaultStyle.dp @@ -1203,7 +1206,7 @@ AbstractWindow { CheckableButton { iconUrl: AppIcons.screencast visible: !!mainWindow.conference - checkedColor: DefaultStyle.main2_400 + ToolTip.text: qsTr("Partager l'écran...") Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp @@ -1220,8 +1223,8 @@ AbstractWindow { CheckableButton { visible: false checkable: false - checkedColor: DefaultStyle.main2_400 iconUrl: AppIcons.handWaving + ToolTip.text: qsTr("Lever la main") Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp @@ -1230,7 +1233,7 @@ AbstractWindow { CheckableButton { visible: false iconUrl: AppIcons.smiley - checkedColor: DefaultStyle.main2_400 + ToolTip.text: qsTr("Envoyer une réaction") Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp @@ -1238,9 +1241,9 @@ AbstractWindow { } CheckableButton { id: participantListButton + ToolTip.text: qsTr("Gérer les participants") visible: mainWindow.conference iconUrl: AppIcons.usersTwo - checkedColor: DefaultStyle.main2_400 Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp icon.width: 32 * DefaultStyle.dp @@ -1260,18 +1263,17 @@ AbstractWindow { } PopupButton { id: moreOptionsButton + ToolTip.text: qsTr("Plus d'options...") Layout.preferredWidth: 55 * DefaultStyle.dp Layout.preferredHeight: 55 * DefaultStyle.dp - contentImageColor: enabled && !checked ? DefaultStyle.grey_0 : DefaultStyle.grey_500 - background: Rectangle { - anchors.fill: moreOptionsButton - color: moreOptionsButton.enabled - ? moreOptionsButton.checked - ? DefaultStyle.main2_400 - : DefaultStyle.grey_500 - : DefaultStyle.grey_600 - radius: 40 * DefaultStyle.dp - } + popup.topPadding: 20 * DefaultStyle.dp + popup.bottomPadding: 20 * DefaultStyle.dp + popup.leftPadding: 10 * DefaultStyle.dp + popup.rightPadding: 10 * DefaultStyle.dp + style: ButtonStyle.checkable + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp + Connections { target: moreOptionsButton.popup function onOpened() { @@ -1282,20 +1284,28 @@ AbstractWindow { id: optionsList spacing: 5 * DefaultStyle.dp - MenuButton { + IconLabelButton { + Layout.fillWidth: true visible: mainWindow.conference icon.source: AppIcons.squaresFour + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Modifier la disposition") + style: ButtonStyle.noBackground onClicked: { rightPanel.visible = true rightPanel.replace(changeLayoutPanel) moreOptionsButton.close() } } - MenuButton { + IconLabelButton { + Layout.fillWidth: true icon.source: AppIcons.fullscreen text: qsTr("Mode Plein écran") + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp checkable: true + style: ButtonStyle.noBackground Binding on checked { value: mainWindow.visibility === Window.FullScreen } onToggled: { if(checked) { @@ -1303,61 +1313,74 @@ AbstractWindow { }else{ mainWindow.showNormal() } + moreOptionsButton.close() } } - MenuButton { + IconLabelButton { + Layout.fillWidth: true icon.source: AppIcons.dialer text: qsTr("Dialer") + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp + style: ButtonStyle.noBackground onClicked: { rightPanel.visible = true rightPanel.replace(dialerPanel) moreOptionsButton.close() } } - MenuButton { + IconLabelButton { + Layout.fillWidth: true checkable: true + style: ButtonStyle.noBackground + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp visible: mainWindow.call && !mainWindow.conference && !SettingsCpp.disableCallRecordings enabled: mainWindow.call && mainWindow.call.core.recordable icon.source: AppIcons.recordFill checked: mainWindow.call && mainWindow.call.core.recording - contentImageColor: down - ? DefaultStyle.main1_500_main - :mainWindow.call && mainWindow.call.core.recording - ? DefaultStyle.danger_500main - : DefaultStyle.main2_500main + hoveredImageColor: contentImageColor + contentImageColor: mainWindow.call && mainWindow.call.core.recording + ? DefaultStyle.danger_500main + : DefaultStyle.main2_500main text: mainWindow.call && mainWindow.call.core.recording ? qsTr("Terminer l'enregistrement") : qsTr("Enregistrer l'appel") - textColor: down - ? DefaultStyle.main1_500_main - :mainWindow.call && mainWindow.call.core.recording - ? DefaultStyle.danger_500main - : DefaultStyle.main2_500main + textColor: mainWindow.call && mainWindow.call.core.recording + ? DefaultStyle.danger_500main + : DefaultStyle.main2_500main + hoveredTextColor : textColor onToggled: { if (mainWindow.call) if (mainWindow.call.core.recording) mainWindow.call.core.lStopRecording() else mainWindow.call.core.lStartRecording() } } - MenuButton { + IconLabelButton { + Layout.fillWidth: true checkable: true + style: ButtonStyle.noBackground + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp icon.source: !mainWindow.call || mainWindow.call.core.speakerMuted ? AppIcons.speakerSlash : AppIcons.speaker - contentImageColor: down - ? DefaultStyle.main1_500_main - : mainWindow.call && mainWindow.call.core.speakerMuted - ? DefaultStyle.danger_500main - : DefaultStyle.main2_500main + contentImageColor: mainWindow.call && mainWindow.call.core.speakerMuted + ? DefaultStyle.danger_500main + : DefaultStyle.main2_500main + hoveredImageColor: contentImageColor text: mainWindow.call && mainWindow.call.core.speakerMuted ? qsTr("Activer le son") : qsTr("Désactiver le son") - textColor: down - ? DefaultStyle.main1_500_main - :mainWindow.call && mainWindow.call.core.speakerMuted - ? DefaultStyle.danger_500main - : DefaultStyle.main2_500main + textColor: mainWindow.call && mainWindow.call.core.speakerMuted + ? DefaultStyle.danger_500main + : DefaultStyle.main2_500main + hoveredTextColor: textColor onCheckedChanged: { if (mainWindow.call) mainWindow.call.core.lSetSpeakerMuted(!mainWindow.call.core.speakerMuted) } } - MenuButton { + IconLabelButton { + Layout.fillWidth: true icon.source: AppIcons.settings + icon.width: 32 * DefaultStyle.dp + icon.height: 32 * DefaultStyle.dp text: qsTr("Paramètres") + style: ButtonStyle.noBackground onClicked: { rightPanel.visible = true rightPanel.replace(settingsPanel) diff --git a/Linphone/view/Page/Window/Main/MainWindow.qml b/Linphone/view/Page/Window/Main/MainWindow.qml index f85a720db..7874188ac 100644 --- a/Linphone/view/Page/Window/Main/MainWindow.qml +++ b/Linphone/view/Page/Window/Main/MainWindow.qml @@ -120,6 +120,10 @@ AbstractWindow { Image { anchors.centerIn: parent source: AppIcons.splashscreenLogo + sourceSize.width: 395 * DefaultStyle.dp + sourceSize.height: 395 * DefaultStyle.dp + width: 395 * DefaultStyle.dp + height: 395 * DefaultStyle.dp } } } @@ -136,7 +140,7 @@ AbstractWindow { id: loginPage LoginPage { objectName: "loginPage" - showBackButton: accountProxy?.haveAccount || false + showBackButton: false onGoBack: openMainPage() onUseSIPButtonClicked: mainWindowStackView.push(sipLoginPage) onGoToRegister: mainWindowStackView.replace(registerPage) @@ -144,6 +148,9 @@ AbstractWindow { openMainPage() proposeH264CodecsDownload() } + StackView.onActivated:{ + if (accountProxy?.haveAccount) showBackButton = true + } } } Component { diff --git a/Linphone/view/Style/AppIcons.qml b/Linphone/view/Style/AppIcons.qml index 2374a9572..42652f102 100644 --- a/Linphone/view/Style/AppIcons.qml +++ b/Linphone/view/Style/AppIcons.qml @@ -31,8 +31,7 @@ QtObject { property string manageProfile: "image://internal/user-circle-gear.svg" property string verif_page_image: "image://internal/verif_page_image.svg" property string check: "image://internal/check.svg" - property string dialer: "image://internal/dialer.svg" - property string dialerSelected: "image://internal/dialer-selected.svg" + property string dialer: "image://internal/numpad.svg" property string chiffrement: "image://internal/chiffrement.svg" property string interoperable: "image://internal/interoperable.svg" property string phone: "image://internal/phone.svg" @@ -51,7 +50,6 @@ QtObject { property string userPlus: "image://internal/user-plus.svg" property string noItemImage: "image://internal/noItemImage.svg" property string verticalDots: "image://internal/dots-three-vertical.svg" - property string more: "image://internal/more.svg" property string plusCircle: "image://internal/plus-circle.svg" property string micro: "image://internal/microphone-stage.svg" property string groupCall: "image://internal/group-call.svg" @@ -79,7 +77,7 @@ QtObject { property string smileySad: "image://internal/smiley-sad.svg" property string trashCan: "image://internal/trash-simple.svg" property string copy: "image://internal/copy.svg" - property string empty: "image://internal/empty.svg" + property string empty: "image://internal/x-circle.svg" property string heart: "image://internal/heart.svg" property string heartFill: "image://internal/heart-fill.svg" property string recordFill: "image://internal/record-fill.svg" @@ -87,9 +85,9 @@ QtObject { property string pencil: "image://internal/pencil-simple.svg" property string shareNetwork: "image://internal/share-network.svg" property string bell: "image://internal/bell-simple.svg" - property string bellSlash: "image://internal/bell-simple-slash.svg" + property string bellSlash: "image://internal/bell-slash.svg" property string question: "image://internal/question.svg" - property string settings: "image://internal/settings.svg" + property string settings: "image://internal/gear.svg" property string clock: "image://internal/clock.svg" property string note: "image://internal/note.svg" property string userRectangle: "image://internal/user-rectangle.svg" @@ -97,7 +95,7 @@ QtObject { property string globe: "image://internal/globe-hemisphere-west.svg" property string slide: "image://internal/slideshow.svg" property string busyIndicator: "image://internal/busy-indicator.svg" - property string pip: "image://internal/pip.svg" + property string pip: "image://internal/picture-in-picture.svg" property string waveform: "image://internal/waveform.svg" property string squaresFour: "image://internal/squares-four.svg" property string handWaving: "image://internal/hand-waving.svg" @@ -107,7 +105,7 @@ QtObject { property string switchOn: "image://internal/switch-on.svg" property string switchOff: "image://internal/switch-off.svg" property string license: "image://internal/license.svg" - property string debug: "image://internal/debug.svg" + property string debug: "image://internal/wrench.svg" property string world: "image://internal/world.svg" property string warningCircle: "image://internal/warning-circle.svg" property string fullscreen: "image://internal/fullscreen.svg" @@ -116,14 +114,14 @@ QtObject { property string cellSignalMedium: "image://internal/cell-signal-medium.svg" property string cellSignalLow: "image://internal/cell-signal-low.svg" property string cellSignalNone: "image://internal/cell-signal-none.svg" - property string mobile: "image://internal/mobile.svg" + property string mobile: "image://internal/device-mobile-camera.svg" property string desktop: "image://internal/desktop.svg" - property string calendar: "image://internal/calendar.svg" + property string calendar: "image://internal/calendar-blank.svg" property string bellDnd: "image://internal/bell-dnd.svg" property string bellRinger: "image://internal/bell-ringer.svg" property string voicemail: "image://internal/voicemail.svg" property string power: "image://internal/power.svg" - property string resourcePackage: "image://internal/resource-package.svg" + property string resourcePackage: "image://internal/package.svg" property string appWindow: "image://internal/app-window.svg" - property string bellMwi: "image://internal/bell-mwi.svg" + property string bellMwi: "image://internal/bell-simple.svg" } diff --git a/Linphone/view/Style/ButtonStyle.qml b/Linphone/view/Style/ButtonStyle.qml new file mode 100644 index 000000000..f447774b2 --- /dev/null +++ b/Linphone/view/Style/ButtonStyle.qml @@ -0,0 +1,276 @@ +pragma Singleton +import QtQuick +import Linphone +import QtQuick.Effects + +QtObject { + +// Orange + property QtObject main: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.main1_500_main + property color hovered: DefaultStyle.main1_600 + property color pressed: DefaultStyle.main1_700 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + } + +// White with orange border + property QtObject secondary: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_0 + property color hovered: DefaultStyle.main1_100 + property color pressed: DefaultStyle.main1_500_main + } + property color borderColor: DefaultStyle.main1_500_main + property QtObject text: QtObject { + property color normal: DefaultStyle.main1_500_main + property color pressed: DefaultStyle.grey_0 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main1_500_main + property color pressed: DefaultStyle.grey_0 + } + } + +// Light orange + property QtObject tertiary: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.main1_100 + property color hovered: DefaultStyle.main1_200 + property color pressed: DefaultStyle.main1_300 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main1_500_main + property color pressed: DefaultStyle.main1_500_main + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main1_500_main + property color pressed: DefaultStyle.main1_500_main + } + } + +// Blue-grey + property QtObject grey: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.main2_200 + property color hovered: DefaultStyle.main2_300 + property color pressed: DefaultStyle.main2_400 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main2_500main + property color pressed: DefaultStyle.main2_700 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main2_500main + property color pressed: DefaultStyle.main2_700 + } + } + +// Red phone + property QtObject phoneRed: QtObject { + property var iconSource: AppIcons.endCall + property QtObject color: QtObject { + property color normal: DefaultStyle.danger_500main + property color hovered: DefaultStyle.danger_700 + property color pressed: DefaultStyle.danger_900 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + } + +// Green phone + property QtObject phoneGreen: QtObject { + property var iconSource: AppIcons.phone + property QtObject color: QtObject { + property color normal: DefaultStyle.success_500main + property color hovered: DefaultStyle.success_700 + property color pressed: DefaultStyle.success_900 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + } + +// Checkable + property QtObject checkable: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_500 + property color hovered: DefaultStyle.grey_600 + property color pressed: DefaultStyle.main2_400 + } + + property QtObject text: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + + property QtObject image: QtObject { + property color normal: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + } + +// No background + property QtObject noBackground: QtObject { + property QtObject color: QtObject { + property color normal: "transparent" + property color hovered: "transparent" + property color pressed: "transparent" + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main2_600 + property color hovered: DefaultStyle.main2_700 + property color pressed: DefaultStyle.main2_800 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main2_600 + property color hovered: DefaultStyle.main2_700 + property color pressed: DefaultStyle.main2_800 + } + } + +// No background red + property QtObject noBackgroundRed: QtObject { + property QtObject color: QtObject { + property color normal: "transparent" + property color hovered: "transparent" + property color pressed: "transparent" + } + property QtObject text: QtObject { + property color normal: DefaultStyle.danger_500main + property color hovered: DefaultStyle.danger_700 + property color pressed: DefaultStyle.danger_900 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.danger_500main + property color hovered: DefaultStyle.danger_700 + property color pressed: DefaultStyle.danger_900 + } + } + +// No background orange + property QtObject noBackgroundOrange: QtObject { + property QtObject color: QtObject { + property color normal: "transparent" + property color hovered: "transparent" + property color pressed: "transparent" + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main1_500_main + property color hovered: DefaultStyle.main1_600 + property color pressed: DefaultStyle.main1_700 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main1_500_main + property color hovered: DefaultStyle.main1_600 + property color pressed: DefaultStyle.main1_700 + } + } + +// Icon + label button + property QtObject hoveredBackground: QtObject { + property QtObject color: QtObject { + property color normal: "transparent" + property color hovered: DefaultStyle.main2_100 + property color pressed: DefaultStyle.main2_100 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main2_500main + property color hovered: DefaultStyle.main2_500main + property color pressed: DefaultStyle.main2_500main + } + property QtObject image: QtObject { + property color normal: DefaultStyle.main2_500main + property color hovered: DefaultStyle.main2_500main + property color pressed: DefaultStyle.main2_500main + } + } + + property QtObject hoveredBackgroundRed: QtObject { + property QtObject color: QtObject { + property color normal: "transparent" + property color hovered: DefaultStyle.main2_100 + property color pressed: DefaultStyle.main2_100 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.danger_500main + property color hovered: DefaultStyle.danger_700 + property color pressed: DefaultStyle.danger_900 + } + property QtObject image: QtObject { + property color normal: DefaultStyle.danger_500main + property color hovered: DefaultStyle.danger_700 + property color pressed: DefaultStyle.danger_900 + } + } + +// Numpad + property QtObject numericPad: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_0 + property color hovered: DefaultStyle.grey_200 + property color pressed: DefaultStyle.grey_300 + } + property QtObject text: QtObject { + property color normal: DefaultStyle.main2_600 + property color pressed: DefaultStyle.main2_700 + } + } + +// Green toast + property QtObject toast: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_0 + property color hovered: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + property color borderColor: DefaultStyle.success_500main + property QtObject text: QtObject { + property color normal: DefaultStyle.success_500main + property color pressed: DefaultStyle.success_700 + } + } + +// Security blue toast + property QtObject securityToast: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_0 + property color hovered: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + property color borderColor: DefaultStyle.info_500_main + property QtObject text: QtObject { + property color normal: DefaultStyle.info_500_main + property color pressed: DefaultStyle.info_500_main + } + } + +// Security red toast + property QtObject securityToastError: QtObject { + property QtObject color: QtObject { + property color normal: DefaultStyle.grey_0 + property color hovered: DefaultStyle.grey_0 + property color pressed: DefaultStyle.grey_0 + } + property color borderColor: DefaultStyle.danger_500main + property QtObject text: QtObject { + property color normal: DefaultStyle.danger_500main + property color pressed: DefaultStyle.danger_500main + } + } +} diff --git a/Linphone/view/Style/DefaultStyle.qml b/Linphone/view/Style/DefaultStyle.qml index 24e195903..f9adc31e0 100644 --- a/Linphone/view/Style/DefaultStyle.qml +++ b/Linphone/view/Style/DefaultStyle.qml @@ -3,7 +3,11 @@ import QtQuick QtObject { property color main1_100: "#FFEACB" + property color main1_200: "#FFD098" + property color main1_300: "#FFB266" property color main1_500_main: "#FE5E00" + property color main1_600: "#DA4400" + property color main1_700: "#B72D00" property color main2_0: "#FAFEFF" property color main2_100: "#EEF6F8" @@ -19,6 +23,7 @@ QtObject { property color grey_0: "#FFFFFF" property color grey_100: "#F9F9F9" property color grey_200: "#EDEDED" + property color grey_300: "#C9C9C9" property color grey_400: "#949494" property color grey_500: "#4E4E4E" property color grey_600: "#2E3030" @@ -28,7 +33,11 @@ QtObject { property color warning_600: "#DBB820" property color danger_500main: "#DD5F5F" + property color danger_700: "#9E3548" + property color danger_900: "#723333" property color success_500main: "#4FAE80" + property color success_700: "#377d71" + property color success_900: "#1E4C53" property color info_500_main: "#4AA8FF" property color vue_meter_light_green: "#6FF88D" diff --git a/Linphone/view/Style/Typography.qml b/Linphone/view/Style/Typography.qml index 31c2cfd33..00688de1b 100644 --- a/Linphone/view/Style/Typography.qml +++ b/Linphone/view/Style/Typography.qml @@ -10,13 +10,6 @@ QtObject { weight: 800 * DefaultStyle.dp }) - // Title/H3M - Bloc title medium - property font h3m: Qt.font( { - family: DefaultStyle.defaultFont, - pixelSize: 16 * DefaultStyle.dp, - weight: 800 * DefaultStyle.dp - }) - // Title/H3 - Bloc title property font h3: Qt.font( { family: DefaultStyle.defaultFont, @@ -30,35 +23,49 @@ QtObject { pixelSize: 29 * DefaultStyle.dp, weight: 800 * DefaultStyle.dp }) + + // Title/H1 - Large bloc title + property font h1: Qt.font( { + family: DefaultStyle.defaultFont, + pixelSize: 36 * DefaultStyle.dp, + weight: 800 * DefaultStyle.dp + }) - // Text/P2 - Bold, reduced paratraph text + // Text/P2 - Bold, reduced paragraph text property font p2: Qt.font( { family: DefaultStyle.defaultFont, pixelSize: 13 * DefaultStyle.dp, weight: 700 * DefaultStyle.dp }) - // Text/P2 - Large Bold, reduced paratraph text + // Text/P2 - Large Bold, reduced paragraph text property font p2l: Qt.font( { family: DefaultStyle.defaultFont, pixelSize: 14 * DefaultStyle.dp, weight: 700 * DefaultStyle.dp }) - // Text/P1 - Paratraph text + // Text/P1 - Paragraph text property font p1: Qt.font( { family: DefaultStyle.defaultFont, pixelSize: 14 * DefaultStyle.dp, weight: 400 * DefaultStyle.dp }) - // Text/P1 - Paratraph text + // Text/P1 - Paragraph text property font p1s: Qt.font( { family: DefaultStyle.defaultFont, pixelSize: 13 * DefaultStyle.dp, weight: 400 * DefaultStyle.dp }) + // Button/B1 - Big Button + property font b1: Qt.font( { + family: DefaultStyle.defaultFont, + pixelSize: 18 * DefaultStyle.dp, + weight: 600 * DefaultStyle.dp + }) + // Button/B2 - Medium Button property font b2: Qt.font( { family: DefaultStyle.defaultFont, diff --git a/Linphone/view/Test/ItemsTest.qml b/Linphone/view/Test/ItemsTest.qml index 68fba149c..e5acbf5ab 100644 --- a/Linphone/view/Test/ItemsTest.qml +++ b/Linphone/view/Test/ItemsTest.qml @@ -43,10 +43,6 @@ Window { capitalization: Font.AllUppercase text: "capital button" } - Button { - text: "inversed colors button" - inversedColors: true - } Button { text: "button with long tooltip" hoverEnabled: true