screen ratio in function
This commit is contained in:
parent
11c586792d
commit
55a54dc10e
137 changed files with 2064 additions and 1968 deletions
|
|
@ -3,15 +3,16 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
textSize: Typography.b1.pixelSize
|
textSize: Typography.b1.pixelSize
|
||||||
textWeight: Typography.b1.weight
|
textWeight: Typography.b1.weight
|
||||||
leftPadding: Math.round(20 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
rightPadding: Math.round(20 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
topPadding: Math.round(11 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(11)
|
||||||
bottomPadding: Math.round(11 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(11)
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -15,24 +16,24 @@ ComboBox {
|
||||||
id: contentText
|
id: contentText
|
||||||
text: UtilsCpp.formatDate(calendar.selectedDate, false, true, "ddd d, MMMM")
|
text: UtilsCpp.formatDate(calendar.selectedDate, false, true, "ddd d, MMMM")
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Math.round(15 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(14 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
weight: Math.min(Math.round(700 * DefaultStyle.dp), 1000)
|
weight: Math.min(Utils.getSizeWithScreenRatio(700), 1000)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
popup: Control.Popup {
|
popup: Control.Popup {
|
||||||
id: popupItem
|
id: popupItem
|
||||||
y: mainItem.height
|
y: mainItem.height
|
||||||
width: Math.round(321 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(321)
|
||||||
height: Math.round(270 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(270)
|
||||||
closePolicy: Popup.NoAutoClose
|
closePolicy: Popup.NoAutoClose
|
||||||
topPadding: Math.round(25 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(25)
|
||||||
bottomPadding: Math.round(24 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(24)
|
||||||
leftPadding: Math.round(21 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(21)
|
||||||
rightPadding: Math.round(19 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(19)
|
||||||
onOpened: calendar.forceActiveFocus()
|
onOpened: calendar.forceActiveFocus()
|
||||||
background: Item {
|
background: Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
@ -40,7 +41,7 @@ ComboBox {
|
||||||
id: calendarBg
|
id: calendarBg
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: Math.round(16 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(16)
|
||||||
border.color: DefaultStyle.main1_500_main
|
border.color: DefaultStyle.main1_500_main
|
||||||
border.width: calendar.activeFocus? 1 : 0
|
border.width: calendar.activeFocus? 1 : 0
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,21 +2,22 @@ import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.CheckBox {
|
Control.CheckBox {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
hoverEnabled: enabled
|
hoverEnabled: enabled
|
||||||
indicator: Item{
|
indicator: Item{
|
||||||
implicitWidth: Math.round(20 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
implicitHeight: Math.round(20 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
x: (parent.width - width) / 2
|
x: (parent.width - width) / 2
|
||||||
y: (parent.height - height) / 2
|
y: (parent.height - height) / 2
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: backgroundArea
|
id: backgroundArea
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(3 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(3)
|
||||||
border.color: mainItem.hovered || mainItem.activeFocus ? DefaultStyle.main1_600 : DefaultStyle.main1_500_main
|
border.color: mainItem.hovered || mainItem.activeFocus ? DefaultStyle.main1_600 : DefaultStyle.main1_500_main
|
||||||
border.width: Math.round(2 * DefaultStyle.dp)
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
color: mainItem.checked ? DefaultStyle.main1_500_main : "transparent"
|
color: mainItem.checked ? DefaultStyle.main1_500_main : "transparent"
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: mainItem.checked
|
visible: mainItem.checked
|
||||||
|
|
|
||||||
|
|
@ -149,7 +149,7 @@ Control.ComboBox {
|
||||||
y: mainItem.height - 1
|
y: mainItem.height - 1
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
implicitHeight: Math.min(contentItem.implicitHeight, mainWindow.height)
|
implicitHeight: Math.min(contentItem.implicitHeight, mainWindow.height)
|
||||||
padding: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
padding: Utils.getSizeWithScreenRatio(1)
|
||||||
|
|
||||||
onOpened: {
|
onOpened: {
|
||||||
listView.positionViewAtIndex(listView.currentIndex, ListView.Center);
|
listView.positionViewAtIndex(listView.currentIndex, ListView.Center);
|
||||||
|
|
@ -168,7 +168,7 @@ Control.ComboBox {
|
||||||
highlight: Rectangle {
|
highlight: Rectangle {
|
||||||
width: listView.width
|
width: listView.width
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
y: listView.currentItem ? listView.currentItem.y : 0
|
y: listView.currentItem ? listView.currentItem.y : 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -190,10 +190,10 @@ Control.ComboBox {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
EffectImage {
|
EffectImage {
|
||||||
id: delegateImg
|
id: delegateImg
|
||||||
Layout.preferredWidth: visible ? Math.round(20 * DefaultStyle.dp) : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(20) : 0
|
||||||
Layout.leftMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: imageSource != ""
|
visible: imageSource != ""
|
||||||
imageWidth: Math.round(20 * DefaultStyle.dp)
|
imageWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
imageSource: typeof (modelData) != "undefined" && modelData.img ? modelData.img : ""
|
imageSource: typeof (modelData) != "undefined" && modelData.img ? modelData.img : ""
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
}
|
}
|
||||||
|
|
@ -201,7 +201,7 @@ Control.ComboBox {
|
||||||
Text {
|
Text {
|
||||||
id: flagItem
|
id: flagItem
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
Layout.leftMargin: delegateImg.visible ? 0 : Math.round(5 * DefaultStyle.dp)
|
Layout.leftMargin: delegateImg.visible ? 0 : Utils.getSizeWithScreenRatio(5)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
visible: mainItem.flagRole
|
visible: mainItem.flagRole
|
||||||
font {
|
font {
|
||||||
|
|
@ -213,8 +213,8 @@ Control.ComboBox {
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.leftMargin: delegateImg.visible ? 0 : flagItem.visble ? Utils.getSizeWithScreenRatio(5) : Utils.getSizeWithScreenRatio(25)
|
Layout.leftMargin: delegateImg.visible ? 0 : Utils.getSizeWithScreenRatio(flagItem.visble ? 5 : 25)
|
||||||
Layout.rightMargin: Math.round(20 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
text: typeof (modelData) != "undefined" ? mainItem.textRole ? modelData[mainItem.textRole] : modelData.text ? modelData.text : modelData : $modelData ? mainItem.textRole ? $modelData[mainItem.textRole] : $modelData : ""
|
text: typeof (modelData) != "undefined" ? mainItem.textRole ? modelData[mainItem.textRole] : modelData.text ? modelData.text : modelData : $modelData ? mainItem.textRole ? $modelData[mainItem.textRole] : $modelData : ""
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.ComboBox {
|
Control.ComboBox {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -16,7 +17,7 @@ Control.ComboBox {
|
||||||
}
|
}
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(63 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(63)
|
||||||
color: mainItem.enableBackgroundColor ? DefaultStyle.grey_100 : "transparent"
|
color: mainItem.enableBackgroundColor ? DefaultStyle.grey_100 : "transparent"
|
||||||
border.color: mainItem.enableBackgroundColors
|
border.color: mainItem.enableBackgroundColors
|
||||||
? (mainItem.errorMessage.length > 0
|
? (mainItem.errorMessage.length > 0
|
||||||
|
|
@ -28,11 +29,11 @@ Control.ComboBox {
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
readonly property var currentItem: combobox.model.getAt(combobox.currentIndex)
|
readonly property var currentItem: combobox.model.getAt(combobox.currentIndex)
|
||||||
spacing: 0// Math.round(5 * DefaultStyle.dp)
|
spacing: 0
|
||||||
Text {
|
Text {
|
||||||
id: selectedItemFlag
|
id: selectedItemFlag
|
||||||
visible: text.length > 0
|
visible: text.length > 0
|
||||||
font.pixelSize: Math.round(21 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(21)
|
||||||
text: parent.currentItem ? parent.currentItem.flag : ""
|
text: parent.currentItem ? parent.currentItem.flag : ""
|
||||||
font.family: DefaultStyle.flagFont
|
font.family: DefaultStyle.flagFont
|
||||||
}
|
}
|
||||||
|
|
@ -41,7 +42,7 @@ Control.ComboBox {
|
||||||
// visible: false
|
// visible: false
|
||||||
// layer.enabled: true
|
// layer.enabled: true
|
||||||
// anchors.centerIn: selectedItemFlag
|
// anchors.centerIn: selectedItemFlag
|
||||||
// radius: Math.round(600 * DefaultStyle.dp)
|
// radius: Utils.getSizeWithScreenRatio(600)
|
||||||
// width: selectedItemFlag.width/2
|
// width: selectedItemFlag.width/2
|
||||||
// height: selectedItemFlag.height/2
|
// height: selectedItemFlag.height/2
|
||||||
// }
|
// }
|
||||||
|
|
@ -68,11 +69,11 @@ Control.ComboBox {
|
||||||
id: indicImage
|
id: indicImage
|
||||||
z: 1
|
z: 1
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(15 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
imageSource: AppIcons.downArrow
|
imageSource: AppIcons.downArrow
|
||||||
width: Math.round(15 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(15)
|
||||||
height: Math.round(15 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(15)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
colorizationColor: mainItem.indicatorColor
|
colorizationColor: mainItem.indicatorColor
|
||||||
}
|
}
|
||||||
|
|
@ -80,8 +81,8 @@ Control.ComboBox {
|
||||||
popup: Control.Popup {
|
popup: Control.Popup {
|
||||||
id: listPopup
|
id: listPopup
|
||||||
y: combobox.height - 1
|
y: combobox.height - 1
|
||||||
width: Math.round(311 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(311)
|
||||||
height: Math.round(250 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(250)
|
||||||
|
|
||||||
contentItem: ListView {
|
contentItem: ListView {
|
||||||
id: listView
|
id: listView
|
||||||
|
|
@ -92,14 +93,14 @@ Control.ComboBox {
|
||||||
keyNavigationEnabled: true
|
keyNavigationEnabled: true
|
||||||
keyNavigationWraps: true
|
keyNavigationWraps: true
|
||||||
maximumFlickVelocity: 1500
|
maximumFlickVelocity: 1500
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
highlight: Rectangle {
|
highlight: Rectangle {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
width: listView.width
|
width: listView.width
|
||||||
height: listView.height
|
height: listView.height
|
||||||
color: DefaultStyle.main2_300
|
color: DefaultStyle.main2_300
|
||||||
// radius: Math.round(15 * DefaultStyle.dp)
|
// radius: Utils.getSizeWithScreenRatio(15)
|
||||||
}
|
}
|
||||||
|
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
|
|
@ -108,15 +109,15 @@ Control.ComboBox {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: contentLayout
|
id: contentLayout
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Math.round(20 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
id: delegateImg
|
id: delegateImg
|
||||||
visible: text.length > 0
|
visible: text.length > 0
|
||||||
text: $modelData.flag
|
text: $modelData.flag
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(28 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(28)
|
||||||
family: DefaultStyle.flagFont
|
family: DefaultStyle.flagFont
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -134,7 +135,7 @@ Control.ComboBox {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: separator
|
id: separator
|
||||||
width: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
width: Utils.getSizeWithScreenRatio(1)
|
||||||
height: combobox.height / 2
|
height: combobox.height / 2
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
}
|
}
|
||||||
|
|
@ -158,7 +159,7 @@ Control.ComboBox {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
opacity: 0.1
|
opacity: 0.1
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
visible: parent.containsMouse
|
visible: parent.containsMouse
|
||||||
}
|
}
|
||||||
|
|
@ -180,7 +181,7 @@ Control.ComboBox {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: popupBg
|
id: popupBg
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
}
|
}
|
||||||
MultiEffect {
|
MultiEffect {
|
||||||
|
|
|
||||||
|
|
@ -2,13 +2,14 @@ import QtQuick
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property string iconSource
|
property string iconSource
|
||||||
property string title
|
property string title
|
||||||
property string subTitle
|
property string subTitle
|
||||||
property real iconSize: (32 * DefaultStyle.dp)
|
property real iconSize: Utils.getSizeWithScreenRatio(32)
|
||||||
property bool shadowEnabled: containsMouse || activeFocus
|
property bool shadowEnabled: containsMouse || activeFocus
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
width: content.implicitWidth
|
width: content.implicitWidth
|
||||||
|
|
@ -36,7 +37,7 @@ MouseArea {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
height: implicitHeight
|
height: implicitHeight
|
||||||
Layout.leftMargin: (16 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
text: mainItem.title
|
text: mainItem.title
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,15 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
textSize: Typography.p1.pixelSize
|
textSize: Typography.p1.pixelSize
|
||||||
textWeight: Typography.p1.weight
|
textWeight: Typography.p1.weight
|
||||||
radius: Math.round(5 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(5)
|
||||||
shadowEnabled: mainItem.activeFocus || hovered
|
shadowEnabled: mainItem.activeFocus || hovered
|
||||||
style: ButtonStyle.hoveredBackground
|
style: ButtonStyle.hoveredBackground
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,20 +3,21 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
textSize: Typography.p1.pixelSize
|
textSize: Typography.p1.pixelSize
|
||||||
textWeight: Typography.p1.weight
|
textWeight: Typography.p1.weight
|
||||||
radius: Math.round(5 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(5)
|
||||||
shadowEnabled: mainItem.activeFocus || hovered
|
shadowEnabled: mainItem.activeFocus || hovered
|
||||||
style: ButtonStyle.hoveredBackground
|
style: ButtonStyle.hoveredBackground
|
||||||
property bool inverseLayout: false
|
property bool inverseLayout: false
|
||||||
|
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
layoutDirection: mainItem.inverseLayout ? Qt.RightToLeft: Qt.LeftToRight
|
layoutDirection: mainItem.inverseLayout ? Qt.RightToLeft: Qt.LeftToRight
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: mainItem.icon.source
|
imageSource: mainItem.icon.source
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: labelButton
|
id: labelButton
|
||||||
|
|
@ -11,18 +12,18 @@ ColumnLayout {
|
||||||
property alias button: button
|
property alias button: button
|
||||||
property alias text: text
|
property alias text: text
|
||||||
property string label
|
property string label
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
Button {
|
Button {
|
||||||
id: button
|
id: button
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.preferredWidth: Math.round(56 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(56)
|
||||||
Layout.preferredHeight: Math.round(56 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(56)
|
||||||
topPadding: Math.round(16 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
contentImageColor: DefaultStyle.main2_600
|
contentImageColor: DefaultStyle.main2_600
|
||||||
radius: Math.round(40 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(40)
|
||||||
style: ButtonStyle.grey
|
style: ButtonStyle.grey
|
||||||
Accessible.name: labelButton.label
|
Accessible.name: labelButton.label
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,15 +3,16 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
textSize: Typography.b2.pixelSize
|
textSize: Typography.b2.pixelSize
|
||||||
textWeight: Typography.b2.weight
|
textWeight: Typography.b2.weight
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
topPadding: Math.round(10 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(10)
|
||||||
bottomPadding: Math.round(10 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(10)
|
||||||
icon.width: Math.round(16 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(16)
|
||||||
icon.height: Math.round(16 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(16)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.RadioButton {
|
Control.RadioButton {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -11,7 +12,7 @@ Control.RadioButton {
|
||||||
property string imgUrl
|
property string imgUrl
|
||||||
property bool checkOnClick: true
|
property bool checkOnClick: true
|
||||||
property color color
|
property color color
|
||||||
property real indicatorSize: Math.round(16 * DefaultStyle.dp)
|
property real indicatorSize: Utils.getSizeWithScreenRatio(16)
|
||||||
property bool shadowEnabled: mainItem.activeFocus || mainItem.hovered
|
property bool shadowEnabled: mainItem.activeFocus || mainItem.hovered
|
||||||
//onClicked: if (checkOnClick && !mainItem.checked) mainItem.toggle()
|
//onClicked: if (checkOnClick && !mainItem.checked) mainItem.toggle()
|
||||||
|
|
||||||
|
|
@ -33,7 +34,7 @@ Control.RadioButton {
|
||||||
radius: mainItem.indicatorSize/2
|
radius: mainItem.indicatorSize/2
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
border.color: mainItem.color
|
border.color: mainItem.color
|
||||||
border.width: Math.round(2 * DefaultStyle.dp)
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: parent.width/2
|
width: parent.width/2
|
||||||
height: parent.height/2
|
height: parent.height/2
|
||||||
|
|
|
||||||
|
|
@ -3,15 +3,16 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
textSize: Typography.p1s.pixelSize
|
textSize: Typography.p1s.pixelSize
|
||||||
textWeight: Typography.p1s.weight
|
textWeight: Typography.p1s.weight
|
||||||
padding: Math.round(16 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(16)
|
||||||
// icon.width: width
|
// icon.width: width
|
||||||
// icon.height: width
|
// icon.height: width
|
||||||
radius: width * 2
|
radius: width * 2
|
||||||
// width: Math.round(24 * DefaultStyle.dp)
|
// width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: width
|
height: width
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.RadioButton {
|
Control.RadioButton {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -21,18 +22,18 @@ Control.RadioButton {
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
border.color: mainItem.checked ? mainItem.color : "transparent"
|
border.color: mainItem.checked ? mainItem.color : "transparent"
|
||||||
radius: Math.round(20 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(20)
|
||||||
}
|
}
|
||||||
|
|
||||||
indicator: RowLayout {
|
indicator: RowLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Math.round(13 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(13)
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Math.round(8 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
spacing: Math.round(4 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(4)
|
||||||
Rectangle {
|
Rectangle {
|
||||||
implicitWidth: Math.round(16 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(16)
|
||||||
implicitHeight: Math.round(16 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(16)
|
||||||
radius: implicitWidth/2
|
radius: implicitWidth/2
|
||||||
border.color: mainItem.color
|
border.color: mainItem.color
|
||||||
|
|
||||||
|
|
@ -51,7 +52,7 @@ Control.RadioButton {
|
||||||
text: mainItem.title
|
text: mainItem.title
|
||||||
font.bold: true
|
font.bold: true
|
||||||
color: DefaultStyle.grey_900
|
color: DefaultStyle.grey_900
|
||||||
font.pixelSize: Math.round(16 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(16)
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
padding: 0
|
padding: 0
|
||||||
|
|
@ -59,12 +60,12 @@ Control.RadioButton {
|
||||||
visible: false
|
visible: false
|
||||||
}
|
}
|
||||||
icon.source: AppIcons.info
|
icon.source: AppIcons.info
|
||||||
Layout.preferredWidth: Math.round(2 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(2)
|
||||||
Layout.preferredHeight: Math.round(2 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(2)
|
||||||
width: Math.round(2 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(2)
|
||||||
height: Math.round(2 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(2)
|
||||||
icon.width: Math.round(2 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(2)
|
||||||
icon.height: Math.round(2 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(2)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -73,27 +74,27 @@ Control.RadioButton {
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.leftMargin: Math.round(13 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(13)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.rightMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
Text {
|
Text {
|
||||||
id: innerText
|
id: innerText
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
Layout.preferredWidth: Math.round(220 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(220)
|
||||||
Layout.preferredHeight: Math.round(100 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(100)
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
text: mainItem.contentText
|
text: mainItem.contentText
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
}
|
}
|
||||||
Image {
|
Image {
|
||||||
id: image
|
id: image
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.preferredWidth: Math.round(100 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(100)
|
||||||
Layout.preferredHeight: Math.round(100 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(100)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
source: mainItem.imgUrl
|
source: mainItem.imgUrl
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ RowLayout {
|
||||||
property var propertyOwner
|
property var propertyOwner
|
||||||
property var propertyOwnerGui
|
property var propertyOwnerGui
|
||||||
property bool enabled: true
|
property bool enabled: true
|
||||||
spacing : Math.round(20 * DefaultStyle.dp)
|
spacing : Utils.getSizeWithScreenRatio(20)
|
||||||
signal checkedChanged(bool checked)
|
signal checkedChanged(bool checked)
|
||||||
|
|
||||||
function setChecked(value) {
|
function setChecked(value) {
|
||||||
|
|
@ -20,8 +20,8 @@ RowLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.minimumHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.minimumHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
spacing: Math.round(4 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(4)
|
||||||
Text {
|
Text {
|
||||||
text: titleText
|
text: titleText
|
||||||
font: Typography.p2l
|
font: Typography.p2l
|
||||||
|
|
|
||||||
|
|
@ -3,15 +3,16 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
textSize: Typography.b3.pixelSize
|
textSize: Typography.b3.pixelSize
|
||||||
textWeight: Typography.b3.weight
|
textWeight: Typography.b3.weight
|
||||||
leftPadding: Math.round(12 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
rightPadding: Math.round(12 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
topPadding: Math.round(6 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(6)
|
||||||
bottomPadding: Math.round(6 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(6)
|
||||||
icon.height: Math.round(14 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(14)
|
||||||
icon.width: Math.round(14 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,8 @@ import Linphone
|
||||||
import EnumsToStringCpp
|
import EnumsToStringCpp
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
|
@ -33,8 +35,8 @@ Item {
|
||||||
|
|
||||||
RowLayout{
|
RowLayout{
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.rightMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
Sticker {
|
Sticker {
|
||||||
id: activeSpeakerSticker
|
id: activeSpeakerSticker
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -58,23 +60,23 @@ Item {
|
||||||
ListView{
|
ListView{
|
||||||
id: sideStickers
|
id: sideStickers
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.preferredWidth: Math.round(300 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(300)
|
||||||
Layout.rightMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: allDevices.count > 2 || !!mainItem.conference?.core.isScreenSharingEnabled
|
visible: allDevices.count > 2 || !!mainItem.conference?.core.isScreenSharingEnabled
|
||||||
//spacing: Math.round(15 * DefaultStyle.dp) // bugged? First item has twice margins
|
//spacing: Utils.getSizeWithScreenRatio(15) // bugged? First item has twice margins
|
||||||
model: allDevices
|
model: allDevices
|
||||||
snapMode: ListView.SnapOneItem
|
snapMode: ListView.SnapOneItem
|
||||||
clip: true
|
clip: true
|
||||||
delegate: Item{ // Spacing workaround
|
delegate: Item{ // Spacing workaround
|
||||||
visible: $modelData && mainItem.callState != LinphoneEnums.CallState.End && mainItem.callState != LinphoneEnums.CallState.Released
|
visible: $modelData && mainItem.callState != LinphoneEnums.CallState.End && mainItem.callState != LinphoneEnums.CallState.Released
|
||||||
&& ($modelData.core.address != activeSpeakerAddress || mainItem.conference?.core.isScreenSharingEnabled) || false
|
&& ($modelData.core.address != activeSpeakerAddress || mainItem.conference?.core.isScreenSharingEnabled) || false
|
||||||
height: visible ? Math.round((180 + 15) * DefaultStyle.dp) : 0
|
height: visible ? Utils.getSizeWithScreenRatio(180 + 15) : 0
|
||||||
width: Math.round(300 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(300)
|
||||||
Sticker {
|
Sticker {
|
||||||
previewEnabled: index == 0 // before anchors for priority initialization
|
previewEnabled: index == 0 // before anchors for priority initialization
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.bottomMargin: Math.round(15 * DefaultStyle.dp)// Spacing
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(15)// Spacing
|
||||||
qmlName: 'S_'+index
|
qmlName: 'S_'+index
|
||||||
visible: parent.visible
|
visible: parent.visible
|
||||||
participantDevice: $modelData
|
participantDevice: $modelData
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQml.Models
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
|
|
@ -32,8 +33,8 @@ Mosaic {
|
||||||
if(index < 0) cameraView.enabled = false // this is a delegate destruction. We need to stop camera before Qt change its currentDevice (and then, let CameraView to delete wrong renderer)
|
if(index < 0) cameraView.enabled = false // this is a delegate destruction. We need to stop camera before Qt change its currentDevice (and then, let CameraView to delete wrong renderer)
|
||||||
}
|
}
|
||||||
|
|
||||||
height: grid.cellHeight - Math.round(10 * DefaultStyle.dp)
|
height: grid.cellHeight - Utils.getSizeWithScreenRatio(10)
|
||||||
width: grid.cellWidth - Math.round(10 * DefaultStyle.dp)
|
width: grid.cellWidth - Utils.getSizeWithScreenRatio(10)
|
||||||
Sticker {
|
Sticker {
|
||||||
id: cameraView
|
id: cameraView
|
||||||
previewEnabled: index == 0
|
previewEnabled: index == 0
|
||||||
|
|
|
||||||
|
|
@ -6,10 +6,11 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
spacing: Math.round(30 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(30)
|
||||||
|
|
||||||
property var callHistoryGui
|
property var callHistoryGui
|
||||||
|
|
||||||
|
|
@ -33,16 +34,16 @@ ColumnLayout {
|
||||||
property alias detailContent: detailControl.data
|
property alias detailContent: detailControl.data
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(13 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(13)
|
||||||
Item {
|
Item {
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
Layout.preferredHeight: detailAvatar.height
|
Layout.preferredHeight: detailAvatar.height
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Avatar {
|
Avatar {
|
||||||
id: detailAvatar
|
id: detailAvatar
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
width: Math.round(100 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(100)
|
||||||
height: Math.round(100 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(100)
|
||||||
contact: mainItem.contact || null
|
contact: mainItem.contact || null
|
||||||
isConference: !!mainItem.conferenceInfo
|
isConference: !!mainItem.conferenceInfo
|
||||||
displayNameVal: mainItem.contactName
|
displayNameVal: mainItem.contactName
|
||||||
|
|
@ -52,18 +53,18 @@ ColumnLayout {
|
||||||
id: rightButton
|
id: rightButton
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.verticalCenter: detailAvatar.verticalCenter
|
anchors.verticalCenter: detailAvatar.verticalCenter
|
||||||
anchors.rightMargin: Math.round(20 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
width: Math.round(30 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(30)
|
||||||
height: Math.round(30 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(30)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(2 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
Text {
|
Text {
|
||||||
Layout.preferredWidth: implicitWidth
|
Layout.preferredWidth: implicitWidth
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
@ -85,8 +86,8 @@ ColumnLayout {
|
||||||
elide: Text.ElideMiddle
|
elide: Text.ElideMiddle
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -98,8 +99,8 @@ ColumnLayout {
|
||||||
text: contact ? contact.core.presenceStatus : ""
|
text: contact ? contact.core.presenceStatus : ""
|
||||||
color: contact ? contact.core.presenceColor : 'transparent'
|
color: contact ? contact.core.presenceColor : 'transparent'
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -120,15 +121,15 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
spacing: Math.round(72 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(72)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: childrenRect.height
|
Layout.preferredHeight: childrenRect.height
|
||||||
visible: !mainItem.isConference
|
visible: !mainItem.isConference
|
||||||
LabelButton {
|
LabelButton {
|
||||||
width: Math.round(56 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(56)
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
button.icon.width: Math.round(24 * DefaultStyle.dp)
|
button.icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.height: Math.round(24 * DefaultStyle.dp)
|
button.icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.source: AppIcons.phone
|
button.icon.source: AppIcons.phone
|
||||||
//: "Appel"
|
//: "Appel"
|
||||||
label: qsTr("contact_call_action")
|
label: qsTr("contact_call_action")
|
||||||
|
|
@ -139,10 +140,10 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
LabelButton {
|
LabelButton {
|
||||||
visible: !SettingsCpp.disableChatFeature
|
visible: !SettingsCpp.disableChatFeature
|
||||||
width: Math.round(56 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(56)
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
button.icon.width: Math.round(24 * DefaultStyle.dp)
|
button.icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.height: Math.round(24 * DefaultStyle.dp)
|
button.icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.source: AppIcons.chatTeardropText
|
button.icon.source: AppIcons.chatTeardropText
|
||||||
//: "Message"
|
//: "Message"
|
||||||
label: qsTr("contact_message_action")
|
label: qsTr("contact_message_action")
|
||||||
|
|
@ -159,10 +160,10 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
LabelButton {
|
LabelButton {
|
||||||
visible: SettingsCpp.videoEnabled
|
visible: SettingsCpp.videoEnabled
|
||||||
width: Math.round(56 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(56)
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
button.icon.width: Math.round(24 * DefaultStyle.dp)
|
button.icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.height: Math.round(24 * DefaultStyle.dp)
|
button.icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
button.icon.source: AppIcons.videoCamera
|
button.icon.source: AppIcons.videoCamera
|
||||||
//: "Appel Video"
|
//: "Appel Video"
|
||||||
label: qsTr("contact_video_call_action")
|
label: qsTr("contact_video_call_action")
|
||||||
|
|
@ -178,6 +179,6 @@ ColumnLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
|
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.topMargin: Math.round(30 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(30)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,8 @@ import Linphone
|
||||||
import EnumsToStringCpp 1.0
|
import EnumsToStringCpp 1.0
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp 1.0
|
||||||
import SettingsCpp 1.0
|
import SettingsCpp 1.0
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
|
|
@ -67,7 +69,7 @@ Item {
|
||||||
id: callTerminatedText
|
id: callTerminatedText
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Math.round(25 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(25)
|
||||||
z: 1
|
z: 1
|
||||||
visible: mainItem.callState === LinphoneEnums.CallState.End || mainItem.callState === LinphoneEnums.CallState.Error || mainItem.callState === LinphoneEnums.CallState.Released
|
visible: mainItem.callState === LinphoneEnums.CallState.End || mainItem.callState === LinphoneEnums.CallState.Error || mainItem.callState === LinphoneEnums.CallState.Released
|
||||||
text: mainItem.conference
|
text: mainItem.conference
|
||||||
|
|
@ -82,8 +84,8 @@ Item {
|
||||||
: call && call.core.lastErrorMessage || ""
|
: call && call.core.lastErrorMessage || ""
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(22 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(22)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
@ -105,12 +107,12 @@ Item {
|
||||||
&& mainItem.callState !== LinphoneEnums.CallState.OutgoingInit
|
&& mainItem.callState !== LinphoneEnums.CallState.OutgoingInit
|
||||||
&& !mainItem.conference?.core.isScreenSharingEnabled
|
&& !mainItem.conference?.core.isScreenSharingEnabled
|
||||||
&& mainItem.participantDeviceCount <= 2
|
&& mainItem.participantDeviceCount <= 2
|
||||||
height: Math.round(180 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(180)
|
||||||
width: Math.round(300 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(300)
|
||||||
anchors.right: mainItem.right
|
anchors.right: mainItem.right
|
||||||
anchors.bottom: mainItem.bottom
|
anchors.bottom: mainItem.bottom
|
||||||
anchors.rightMargin: Math.round(20 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
anchors.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
videoEnabled: preview.visible && mainItem.call && mainItem.call.core.localVideoEnabled
|
videoEnabled: preview.visible && mainItem.call && mainItem.call.core.localVideoEnabled
|
||||||
onVideoEnabledChanged: console.log("P : " +videoEnabled + " / " +visible +" / " +mainItem.call)
|
onVideoEnabledChanged: console.log("P : " +videoEnabled + " / " +visible +" / " +mainItem.call)
|
||||||
property var accountObj: UtilsCpp.findLocalAccountByAddress(mainItem.localAddress)
|
property var accountObj: UtilsCpp.findLocalAccountByAddress(mainItem.localAddress)
|
||||||
|
|
@ -123,7 +125,7 @@ Item {
|
||||||
id: previewMouseArea
|
id: previewMouseArea
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
movableArea: mainItem
|
movableArea: mainItem
|
||||||
margin: Math.round(10 * DefaultStyle.dp)
|
margin: Utils.getSizeWithScreenRatio(10)
|
||||||
function resetPosition(){
|
function resetPosition(){
|
||||||
preview.anchors.right = mainItem.right
|
preview.anchors.right = mainItem.right
|
||||||
preview.anchors.bottom = mainItem.bottom
|
preview.anchors.bottom = mainItem.bottom
|
||||||
|
|
@ -146,22 +148,22 @@ Item {
|
||||||
id: waitingForOthersComponent
|
id: waitingForOthersComponent
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: DefaultStyle.grey_600
|
color: DefaultStyle.grey_600
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
spacing: Math.round(22 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(22)
|
||||||
width: waitText.implicitWidth
|
width: waitText.implicitWidth
|
||||||
Text {
|
Text {
|
||||||
id: waitText
|
id: waitText
|
||||||
//: "En attente d'autres participants…"
|
//: "En attente d'autres participants…"
|
||||||
text: qsTr("conference_call_empty")
|
text: qsTr("conference_call_empty")
|
||||||
Layout.preferredHeight: Math.round(67 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(67)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(30 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(30)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
|
|
|
||||||
|
|
@ -2,6 +2,7 @@ import QtQuick
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Controls.Basic
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQml.Models
|
import QtQml.Models
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
|
@ -56,7 +57,7 @@ ColumnLayout {
|
||||||
|
|
||||||
GridView{
|
GridView{
|
||||||
id: grid
|
id: grid
|
||||||
property real margin: Math.round(10 * DefaultStyle.dp)
|
property real margin: Utils.getSizeWithScreenRatio(10)
|
||||||
property int itemCount: model.count ? model.count :( model.length ? model.length : 0)
|
property int itemCount: model.count ? model.count :( model.length ? model.length : 0)
|
||||||
property int columns: 1
|
property int columns: 1
|
||||||
property int rows: 1
|
property int rows: 1
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -12,7 +13,7 @@ ColumnLayout {
|
||||||
required property int itemsCount
|
required property int itemsCount
|
||||||
property int currentIndex: carouselStackLayout.currentIndex
|
property int currentIndex: carouselStackLayout.currentIndex
|
||||||
property var currentItem: carouselButton.itemAt(currentIndex)
|
property var currentItem: carouselButton.itemAt(currentIndex)
|
||||||
spacing: Math.round(61 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(61)
|
||||||
|
|
||||||
function goToSlide(index) {
|
function goToSlide(index) {
|
||||||
carouselStackLayout.goToSlideAtIndex(index)
|
carouselStackLayout.goToSlideAtIndex(index)
|
||||||
|
|
@ -67,9 +68,9 @@ ColumnLayout {
|
||||||
Item {
|
Item {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: currentIndicator
|
id: currentIndicator
|
||||||
width: Math.round(13 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(13)
|
||||||
height: Math.round(8 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(8)
|
||||||
radius: Math.round(30 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(30)
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
z: 1
|
z: 1
|
||||||
x: mainItem.currentIndex >= 0 && mainItem.currentItem ? mainItem.currentItem.x - width/2 + mainItem.currentItem.width/2 : 0
|
x: mainItem.currentIndex >= 0 && mainItem.currentItem ? mainItem.currentItem.x - width/2 + mainItem.currentItem.width/2 : 0
|
||||||
|
|
@ -77,21 +78,21 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: carouselButtonsLayout
|
id: carouselButtonsLayout
|
||||||
spacing: Math.round(7.5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(7.5)
|
||||||
anchors.leftMargin: Math.round(2.5 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(2.5)
|
||||||
Repeater {
|
Repeater {
|
||||||
id: carouselButton
|
id: carouselButton
|
||||||
model: mainItem.itemsCount
|
model: mainItem.itemsCount
|
||||||
delegate: Button {
|
delegate: Button {
|
||||||
Layout.preferredWidth: Math.round(8 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(8)
|
||||||
Layout.preferredHeight: Math.round(8 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(8)
|
||||||
topPadding: 0
|
topPadding: 0
|
||||||
bottomPadding: 0
|
bottomPadding: 0
|
||||||
leftPadding: 0
|
leftPadding: 0
|
||||||
rightPadding: 0
|
rightPadding: 0
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
radius: Math.round(30 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(30)
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
}
|
}
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
GridLayout {
|
GridLayout {
|
||||||
|
|
@ -12,10 +13,10 @@ GridLayout {
|
||||||
property ChatMessageContentProxy proxyModel
|
property ChatMessageContentProxy proxyModel
|
||||||
property bool isHoveringFile: false
|
property bool isHoveringFile: false
|
||||||
property int itemCount: delModel.count
|
property int itemCount: delModel.count
|
||||||
property int itemWidth: Math.round(95 * DefaultStyle.dp)
|
property int itemWidth: Utils.getSizeWithScreenRatio(95)
|
||||||
// cellWidth:
|
// cellWidth:
|
||||||
// cellHeight: Math.round(105 * DefaultStyle.dp)
|
// cellHeight: Utils.getSizeWithScreenRatio(105)
|
||||||
property real maxWidth: 3 * 105 * DefaultStyle.dp
|
property real maxWidth: Utils.getSizeWithScreenRatio(3 * 105)
|
||||||
columns: optimalColumns
|
columns: optimalColumns
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,10 +6,11 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
spacing: Math.round(30 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(30)
|
||||||
|
|
||||||
property FriendGui contact
|
property FriendGui contact
|
||||||
|
|
||||||
|
|
@ -17,34 +18,34 @@ ColumnLayout {
|
||||||
property alias content: detailLayout.data
|
property alias content: detailLayout.data
|
||||||
property alias bannerContent: bannerLayout.data
|
property alias bannerContent: bannerLayout.data
|
||||||
property alias secondLineContent: verticalLayoutSecondLine.data
|
property alias secondLineContent: verticalLayoutSecondLine.data
|
||||||
property real minimumWidthForSwitchintToRowLayout: Math.round(756 * DefaultStyle.dp)
|
property real minimumWidthForSwitchintToRowLayout: Utils.getSizeWithScreenRatio(756)
|
||||||
property var useVerticalLayout: width < minimumWidthForSwitchintToRowLayout
|
property var useVerticalLayout: width < minimumWidthForSwitchintToRowLayout
|
||||||
|
|
||||||
GridLayout {
|
GridLayout {
|
||||||
Layout.leftMargin: Math.round(64 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(64)
|
||||||
Layout.rightMargin: Math.round(64 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(64)
|
||||||
Layout.topMargin: Math.round(56 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(56)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
columns: mainItem.useVerticalLayout ? 1 : children.length
|
columns: mainItem.useVerticalLayout ? 1 : children.length
|
||||||
rows: 1
|
rows: 1
|
||||||
columnSpacing: Math.round(49 * DefaultStyle.dp)
|
columnSpacing: Utils.getSizeWithScreenRatio(49)
|
||||||
rowSpacing: Math.round(27 * DefaultStyle.dp)
|
rowSpacing: Utils.getSizeWithScreenRatio(27)
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.preferredWidth: Math.round(341 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(341)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.preferredWidth: Math.round(341 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(341)
|
||||||
Control.Control {
|
Control.Control {
|
||||||
// Layout.preferredWidth: Math.round(734 * DefaultStyle.dp)
|
// Layout.preferredWidth: Utils.getSizeWithScreenRatio(734)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
width: Math.round(734 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(734)
|
||||||
height: Math.round(100 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(100)
|
||||||
rightPadding: Math.round(21 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(21)
|
||||||
background: GradientRectangle {
|
background: GradientRectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: avatar.width / 2
|
anchors.leftMargin: avatar.width / 2
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
borderGradient: Gradient {
|
borderGradient: Gradient {
|
||||||
orientation: Gradient.Horizontal
|
orientation: Gradient.Horizontal
|
||||||
GradientStop { position: 0.0; color: DefaultStyle.grey_100 }
|
GradientStop { position: 0.0; color: DefaultStyle.grey_100 }
|
||||||
|
|
@ -58,12 +59,12 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
id: bannerLayout
|
id: bannerLayout
|
||||||
spacing: Math.round(32 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(32)
|
||||||
Avatar {
|
Avatar {
|
||||||
id: avatar
|
id: avatar
|
||||||
contact: mainItem.contact
|
contact: mainItem.contact
|
||||||
Layout.preferredWidth: Math.round(100 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(100)
|
||||||
Layout.preferredHeight: Math.round(100 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(100)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -71,8 +72,8 @@ ColumnLayout {
|
||||||
PresenceNoteLayout {
|
PresenceNoteLayout {
|
||||||
visible: contact?.core.presenceNote.length > 0 && mainItem.useVerticalLayout
|
visible: contact?.core.presenceNote.length > 0 && mainItem.useVerticalLayout
|
||||||
friendCore: contact?.core || null
|
friendCore: contact?.core || null
|
||||||
Layout.preferredWidth: 412 * DefaultStyle.dp
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(412)
|
||||||
Layout.preferredHeight: 85 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(85)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
|
|
@ -90,23 +91,23 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.fillWidth:true
|
Layout.fillWidth:true
|
||||||
Layout.preferredHeight: 79 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(79)
|
||||||
color: 'transparent'
|
color: 'transparent'
|
||||||
visible: contact && contact.core.presenceNote.length > 0 && !mainItem.useVerticalLayout
|
visible: contact && contact.core.presenceNote.length > 0 && !mainItem.useVerticalLayout
|
||||||
PresenceNoteLayout {
|
PresenceNoteLayout {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
friendCore: contact?.core || null
|
friendCore: contact?.core || null
|
||||||
width: 412 * DefaultStyle.dp
|
width: Utils.getSizeWithScreenRatio(412)
|
||||||
height: 85 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(85)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
StackLayout {
|
StackLayout {
|
||||||
id: detailLayout
|
id: detailLayout
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
Layout.topMargin: mainItem.useVerticalLayout ? 0 : Math.round(30 * DefaultStyle.dp)
|
Layout.topMargin: mainItem.useVerticalLayout ? 0 : Utils.getSizeWithScreenRatio(30)
|
||||||
Layout.leftMargin: Math.round(64 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(64)
|
||||||
Layout.rightMargin: Math.round(64 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(64)
|
||||||
Layout.bottomMargin: Math.round(53 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(53)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -6,32 +6,33 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property var friendCore
|
property var friendCore
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: 20 * DefaultStyle.dp
|
radius: Utils.getSizeWithScreenRatio(20)
|
||||||
border.color: DefaultStyle.main2_200
|
border.color: DefaultStyle.main2_200
|
||||||
border.width: 2 * DefaultStyle.dp
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.leftMargin: 16 * DefaultStyle.dp
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.rightMargin: 16 * DefaultStyle.dp
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
spacing: 8 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: 6 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(6)
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.presenceNote
|
imageSource: AppIcons.presenceNote
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredHeight: Math.round(17 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(17)
|
||||||
Layout.preferredWidth: Math.round(17 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(17)
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
|
|
||||||
|
|
@ -72,17 +72,17 @@ FocusScope {
|
||||||
}
|
}
|
||||||
Accessible.name: mainItem.startGroupButtonText
|
Accessible.name: mainItem.startGroupButtonText
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: Math.round(44 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(44)
|
||||||
height: width
|
height: width
|
||||||
radius: width / 2
|
radius: width / 2
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.usersThreeFilled
|
imageSource: AppIcons.usersThreeFilled
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: width
|
height: width
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
colorizationColor: DefaultStyle.grey_0
|
colorizationColor: DefaultStyle.grey_0
|
||||||
|
|
|
||||||
|
|
@ -6,16 +6,17 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
property string label
|
property string label
|
||||||
property var icon
|
property var icon
|
||||||
property alias content: contentControl.contentItem
|
property alias content: contentControl.contentItem
|
||||||
signal titleIconClicked
|
signal titleIconClicked
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.label
|
text: mainItem.label
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
|
|
@ -46,9 +47,9 @@ ColumnLayout {
|
||||||
id: contentControl
|
id: contentControl
|
||||||
visible: expandButton.checked
|
visible: expandButton.checked
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
leftPadding: Math.round(20 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
rightPadding: Math.round(20 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
topPadding: Math.round(17 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(17)
|
||||||
bottomPadding: Math.round(17 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(17)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope{
|
FocusScope{
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -40,11 +41,11 @@ FocusScope{
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: layout
|
id: layout
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
Text {
|
Text {
|
||||||
visible: label.length > 0
|
visible: label.length > 0
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
|
|
@ -63,8 +64,8 @@ FocusScope{
|
||||||
Item{Layout.fillWidth: true}
|
Item{Layout.fillWidth: true}
|
||||||
PopupButton {
|
PopupButton {
|
||||||
visible: mainItem.tooltip !== ""
|
visible: mainItem.tooltip !== ""
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
icon.source: AppIcons.info
|
icon.source: AppIcons.info
|
||||||
popUpTitle: mainItem.label
|
popUpTitle: mainItem.label
|
||||||
|
|
|
||||||
|
|
@ -3,7 +3,8 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -17,10 +18,10 @@ ColumnLayout {
|
||||||
id: rightPanelHeader
|
id: rightPanelHeader
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
z: rightPanelContent.z + 1
|
z: rightPanelContent.z + 1
|
||||||
topPadding: Math.round(30 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(30)
|
||||||
bottomPadding: Math.round(24 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(24)
|
||||||
leftPadding: Math.round(32 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
rightPadding: Math.round(32 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
|
|
||||||
background: Item {
|
background: Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
@ -36,7 +37,7 @@ ColumnLayout {
|
||||||
shadowColor: DefaultStyle.grey_1000
|
shadowColor: DefaultStyle.grey_1000
|
||||||
shadowBlur: 1
|
shadowBlur: 1
|
||||||
shadowOpacity: 0.05
|
shadowOpacity: 0.05
|
||||||
shadowVerticalOffset: Math.round(10 * DefaultStyle.dp)
|
shadowVerticalOffset: Utils.getSizeWithScreenRatio(10)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,14 +3,15 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.ScrollBar {
|
Control.ScrollBar {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
padding: 0
|
padding: 0
|
||||||
property color color: DefaultStyle.grey_850
|
property color color: DefaultStyle.grey_850
|
||||||
contentItem: Rectangle {
|
contentItem: Rectangle {
|
||||||
implicitWidth: Math.round(6 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(6)
|
||||||
radius: Math.round(32 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(32)
|
||||||
color: mainItem.color
|
color: mainItem.color
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,28 +2,30 @@ import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
/*
|
/*
|
||||||
Layout with line separator used in several views
|
Layout with line separator used in several views
|
||||||
*/
|
*/
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
property alias content: contentLayout.data
|
property alias content: contentLayout.data
|
||||||
property alias contentLayout: contentLayout
|
property alias contentLayout: contentLayout
|
||||||
implicitHeight: contentLayout.implicitHeight + Math.max(Math.round(1 * DefaultStyle.dp), 1) + spacing
|
implicitHeight: contentLayout.implicitHeight + Utils.getSizeWithScreenRatio(1) + spacing
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: contentLayout
|
id: contentLayout
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
// width: parent.width
|
// width: parent.width
|
||||||
// Layout.fillWidth: true
|
// Layout.fillWidth: true
|
||||||
// Layout.preferredHeight: childrenRect.height
|
// Layout.preferredHeight: childrenRect.height
|
||||||
// Layout.preferredWidth: parent.width
|
// Layout.preferredWidth: parent.width
|
||||||
// Layout.leftMargin: Math.round(8 * DefaultStyle.dp)
|
// Layout.leftMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
width: parent.width
|
width: parent.width
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -50,7 +50,7 @@ Control.TabBar {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
fontSizeMode: Text.Fit
|
fontSizeMode: Text.Fit
|
||||||
font.pixelSize: Math.round(15 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(15)
|
||||||
text: parent.unread > 100 ? '99+' : parent.unread
|
text: parent.unread > 100 ? '99+' : parent.unread
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -136,7 +136,7 @@ Control.TabBar {
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
id: buttonIcon
|
id: buttonIcon
|
||||||
property real buttonSize: mainItem.currentIndex !== index && tabButton.hovered ? Utils.getSizeWithScreenRatio(26) : Utils.getSizeWithScreenRatio(24)
|
property real buttonSize: Utils.getSizeWithScreenRatio(mainItem.currentIndex !== index && tabButton.hovered ? 26 : 24)
|
||||||
imageSource: mainItem.currentIndex === index ? modelData.selectedIcon : modelData.icon
|
imageSource: mainItem.currentIndex === index ? modelData.selectedIcon : modelData.icon
|
||||||
Layout.preferredWidth: buttonSize
|
Layout.preferredWidth: buttonSize
|
||||||
Layout.preferredHeight: buttonSize
|
Layout.preferredHeight: buttonSize
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -13,7 +14,7 @@ Item {
|
||||||
height: busyIndicator.height
|
height: busyIndicator.height
|
||||||
Control.BusyIndicator {
|
Control.BusyIndicator {
|
||||||
id: busyIndicator
|
id: busyIndicator
|
||||||
width: Math.round(60 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(60)
|
||||||
height: width
|
height: width
|
||||||
running: mainItem.visible
|
running: mainItem.visible
|
||||||
anchors.centerIn: mainItem
|
anchors.centerIn: mainItem
|
||||||
|
|
|
||||||
|
|
@ -32,9 +32,7 @@ ListView {
|
||||||
onListAboutToBeReset: loading = true
|
onListAboutToBeReset: loading = true
|
||||||
filterText: mainItem.searchText
|
filterText: mainItem.searchText
|
||||||
onFilterTextChanged: maxDisplayItems = initialDisplayItems
|
onFilterTextChanged: maxDisplayItems = initialDisplayItems
|
||||||
initialDisplayItems: Math.max(
|
initialDisplayItems: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(56)))
|
||||||
20,
|
|
||||||
2 * mainItem.height / (Utils.getSizeWithScreenRatio(56)))
|
|
||||||
displayItemsStep: 3 * initialDisplayItems / 2
|
displayItemsStep: 3 * initialDisplayItems / 2
|
||||||
onModelReset: {
|
onModelReset: {
|
||||||
mainItem.resultsReceived()
|
mainItem.resultsReceived()
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@ import QtQml
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp 1.0
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -15,7 +16,7 @@ ListView {
|
||||||
sourceModel: AppCpp.calls
|
sourceModel: AppCpp.calls
|
||||||
}
|
}
|
||||||
implicitHeight: contentHeight
|
implicitHeight: contentHeight
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
clip: true
|
clip: true
|
||||||
onCountChanged: forceLayout()
|
onCountChanged: forceLayout()
|
||||||
|
|
||||||
|
|
@ -26,9 +27,9 @@ ListView {
|
||||||
|
|
||||||
delegate: RowLayout {
|
delegate: RowLayout {
|
||||||
id: callInformationItem
|
id: callInformationItem
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: Math.round(45 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(45)
|
||||||
property var remoteNameObj: UtilsCpp.getDisplayName(modelData.core.remoteAddress)
|
property var remoteNameObj: UtilsCpp.getDisplayName(modelData.core.remoteAddress)
|
||||||
property var callName : (modelData && !SettingsCpp.disableMeetingsFeature && modelData.core.isConference)
|
property var callName : (modelData && !SettingsCpp.disableMeetingsFeature && modelData.core.isConference)
|
||||||
? modelData.core.conference.core.subject
|
? modelData.core.conference.core.subject
|
||||||
|
|
@ -37,8 +38,8 @@ ListView {
|
||||||
: ""
|
: ""
|
||||||
Avatar {
|
Avatar {
|
||||||
id: delegateAvatar
|
id: delegateAvatar
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
_address: modelData.core.remoteAddress
|
_address: modelData.core.remoteAddress
|
||||||
secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
||||||
isConference: modelData.core.isConference
|
isConference: modelData.core.isConference
|
||||||
|
|
@ -49,7 +50,7 @@ ListView {
|
||||||
Text {
|
Text {
|
||||||
id: delegateName
|
id: delegateName
|
||||||
text: callInformationItem.callName
|
text: callInformationItem.callName
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
}
|
}
|
||||||
|
|
@ -59,7 +60,7 @@ ListView {
|
||||||
property string type: modelData.core.isConference ? qsTr("meeting")
|
property string type: modelData.core.isConference ? qsTr("meeting")
|
||||||
//: "Appel"
|
//: "Appel"
|
||||||
: qsTr("call")
|
: qsTr("call")
|
||||||
Layout.rightMargin: Math.round(2 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(2)
|
||||||
text: modelData.core.state === LinphoneEnums.CallState.Paused
|
text: modelData.core.state === LinphoneEnums.CallState.Paused
|
||||||
|| modelData.core.state === LinphoneEnums.CallState.PausedByRemote
|
|| modelData.core.state === LinphoneEnums.CallState.PausedByRemote
|
||||||
//: "%1 en pause"
|
//: "%1 en pause"
|
||||||
|
|
@ -67,16 +68,16 @@ ListView {
|
||||||
//: "%1 en cours"
|
//: "%1 en cours"
|
||||||
: qsTr("ongoing_call_or_meeting").arg(type)
|
: qsTr("ongoing_call_or_meeting").arg(type)
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item{Layout.fillWidth: true}
|
Item{Layout.fillWidth: true}
|
||||||
Button {
|
Button {
|
||||||
id: transferButton
|
id: transferButton
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
visible: mainItem.isTransferList && (mainItem.currentRemoteAddress !== modelData.core.remoteAddress)
|
visible: mainItem.isTransferList && (mainItem.currentRemoteAddress !== modelData.core.remoteAddress)
|
||||||
icon.source: AppIcons.transferCall
|
icon.source: AppIcons.transferCall
|
||||||
|
|
@ -90,21 +91,21 @@ ListView {
|
||||||
Button {
|
Button {
|
||||||
id: pausingButton
|
id: pausingButton
|
||||||
enabled: !(modelData.core.state === LinphoneEnums.CallState.PausedByRemote)
|
enabled: !(modelData.core.state === LinphoneEnums.CallState.PausedByRemote)
|
||||||
Layout.preferredWidth: Math.round(28 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(28)
|
||||||
Layout.preferredHeight: Math.round(28 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(28)
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
leftPadding: Math.round(5 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
rightPadding: Math.round(5 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
topPadding: Math.round(5 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
bottomPadding: Math.round(5 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
property bool pausedByUser: modelData.core.state === LinphoneEnums.CallState.Paused
|
property bool pausedByUser: modelData.core.state === LinphoneEnums.CallState.Paused
|
||||||
color: pausedByUser ? DefaultStyle.success_500_main : DefaultStyle.grey_500
|
color: pausedByUser ? DefaultStyle.success_500_main : DefaultStyle.grey_500
|
||||||
contentImageColor: DefaultStyle.grey_0
|
contentImageColor: DefaultStyle.grey_0
|
||||||
KeyNavigation.right: endCallButton
|
KeyNavigation.right: endCallButton
|
||||||
KeyNavigation.left: endCallButton
|
KeyNavigation.left: endCallButton
|
||||||
icon.source: pausedByUser ? AppIcons.play : AppIcons.pause
|
icon.source: pausedByUser ? AppIcons.play : AppIcons.pause
|
||||||
icon.width: Math.round(18 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(18)
|
||||||
icon.height: Math.round(18 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(18)
|
||||||
onClicked: modelData.core.lSetPaused(!modelData.core.paused)
|
onClicked: modelData.core.lSetPaused(!modelData.core.paused)
|
||||||
TextMetrics {
|
TextMetrics {
|
||||||
id: pauseMeter
|
id: pauseMeter
|
||||||
|
|
@ -120,14 +121,14 @@ ListView {
|
||||||
}
|
}
|
||||||
SmallButton {
|
SmallButton {
|
||||||
id: endCallButton
|
id: endCallButton
|
||||||
Layout.preferredWidth: Math.round(38 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(38)
|
||||||
Layout.preferredHeight: Math.round(28 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(28)
|
||||||
style: ButtonStyle.phoneRed
|
style: ButtonStyle.phoneRed
|
||||||
KeyNavigation.left: pausingButton
|
KeyNavigation.left: pausingButton
|
||||||
KeyNavigation.right: pausingButton
|
KeyNavigation.right: pausingButton
|
||||||
contentImageColor: DefaultStyle.grey_0
|
contentImageColor: DefaultStyle.grey_0
|
||||||
icon.width: Math.round(18 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(18)
|
||||||
icon.height: Math.round(18 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(18)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
mainWindow.callTerminatedByUser = true
|
mainWindow.callTerminatedByUser = true
|
||||||
mainWindow.endCall(modelData)
|
mainWindow.endCall(modelData)
|
||||||
|
|
|
||||||
|
|
@ -3,69 +3,70 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import SettingsCpp 1.0
|
import SettingsCpp 1.0
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property var call
|
property var call
|
||||||
property string objectName: "statsPanel"
|
property string objectName: "statsPanel"
|
||||||
spacing: Math.round(20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
|
|
||||||
RoundedPane {
|
RoundedPane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
topPadding: Math.round(13 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
bottomPadding: Math.round(13 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
|
|
||||||
Layout.topMargin: Math.round(13 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(13)
|
||||||
Layout.leftMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.rightMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
|
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Text {
|
Text {
|
||||||
//: "Audio"
|
//: "Audio"
|
||||||
text: qsTr("call_stats_audio_title")
|
text: qsTr("call_stats_audio_title")
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Typography.p2.weight
|
weight: Typography.p2.weight
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.audioStats.codec : ""
|
text: mainItem.call ? mainItem.call.core.audioStats.codec : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.audioStats.bandwidth : ""
|
text: mainItem.call ? mainItem.call.core.audioStats.bandwidth : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.audioStats.lossRate : ""
|
text: mainItem.call ? mainItem.call.core.audioStats.lossRate : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.audioStats.jitterBufferSize : ""
|
text: mainItem.call ? mainItem.call.core.audioStats.jitterBufferSize : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -73,69 +74,69 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
RoundedPane {
|
RoundedPane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
topPadding: Math.round(13 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
bottomPadding: Math.round(13 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
|
|
||||||
Layout.leftMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.rightMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
|
|
||||||
visible: mainItem.call && (mainItem.call.core.localVideoEnabled || mainItem.call.core.remoteVideoEnabled)
|
visible: mainItem.call && (mainItem.call.core.localVideoEnabled || mainItem.call.core.remoteVideoEnabled)
|
||||||
|
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Text {
|
Text {
|
||||||
//: "Vidéo"
|
//: "Vidéo"
|
||||||
text: qsTr("call_stats_video_title")
|
text: qsTr("call_stats_video_title")
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Typography.p2.weight
|
weight: Typography.p2.weight
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.videoStats.codec : ""
|
text: mainItem.call ? mainItem.call.core.videoStats.codec : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.videoStats.bandwidth : ""
|
text: mainItem.call ? mainItem.call.core.videoStats.bandwidth : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.videoStats.lossRate : ""
|
text: mainItem.call ? mainItem.call.core.videoStats.lossRate : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.videoStats.resolution : ""
|
text: mainItem.call ? mainItem.call.core.videoStats.resolution : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call ? mainItem.call.core.videoStats.fps : ""
|
text: mainItem.call ? mainItem.call.core.videoStats.fps : ""
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ ListView {
|
||||||
property SearchBar searchBar
|
property SearchBar searchBar
|
||||||
property bool loading: false
|
property bool loading: false
|
||||||
property string searchText: searchBar?.text
|
property string searchText: searchBar?.text
|
||||||
property real busyIndicatorSize: Math.round(60 * DefaultStyle.dp)
|
property real busyIndicatorSize: Utils.getSizeWithScreenRatio(60)
|
||||||
|
|
||||||
property ChatGui currentChatGui: model.getAt(currentIndex) || null
|
property ChatGui currentChatGui: model.getAt(currentIndex) || null
|
||||||
property ChatGui chatToSelect: null
|
property ChatGui chatToSelect: null
|
||||||
|
|
@ -41,7 +41,7 @@ ListView {
|
||||||
loading = true
|
loading = true
|
||||||
}
|
}
|
||||||
filterText: mainItem.searchText
|
filterText: mainItem.searchText
|
||||||
initialDisplayItems: Math.max(20, 2 * mainItem.height / (Math.round(56 * DefaultStyle.dp)))
|
initialDisplayItems: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(56)))
|
||||||
displayItemsStep: 3 * initialDisplayItems / 2
|
displayItemsStep: 3 * initialDisplayItems / 2
|
||||||
onModelReset: {
|
onModelReset: {
|
||||||
loading = false
|
loading = false
|
||||||
|
|
@ -62,7 +62,7 @@ ListView {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
// flickDeceleration: 10000
|
// flickDeceleration: 10000
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
|
|
||||||
function selectChat(chatGui) {
|
function selectChat(chatGui) {
|
||||||
var index = chatProxy.findChatIndex(chatGui)
|
var index = chatProxy.findChatIndex(chatGui)
|
||||||
|
|
@ -134,8 +134,8 @@ ListView {
|
||||||
component UnreadNotification: Item {
|
component UnreadNotification: Item {
|
||||||
id: unreadNotif
|
id: unreadNotif
|
||||||
property int unread: 0
|
property int unread: 0
|
||||||
width: Math.round(14 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(14)
|
||||||
height: Math.round(14 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(14)
|
||||||
visible: unread > 0
|
visible: unread > 0
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: background
|
id: background
|
||||||
|
|
@ -148,7 +148,7 @@ ListView {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
fontSizeMode: Text.Fit
|
fontSizeMode: Text.Fit
|
||||||
font.pixelSize: Math.round(10 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(10)
|
||||||
text: parent.unreadNotif > 100 ? '99+' : unreadNotif.unread
|
text: parent.unreadNotif > 100 ? '99+' : unreadNotif.unread
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -168,7 +168,7 @@ ListView {
|
||||||
delegate: FocusScope {
|
delegate: FocusScope {
|
||||||
visible: !mainItem.loading
|
visible: !mainItem.loading
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: Math.round(63 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(63)
|
||||||
Connections {
|
Connections {
|
||||||
target: mainItem
|
target: mainItem
|
||||||
function onMarkAllAsRead() {modelData.core.lMarkAsRead()}
|
function onMarkAllAsRead() {modelData.core.lMarkAsRead()}
|
||||||
|
|
@ -176,18 +176,18 @@ ListView {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
z: 1
|
z: 1
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Math.round(11 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(11)
|
||||||
anchors.rightMargin: Math.round(11 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(11)
|
||||||
anchors.topMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
anchors.bottomMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Avatar {
|
Avatar {
|
||||||
property var contactObj: modelData ? UtilsCpp.findFriendByAddress(modelData.core.peerAddress) : null
|
property var contactObj: modelData ? UtilsCpp.findFriendByAddress(modelData.core.peerAddress) : null
|
||||||
contact: contactObj?.value || null
|
contact: contactObj?.value || null
|
||||||
displayNameVal: modelData && modelData.core.avatarUri || ""
|
displayNameVal: modelData && modelData.core.avatarUri || ""
|
||||||
secured: modelData?.core.isSecured || false
|
secured: modelData?.core.isSecured || false
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
// isConference: modelData.core.isConference
|
// isConference: modelData.core.isConference
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
asynchronous: false
|
asynchronous: false
|
||||||
|
|
@ -195,7 +195,7 @@ ListView {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
Text {
|
Text {
|
||||||
id: friendAddress
|
id: friendAddress
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -209,7 +209,7 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
@ -217,8 +217,8 @@ ListView {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.reply
|
imageSource: AppIcons.reply
|
||||||
colorizationColor: DefaultStyle.main2_500
|
colorizationColor: DefaultStyle.main2_500
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
@ -226,8 +226,8 @@ ListView {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.forward
|
imageSource: AppIcons.forward
|
||||||
colorizationColor: DefaultStyle.main2_500
|
colorizationColor: DefaultStyle.main2_500
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
@ -235,8 +235,8 @@ ListView {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.paperclip
|
imageSource: AppIcons.paperclip
|
||||||
colorizationColor: DefaultStyle.main2_500
|
colorizationColor: DefaultStyle.main2_500
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
@ -244,8 +244,8 @@ ListView {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.waveform
|
imageSource: AppIcons.waveform
|
||||||
colorizationColor: DefaultStyle.main2_500
|
colorizationColor: DefaultStyle.main2_500
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
@ -253,8 +253,8 @@ ListView {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.calendarBlank
|
imageSource: AppIcons.calendarBlank
|
||||||
colorizationColor: DefaultStyle.main2_500
|
colorizationColor: DefaultStyle.main2_500
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -306,26 +306,26 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Item {Layout.fillWidth: true}
|
Item {Layout.fillWidth: true}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: modelData?.core.ephemeralEnabled || false
|
visible: modelData?.core.ephemeralEnabled || false
|
||||||
Layout.preferredWidth: visible ? 14 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(14) : 0
|
||||||
Layout.preferredHeight: 14 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.main2_400
|
colorizationColor: DefaultStyle.main2_400
|
||||||
imageSource: AppIcons.clockCountDown
|
imageSource: AppIcons.clockCountDown
|
||||||
}
|
}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: modelData != undefined && modelData?.core.isBasic
|
visible: modelData != undefined && modelData?.core.isBasic
|
||||||
Layout.preferredWidth: visible ? 14 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(14) : 0
|
||||||
Layout.preferredHeight: 14 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.warning_700
|
colorizationColor: DefaultStyle.warning_700
|
||||||
imageSource: AppIcons.lockSimpleOpen
|
imageSource: AppIcons.lockSimpleOpen
|
||||||
}
|
}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: modelData != undefined && modelData?.core.muted
|
visible: modelData != undefined && modelData?.core.muted
|
||||||
Layout.preferredWidth: visible ? 14 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(14) : 0
|
||||||
Layout.preferredHeight: 14 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.main2_400
|
colorizationColor: DefaultStyle.main2_400
|
||||||
imageSource: AppIcons.bellSlash
|
imageSource: AppIcons.bellSlash
|
||||||
}
|
}
|
||||||
|
|
@ -336,8 +336,8 @@ ListView {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: modelData?.core.lastMessage && modelData?.core.lastMessageState !== LinphoneEnums.ChatMessageState.StateIdle
|
visible: modelData?.core.lastMessage && modelData?.core.lastMessageState !== LinphoneEnums.ChatMessageState.StateIdle
|
||||||
&& !modelData.core.lastMessage.core.isRemoteMessage || false
|
&& !modelData.core.lastMessage.core.isRemoteMessage || false
|
||||||
Layout.preferredWidth: visible ? 14 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(14) : 0
|
||||||
Layout.preferredHeight: 14 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.main1_500_main
|
colorizationColor: DefaultStyle.main1_500_main
|
||||||
imageSource: modelData
|
imageSource: modelData
|
||||||
? modelData.core.lastMessageState === LinphoneEnums.ChatMessageState.StateDelivered
|
? modelData.core.lastMessageState === LinphoneEnums.ChatMessageState.StateDelivered
|
||||||
|
|
@ -357,7 +357,7 @@ ListView {
|
||||||
id: chatroomPopup
|
id: chatroomPopup
|
||||||
// z: 1
|
// z: 1
|
||||||
popup.x: 0
|
popup.x: 0
|
||||||
popup.padding: Math.round(10 * DefaultStyle.dp)
|
popup.padding: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: mouseArea.containsMouse || hovered || popup.opened
|
visible: mouseArea.containsMouse || hovered || popup.opened
|
||||||
enabled: visible
|
enabled: visible
|
||||||
popup.contentItem: ColumnLayout {
|
popup.contentItem: ColumnLayout {
|
||||||
|
|
@ -369,7 +369,7 @@ ListView {
|
||||||
: qsTr("chat_room_mute")
|
: qsTr("chat_room_mute")
|
||||||
: ""
|
: ""
|
||||||
icon.source: modelData ? modelData.core.muted ? AppIcons.bell : AppIcons.bellSlash : ""
|
icon.source: modelData ? modelData.core.muted ? AppIcons.bell : AppIcons.bellSlash : ""
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onClicked: {
|
onClicked: {
|
||||||
modelData.core.muted = !modelData.core.muted
|
modelData.core.muted = !modelData.core.muted
|
||||||
|
|
@ -380,7 +380,7 @@ ListView {
|
||||||
//: "Mark as read"
|
//: "Mark as read"
|
||||||
text: qsTr("chat_room_mark_as_read")
|
text: qsTr("chat_room_mark_as_read")
|
||||||
icon.source: AppIcons.checks
|
icon.source: AppIcons.checks
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onClicked: {
|
onClicked: {
|
||||||
modelData.core.lMarkAsRead()
|
modelData.core.lMarkAsRead()
|
||||||
|
|
@ -392,14 +392,14 @@ ListView {
|
||||||
visible: modelData && !modelData.core.isReadOnly && modelData.core.isGroupChat || false
|
visible: modelData && !modelData.core.isReadOnly && modelData.core.isGroupChat || false
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.min(1, Math.round(1 * DefaultStyle.dp))
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
}
|
}
|
||||||
IconLabelButton {
|
IconLabelButton {
|
||||||
//: "leave"
|
//: "leave"
|
||||||
text: qsTr("chat_room_leave")
|
text: qsTr("chat_room_leave")
|
||||||
icon.source: AppIcons.trashCan
|
icon.source: AppIcons.trashCan
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onClicked: {
|
onClicked: {
|
||||||
//: leave the conversation ?
|
//: leave the conversation ?
|
||||||
|
|
@ -420,7 +420,7 @@ ListView {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
visible: deleteButton.visible
|
visible: deleteButton.visible
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.min(1, Math.round(1 * DefaultStyle.dp))
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
}
|
}
|
||||||
IconLabelButton {
|
IconLabelButton {
|
||||||
|
|
@ -428,7 +428,7 @@ ListView {
|
||||||
//: "Delete"
|
//: "Delete"
|
||||||
text: qsTr("chat_room_delete")
|
text: qsTr("chat_room_delete")
|
||||||
icon.source: AppIcons.trashCan
|
icon.source: AppIcons.trashCan
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onClicked: {
|
onClicked: {
|
||||||
//: Delete the conversation ?
|
//: Delete the conversation ?
|
||||||
|
|
@ -463,7 +463,7 @@ ListView {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
opacity: 0.7
|
opacity: 0.7
|
||||||
radius: Math.round(8 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(8)
|
||||||
color: mainItem.currentIndex === index ? DefaultStyle.main2_200 : DefaultStyle.main2_100
|
color: mainItem.currentIndex === index ? DefaultStyle.main2_200 : DefaultStyle.main2_100
|
||||||
visible: mainItem.lastMouseContainsIndex === index || mainItem.currentIndex === index
|
visible: mainItem.lastMouseContainsIndex === index || mainItem.currentIndex === index
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -458,7 +458,7 @@ Control.Control {
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.min(1, Utils.getSizeWithScreenRatio(1))
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
}
|
}
|
||||||
IconLabelButton {
|
IconLabelButton {
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import QtMultimedia
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
// Simple content display without reply and forward. These modules need to be splitted because of cyclic dependencies.
|
// Simple content display without reply and forward. These modules need to be splitted because of cyclic dependencies.
|
||||||
|
|
@ -30,8 +31,8 @@ ColumnLayout {
|
||||||
|
|
||||||
property int fileBorderWidth : 0
|
property int fileBorderWidth : 0
|
||||||
|
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
property int padding: Math.round(10 * DefaultStyle.dp)
|
property int padding: Utils.getSizeWithScreenRatio(10)
|
||||||
|
|
||||||
property ChatMessageContentProxy filescontentProxy: ChatMessageContentProxy {
|
property ChatMessageContentProxy filescontentProxy: ChatMessageContentProxy {
|
||||||
filterType: ChatMessageContentProxy.FilterContentType.File
|
filterType: ChatMessageContentProxy.FilterContentType.File
|
||||||
|
|
@ -49,8 +50,8 @@ ColumnLayout {
|
||||||
delegate: ChatAudioContent {
|
delegate: ChatAudioContent {
|
||||||
id: audioContent
|
id: audioContent
|
||||||
// Layout.fillWidth: true
|
// Layout.fillWidth: true
|
||||||
width: Math.round(269 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(269)
|
||||||
height: Math.round(48 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(48)
|
||||||
Layout.preferredHeight: height
|
Layout.preferredHeight: height
|
||||||
chatMessageContentGui: modelData
|
chatMessageContentGui: modelData
|
||||||
onEndOfFileReached: mainItem.endOfVoiceRecordingReached()
|
onEndOfFileReached: mainItem.endOfVoiceRecordingReached()
|
||||||
|
|
@ -73,7 +74,7 @@ ColumnLayout {
|
||||||
chatMessageGui: mainItem.chatMessageGui
|
chatMessageGui: mainItem.chatMessageGui
|
||||||
}
|
}
|
||||||
delegate: ChatMessageInvitationBubble {
|
delegate: ChatMessageInvitationBubble {
|
||||||
Layout.preferredWidth: 490 * DefaultStyle.dp
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(490)
|
||||||
conferenceInfoGui: modelData.core.conferenceInfo
|
conferenceInfoGui: modelData.core.conferenceInfo
|
||||||
onMouseEvent: (event) => mainItem.mouseEvent(event)
|
onMouseEvent: (event) => mainItem.mouseEvent(event)
|
||||||
}
|
}
|
||||||
|
|
@ -85,7 +86,7 @@ ColumnLayout {
|
||||||
contentGui: mainItem.filescontentProxy.count === 1
|
contentGui: mainItem.filescontentProxy.count === 1
|
||||||
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
||||||
: null
|
: null
|
||||||
width: Math.round(285 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(285)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
}
|
}
|
||||||
|
|
@ -95,7 +96,7 @@ ColumnLayout {
|
||||||
contentGui: mainItem.filescontentProxy.count === 1
|
contentGui: mainItem.filescontentProxy.count === 1
|
||||||
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
||||||
: null
|
: null
|
||||||
Layout.preferredWidth: Math.round(285 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(285)
|
||||||
Layout.preferredHeight: paintedHeight
|
Layout.preferredHeight: paintedHeight
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
|
|
@ -106,8 +107,8 @@ ColumnLayout {
|
||||||
contentGui: mainItem.filescontentProxy.count === 1
|
contentGui: mainItem.filescontentProxy.count === 1
|
||||||
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
? mainItem.filescontentProxy.getChatMessageContentAtIndex(0)
|
||||||
: null
|
: null
|
||||||
width: Math.round(285 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(285)
|
||||||
height: Math.round(285 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(285)
|
||||||
Layout.preferredWidth: videoOutput.contentRect.width
|
Layout.preferredWidth: videoOutput.contentRect.width
|
||||||
Layout.preferredHeight: videoOutput.contentRect.height
|
Layout.preferredHeight: videoOutput.contentRect.height
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
@ -123,7 +124,7 @@ ColumnLayout {
|
||||||
&& !singleVideoFile.visible
|
&& !singleVideoFile.visible
|
||||||
Layout.fillWidth: visible
|
Layout.fillWidth: visible
|
||||||
Layout.fillHeight: visible
|
Layout.fillHeight: visible
|
||||||
maxWidth: Math.round(115*3 * DefaultStyle.dp)
|
maxWidth: Utils.getSizeWithScreenRatio(115*3)
|
||||||
// Layout.fillHeight: true
|
// Layout.fillHeight: true
|
||||||
proxyModel: visible ? mainItem.filescontentProxy : null
|
proxyModel: visible ? mainItem.filescontentProxy : null
|
||||||
// onIsHoveringFileChanged: mainItem.isFileHoveringChanged(isHoveringFile)
|
// onIsHoveringFileChanged: mainItem.isFileHoveringChanged(isHoveringFile)
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ ColumnLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
||||||
id: mainItem
|
id: mainItem
|
||||||
width: 490 * DefaultStyle.dp
|
width: Utils.getSizeWithScreenRatio(490)
|
||||||
|
|
||||||
property ConferenceInfoGui conferenceInfoGui
|
property ConferenceInfoGui conferenceInfoGui
|
||||||
property var conferenceInfo: conferenceInfoGui?.core
|
property var conferenceInfo: conferenceInfoGui?.core
|
||||||
|
|
@ -43,16 +43,16 @@ ColumnLayout {
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: infoControl
|
id: infoControl
|
||||||
topPadding: Math.round(16 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
radius: 10 * DefaultStyle.dp // rounded all, but only top visible
|
radius: Utils.getSizeWithScreenRatio(10) // rounded all, but only top visible
|
||||||
}
|
}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -77,21 +77,21 @@ ColumnLayout {
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: dayRect
|
id: dayRect
|
||||||
Layout.alignment: Qt.AlignTop
|
Layout.alignment: Qt.AlignTop
|
||||||
topPadding: Math.round(4 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(4)
|
||||||
bottomPadding: Math.round(6 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(6)
|
||||||
leftPadding: Math.round(13 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
rightPadding: Math.round(13 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
|
|
||||||
background: Item {
|
background: Item {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: dayRectBg
|
id: dayRectBg
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: 10 * DefaultStyle.dp
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
}
|
}
|
||||||
MultiEffect {
|
MultiEffect {
|
||||||
|
|
@ -103,7 +103,7 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: 2 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -120,8 +120,8 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: 23 * DefaultStyle.dp
|
width: Utils.getSizeWithScreenRatio(23)
|
||||||
height: 23 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(23)
|
||||||
radius: width / 2
|
radius: width / 2
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
// anchors.horizontalCenter: parent.horizontalCenter
|
// anchors.horizontalCenter: parent.horizontalCenter
|
||||||
|
|
@ -138,14 +138,14 @@ ColumnLayout {
|
||||||
|
|
||||||
// Info
|
// Info
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: -2 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(-2)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: 8 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.videoconference
|
imageSource: AppIcons.videoconference
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -189,26 +189,26 @@ ColumnLayout {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
height: 10 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(10)
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
Layout.topMargin: -10 * DefaultStyle.dp
|
Layout.topMargin: Utils.getSizeWithScreenRatio(-10)
|
||||||
z: infoControl.z + 1
|
z: infoControl.z + 1
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
height: 10 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(10)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
Layout.bottomMargin: -10 * DefaultStyle.dp
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(-10)
|
||||||
z: infoControl.z + 1
|
z: infoControl.z + 1
|
||||||
}
|
}
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
visible: conferenceInfo.description.length > 0 || conferenceInfo.participantCount > 0
|
||||||
topPadding: Math.round(16 * DefaultStyle.dp) // only 6 because the rectangle linking the 2 controls is size 10
|
topPadding: Utils.getSizeWithScreenRatio(16) // only 6 because the rectangle linking the 2 controls is size 10
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
||||||
MouseArea {
|
MouseArea {
|
||||||
|
|
@ -221,11 +221,11 @@ ColumnLayout {
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: 10 * DefaultStyle.dp
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
}
|
}
|
||||||
|
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: 10 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
@ -263,13 +263,13 @@ ColumnLayout {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
visible: conferenceInfo.participantCount > 0
|
visible: conferenceInfo.participantCount > 0
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.preferredHeight: 30 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
spacing: 10 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.usersTwo
|
imageSource: AppIcons.usersTwo
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
//: %n participant(s)
|
//: %n participant(s)
|
||||||
|
|
|
||||||
|
|
@ -6,15 +6,16 @@ import Qt.labs.qmlmodels
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
spacing: Math.round(4 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(4)
|
||||||
property ChatGui chat
|
property ChatGui chat
|
||||||
property color backgroundColor
|
property color backgroundColor
|
||||||
property bool lastItemVisible: false
|
property bool lastItemVisible: false
|
||||||
property int lastIndexFoundWithFilter: -1
|
property int lastIndexFoundWithFilter: -1
|
||||||
property real busyIndicatorSize: Math.round(60 * DefaultStyle.dp)
|
property real busyIndicatorSize: Utils.getSizeWithScreenRatio(60)
|
||||||
property bool loading: false
|
property bool loading: false
|
||||||
property bool isEncrypted: chat && chat.core.isEncrypted
|
property bool isEncrypted: chat && chat.core.isEncrypted
|
||||||
|
|
||||||
|
|
@ -53,15 +54,15 @@ ListView {
|
||||||
Button {
|
Button {
|
||||||
visible: !mainItem.lastItemVisible
|
visible: !mainItem.lastItemVisible
|
||||||
icon.source: AppIcons.downArrow
|
icon.source: AppIcons.downArrow
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
topPadding: Math.round(16 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
style: ButtonStyle.main
|
style: ButtonStyle.main
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.bottomMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
anchors.rightMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
var index = eventLogProxy.findFirstUnreadIndex()
|
var index = eventLogProxy.findFirstUnreadIndex()
|
||||||
mainItem.positionViewAtIndex(index, ListView.Beginning)
|
mainItem.positionViewAtIndex(index, ListView.Beginning)
|
||||||
|
|
@ -129,32 +130,32 @@ ListView {
|
||||||
|
|
||||||
footer: Item {
|
footer: Item {
|
||||||
visible: mainItem.chat && !mainItem.loading
|
visible: mainItem.chat && !mainItem.loading
|
||||||
height: visible ? headerMessage.height + headerMessage.topMargin + headerMessage.bottomMargin : Math.round(30 * DefaultStyle.dp)
|
height: visible ? (headerMessage.height + headerMessage.topMargin + headerMessage.bottomMargin) : Utils.getSizeWithScreenRatio(30)
|
||||||
width: headerMessage.width
|
width: headerMessage.width
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: headerMessage
|
id: headerMessage
|
||||||
property int topMargin: mainItem.contentHeight > mainItem.height ? Math.round(30 * DefaultStyle.dp) : Math.round(50 * DefaultStyle.dp)
|
property int topMargin: Utils.getSizeWithScreenRatio(mainItem.contentHeight > mainItem.height ? 30 : 50)
|
||||||
property int bottomMargin: Math.round(30 * DefaultStyle.dp)
|
property int bottomMargin: Utils.getSizeWithScreenRatio(30)
|
||||||
anchors.topMargin: topMargin
|
anchors.topMargin: topMargin
|
||||||
anchors.bottomMargin: bottomMargin
|
anchors.bottomMargin: bottomMargin
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
padding: Math.round(10 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(10)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
border.color: DefaultStyle.main2_200
|
border.color: DefaultStyle.main2_200
|
||||||
border.width: Math.round(2 * DefaultStyle.dp)
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
Layout.preferredWidth: Math.round(23 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(23)
|
||||||
Layout.preferredHeight: Math.round(23 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(23)
|
||||||
imageSource: mainItem.isEncrypted ? AppIcons.lockSimple : AppIcons.lockSimpleOpen
|
imageSource: mainItem.isEncrypted ? AppIcons.lockSimple : AppIcons.lockSimpleOpen
|
||||||
colorizationColor: mainItem.isEncrypted ? DefaultStyle.info_500_main : DefaultStyle.warning_700
|
colorizationColor: mainItem.isEncrypted ? DefaultStyle.info_500_main : DefaultStyle.warning_700
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(2 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.isEncrypted
|
text: mainItem.isEncrypted
|
||||||
//: End to end encrypted chat
|
//: End to end encrypted chat
|
||||||
|
|
@ -192,8 +193,8 @@ ListView {
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
// height: visible ? contentItem.implicitHeight + topPadding + bottomPadding : 0
|
// height: visible ? contentItem.implicitHeight + topPadding + bottomPadding : 0
|
||||||
z: mainItem.z + 2
|
z: mainItem.z + 2
|
||||||
topPadding: Math.round(5 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
bottomPadding: Math.round(5 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: mainItem.backgroundColor
|
color: mainItem.backgroundColor
|
||||||
|
|
@ -202,8 +203,8 @@ ListView {
|
||||||
id: composeLayout
|
id: composeLayout
|
||||||
property var composingName: mainItem.chat?.core.composingName
|
property var composingName: mainItem.chat?.core.composingName
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
_address: mainItem.chat?.core.composingAddress
|
_address: mainItem.chat?.core.composingAddress
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -303,11 +304,11 @@ ListView {
|
||||||
}
|
}
|
||||||
property bool showTopMargin: !header.visible && index == 0
|
property bool showTopMargin: !header.visible && index == 0
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: (showTopMargin ? 30 * DefaultStyle.dp : 0) + eventItem.implicitHeight
|
height: (showTopMargin ? Utils.getSizeWithScreenRatio(30) : 0) + eventItem.implicitHeight
|
||||||
Event {
|
Event {
|
||||||
id: eventItem
|
id: eventItem
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: showTopMargin ? 30 : 0 * DefaultStyle.dp
|
anchors.topMargin: showTopMargin ? Utils.getSizeWithScreenRatio(30) : 0
|
||||||
width: parent.width
|
width: parent.width
|
||||||
eventLogGui: modelData
|
eventLogGui: modelData
|
||||||
}
|
}
|
||||||
|
|
@ -328,12 +329,12 @@ ListView {
|
||||||
}
|
}
|
||||||
property bool showTopMargin: !header.visible && index == 0
|
property bool showTopMargin: !header.visible && index == 0
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
//height: 40 * DefaultStyle.dp
|
//height: Utils.getSizeWithScreenRatio(40)
|
||||||
height: (showTopMargin ? 30 : 0 * DefaultStyle.dp) + ephemeralEventItem.height
|
height: (showTopMargin ? Utils.getSizeWithScreenRatio(30) : 0) + ephemeralEventItem.height
|
||||||
EphemeralEvent {
|
EphemeralEvent {
|
||||||
id: ephemeralEventItem
|
id: ephemeralEventItem
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: showTopMargin ? 30 : 0 * DefaultStyle.dp
|
anchors.topMargin: showTopMargin ? Utils.getSizeWithScreenRatio(30) : 0
|
||||||
eventLogGui: modelData
|
eventLogGui: modelData
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -64,23 +64,23 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: categoriesRow
|
id: categoriesRow
|
||||||
Layout.preferredWidth: parent.width - Math.round(15 * DefaultStyle.dp)
|
Layout.preferredWidth: parent.width - Utils.getSizeWithScreenRatio(15)
|
||||||
Layout.preferredHeight: Math.round(35 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(35)
|
||||||
Layout.leftMargin: Math.round(5 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
spacing: searchField.widthSize > 0 ? Math.round(7 * DefaultStyle.dp) : Math.round(17 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(searchField.widthSize > 0 ? 7 : 17)
|
||||||
clip: true
|
clip: true
|
||||||
Image {
|
Image {
|
||||||
id: searchIcon
|
id: searchIcon
|
||||||
source: "image://emoji/icons/search.svg"
|
source: "image://emoji/icons/search.svg"
|
||||||
sourceSize: Qt.size(Math.round(21 * DefaultStyle.dp), Math.round(21 * DefaultStyle.dp))
|
sourceSize: Qt.size(Utils.getSizeWithScreenRatio(21),Utils.getSizeWithScreenRatio(21))
|
||||||
visible: !mainItem.searchMode
|
visible: !mainItem.searchMode
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
onClicked: {
|
onClicked: {
|
||||||
mainItem.searchMode = true
|
mainItem.searchMode = true
|
||||||
searchField.widthSize = categoriesRow.width - Math.round(25 * DefaultStyle.dp)
|
searchField.widthSize = categoriesRow.width - Utils.getSizeWithScreenRatio(25)
|
||||||
list.model = 1
|
list.model = 1
|
||||||
searchField.focus = true
|
searchField.focus = true
|
||||||
}
|
}
|
||||||
|
|
@ -89,7 +89,7 @@ ColumnLayout {
|
||||||
Image {
|
Image {
|
||||||
id: closeIcon
|
id: closeIcon
|
||||||
source: "image://emoji/icons/close.svg"
|
source: "image://emoji/icons/close.svg"
|
||||||
sourceSize: Qt.size(Math.round(21 * DefaultStyle.dp), Math.round(21 * DefaultStyle.dp))
|
sourceSize: Qt.size(Utils.getSizeWithScreenRatio(21),Utils.getSizeWithScreenRatio(21))
|
||||||
visible: mainItem.searchMode
|
visible: mainItem.searchMode
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
@ -106,7 +106,7 @@ ColumnLayout {
|
||||||
id: searchField
|
id: searchField
|
||||||
property int widthSize: 0
|
property int widthSize: 0
|
||||||
Layout.preferredWidth: widthSize
|
Layout.preferredWidth: widthSize
|
||||||
Layout.preferredHeight: Math.round(28 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(28)
|
||||||
visible: widthSize > 0 ? true : false
|
visible: widthSize > 0 ? true : false
|
||||||
placeholderText: 'Search Emoji'
|
placeholderText: 'Search Emoji'
|
||||||
Behavior on widthSize {
|
Behavior on widthSize {
|
||||||
|
|
@ -115,7 +115,7 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
border.color: DefaultStyle.main1_500_main
|
border.color: DefaultStyle.main1_500_main
|
||||||
}
|
}
|
||||||
onTextChanged: {
|
onTextChanged: {
|
||||||
|
|
@ -134,7 +134,7 @@ ColumnLayout {
|
||||||
delegate: Image {
|
delegate: Image {
|
||||||
id: icon
|
id: icon
|
||||||
source: "image://emoji/icons/" + cateIcons.blackSvg[index]
|
source: "image://emoji/icons/" + cateIcons.blackSvg[index]
|
||||||
sourceSize: Qt.size(Math.round(20 * DefaultStyle.dp), Math.round(20 * DefaultStyle.dp))
|
sourceSize: Qt.size(Utils.getSizeWithScreenRatio(20),Utils.getSizeWithScreenRatio(20))
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
cursorShape: Qt.PointingHandCursor
|
cursorShape: Qt.PointingHandCursor
|
||||||
|
|
@ -156,46 +156,46 @@ ColumnLayout {
|
||||||
ListView {
|
ListView {
|
||||||
id: list
|
id: list
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: Math.round(250 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(250)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
model: mainItem.categories
|
model: mainItem.categories
|
||||||
spacing: Math.round(30 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(30)
|
||||||
topMargin: Math.round(7 * DefaultStyle.dp)
|
topMargin: Utils.getSizeWithScreenRatio(7)
|
||||||
bottomMargin: Math.round(7 * DefaultStyle.dp)
|
bottomMargin: Utils.getSizeWithScreenRatio(7)
|
||||||
leftMargin: Math.round(12 * DefaultStyle.dp)
|
leftMargin: Utils.getSizeWithScreenRatio(12)
|
||||||
clip: true
|
clip: true
|
||||||
delegate: GridLayout {
|
delegate: GridLayout {
|
||||||
id: grid
|
id: grid
|
||||||
property string category: mainItem.searchMode ? 'Search Result' : modelData
|
property string category: mainItem.searchMode ? 'Search Result' : modelData
|
||||||
property int columnCount: Math.round(list.width / 50 * DefaultStyle.dp)
|
property int columnCount: Math.round(list.width / Utils.getSizeWithScreenRatio(50))
|
||||||
property int sc: grid.category === 'People & Body' ? mainItem.skinColor : -1
|
property int sc: grid.category === 'People & Body' ? mainItem.skinColor : -1
|
||||||
columns: columnCount
|
columns: columnCount
|
||||||
width: list.width
|
width: list.width
|
||||||
columnSpacing: Math.round(5 * DefaultStyle.dp)
|
columnSpacing: Utils.getSizeWithScreenRatio(5)
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
text: grid.category
|
text: grid.category
|
||||||
color: Qt.rgba(0, 0, 0, 0.5)
|
color: Qt.rgba(0, 0, 0, 0.5)
|
||||||
font.pixelSize: Math.round(15 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(15)
|
||||||
horizontalAlignment: Text.AlignLeft
|
horizontalAlignment: Text.AlignLeft
|
||||||
leftPadding: Math.round(6 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(6)
|
||||||
Layout.columnSpan: grid.columnCount != 0 ? grid.columnCount : 1
|
Layout.columnSpan: grid.columnCount != 0 ? grid.columnCount : 1
|
||||||
Layout.bottomMargin: Math.round(8 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
}
|
}
|
||||||
Repeater {
|
Repeater {
|
||||||
model: mainItem.searchMode ? mainItem.searchModel : mainItem.model.count(grid.category)
|
model: mainItem.searchMode ? mainItem.searchModel : mainItem.model.count(grid.category)
|
||||||
delegate: Rectangle {
|
delegate: Rectangle {
|
||||||
property alias es: emojiSvg
|
property alias es: emojiSvg
|
||||||
Layout.preferredWidth: Math.round(40 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(40)
|
||||||
Layout.preferredHeight: Math.round(40 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(40)
|
||||||
radius: Math.round(40 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(40)
|
||||||
color: mouseArea.containsMouse ? '#e6e6e6' : '#ffffff'
|
color: mouseArea.containsMouse ? '#e6e6e6' : '#ffffff'
|
||||||
Image {
|
Image {
|
||||||
id: emojiSvg
|
id: emojiSvg
|
||||||
source: mainItem.searchMode ? path : mainItem.model.path(grid.category, index, grid.sc)
|
source: mainItem.searchMode ? path : mainItem.model.path(grid.category, index, grid.sc)
|
||||||
sourceSize: Qt.size(Math.round(30 * DefaultStyle.dp), Math.round(30 * DefaultStyle.dp))
|
sourceSize: Qt.size(Utils.getSizeWithScreenRatio(30),Utils.getSizeWithScreenRatio(30))
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
asynchronous: true
|
asynchronous: true
|
||||||
}
|
}
|
||||||
|
|
@ -224,7 +224,7 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.preferredHeight: Math.round(35 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(35)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
spacing: 10
|
spacing: 10
|
||||||
Repeater {
|
Repeater {
|
||||||
|
|
@ -234,10 +234,10 @@ ColumnLayout {
|
||||||
model: 6
|
model: 6
|
||||||
delegate: Rectangle {
|
delegate: Rectangle {
|
||||||
id: colorRect
|
id: colorRect
|
||||||
Layout.preferredWidth: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(30)
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
Layout.bottomMargin: Math.round(3 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(3)
|
||||||
radius: Math.round(30 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(30)
|
||||||
scale: 0.65
|
scale: 0.65
|
||||||
color: skinColors.colors[index]
|
color: skinColors.colors[index]
|
||||||
Behavior on scale {
|
Behavior on scale {
|
||||||
|
|
|
||||||
|
|
@ -2,24 +2,25 @@ import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
property EventLogGui eventLogGui
|
property EventLogGui eventLogGui
|
||||||
property var eventLogCore: eventLogGui.core
|
property var eventLogCore: eventLogGui.core
|
||||||
visible: eventLogCore.handled
|
visible: eventLogCore.handled
|
||||||
height: row.height + 15 * DefaultStyle.dp
|
height: row.height + Utils.getSizeWithScreenRatio(15)
|
||||||
width: row.width + 15 * DefaultStyle.dp
|
width: row.width + Utils.getSizeWithScreenRatio(15)
|
||||||
radius: 10 * DefaultStyle.dp
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
border.width: 2 * DefaultStyle.dp
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
border.color: DefaultStyle.main2_200
|
border.color: DefaultStyle.main2_200
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: row
|
id: row
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
EffectImage {
|
EffectImage {
|
||||||
Layout.preferredWidth: visible ? 20 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(20) : 0
|
||||||
Layout.preferredHeight: 20 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
colorizationColor: DefaultStyle.main2_400
|
colorizationColor: DefaultStyle.main2_400
|
||||||
imageSource: AppIcons.clockCountDown
|
imageSource: AppIcons.clockCountDown
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
|
|
|
||||||
|
|
@ -2,10 +2,11 @@ import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: mainLayout
|
id: mainLayout
|
||||||
height: 40 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(40)
|
||||||
visible: eventLogCore.handled
|
visible: eventLogCore.handled
|
||||||
property EventLogGui eventLogGui
|
property EventLogGui eventLogGui
|
||||||
property var eventLogCore: eventLogGui.core
|
property var eventLogCore: eventLogGui.core
|
||||||
|
|
@ -17,8 +18,8 @@ RowLayout {
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.rightMargin: 20 * DefaultStyle.dp
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.leftMargin: 20 * DefaultStyle.dp
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
|
|
|
||||||
|
|
@ -116,8 +116,8 @@ Item {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
visible: videoThumbnail.playbackState !== MediaPlayer.PlayingState
|
visible: videoThumbnail.playbackState !== MediaPlayer.PlayingState
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
imageSource: AppIcons.playFill
|
imageSource: AppIcons.playFill
|
||||||
colorizationColor: DefaultStyle.main2_0
|
colorizationColor: DefaultStyle.main2_0
|
||||||
}
|
}
|
||||||
|
|
@ -126,8 +126,8 @@ Item {
|
||||||
property int timeDisplayed: videoThumbnail.playbackState === MediaPlayer.PlayingState ? videoThumbnail.position : videoThumbnail.duration
|
property int timeDisplayed: videoThumbnail.playbackState === MediaPlayer.PlayingState ? videoThumbnail.position : videoThumbnail.duration
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.bottomMargin: Math.round(6 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(6)
|
||||||
anchors.leftMargin: Math.round(6 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(6)
|
||||||
text: UtilsCpp.formatDuration(timeDisplayed)
|
text: UtilsCpp.formatDuration(timeDisplayed)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
|
|
@ -156,10 +156,10 @@ Item {
|
||||||
Component {
|
Component {
|
||||||
id: defaultSquareView
|
id: defaultSquareView
|
||||||
Control.Control {
|
Control.Control {
|
||||||
leftPadding: Math.round(4 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(4)
|
||||||
rightPadding: Math.round(4 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(4)
|
||||||
topPadding: Math.round(23 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(23)
|
||||||
bottomPadding: Math.round(4 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(4)
|
||||||
hoverEnabled: false
|
hoverEnabled: false
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
|
|
@ -172,12 +172,12 @@ Item {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
height: Math.round(23 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(23)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
imageSource: mainItem.imageSource
|
imageSource: mainItem.imageSource
|
||||||
imageWidth: Math.round(14 * DefaultStyle.dp)
|
imageWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
imageHeight: Math.round(14 * DefaultStyle.dp)
|
imageHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -234,8 +234,8 @@ Item {
|
||||||
visible: thumbnailProvider.state === 'hovered' && mainItem.contentGui && (/*!mainItem.isOutgoing &&*/ !mainItem.contentGui.core.wasDownloaded)
|
visible: thumbnailProvider.state === 'hovered' && mainItem.contentGui && (/*!mainItem.isOutgoing &&*/ !mainItem.contentGui.core.wasDownloaded)
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
imageSource: AppIcons.download
|
imageSource: AppIcons.download
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -244,20 +244,20 @@ Item {
|
||||||
Component {
|
Component {
|
||||||
id: defaultView
|
id: defaultView
|
||||||
Control.Control {
|
Control.Control {
|
||||||
rightPadding: Math.round(17*DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(17)
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
id: bg
|
id: bg
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: mainItem.height
|
height: mainItem.height
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
width: Math.round(58 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(58)
|
||||||
height: bg.height
|
height: bg.height
|
||||||
radius: bg.radius
|
radius: bg.radius
|
||||||
Rectangle {
|
Rectangle {
|
||||||
|
|
@ -272,13 +272,13 @@ Item {
|
||||||
z: parent.z + 1
|
z: parent.z + 1
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
imageSource: defaultViewStack.imageSource
|
imageSource: defaultViewStack.imageSource
|
||||||
width: Math.round(22 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(22)
|
||||||
height: width
|
height: width
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(1 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(1)
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.name
|
text: mainItem.name
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
|
||||||
|
|
@ -40,8 +40,8 @@ Rectangle {
|
||||||
property int timeDisplayed: mediaPlayer.playbackState === MediaPlayer.PlayingState ? mediaPlayer.position : mediaPlayer.duration
|
property int timeDisplayed: mediaPlayer.playbackState === MediaPlayer.PlayingState ? mediaPlayer.position : mediaPlayer.duration
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.bottomMargin: Math.round(6 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(6)
|
||||||
anchors.leftMargin: Math.round(6 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(6)
|
||||||
text: UtilsCpp.formatDuration(timeDisplayed)
|
text: UtilsCpp.formatDuration(timeDisplayed)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
|
|
@ -64,8 +64,8 @@ Rectangle {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
visible: mediaPlayer.playbackState !== MediaPlayer.PlayingState
|
visible: mediaPlayer.playbackState !== MediaPlayer.PlayingState
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
imageSource: AppIcons.playFill
|
imageSource: AppIcons.playFill
|
||||||
colorizationColor: DefaultStyle.main2_0
|
colorizationColor: DefaultStyle.main2_0
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -46,10 +46,10 @@ Flickable {
|
||||||
property bool haveContacts: count > 0
|
property bool haveContacts: count > 0
|
||||||
property real sectionsPixelSize: Typography.h4.pixelSize
|
property real sectionsPixelSize: Typography.h4.pixelSize
|
||||||
property real sectionsWeight: Typography.h4.weight
|
property real sectionsWeight: Typography.h4.weight
|
||||||
property real sectionsSpacing: Math.round(18 * DefaultStyle.dp)
|
property real sectionsSpacing: Utils.getSizeWithScreenRatio(18)
|
||||||
property real busyIndicatorSize: Math.round(60 * DefaultStyle.dp)
|
property real busyIndicatorSize: Utils.getSizeWithScreenRatio(60)
|
||||||
|
|
||||||
property real itemsRightMargin: Math.round(39 * DefaultStyle.dp)
|
property real itemsRightMargin: Utils.getSizeWithScreenRatio(39)
|
||||||
property int count: contactsList.count + suggestionsList.count + favoritesList.count
|
property int count: contactsList.count + suggestionsList.count + favoritesList.count
|
||||||
|
|
||||||
contentHeight: contentsLayout.height
|
contentHeight: contentsLayout.height
|
||||||
|
|
@ -233,7 +233,7 @@ Flickable {
|
||||||
Control.ScrollBar.vertical: ScrollBar {
|
Control.ScrollBar.vertical: ScrollBar {
|
||||||
id: scrollbar
|
id: scrollbar
|
||||||
z: 1
|
z: 1
|
||||||
topPadding: Math.round(24 * DefaultStyle.dp) // Avoid to be on top of collapse button
|
topPadding: Utils.getSizeWithScreenRatio(24) // Avoid to be on top of collapse button
|
||||||
active: true
|
active: true
|
||||||
interactive: true
|
interactive: true
|
||||||
visible: mainItem.contentHeight > mainItem.height
|
visible: mainItem.contentHeight > mainItem.height
|
||||||
|
|
@ -243,7 +243,7 @@ Flickable {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: contentsLayout
|
id: contentsLayout
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
spacing: 0 //Math.round(20 * DefaultStyle.dp)
|
spacing: 0
|
||||||
|
|
||||||
BusyIndicator {
|
BusyIndicator {
|
||||||
id: busyIndicator
|
id: busyIndicator
|
||||||
|
|
@ -307,7 +307,7 @@ Flickable {
|
||||||
visible: contentHeight > 0
|
visible: contentHeight > 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: implicitHeight
|
Layout.preferredHeight: implicitHeight
|
||||||
Layout.topMargin: favoritesList.height > 0 ? Math.round(4 * DefaultStyle.dp) : 0
|
Layout.topMargin: favoritesList.height > 0 ? Utils.getSizeWithScreenRatio(4) : 0
|
||||||
interactive: false
|
interactive: false
|
||||||
highlightText: mainItem.highlightText
|
highlightText: mainItem.highlightText
|
||||||
showActions: mainItem.showActions
|
showActions: mainItem.showActions
|
||||||
|
|
@ -345,11 +345,9 @@ Flickable {
|
||||||
| (mainItem.searchText != '*'
|
| (mainItem.searchText != '*'
|
||||||
&& mainItem.searchText != ''
|
&& mainItem.searchText != ''
|
||||||
|| SettingsCpp.syncLdapContacts ? MagicSearchProxy.FilteringTypes.Ldap | MagicSearchProxy.FilteringTypes.CardDAV : 0)
|
|| SettingsCpp.syncLdapContacts ? MagicSearchProxy.FilteringTypes.Ldap | MagicSearchProxy.FilteringTypes.CardDAV : 0)
|
||||||
initialDisplayItems: Math.max(
|
initialDisplayItems: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(63)))
|
||||||
20,
|
|
||||||
2 * mainItem.height / (Math.round(63 * DefaultStyle.dp)))
|
|
||||||
displayItemsStep: 3 * initialDisplayItems / 2
|
displayItemsStep: 3 * initialDisplayItems / 2
|
||||||
onLocalFriendCreated: index => {
|
onLocalFriendCreated: (index) => {
|
||||||
contactsList.selectIndex(index)
|
contactsList.selectIndex(index)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -359,8 +357,7 @@ Flickable {
|
||||||
visible: contentHeight > 0
|
visible: contentHeight > 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: implicitHeight
|
Layout.preferredHeight: implicitHeight
|
||||||
Layout.topMargin: contactsList.height + favoritesList.height
|
Layout.topMargin: (contactsList.height + favoritesList.height) > 0 ? Utils.getSizeWithScreenRatio(4) : 0
|
||||||
> 0 ? Math.round(4 * DefaultStyle.dp) : 0
|
|
||||||
interactive: false
|
interactive: false
|
||||||
showInitials: false
|
showInitials: false
|
||||||
highlightText: mainItem.highlightText
|
highlightText: mainItem.highlightText
|
||||||
|
|
@ -395,11 +392,9 @@ Flickable {
|
||||||
id: suggestionsProxy
|
id: suggestionsProxy
|
||||||
parentProxy: mainItem.mainModel
|
parentProxy: mainItem.mainModel
|
||||||
filterType: mainItem.hideSuggestions ? MagicSearchProxy.FilteringTypes.None : MagicSearchProxy.FilteringTypes.Other
|
filterType: mainItem.hideSuggestions ? MagicSearchProxy.FilteringTypes.None : MagicSearchProxy.FilteringTypes.Other
|
||||||
initialDisplayItems: contactsProxy.haveMore
|
initialDisplayItems: contactsProxy.haveMore && contactsList.expanded
|
||||||
&& contactsList.expanded ? 0 : Math.max(
|
? 0
|
||||||
20,
|
: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(63)))
|
||||||
2 * mainItem.height
|
|
||||||
/ (Math.round(63 * DefaultStyle.dp)))
|
|
||||||
onInitialDisplayItemsChanged: maxDisplayItems = initialDisplayItems
|
onInitialDisplayItemsChanged: maxDisplayItems = initialDisplayItems
|
||||||
displayItemsStep: 3 * initialDisplayItems / 2
|
displayItemsStep: 3 * initialDisplayItems / 2
|
||||||
onModelReset: maxDisplayItems = initialDisplayItems
|
onModelReset: maxDisplayItems = initialDisplayItems
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// Fill contact, account or call
|
// Fill contact, account or call
|
||||||
// Initials will be displayed if there isn't any avatar.
|
// Initials will be displayed if there isn't any avatar.
|
||||||
|
|
@ -93,7 +94,7 @@ Loader{
|
||||||
z: 1
|
z: 1
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
border {
|
border {
|
||||||
width: Math.round(2 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(2)
|
||||||
color: mainItem.secured ? DefaultStyle.info_500_main : DefaultStyle.danger_500_main
|
color: mainItem.secured ? DefaultStyle.info_500_main : DefaultStyle.danger_500_main
|
||||||
}
|
}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
|
|
|
||||||
|
|
@ -120,8 +120,8 @@ Control.Control{
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
minimumPixelSize: 5
|
minimumPixelSize: 5
|
||||||
fontSizeMode: Text.Fit
|
fontSizeMode: Text.Fit
|
||||||
font.pixelSize: Math.round(11 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(11)
|
||||||
font.weight: Math.round(700 * DefaultStyle.dp)
|
font.weight: Utils.getSizeWithScreenRatio(700)
|
||||||
text: mainItem.account.core.unreadNotifications >= 100 ? '99+' : mainItem.account.core.unreadNotifications
|
text: mainItem.account.core.unreadNotifications >= 100 ? '99+' : mainItem.account.core.unreadNotifications
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -7,10 +7,11 @@ import UtilsCpp 1.0
|
||||||
import ConstantsCpp
|
import ConstantsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope {
|
FocusScope {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
implicitHeight: visible ? Math.round(56 * DefaultStyle.dp) : 0
|
implicitHeight: visible ? Utils.getSizeWithScreenRatio(56) : 0
|
||||||
property var searchResultItem
|
property var searchResultItem
|
||||||
property bool showInitials: true // Display Initials of Display name.
|
property bool showInitials: true // Display Initials of Display name.
|
||||||
property bool showDefaultAddress: true // Display address below display name.
|
property bool showDefaultAddress: true // Display address below display name.
|
||||||
|
|
@ -32,7 +33,7 @@ FocusScope {
|
||||||
|
|
||||||
property var previousInitial
|
property var previousInitial
|
||||||
// Use directly previous initial
|
// Use directly previous initial
|
||||||
property real itemsRightMargin: Math.round(39 * DefaultStyle.dp)
|
property real itemsRightMargin: Utils.getSizeWithScreenRatio(39)
|
||||||
|
|
||||||
property var displayName: searchResultItem? searchResultItem.core.fullName : ""
|
property var displayName: searchResultItem? searchResultItem.core.fullName : ""
|
||||||
property var initial: displayName != "" ? displayName[0].toLocaleLowerCase(ConstantsCpp.DefaultLocale) : ''
|
property var initial: displayName != "" ? displayName[0].toLocaleLowerCase(ConstantsCpp.DefaultLocale) : ''
|
||||||
|
|
@ -48,15 +49,15 @@ FocusScope {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
visible: mainItem.showInitials
|
visible: mainItem.showInitials
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.rightMargin: Math.round(15 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
width: Math.round(20 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(20)
|
||||||
opacity: previousInitial != mainItem.initial ? 1 : 0
|
opacity: previousInitial != mainItem.initial ? 1 : 0
|
||||||
text: mainItem.initial || ""
|
text: mainItem.initial || ""
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
capitalization: Font.AllUppercase
|
capitalization: Font.AllUppercase
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -67,12 +68,12 @@ FocusScope {
|
||||||
anchors.rightMargin: mainItem.itemsRightMargin
|
anchors.rightMargin: mainItem.itemsRightMargin
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
z: contactArea.z + 1
|
z: contactArea.z + 1
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.leftMargin: Math.round(5 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
contact: searchResultItem
|
contact: searchResultItem
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
}
|
}
|
||||||
|
|
@ -93,7 +94,7 @@ FocusScope {
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
Layout.topMargin: Math.round(2 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(2)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: visible ? implicitHeight: 0
|
Layout.preferredHeight: visible ? implicitHeight: 0
|
||||||
visible: mainItem.showDefaultAddress
|
visible: mainItem.showDefaultAddress
|
||||||
|
|
@ -104,8 +105,8 @@ FocusScope {
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
font {
|
font {
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -116,31 +117,31 @@ FocusScope {
|
||||||
id: actionsRow
|
id: actionsRow
|
||||||
z: contactArea.z + 1
|
z: contactArea.z + 1
|
||||||
visible: mainItem.showActions || actionButtons.visible || mainItem.showContactMenu || mainItem.multiSelectionEnabled
|
visible: mainItem.showActions || actionButtons.visible || mainItem.showContactMenu || mainItem.multiSelectionEnabled
|
||||||
spacing: visible ? Math.round(16 * DefaultStyle.dp) : 0
|
spacing: visible ? Utils.getSizeWithScreenRatio(16) : 0
|
||||||
enabled: visible
|
enabled: visible
|
||||||
Layout.rightMargin: Math.round(5 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
id: isSelectedCheck
|
id: isSelectedCheck
|
||||||
visible: mainItem.multiSelectionEnabled
|
visible: mainItem.multiSelectionEnabled
|
||||||
&& (mainItem.selectedContacts.indexOf(mainItem.addressFromFilter) != -1)
|
&& (mainItem.selectedContacts.indexOf(mainItem.addressFromFilter) != -1)
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
imageSource: AppIcons.check
|
imageSource: AppIcons.check
|
||||||
colorizationColor: DefaultStyle.main1_500_main
|
colorizationColor: DefaultStyle.main1_500_main
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: actionButtons
|
id: actionButtons
|
||||||
visible: mainItem.showActions
|
visible: mainItem.showActions
|
||||||
spacing: visible ? Math.round(10 * DefaultStyle.dp) : 0
|
spacing: visible ? Utils.getSizeWithScreenRatio(10) : 0
|
||||||
IconButton {
|
IconButton {
|
||||||
id: callButton
|
id: callButton
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.source: AppIcons.phone
|
icon.source: AppIcons.phone
|
||||||
focus: visible
|
focus: visible
|
||||||
radius: Math.round(40 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(40)
|
||||||
style: ButtonStyle.grey
|
style: ButtonStyle.grey
|
||||||
onClicked: UtilsCpp.createCall(mainItem.addressFromFilter)
|
onClicked: UtilsCpp.createCall(mainItem.addressFromFilter)
|
||||||
KeyNavigation.left: chatButton
|
KeyNavigation.left: chatButton
|
||||||
|
|
@ -149,13 +150,13 @@ FocusScope {
|
||||||
IconButton {
|
IconButton {
|
||||||
id: videoCallButton
|
id: videoCallButton
|
||||||
visible: SettingsCpp.videoEnabled
|
visible: SettingsCpp.videoEnabled
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.source: AppIcons.videoCamera
|
icon.source: AppIcons.videoCamera
|
||||||
focus: visible && !callButton.visible
|
focus: visible && !callButton.visible
|
||||||
radius: Math.round(40 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(40)
|
||||||
style: ButtonStyle.grey
|
style: ButtonStyle.grey
|
||||||
onClicked: UtilsCpp.createCall(mainItem.addressFromFilter, {"localVideoEnabled": true})
|
onClicked: UtilsCpp.createCall(mainItem.addressFromFilter, {"localVideoEnabled": true})
|
||||||
KeyNavigation.left: callButton
|
KeyNavigation.left: callButton
|
||||||
|
|
@ -165,14 +166,14 @@ FocusScope {
|
||||||
id: chatButton
|
id: chatButton
|
||||||
visible: actionButtons.visible
|
visible: actionButtons.visible
|
||||||
&& !SettingsCpp.disableChatFeature
|
&& !SettingsCpp.disableChatFeature
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.source: AppIcons.chatTeardropText
|
icon.source: AppIcons.chatTeardropText
|
||||||
focus: visible && !callButton.visible
|
focus: visible && !callButton.visible
|
||||||
&& !videoCallButton.visible
|
&& !videoCallButton.visible
|
||||||
radius: Math.round(40 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(40)
|
||||||
style: ButtonStyle.grey
|
style: ButtonStyle.grey
|
||||||
KeyNavigation.left: videoCallButton
|
KeyNavigation.left: videoCallButton
|
||||||
KeyNavigation.right: callButton
|
KeyNavigation.right: callButton
|
||||||
|
|
@ -186,7 +187,7 @@ FocusScope {
|
||||||
id: friendPopup
|
id: friendPopup
|
||||||
z: contactArea.z + 1
|
z: contactArea.z + 1
|
||||||
popup.x: 0
|
popup.x: 0
|
||||||
popup.padding: Math.round(10 * DefaultStyle.dp)
|
popup.padding: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: mainItem.showContactMenu && (contactArea.containsMouse || mainItem.isLastHovered || hovered || popup.opened)
|
visible: mainItem.showContactMenu && (contactArea.containsMouse || mainItem.isLastHovered || hovered || popup.opened)
|
||||||
enabled: visible
|
enabled: visible
|
||||||
|
|
||||||
|
|
@ -200,7 +201,7 @@ FocusScope {
|
||||||
//: "Ajouter aux favoris"
|
//: "Ajouter aux favoris"
|
||||||
: qsTr("contact_details_add_to_favourites")
|
: qsTr("contact_details_add_to_favourites")
|
||||||
icon.source: searchResultItem.core.starred ? AppIcons.heartFill : AppIcons.heart
|
icon.source: searchResultItem.core.starred ? AppIcons.heartFill : AppIcons.heart
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
textColor: DefaultStyle.main2_500_main
|
textColor: DefaultStyle.main2_500_main
|
||||||
hoveredImageColor: searchResultItem.core.starred ? DefaultStyle.main1_700 : DefaultStyle.danger_700
|
hoveredImageColor: searchResultItem.core.starred ? DefaultStyle.main1_700 : DefaultStyle.danger_700
|
||||||
contentImageColor: searchResultItem.core.starred ? DefaultStyle.danger_500_main : DefaultStyle.main2_600
|
contentImageColor: searchResultItem.core.starred ? DefaultStyle.danger_500_main : DefaultStyle.main2_600
|
||||||
|
|
@ -215,7 +216,7 @@ FocusScope {
|
||||||
text: qsTr("Partager")
|
text: qsTr("Partager")
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
icon.source: AppIcons.shareNetwork
|
icon.source: AppIcons.shareNetwork
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
textColor: DefaultStyle.main2_500_main
|
textColor: DefaultStyle.main2_500_main
|
||||||
onClicked: {
|
onClicked: {
|
||||||
var vcard = searchResultItem.core.getVCard()
|
var vcard = searchResultItem.core.getVCard()
|
||||||
|
|
@ -243,7 +244,7 @@ FocusScope {
|
||||||
//: "Supprimer"
|
//: "Supprimer"
|
||||||
text: qsTr("contact_details_delete")
|
text: qsTr("contact_details_delete")
|
||||||
icon.source: AppIcons.trashCan
|
icon.source: AppIcons.trashCan
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: searchResultItem && searchResultItem.core.isStored && !searchResultItem.core.readOnly
|
visible: searchResultItem && searchResultItem.core.isStored && !searchResultItem.core.readOnly
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -269,7 +270,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.fill: contactArea
|
anchors.fill: contactArea
|
||||||
radius: Math.round(8 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(8)
|
||||||
opacity: 0.7
|
opacity: 0.7
|
||||||
color: mainItem.isSelected ? DefaultStyle.main2_200 : DefaultStyle.main2_100
|
color: mainItem.isSelected ? DefaultStyle.main2_200 : DefaultStyle.main2_100
|
||||||
visible: mainItem.isLastHovered || mainItem.isSelected || friendPopup.hovered
|
visible: mainItem.isLastHovered || mainItem.isSelected || friendPopup.hovered
|
||||||
|
|
|
||||||
|
|
@ -63,18 +63,18 @@ PopupButton {
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.rightMargin: 8 * DefaultStyle.dp
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
popup.contentItem: Rectangle {
|
popup.contentItem: Rectangle {
|
||||||
implicitWidth: Utils.getSizeWithScreenRatio(280)
|
implicitWidth: Utils.getSizeWithScreenRatio(280)
|
||||||
implicitHeight: 20 * DefaultStyle.dp + (setCustomStatus.visible ? 240 * DefaultStyle.dp : setPresence.implicitHeight)
|
implicitHeight: Utils.getSizeWithScreenRatio(20) + (setCustomStatus.visible ? Utils.getSizeWithScreenRatio(240) : setPresence.implicitHeight)
|
||||||
Presence {
|
Presence {
|
||||||
id: setPresence
|
id: setPresence
|
||||||
visible: !presenceAndRegistrationItem.editCustomStatus
|
visible: !presenceAndRegistrationItem.editCustomStatus
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: 20 * DefaultStyle.dp
|
anchors.margins: Utils.getSizeWithScreenRatio(20)
|
||||||
accountCore: mainItem.account.core
|
accountCore: mainItem.account.core
|
||||||
onSetCustomStatusClicked: {
|
onSetCustomStatusClicked: {
|
||||||
presenceAndRegistrationItem.editCustomStatus = true
|
presenceAndRegistrationItem.editCustomStatus = true
|
||||||
|
|
@ -85,7 +85,7 @@ PopupButton {
|
||||||
id: setCustomStatus
|
id: setCustomStatus
|
||||||
visible: presenceAndRegistrationItem.editCustomStatus
|
visible: presenceAndRegistrationItem.editCustomStatus
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: 20 * DefaultStyle.dp
|
anchors.margins: Utils.getSizeWithScreenRatio(20)
|
||||||
accountCore: mainItem.account.core
|
accountCore: mainItem.account.core
|
||||||
onVisibleChanged: {
|
onVisibleChanged: {
|
||||||
if (!visible) {
|
if (!visible) {
|
||||||
|
|
|
||||||
|
|
@ -4,10 +4,11 @@ import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Column {
|
Column {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
spacing: 20 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
property var accountCore
|
property var accountCore
|
||||||
signal isSet
|
signal isSet
|
||||||
|
|
@ -21,15 +22,15 @@ Column {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: 150 * DefaultStyle.dp
|
height: Utils.getSizeWithScreenRatio(150)
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
border.color: DefaultStyle.main1_500_main
|
border.color: DefaultStyle.main1_500_main
|
||||||
border.width: 1 * DefaultStyle.dp
|
border.width: Utils.getSizeWithScreenRatio(1)
|
||||||
radius: 8 * DefaultStyle.dp
|
radius: Utils.getSizeWithScreenRatio(8)
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: 10 * DefaultStyle.dp
|
anchors.margins: Utils.getSizeWithScreenRatio(10)
|
||||||
TextEdit {
|
TextEdit {
|
||||||
id: statusMessage
|
id: statusMessage
|
||||||
wrapMode: TextEdit.Wrap
|
wrapMode: TextEdit.Wrap
|
||||||
|
|
@ -62,7 +63,7 @@ Column {
|
||||||
}
|
}
|
||||||
|
|
||||||
Row {
|
Row {
|
||||||
spacing: 10 * DefaultStyle.dp
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
|
||||||
SmallButton {
|
SmallButton {
|
||||||
|
|
|
||||||
|
|
@ -5,13 +5,14 @@ import QtQuick.Controls.Basic
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Rectangle{
|
Rectangle{
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property int voicemailCount: 0
|
property int voicemailCount: 0
|
||||||
property bool showMwi: false
|
property bool showMwi: false
|
||||||
width: Math.round(42 * DefaultStyle.dp) * scaleFactor
|
width: Utils.getSizeWithScreenRatio(42 * scaleFactor)
|
||||||
height: Math.round(36 * DefaultStyle.dp) * scaleFactor
|
height: Utils.getSizeWithScreenRatio(36 * scaleFactor)
|
||||||
property real scaleFactor: 1.0
|
property real scaleFactor: 1.0
|
||||||
signal clicked()
|
signal clicked()
|
||||||
color: 'transparent'
|
color: 'transparent'
|
||||||
|
|
@ -20,7 +21,7 @@ Rectangle{
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
icon.source: AppIcons.voicemail
|
icon.source: AppIcons.voicemail
|
||||||
icon.color: DefaultStyle.main2_600
|
icon.color: DefaultStyle.main2_600
|
||||||
width: Math.round(33 * DefaultStyle.dp) * scaleFactor
|
width: Utils.getSizeWithScreenRatio(33 * scaleFactor)
|
||||||
height: width
|
height: width
|
||||||
icon.width: width
|
icon.width: width
|
||||||
icon.height: width
|
icon.height: width
|
||||||
|
|
@ -35,7 +36,7 @@ Rectangle{
|
||||||
Text {
|
Text {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
width: Math.round(14 * DefaultStyle.dp) * scaleFactor
|
width: Utils.getSizeWithScreenRatio(14 * scaleFactor)
|
||||||
height: width
|
height: width
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
font.weight: Typography.p2.weight
|
font.weight: Typography.p2.weight
|
||||||
|
|
@ -51,12 +52,12 @@ Rectangle{
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
color: DefaultStyle.danger_500_main
|
color: DefaultStyle.danger_500_main
|
||||||
visible: showMwi && voicemailCount == 0
|
visible: showMwi && voicemailCount == 0
|
||||||
width: Math.round(14 * DefaultStyle.dp) * scaleFactor
|
width: Utils.getSizeWithScreenRatio(14 * scaleFactor)
|
||||||
height: width
|
height: width
|
||||||
radius: width / 2
|
radius: width / 2
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Math.round(1.5 * DefaultStyle.dp) * scaleFactor
|
anchors.margins: Utils.getSizeWithScreenRatio(1.5 * scaleFactor)
|
||||||
imageSource: AppIcons.bell
|
imageSource: AppIcons.bell
|
||||||
colorizationColor: DefaultStyle.grey_0
|
colorizationColor: DefaultStyle.grey_0
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,9 +1,10 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Item {
|
Item {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property real borderWidth: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
property real borderWidth: Utils.getSizeWithScreenRatio(1)
|
||||||
property alias borderGradient: border.gradient
|
property alias borderGradient: border.gradient
|
||||||
property alias gradient: fill.gradient
|
property alias gradient: fill.gradient
|
||||||
property alias color: fill.color
|
property alias color: fill.color
|
||||||
|
|
|
||||||
|
|
@ -9,6 +9,7 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
|
|
@ -74,7 +75,7 @@ ProgressBar {
|
||||||
GradientStop { position: 0.0; color: "#FF9E79" }
|
GradientStop { position: 0.0; color: "#FF9E79" }
|
||||||
GradientStop { position: 1.0; color: "#FE5E00" }
|
GradientStop { position: 1.0; color: "#FE5E00" }
|
||||||
}
|
}
|
||||||
radius: Math.round(70 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(70)
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: mask
|
id: mask
|
||||||
|
|
@ -115,10 +116,10 @@ ProgressBar {
|
||||||
RoundButton {
|
RoundButton {
|
||||||
z: parent.z + 1
|
z: parent.z + 1
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
icon.width: Math.round(14 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(14)
|
||||||
icon.height: Math.round(14 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(14)
|
||||||
icon.source: animationTest.running
|
icon.source: animationTest.running
|
||||||
? mainItem.recording
|
? mainItem.recording
|
||||||
? AppIcons.stopFill
|
? AppIcons.stopFill
|
||||||
|
|
@ -131,25 +132,25 @@ ProgressBar {
|
||||||
}
|
}
|
||||||
Control.Control {
|
Control.Control {
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
leftPadding: Math.round(18 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
rightPadding: Math.round(18 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
topPadding: Math.round(5 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
bottomPadding: Math.round(5 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: Math.round(50 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(50)
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: mainItem.recording ? Math.round(5 * DefaultStyle.dp) : 0
|
spacing: mainItem.recording ? Utils.getSizeWithScreenRatio(5) : 0
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: mainItem.recording
|
visible: mainItem.recording
|
||||||
colorizationColor: DefaultStyle.danger_500_main
|
colorizationColor: DefaultStyle.danger_500_main
|
||||||
imageSource: AppIcons.recordFill
|
imageSource: AppIcons.recordFill
|
||||||
Layout.preferredWidth: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.preferredHeight: Math.round(14 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
id: durationText
|
id: durationText
|
||||||
|
|
|
||||||
|
|
@ -18,12 +18,12 @@ ListView {
|
||||||
property ConferenceInfoGui selectedConference
|
property ConferenceInfoGui selectedConference
|
||||||
property bool _moveToIndex: false
|
property bool _moveToIndex: false
|
||||||
property bool loading: false
|
property bool loading: false
|
||||||
property real busyIndicatorSize: Math.round(60 * DefaultStyle.dp)
|
property real busyIndicatorSize: Utils.getSizeWithScreenRatio(60)
|
||||||
|
|
||||||
clip: true
|
clip: true
|
||||||
cacheBuffer: height/2
|
cacheBuffer: height/2
|
||||||
|
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
highlightFollowsCurrentItem: false
|
highlightFollowsCurrentItem: false
|
||||||
|
|
||||||
signal meetingDeletionRequested(ConferenceInfoGui confInfo, bool canCancel)
|
signal meetingDeletionRequested(ConferenceInfoGui confInfo, bool canCancel)
|
||||||
|
|
@ -93,13 +93,13 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Let some space for better UI
|
// Let some space for better UI
|
||||||
footer: Item{height: Math.round(38 * DefaultStyle.dp)}
|
footer: Item{height: Utils.getSizeWithScreenRatio(38)}
|
||||||
|
|
||||||
model: ConferenceInfoProxy {
|
model: ConferenceInfoProxy {
|
||||||
id: confInfoProxy
|
id: confInfoProxy
|
||||||
filterText: searchBarText
|
filterText: searchBarText
|
||||||
filterType: ConferenceInfoProxy.None
|
filterType: ConferenceInfoProxy.None
|
||||||
initialDisplayItems: Math.max(20, 2 * mainItem.height / (Math.round(63 * DefaultStyle.dp)))
|
initialDisplayItems: Math.max(20, Math.round(2 * mainItem.height / Utils.getSizeWithScreenRatio(63)))
|
||||||
displayItemsStep: initialDisplayItems/2
|
displayItemsStep: initialDisplayItems/2
|
||||||
Component.onCompleted: {
|
Component.onCompleted: {
|
||||||
mainItem.loading = !confInfoProxy.accountConnected
|
mainItem.loading = !confInfoProxy.accountConnected
|
||||||
|
|
@ -137,7 +137,7 @@ ListView {
|
||||||
|
|
||||||
ScrollBar.vertical: ScrollBar {
|
ScrollBar.vertical: ScrollBar {
|
||||||
id: scrollbar
|
id: scrollbar
|
||||||
rightPadding: Math.round(8 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(8)
|
||||||
|
|
||||||
active: true
|
active: true
|
||||||
interactive: true
|
interactive: true
|
||||||
|
|
@ -147,14 +147,14 @@ ListView {
|
||||||
section {
|
section {
|
||||||
criteria: ViewSection.FullString
|
criteria: ViewSection.FullString
|
||||||
delegate: Text {
|
delegate: Text {
|
||||||
topPadding: Math.round(24 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(24)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
text: section
|
text: section
|
||||||
height: Math.round(29 * DefaultStyle.dp) + topPadding + bottomPadding
|
height: Utils.getSizeWithScreenRatio(29) + topPadding + bottomPadding
|
||||||
wrapMode: Text.NoWrap
|
wrapMode: Text.NoWrap
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Math.round(800 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(800)
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -164,7 +164,7 @@ ListView {
|
||||||
delegate: FocusScope {
|
delegate: FocusScope {
|
||||||
id: itemDelegate
|
id: itemDelegate
|
||||||
visible: !mainItem.loading
|
visible: !mainItem.loading
|
||||||
height: Math.round(63 * DefaultStyle.dp) + (!isFirst && dateDay.visible ? topOffset : 0)
|
height: Utils.getSizeWithScreenRatio(63) + (!isFirst && dateDay.visible ? topOffset : 0)
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
enabled: haveModel
|
enabled: haveModel
|
||||||
|
|
||||||
|
|
@ -176,7 +176,7 @@ ListView {
|
||||||
property string dateString: UtilsCpp.toDateString(dateTime)
|
property string dateString: UtilsCpp.toDateString(dateTime)
|
||||||
property string previousDateString: previousConfInfoGui ? UtilsCpp.toDateString(previousConfInfoGui.core ? previousConfInfoGui.core.dateTime : UtilsCpp.getCurrentDateTime()) : ''
|
property string previousDateString: previousConfInfoGui ? UtilsCpp.toDateString(previousConfInfoGui.core ? previousConfInfoGui.core.dateTime : UtilsCpp.getCurrentDateTime()) : ''
|
||||||
property bool isFirst : ListView.previousSection !== ListView.section
|
property bool isFirst : ListView.previousSection !== ListView.section
|
||||||
property real topOffset: (dateDay.visible && !isFirst? Math.round(8 * DefaultStyle.dp) : 0)
|
property real topOffset: (dateDay.visible && !isFirst) ? Utils.getSizeWithScreenRatio(8) : 0
|
||||||
property var endDateTime: itemGui.core ? itemGui.core.endDateTime : UtilsCpp.getCurrentDateTime()
|
property var endDateTime: itemGui.core ? itemGui.core.endDateTime : UtilsCpp.getCurrentDateTime()
|
||||||
property bool haveModel: itemGui.core ? itemGui.core.haveModel : false
|
property bool haveModel: itemGui.core ? itemGui.core.haveModel : false
|
||||||
property bool isCanceled: itemGui.core ? itemGui.core.state === LinphoneEnums.ConferenceInfoState.Cancelled : false
|
property bool isCanceled: itemGui.core ? itemGui.core.state === LinphoneEnums.ConferenceInfoState.Cancelled : false
|
||||||
|
|
@ -188,19 +188,19 @@ ListView {
|
||||||
anchors.topMargin: !itemDelegate.isFirst && dateDay.visible ? itemDelegate.topOffset : 0
|
anchors.topMargin: !itemDelegate.isFirst && dateDay.visible ? itemDelegate.topOffset : 0
|
||||||
spacing: 0
|
spacing: 0
|
||||||
Item{
|
Item{
|
||||||
Layout.preferredWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
visible: !dateDay.visible
|
visible: !dateDay.visible
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: dateDay
|
id: dateDay
|
||||||
Layout.fillWidth: false
|
Layout.fillWidth: false
|
||||||
Layout.preferredWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.minimumWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.minimumWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.preferredHeight: Math.round(51 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(51)
|
||||||
visible: previousDateString.length == 0 || previousDateString != dateString
|
visible: previousDateString.length == 0 || previousDateString != dateString
|
||||||
spacing: 0
|
spacing: 0
|
||||||
Text {
|
Text {
|
||||||
Layout.preferredHeight: Math.round(19 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(19)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
text: day.substring(0,3) + '.'
|
text: day.substring(0,3) + '.'
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
|
|
@ -214,8 +214,8 @@ ListView {
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: dayNum
|
id: dayNum
|
||||||
Layout.preferredWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.preferredHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
radius: height/2
|
radius: height/2
|
||||||
property var isCurrentDay: UtilsCpp.isCurrentDay(dateTime)
|
property var isCurrentDay: UtilsCpp.isCurrentDay(dateTime)
|
||||||
|
|
@ -230,40 +230,40 @@ ListView {
|
||||||
color: dayNum.isCurrentDay ? DefaultStyle.grey_0 : DefaultStyle.main2_500_main
|
color: dayNum.isCurrentDay ? DefaultStyle.grey_0 : DefaultStyle.main2_500_main
|
||||||
wrapMode: Text.NoWrap
|
wrapMode: Text.NoWrap
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Math.round(800 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(800)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item{Layout.fillHeight:true;Layout.fillWidth: true}
|
Item{Layout.fillHeight:true;Layout.fillWidth: true}
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
Layout.preferredWidth: Math.round(265 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(265)
|
||||||
Layout.preferredHeight: Math.round(63 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(63)
|
||||||
Layout.leftMargin: Math.round(23 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(23)
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: conferenceInfoDelegate
|
id: conferenceInfoDelegate
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.rightMargin: 5 // margin to avoid clipping shadows at right
|
anchors.rightMargin: 5 // margin to avoid clipping shadows at right
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
visible: itemDelegate.haveModel || itemDelegate.activeFocus
|
visible: itemDelegate.haveModel || itemDelegate.activeFocus
|
||||||
color: itemDelegate.isSelected ? DefaultStyle.main2_200 : DefaultStyle.grey_0 // mainItem.currentIndex === index
|
color: itemDelegate.isSelected ? DefaultStyle.main2_200 : DefaultStyle.grey_0 // mainItem.currentIndex === index
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Math.round(16 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.rightMargin: Math.round(16 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.topMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
spacing: Math.round(2 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
visible: itemDelegate.haveModel
|
visible: itemDelegate.haveModel
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.usersThree
|
imageSource: AppIcons.usersThree
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: itemGui.core? itemGui.core.subject : ""
|
text: itemGui.core? itemGui.core.subject : ""
|
||||||
|
|
@ -296,14 +296,14 @@ ListView {
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.rightMargin: Math.round(5 * DefaultStyle.dp) // margin to avoid clipping shadows at right
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(5) // margin to avoid clipping shadows at right
|
||||||
anchors.leftMargin: Math.round(16 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
visible: !itemDelegate.haveModel
|
visible: !itemDelegate.haveModel
|
||||||
//: "Aucune réunion aujourd'hui"
|
//: "Aucune réunion aujourd'hui"
|
||||||
text: qsTr("meetings_list_no_meeting_for_today")
|
text: qsTr("meetings_list_no_meeting_for_today")
|
||||||
lineHeightMode: Text.FixedHeight
|
lineHeightMode: Text.FixedHeight
|
||||||
lineHeight: Math.round(18 * DefaultStyle.dp)
|
lineHeight: Utils.getSizeWithScreenRatio(18)
|
||||||
font {
|
font {
|
||||||
pixelSize: Typography.p2.pixelSize
|
pixelSize: Typography.p2.pixelSize
|
||||||
weight: Typography.p2.weight
|
weight: Typography.p2.weight
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,8 @@ import QtQuick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -10,8 +11,8 @@ ListView {
|
||||||
height: contentHeight
|
height: contentHeight
|
||||||
visible: contentHeight > 0
|
visible: contentHeight > 0
|
||||||
clip: true
|
clip: true
|
||||||
rightMargin: Math.round(5 * DefaultStyle.dp)
|
rightMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
|
|
||||||
property string searchBarText
|
property string searchBarText
|
||||||
|
|
||||||
|
|
@ -31,28 +32,28 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: participantDelegate
|
id: participantDelegate
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.leftMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
z: 1
|
z: 1
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
_address: modelData.core.address
|
_address: modelData.core.address
|
||||||
secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
secured: securityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: modelData.core.displayName
|
text: modelData.core.displayName
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
|
||||||
|
|
@ -3,11 +3,12 @@ import QtQuick.Layouts
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
clip: true
|
clip: true
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
|
|
||||||
property bool hoverEnabled: true
|
property bool hoverEnabled: true
|
||||||
property bool displayNameCapitalization: true
|
property bool displayNameCapitalization: true
|
||||||
|
|
@ -26,22 +27,22 @@ ListView {
|
||||||
|
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
id: participantDelegate
|
id: participantDelegate
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
width: mainItem.width//mainItem.width
|
width: mainItem.width//mainItem.width
|
||||||
RowLayout {
|
RowLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
anchors.rightMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
_address: modelData.core.sipAddress
|
_address: modelData.core.sipAddress
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: modelData.core.displayName
|
text: modelData.core.displayName
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
|
||||||
|
|
@ -3,15 +3,16 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
|
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
visible: contentHeight > 0
|
visible: contentHeight > 0
|
||||||
clip: true
|
clip: true
|
||||||
rightMargin: Math.round(5 * DefaultStyle.dp)
|
rightMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
|
|
||||||
property string searchBarText
|
property string searchBarText
|
||||||
|
|
||||||
|
|
@ -43,25 +44,25 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: participantDelegate
|
id: participantDelegate
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.rightMargin: (scrollbar.width + 5 * DefaultStyle.dp)
|
anchors.rightMargin: (scrollbar.width + Utils.getSizeWithScreenRatio(5))
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
z: 1
|
z: 1
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
_address: modelData.core.sipAddress
|
_address: modelData.core.sipAddress
|
||||||
secured: friendSecurityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
secured: friendSecurityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: modelData.core.displayName
|
text: modelData.core.displayName
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
font.capitalization: mainItem.displayNameCapitalization ? Font.Capitalize : Font.MixedCase
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -71,9 +72,9 @@ ListView {
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
property bool isMe: modelData.core.isMe
|
property bool isMe: modelData.core.isMe
|
||||||
onIsMeChanged: if (isMe) mainItem.me = modelData
|
onIsMeChanged: if (isMe) mainItem.me = modelData
|
||||||
spacing: Math.round(26 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(26)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Text {
|
Text {
|
||||||
visible: mainItem.isMeAdmin || modelData.core.isAdmin
|
visible: mainItem.isMeAdmin || modelData.core.isAdmin
|
||||||
Layout.alignment: Qt.AlignRight
|
Layout.alignment: Qt.AlignRight
|
||||||
|
|
@ -81,8 +82,8 @@ ListView {
|
||||||
text: qsTr("meeting_participant_is_admin_label")
|
text: qsTr("meeting_participant_is_admin_label")
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Switch {
|
Switch {
|
||||||
|
|
@ -94,13 +95,13 @@ ListView {
|
||||||
}
|
}
|
||||||
SmallButton {
|
SmallButton {
|
||||||
opacity: mainItem.isMeAdmin && !modelData.core.isMe ? 1 : 0
|
opacity: mainItem.isMeAdmin && !modelData.core.isMe ? 1 : 0
|
||||||
Layout.preferredWidth: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
color: DefaultStyle.main2_100
|
color: DefaultStyle.main2_100
|
||||||
leftPadding: Math.round(3 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(3)
|
||||||
rightPadding: Math.round(3 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(3)
|
||||||
topPadding: Math.round(3 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(3)
|
||||||
bottomPadding: Math.round(3 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(3)
|
||||||
style: ButtonStyle.hoveredBackground
|
style: ButtonStyle.hoveredBackground
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
onClicked: participantModel.removeParticipant(modelData.core)
|
onClicked: participantModel.removeParticipant(modelData.core)
|
||||||
|
|
|
||||||
|
|
@ -1,11 +1,12 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.ProgressBar {
|
Control.ProgressBar {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
||||||
padding: Math.round(3 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(3)
|
||||||
|
|
||||||
property color backgroundColor: DefaultStyle.main2_100
|
property color backgroundColor: DefaultStyle.main2_100
|
||||||
property color innerColor: DefaultStyle.info_500_main
|
property color innerColor: DefaultStyle.info_500_main
|
||||||
|
|
@ -19,15 +20,15 @@ Control.ProgressBar {
|
||||||
id: textSize
|
id: textSize
|
||||||
text: mainItem.innerText
|
text: mainItem.innerText
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(10 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(10)
|
||||||
weight: Math.round(700 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(700)
|
||||||
bold: true
|
bold: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
color: mainItem.backgroundColor
|
color: mainItem.backgroundColor
|
||||||
radius: Math.round(50 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(50)
|
||||||
anchors.fill: mainItem
|
anchors.fill: mainItem
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: mainItem.height
|
height: mainItem.height
|
||||||
|
|
@ -37,7 +38,7 @@ Control.ProgressBar {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: bar
|
id: bar
|
||||||
color: mainItem.innerColor
|
color: mainItem.innerColor
|
||||||
radius: Math.round(50 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(50)
|
||||||
width: mainItem.barWidth
|
width: mainItem.barWidth
|
||||||
height: parent.height
|
height: parent.height
|
||||||
}
|
}
|
||||||
|
|
@ -51,8 +52,8 @@ Control.ProgressBar {
|
||||||
color: mainItem.innerTextColor
|
color: mainItem.innerTextColor
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(10 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(10)
|
||||||
weight: Math.round(700 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(700)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ import QtQuick
|
||||||
import QtQuick.Controls
|
import QtQuick.Controls
|
||||||
import QtQuick.Shapes
|
import QtQuick.Shapes
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ProgressBar{
|
ProgressBar{
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -22,9 +22,9 @@ ProgressBar{
|
||||||
Shape {
|
Shape {
|
||||||
id: shape
|
id: shape
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Math.round(2 * DefaultStyle.dp)
|
anchors.margins: Utils.getSizeWithScreenRatio(2)
|
||||||
|
|
||||||
property real progressionRadius : Math.min(shape.width / 2, shape.height / 2) - Math.round(3 * DefaultStyle.dp) / 2
|
property real progressionRadius : Math.round(Math.min(shape.width / 2, shape.height / 2) - Utils.getSizeWithScreenRatio(3) / 2)
|
||||||
|
|
||||||
layer.enabled: true
|
layer.enabled: true
|
||||||
layer.samples: 8
|
layer.samples: 8
|
||||||
|
|
@ -35,14 +35,14 @@ ProgressBar{
|
||||||
id: pathDial
|
id: pathDial
|
||||||
strokeColor: DefaultStyle.main1_100
|
strokeColor: DefaultStyle.main1_100
|
||||||
fillColor: 'transparent'
|
fillColor: 'transparent'
|
||||||
strokeWidth: Math.round(3 * DefaultStyle.dp)
|
strokeWidth: Utils.getSizeWithScreenRatio(3)
|
||||||
capStyle: Qt.RoundCap
|
capStyle: Qt.RoundCap
|
||||||
|
|
||||||
PathAngleArc {
|
PathAngleArc {
|
||||||
radiusX: shape.progressionRadius
|
radiusX: shape.progressionRadius
|
||||||
radiusY: shape.progressionRadius
|
radiusY: shape.progressionRadius
|
||||||
centerX: shape.width / 2
|
centerX: Math.round(shape.width / 2)
|
||||||
centerY: shape.height / 2
|
centerY: Math.round(shape.height / 2)
|
||||||
startAngle: -90 // top start
|
startAngle: -90 // top start
|
||||||
sweepAngle: 360
|
sweepAngle: 360
|
||||||
}
|
}
|
||||||
|
|
@ -52,14 +52,14 @@ ProgressBar{
|
||||||
id: pathProgress
|
id: pathProgress
|
||||||
strokeColor: DefaultStyle.main1_500_main
|
strokeColor: DefaultStyle.main1_500_main
|
||||||
fillColor: 'transparent'
|
fillColor: 'transparent'
|
||||||
strokeWidth: Math.round(3 * DefaultStyle.dp)
|
strokeWidth: Utils.getSizeWithScreenRatio(3)
|
||||||
capStyle: Qt.RoundCap
|
capStyle: Qt.RoundCap
|
||||||
|
|
||||||
PathAngleArc {
|
PathAngleArc {
|
||||||
radiusX: shape.progressionRadius
|
radiusX: shape.progressionRadius
|
||||||
radiusY: shape.progressionRadius
|
radiusY: shape.progressionRadius
|
||||||
centerX: shape.width / 2
|
centerX: Math.round(shape.width / 2)
|
||||||
centerY: shape.height / 2
|
centerY: Math.round(shape.height / 2)
|
||||||
startAngle: -90 // top start
|
startAngle: -90 // top start
|
||||||
sweepAngle: (360/ mainItem.to * mainItem.value)
|
sweepAngle: (360/ mainItem.to * mainItem.value)
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,15 +1,16 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
// width: Math.round(360 * DefaultStyle.dp)
|
// width: Utils.getSizeWithScreenRatio(360)
|
||||||
property color backgroundColor: DefaultStyle.grey_0
|
property color backgroundColor: DefaultStyle.grey_0
|
||||||
padding: Math.round(10 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(10)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
color: mainItem.backgroundColor
|
color: mainItem.backgroundColor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// Display a sticker from a call or from an account.
|
// Display a sticker from a call or from an account.
|
||||||
// The Avatar is shown while the camera become available.
|
// The Avatar is shown while the camera become available.
|
||||||
|
|
@ -25,7 +26,7 @@ Item {
|
||||||
property bool displayBorder : participantDevice && participantDevice.core.isSpeaking || false
|
property bool displayBorder : participantDevice && participantDevice.core.isSpeaking || false
|
||||||
property alias displayPresence: avatar.displayPresence
|
property alias displayPresence: avatar.displayPresence
|
||||||
property color color: DefaultStyle.grey_600
|
property color color: DefaultStyle.grey_600
|
||||||
property real radius: Math.round(15 * DefaultStyle.dp)
|
property real radius: Utils.getSizeWithScreenRatio(15)
|
||||||
property bool remoteIsPaused: participantDevice
|
property bool remoteIsPaused: participantDevice
|
||||||
? participantDevice.core.isPaused
|
? participantDevice.core.isPaused
|
||||||
: previewEnabled
|
: previewEnabled
|
||||||
|
|
@ -74,7 +75,7 @@ Item {
|
||||||
radius: mainItem.radius
|
radius: mainItem.radius
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
border.color: DefaultStyle.main2_200
|
border.color: DefaultStyle.main2_200
|
||||||
border.width: mainItem.displayBorder ? Math.round(3 * DefaultStyle.dp) : 0
|
border.width: mainItem.displayBorder ? Utils.getSizeWithScreenRatio(3) : 0
|
||||||
property real minSize: Math.min(height, width)
|
property real minSize: Math.min(height, width)
|
||||||
Item {
|
Item {
|
||||||
id: noCameraLayout
|
id: noCameraLayout
|
||||||
|
|
@ -82,7 +83,7 @@ Item {
|
||||||
visible: !cameraLoader.active || cameraLoader.status != Loader.Ready || !cameraLoader.item.isReady
|
visible: !cameraLoader.active || cameraLoader.status != Loader.Ready || !cameraLoader.item.isReady
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Math.round(81 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(81)
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
// Layout.alignment: Qt.AlignHCenter |Qt.AlignTop
|
// Layout.alignment: Qt.AlignHCenter |Qt.AlignTop
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
@ -94,8 +95,8 @@ Item {
|
||||||
BusyIndicator {
|
BusyIndicator {
|
||||||
indicatorColor: DefaultStyle.main2_100
|
indicatorColor: DefaultStyle.main2_100
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
indicatorHeight: Math.round(42 * DefaultStyle.dp)
|
indicatorHeight: Utils.getSizeWithScreenRatio(42)
|
||||||
indicatorWidth: Math.round(42 * DefaultStyle.dp)
|
indicatorWidth: Utils.getSizeWithScreenRatio(42)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item{
|
Item{
|
||||||
|
|
@ -104,7 +105,7 @@ Item {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
height: mainItem.conference
|
height: mainItem.conference
|
||||||
? background.minSize * 142 / 372
|
? background.minSize * 142 / 372
|
||||||
: Math.round(120 * DefaultStyle.dp)
|
: Utils.getSizeWithScreenRatio(120)
|
||||||
width: height
|
width: height
|
||||||
Avatar{
|
Avatar{
|
||||||
id: avatar
|
id: avatar
|
||||||
|
|
@ -122,30 +123,30 @@ Item {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
visible: mainItem.participantDevice && (mainItem.participantDevice.core.state == LinphoneEnums.ParticipantDeviceState.Joining || mainItem.participantDevice.core.state == LinphoneEnums.ParticipantDeviceState.Alerting) || false
|
visible: mainItem.participantDevice && (mainItem.participantDevice.core.state == LinphoneEnums.ParticipantDeviceState.Joining || mainItem.participantDevice.core.state == LinphoneEnums.ParticipantDeviceState.Alerting) || false
|
||||||
BusyIndicator {
|
BusyIndicator {
|
||||||
Layout.preferredHeight: Math.round(42 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(42)
|
||||||
indicatorColor: DefaultStyle.main2_100
|
indicatorColor: DefaultStyle.main2_100
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
indicatorHeight: Math.round(42 * DefaultStyle.dp)
|
indicatorHeight: Utils.getSizeWithScreenRatio(42)
|
||||||
indicatorWidth: Math.round(42 * DefaultStyle.dp)
|
indicatorWidth: Utils.getSizeWithScreenRatio(42)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
Layout.preferredHeight: Math.round(27 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(27)
|
||||||
Layout.topMargin: Math.round(15 * DefaultStyle.dp) // (84-27)-42
|
Layout.topMargin: Utils.getSizeWithScreenRatio(15) // (84-27)-42
|
||||||
//: "rejoint…"
|
//: "rejoint…"
|
||||||
text: qsTr("conference_participant_joining_text")
|
text: qsTr("conference_participant_joining_text")
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
visible: mainItem.remoteIsPaused
|
visible: mainItem.remoteIsPaused
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.pause
|
imageSource: AppIcons.pause
|
||||||
|
|
@ -160,8 +161,8 @@ Item {
|
||||||
//: "En pause"
|
//: "En pause"
|
||||||
text: qsTr("conference_participant_paused_text")
|
text: qsTr("conference_participant_paused_text")
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -169,7 +170,7 @@ Item {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
visible: mainItem.displayAll && !mainItem.remoteIsPaused && !mainItem.conference
|
visible: mainItem.displayAll && !mainItem.remoteIsPaused && !mainItem.conference
|
||||||
anchors.top: centerItem.bottom
|
anchors.top: centerItem.bottom
|
||||||
anchors.topMargin: Math.round(21 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(21)
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
|
|
||||||
|
|
@ -179,8 +180,8 @@ Item {
|
||||||
text: mainItem.displayName
|
text: mainItem.displayName
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(22 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(22)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -191,8 +192,8 @@ Item {
|
||||||
text: SettingsCpp.hideSipAddresses ? UtilsCpp.getUsername(_text) : _text
|
text: SettingsCpp.hideSipAddresses ? UtilsCpp.getUsername(_text) : _text
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(14 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -255,9 +256,9 @@ Item {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.leftMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.rightMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
width: implicitWidth
|
width: implicitWidth
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
property string _text: mainItem.displayName != ''
|
property string _text: mainItem.displayName != ''
|
||||||
|
|
@ -268,8 +269,8 @@ Item {
|
||||||
text: SettingsCpp.hideSipAddresses ? UtilsCpp.getUsername(_text) : _text
|
text: SettingsCpp.hideSipAddresses ? UtilsCpp.getUsername(_text) : _text
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(14 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -286,22 +287,22 @@ Item {
|
||||||
RowLayout{
|
RowLayout{
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.rightMargin: Math.round(8 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
anchors.topMargin: Math.round(8 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
|
|
||||||
height: Math.round(18 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(18)
|
||||||
spacing: 0
|
spacing: 0
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: muteIcon
|
id: muteIcon
|
||||||
Layout.preferredWidth: Math.min(mainItem.width / 16, Math.round(20 * DefaultStyle.dp))
|
Layout.preferredWidth: Math.min(Math.round(mainItem.width / 16), Utils.getSizeWithScreenRatio(20))
|
||||||
Layout.preferredHeight: Math.min(mainItem.width / 16, Math.round(20 * DefaultStyle.dp))
|
Layout.preferredHeight: Math.min(Math.round(mainItem.width / 16), Utils.getSizeWithScreenRatio(20))
|
||||||
visible: mainItem.mutedStatus
|
visible: mainItem.mutedStatus
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: width /2
|
radius: width /2
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
imageWidth: Math.min(mainItem.width / 16, Math.round(20 * DefaultStyle.dp))
|
imageWidth: Math.min(Math.round(mainItem.width / 16),Utils.getSizeWithScreenRatio(20))
|
||||||
imageHeight: Math.min(mainItem.width / 16, Math.round(20 * DefaultStyle.dp))
|
imageHeight: Math.min(Math.round(mainItem.width / 16),Utils.getSizeWithScreenRatio(20))
|
||||||
imageSource: AppIcons.microphoneSlash
|
imageSource: AppIcons.microphoneSlash
|
||||||
colorizationColor: DefaultStyle.main2_500_main
|
colorizationColor: DefaultStyle.main2_500_main
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
import QtQuick as Quick
|
import QtQuick as Quick
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Quick.Text {
|
Quick.Text {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -8,7 +9,7 @@ Quick.Text {
|
||||||
width: txtMeter.advanceWidth
|
width: txtMeter.advanceWidth
|
||||||
font {
|
font {
|
||||||
family: DefaultStyle.defaultFont
|
family: DefaultStyle.defaultFont
|
||||||
pixelSize: Math.round(10 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(10)
|
||||||
weight: Typography.p1.weight
|
weight: Typography.p1.weight
|
||||||
}
|
}
|
||||||
color: DefaultStyle.main2_600
|
color: DefaultStyle.main2_600
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.ToolTip {
|
Control.ToolTip {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -10,7 +11,7 @@ Control.ToolTip {
|
||||||
id: tooltipBackground
|
id: tooltipBackground
|
||||||
opacity: 0.7
|
opacity: 0.7
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
}
|
}
|
||||||
contentItem: Text {
|
contentItem: Text {
|
||||||
text: mainItem.text
|
text: mainItem.text
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import SettingsCpp 1.0
|
import SettingsCpp 1.0
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope {
|
FocusScope {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -12,11 +13,11 @@ FocusScope {
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.topMargin: Math.round(16 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.bottomMargin: Math.round(16 * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.leftMargin: Math.round(17 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(17)
|
||||||
anchors.rightMargin: Math.round(17 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(17)
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
|
|
||||||
RoundedPane {
|
RoundedPane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -32,9 +33,9 @@ FocusScope {
|
||||||
id: radiobutton
|
id: radiobutton
|
||||||
checkOnClick: false
|
checkOnClick: false
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
indicatorSize: Math.round(20 * DefaultStyle.dp)
|
indicatorSize: Utils.getSizeWithScreenRatio(20)
|
||||||
leftPadding: indicator.width + spacing
|
leftPadding: indicator.width + spacing
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
checkable: false // Qt Documentation is wrong: It is true by default. We don't want to change the checked state if the layout change is not effective.
|
checkable: false // Qt Documentation is wrong: It is true by default. We don't want to change the checked state if the layout change is not effective.
|
||||||
checked: index == 0
|
checked: index == 0
|
||||||
? mainItem.conferenceLayout === LinphoneEnums.ConferenceLayout.Grid
|
? mainItem.conferenceLayout === LinphoneEnums.ConferenceLayout.Grid
|
||||||
|
|
@ -44,11 +45,11 @@ FocusScope {
|
||||||
onClicked: mainItem.changeLayoutRequested(index)
|
onClicked: mainItem.changeLayoutRequested(index)
|
||||||
|
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
id: radioButtonImg
|
id: radioButtonImg
|
||||||
Layout.preferredWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.preferredHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
imageSource: modelData.imgUrl
|
imageSource: modelData.imgUrl
|
||||||
colorizationColor: DefaultStyle.main2_500_main
|
colorizationColor: DefaultStyle.main2_500_main
|
||||||
}
|
}
|
||||||
|
|
@ -56,7 +57,7 @@ FocusScope {
|
||||||
text: modelData.text
|
text: modelData.text
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -86,7 +86,7 @@ ColumnLayout {
|
||||||
implicitHeight: parent.height
|
implicitHeight: parent.height
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
indicatorColor: DefaultStyle.grey_0
|
indicatorColor: DefaultStyle.grey_0
|
||||||
indicatorWidth: Math.round(25 * DefaultStyle.dp)
|
indicatorWidth: Utils.getSizeWithScreenRatio(25)
|
||||||
}
|
}
|
||||||
Connections {
|
Connections {
|
||||||
target: LoginPageCpp
|
target: LoginPageCpp
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import SettingsCpp 1.0
|
import SettingsCpp 1.0
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -11,32 +12,32 @@ ColumnLayout {
|
||||||
property var call
|
property var call
|
||||||
RoundedPane {
|
RoundedPane {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
rightPadding: Math.round(16 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
topPadding: Math.round(13 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
bottomPadding: Math.round(13 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
Text {
|
Text {
|
||||||
//: "Encryption :"
|
//: "Encryption :"
|
||||||
text: qsTr("call_stats_media_encryption_title")
|
text: qsTr("call_stats_media_encryption_title")
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Typography.p2.weight
|
weight: Typography.p2.weight
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
spacing: Math.round(7 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(7)
|
||||||
Text {
|
Text {
|
||||||
property bool isPostQuantum: mainItem.call.core.encryption === LinphoneEnums.MediaEncryption.Zrtp && mainItem.call.core.zrtpStats.isPostQuantum
|
property bool isPostQuantum: mainItem.call.core.encryption === LinphoneEnums.MediaEncryption.Zrtp && mainItem.call.core.zrtpStats.isPostQuantum
|
||||||
//: Media encryption : %1
|
//: Media encryption : %1
|
||||||
text: qsTr("call_stats_media_encryption").arg(mainItem.call.core.encryptionString)
|
text: qsTr("call_stats_media_encryption").arg(mainItem.call.core.encryptionString)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
|
@ -46,8 +47,8 @@ ColumnLayout {
|
||||||
text: qsTr("call_stats_zrtp_cipher_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.cipherAlgo)
|
text: qsTr("call_stats_zrtp_cipher_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.cipherAlgo)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -55,8 +56,8 @@ ColumnLayout {
|
||||||
text: qsTr("call_stats_zrtp_key_agreement_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.keyAgreementAlgo)
|
text: qsTr("call_stats_zrtp_key_agreement_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.keyAgreementAlgo)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -64,8 +65,8 @@ ColumnLayout {
|
||||||
text: qsTr("call_stats_zrtp_hash_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.hashAlgo)
|
text: qsTr("call_stats_zrtp_hash_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.hashAlgo)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -73,8 +74,8 @@ ColumnLayout {
|
||||||
text: qsTr("call_stats_zrtp_auth_tag_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.authenticationAlgo)
|
text: qsTr("call_stats_zrtp_auth_tag_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.authenticationAlgo)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -82,8 +83,8 @@ ColumnLayout {
|
||||||
text: qsTr("call_stats_zrtp_sas_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.sasAlgo)
|
text: qsTr("call_stats_zrtp_sas_algo").arg(mainItem.call && mainItem.call.core.zrtpStats.sasAlgo)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -97,9 +98,9 @@ ColumnLayout {
|
||||||
//: "Validation chiffrement"
|
//: "Validation chiffrement"
|
||||||
text: qsTr("call_zrtp_validation_button_label")
|
text: qsTr("call_zrtp_validation_button_label")
|
||||||
onClicked: mainItem.encryptionValidationRequested()
|
onClicked: mainItem.encryptionValidationRequested()
|
||||||
Layout.bottomMargin: Math.round(13 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(13)
|
||||||
Layout.leftMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.rightMargin: Math.round(16 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(16)
|
||||||
style: ButtonStyle.main
|
style: ButtonStyle.main
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp 1.0
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -14,21 +15,21 @@ ColumnLayout {
|
||||||
property bool isLocalScreenSharing : conference?.core.isLocalScreenSharing || false
|
property bool isLocalScreenSharing : conference?.core.isLocalScreenSharing || false
|
||||||
property bool screenSharingAvailable: !!conference && (!conference.core.isScreenSharingEnabled || isLocalScreenSharing)
|
property bool screenSharingAvailable: !!conference && (!conference.core.isScreenSharingEnabled || isLocalScreenSharing)
|
||||||
|
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
|
|
||||||
onIsLocalScreenSharingChanged: {if(isLocalScreenSharing) mainItem.call.core.videoSourceDescriptor = mainItem.desc }
|
onIsLocalScreenSharingChanged: {if(isLocalScreenSharing) mainItem.call.core.videoSourceDescriptor = mainItem.desc }
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
//: "Veuillez choisir l’écran ou la fenêtre que vous souihaitez partager au autres participants"
|
//: "Veuillez choisir l’écran ou la fenêtre que vous souihaitez partager au autres participants"
|
||||||
text: qsTr("screencast_settings_choose_window_text")
|
text: qsTr("screencast_settings_choose_window_text")
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
}
|
}
|
||||||
TabBar {
|
TabBar {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
id: bar
|
id: bar
|
||||||
spacing: Math.round(40 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(40)
|
||||||
pixelSize: Math.round(16 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(16)
|
||||||
//: "Ecran entier"
|
//: "Ecran entier"
|
||||||
model: [qsTr("screencast_settings_all_screen_label"),
|
model: [qsTr("screencast_settings_all_screen_label"),
|
||||||
//: "Fenêtre"
|
//: "Fenêtre"
|
||||||
|
|
@ -42,18 +43,18 @@ ColumnLayout {
|
||||||
property bool selected: false
|
property bool selected: false
|
||||||
property bool displayScreen: true
|
property bool displayScreen: true
|
||||||
property real horizontalMargin: 0
|
property real horizontalMargin: 0
|
||||||
leftPadding: Math.round(18 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
rightPadding: Math.round(18 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
topPadding: Math.round(13 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
bottomPadding: Math.round(13 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(13)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: screenPreview.horizontalMargin
|
anchors.leftMargin: screenPreview.horizontalMargin
|
||||||
anchors.rightMargin: screenPreview.horizontalMargin
|
anchors.rightMargin: screenPreview.horizontalMargin
|
||||||
color: screenPreview.selected ? DefaultStyle.main2_100 : DefaultStyle.grey_0
|
color: screenPreview.selected ? DefaultStyle.main2_100 : DefaultStyle.grey_0
|
||||||
border.width: Math.round(2 * DefaultStyle.dp)
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
border.color: screenPreview.selected ? DefaultStyle.main2_400 : DefaultStyle.main2_200
|
border.color: screenPreview.selected ? DefaultStyle.main2_400 : DefaultStyle.main2_200
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -68,7 +69,7 @@ ColumnLayout {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Image {
|
Image {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
//Layout.preferredHeight: Math.round(170 * DefaultStyle.dp)
|
//Layout.preferredHeight: Utils.getSizeWithScreenRatio(170)
|
||||||
source: $modelData?.windowId ? "image://window/"+ $modelData.windowId : "image://screen/"+ $modelData.screenIndex
|
source: $modelData?.windowId ? "image://window/"+ $modelData.windowId : "image://screen/"+ $modelData.screenIndex
|
||||||
sourceSize.width: parent.width
|
sourceSize.width: parent.width
|
||||||
sourceSize.height: parent.height
|
sourceSize.height: parent.height
|
||||||
|
|
@ -76,11 +77,11 @@ ColumnLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout{
|
RowLayout{
|
||||||
Layout.topMargin: Math.round(6 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(6)
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
Image{
|
Image{
|
||||||
Layout.preferredHeight: Math.round(15 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(15)
|
||||||
Layout.preferredWidth: Math.round(15 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(15)
|
||||||
visible: !!$modelData?.windowId
|
visible: !!$modelData?.windowId
|
||||||
source: visible ? "image://window_icon/"+ $modelData.windowId : ''
|
source: visible ? "image://window_icon/"+ $modelData.windowId : ''
|
||||||
sourceSize.width: width
|
sourceSize.width: width
|
||||||
|
|
@ -92,7 +93,7 @@ ColumnLayout {
|
||||||
//: "Ecran %1"
|
//: "Ecran %1"
|
||||||
text: !!$modelData?.windowId ? $modelData.name : qsTr("screencast_settings_screen").arg(screenIndex+1)
|
text: !!$modelData?.windowId ? $modelData.name : qsTr("screencast_settings_screen").arg(screenIndex+1)
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
font.pixelSize: Math.round((displayScreen ? 14 : 10) * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(displayScreen ? 14 : 10)
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
}
|
}
|
||||||
|
|
@ -104,7 +105,7 @@ ColumnLayout {
|
||||||
currentIndex: bar.currentIndex
|
currentIndex: bar.currentIndex
|
||||||
ListView{
|
ListView{
|
||||||
id: screensLayout
|
id: screensLayout
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
clip: true
|
clip: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
height: visible ? contentHeight : 0
|
height: visible ? contentHeight : 0
|
||||||
|
|
@ -118,9 +119,9 @@ ColumnLayout {
|
||||||
else currentIndex = -1
|
else currentIndex = -1
|
||||||
}
|
}
|
||||||
delegate: ScreenPreviewLayout {
|
delegate: ScreenPreviewLayout {
|
||||||
horizontalMargin: Math.round((28 - 20 ) * DefaultStyle.dp) // 20 coming from CallsWindow panel
|
horizontalMargin: Utils.getSizeWithScreenRatio(28 - 20 ) // 20 coming from CallsWindow panel
|
||||||
width: screensLayout.width
|
width: screensLayout.width
|
||||||
height: Math.round(219 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(219)
|
||||||
screenIndex: index
|
screenIndex: index
|
||||||
onClicked: {//screensLayout.selectedIndex = index
|
onClicked: {//screensLayout.selectedIndex = index
|
||||||
screensLayout.currentIndex = index
|
screensLayout.currentIndex = index
|
||||||
|
|
@ -147,14 +148,14 @@ ColumnLayout {
|
||||||
else currentIndex = -1
|
else currentIndex = -1
|
||||||
}
|
}
|
||||||
cellWidth: width / 2
|
cellWidth: width / 2
|
||||||
cellHeight: Math.round((112 + 15) * DefaultStyle.dp)
|
cellHeight: Utils.getSizeWithScreenRatio(112 + 15)
|
||||||
clip: true
|
clip: true
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
width: windowsLayout.cellWidth
|
width: windowsLayout.cellWidth
|
||||||
height: windowsLayout.cellHeight
|
height: windowsLayout.cellHeight
|
||||||
ScreenPreviewLayout {
|
ScreenPreviewLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.margins: Math.round(7 * DefaultStyle.dp)
|
anchors.margins: Utils.getSizeWithScreenRatio(7)
|
||||||
displayScreen: false
|
displayScreen: false
|
||||||
screenIndex: index
|
screenIndex: index
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
|
||||||
|
|
@ -7,6 +7,7 @@ import Linphone
|
||||||
import ConstantsCpp 1.0
|
import ConstantsCpp 1.0
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp 1.0
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ListView {
|
ListView {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -40,10 +41,10 @@ ListView {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
property int currentMonth: model.month
|
property int currentMonth: model.month
|
||||||
spacing: Math.round(18 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(18)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Math.round(38 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(38)
|
||||||
Text {
|
Text {
|
||||||
text: UtilsCpp.toDateMonthAndYearString(new Date(model.year, model.month, 15))// 15 because of timezones that can change the date for localeString
|
text: UtilsCpp.toDateMonthAndYearString(new Date(model.year, model.month, 15))// 15 because of timezones that can change the date for localeString
|
||||||
font {
|
font {
|
||||||
|
|
@ -57,8 +58,8 @@ ListView {
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
id: previousButton
|
id: previousButton
|
||||||
Layout.preferredWidth: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
icon.width: width
|
icon.width: width
|
||||||
icon.height: height
|
icon.height: height
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
|
|
@ -67,8 +68,8 @@ ListView {
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
id: nextButton
|
id: nextButton
|
||||||
Layout.preferredWidth: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
icon.width: width
|
icon.width: width
|
||||||
icon.height: height
|
icon.height: height
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
|
|
@ -78,7 +79,7 @@ ListView {
|
||||||
}
|
}
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
Control.DayOfWeekRow {
|
Control.DayOfWeekRow {
|
||||||
locale: monthGrid.locale
|
locale: monthGrid.locale
|
||||||
Layout.column: 1
|
Layout.column: 1
|
||||||
|
|
@ -89,8 +90,8 @@ ListView {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
verticalAlignment: Text.AlignVCenter
|
verticalAlignment: Text.AlignVCenter
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -146,9 +147,9 @@ ListView {
|
||||||
|
|
||||||
Rectangle {
|
Rectangle {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
width: Math.round(30 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(30)
|
||||||
height: Math.round(30 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(30)
|
||||||
radius: Math.round(50 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(50)
|
||||||
color: isSelectedDay ? DefaultStyle.main1_500_main : "transparent"
|
color: isSelectedDay ? DefaultStyle.main1_500_main : "transparent"
|
||||||
border.width: focusDay.activeFocus || hoveringArea.containsMouse ? 1 : 0
|
border.width: focusDay.activeFocus || hoveringArea.containsMouse ? 1 : 0
|
||||||
|
|
||||||
|
|
@ -164,8 +165,8 @@ ListView {
|
||||||
? DefaultStyle.main2_700
|
? DefaultStyle.main2_700
|
||||||
: DefaultStyle.main2_400
|
: DefaultStyle.main2_400
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -58,10 +58,10 @@ Control.Control {
|
||||||
|
|
||||||
// width: mainItem.implicitWidth
|
// width: mainItem.implicitWidth
|
||||||
// height: mainItem.height
|
// height: mainItem.height
|
||||||
leftPadding: Math.round(15 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(15)
|
||||||
rightPadding: Math.round(15 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(15)
|
||||||
topPadding: Math.round(16 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
bottomPadding: Math.round(16 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
|
|
@ -75,13 +75,13 @@ Control.Control {
|
||||||
Component {
|
Component {
|
||||||
id: textAreaComp
|
id: textAreaComp
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
PopupButton {
|
PopupButton {
|
||||||
id: emojiPickerButton
|
id: emojiPickerButton
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
icon.source: checked ? AppIcons.closeX : AppIcons.smiley
|
icon.source: checked ? AppIcons.closeX : AppIcons.smiley
|
||||||
popup.width: Math.round(393 * DefaultStyle.dp)
|
popup.width: Utils.getSizeWithScreenRatio(393)
|
||||||
popup.height: Math.round(291 * DefaultStyle.dp)
|
popup.height: Utils.getSizeWithScreenRatio(291)
|
||||||
popup.contentItem: EmojiPicker {
|
popup.contentItem: EmojiPicker {
|
||||||
editor: sendingTextArea
|
editor: sendingTextArea
|
||||||
}
|
}
|
||||||
|
|
@ -100,14 +100,14 @@ Control.Control {
|
||||||
}
|
}
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
leftPadding: Math.round(24 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(24)
|
||||||
rightPadding: Math.round(20 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
topPadding: Math.round(12 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
bottomPadding: Math.round(12 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
id: inputBackground
|
id: inputBackground
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(35 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(35)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
@ -118,7 +118,7 @@ Control.Control {
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
Flickable {
|
Flickable {
|
||||||
id: sendingAreaFlickable
|
id: sendingAreaFlickable
|
||||||
Layout.preferredHeight: Math.min(Math.round(100 * DefaultStyle.dp), contentHeight)
|
Layout.preferredHeight: Math.min(Utils.getSizeWithScreenRatio(100), contentHeight)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
width: sendingControl.width - sendingControl.leftPadding - sendingControl.rightPadding
|
width: sendingControl.width - sendingControl.leftPadding - sendingControl.rightPadding
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -215,15 +215,15 @@ Control.Control {
|
||||||
Component {
|
Component {
|
||||||
id: voiceMessageRecordComp
|
id: voiceMessageRecordComp
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
RoundButton {
|
RoundButton {
|
||||||
style: ButtonStyle.player
|
style: ButtonStyle.player
|
||||||
shadowEnabled: true
|
shadowEnabled: true
|
||||||
padding: Math.round(4 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(4)
|
||||||
icon.width: Math.round(22 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(22)
|
||||||
icon.height: Math.round(22 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(22)
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
width: Math.round(30 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(30)
|
||||||
Layout.preferredWidth: width
|
Layout.preferredWidth: width
|
||||||
Layout.preferredHeight: height
|
Layout.preferredHeight: height
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -238,7 +238,7 @@ Control.Control {
|
||||||
}
|
}
|
||||||
recording: true
|
recording: true
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(48 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(48)
|
||||||
chatMessageContentGui: chatMessage ? chatMessage.core.getVoiceRecordingContent() : null
|
chatMessageContentGui: chatMessage ? chatMessage.core.getVoiceRecordingContent() : null
|
||||||
onVoiceRecordingMessageCreationRequested: (recorderGui) => {
|
onVoiceRecordingMessageCreationRequested: (recorderGui) => {
|
||||||
chatMessageObj = UtilsCpp.createVoiceRecordingMessage(recorderGui, mainItem.chat)
|
chatMessageObj = UtilsCpp.createVoiceRecordingMessage(recorderGui, mainItem.chat)
|
||||||
|
|
@ -248,8 +248,8 @@ Control.Control {
|
||||||
id: sendButton
|
id: sendButton
|
||||||
style: ButtonStyle.noBackgroundOrange
|
style: ButtonStyle.noBackgroundOrange
|
||||||
icon.source: AppIcons.paperPlaneRight
|
icon.source: AppIcons.paperPlaneRight
|
||||||
icon.width: Math.round(22 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(22)
|
||||||
icon.height: Math.round(22 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(22)
|
||||||
// Layout.preferredWidth: icon.width
|
// Layout.preferredWidth: icon.width
|
||||||
// Layout.preferredHeight: icon.height
|
// Layout.preferredHeight: icon.height
|
||||||
property bool sendVoiceRecordingOnCreated: false
|
property bool sendVoiceRecordingOnCreated: false
|
||||||
|
|
@ -283,13 +283,13 @@ Control.Control {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.main2_0
|
color: DefaultStyle.main2_0
|
||||||
visible: false
|
visible: false
|
||||||
radius: Math.round(20 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(20)
|
||||||
|
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
imageSource: AppIcons.filePlus
|
imageSource: AppIcons.filePlus
|
||||||
width: Math.round(37 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(37)
|
||||||
height: Math.round(37 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(37)
|
||||||
colorizationColor: DefaultStyle.main2_500_main
|
colorizationColor: DefaultStyle.main2_500_main
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQuick.Layouts 1.0
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FormItemLayout {
|
FormItemLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -39,7 +40,7 @@ FormItemLayout {
|
||||||
|
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: textField
|
id: textField
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
placeholderText: useTitleAsPlaceHolder ? mainItem.title : mainItem.placeHolder
|
placeholderText: useTitleAsPlaceHolder ? mainItem.title : mainItem.placeHolder
|
||||||
initialText: (mainItem.propertyOwnerGui ? mainItem.propertyOwnerGui.core[mainItem.propertyName] : mainItem.propertyOwner[mainItem.propertyName]) || ''
|
initialText: (mainItem.propertyOwnerGui ? mainItem.propertyOwnerGui.core[mainItem.propertyName] : mainItem.propertyOwner[mainItem.propertyName]) || ''
|
||||||
customWidth: mainItem.parent.width
|
customWidth: mainItem.parent.width
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,11 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.TextField {
|
Control.TextField {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property real inputSize: Math.round(100 * DefaultStyle.dp)
|
property real inputSize: Utils.getSizeWithScreenRatio(100)
|
||||||
color: activeFocus ? DefaultStyle.main1_500_main : DefaultStyle.main2_500_main
|
color: activeFocus ? DefaultStyle.main1_500_main : DefaultStyle.main2_500_main
|
||||||
validator: IntValidator{bottom: 0; top: 9}
|
validator: IntValidator{bottom: 0; top: 9}
|
||||||
|
|
||||||
|
|
@ -24,7 +25,7 @@ Control.TextField {
|
||||||
// horizontalAlignment: Control.TextField.AlignHCenter
|
// horizontalAlignment: Control.TextField.AlignHCenter
|
||||||
font.family: DefaultStyle.defaultFont
|
font.family: DefaultStyle.defaultFont
|
||||||
font.pixelSize: inputSize / 2
|
font.pixelSize: inputSize / 2
|
||||||
font.weight: Math.round(300 * DefaultStyle.dp)
|
font.weight: Utils.getSizeWithScreenRatio(300)
|
||||||
|
|
||||||
background: Item {
|
background: Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
|
|
@ -32,7 +33,7 @@ Control.TextField {
|
||||||
// height: mainItem.inputSize
|
// height: mainItem.inputSize
|
||||||
Rectangle {
|
Rectangle {
|
||||||
id: background
|
id: background
|
||||||
border.width: Math.round(Math.max(DefaultStyle.dp), 1)
|
border.width: Utils.getSizeWithScreenRatio(1)
|
||||||
border.color: mainItem.activeFocus ? DefaultStyle.main1_500_main : DefaultStyle.main2_500_main
|
border.color: mainItem.activeFocus ? DefaultStyle.main1_500_main : DefaultStyle.main2_500_main
|
||||||
radius: mainItem.inputSize * 0.15
|
radius: mainItem.inputSize * 0.15
|
||||||
width: mainItem.inputSize * 0.9
|
width: mainItem.inputSize * 0.9
|
||||||
|
|
@ -42,11 +43,11 @@ Control.TextField {
|
||||||
id: indicator
|
id: indicator
|
||||||
visible: mainItem.activeFocus
|
visible: mainItem.activeFocus
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
height : Math.max(1, Math.round(1 * DefaultStyle.dp))
|
height : Utils.getSizeWithScreenRatio(1)
|
||||||
width: mainItem.inputSize * 0.67
|
width: mainItem.inputSize * 0.67
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.bottomMargin: Math.round((mainItem.inputSize / 8) * DefaultStyle.dp)
|
anchors.bottomMargin: Utils.getSizeWithScreenRatio(mainItem.inputSize / 8)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope {
|
FocusScope {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -90,8 +91,8 @@ FocusScope {
|
||||||
Layout.GridLayout {
|
Layout.GridLayout {
|
||||||
id: numPadGrid
|
id: numPadGrid
|
||||||
columns: 3
|
columns: 3
|
||||||
columnSpacing: Math.round(40 * DefaultStyle.dp)
|
columnSpacing: Utils.getSizeWithScreenRatio(40)
|
||||||
rowSpacing: Math.round(10 * DefaultStyle.dp)
|
rowSpacing: Utils.getSizeWithScreenRatio(10)
|
||||||
function getButtonAt(index){
|
function getButtonAt(index){
|
||||||
index = (index+15) % 15
|
index = (index+15) % 15
|
||||||
if(index >= 0){
|
if(index >= 0){
|
||||||
|
|
@ -113,8 +114,8 @@ FocusScope {
|
||||||
id: numPadButton
|
id: numPadButton
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
required property int index
|
required property int index
|
||||||
implicitWidth: Math.round(60 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(60)
|
||||||
implicitHeight: Math.round(60 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(60)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
mainItem.buttonPressed(text)
|
mainItem.buttonPressed(text)
|
||||||
}
|
}
|
||||||
|
|
@ -123,10 +124,10 @@ FocusScope {
|
||||||
KeyNavigation.up: numPadGrid.getButtonAt(index - 3)
|
KeyNavigation.up: numPadGrid.getButtonAt(index - 3)
|
||||||
KeyNavigation.down: numPadGrid.getButtonAt(index + 3)
|
KeyNavigation.down: numPadGrid.getButtonAt(index + 3)
|
||||||
style: ButtonStyle.numericPad
|
style: ButtonStyle.numericPad
|
||||||
radius: Math.round(71 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(71)
|
||||||
text: index + 1
|
text: index + 1
|
||||||
textSize: Math.round(32 * DefaultStyle.dp)
|
textSize: Utils.getSizeWithScreenRatio(32)
|
||||||
textWeight: Math.round(400 * DefaultStyle.dp)
|
textWeight: Utils.getSizeWithScreenRatio(400)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Repeater {
|
Repeater {
|
||||||
|
|
@ -139,8 +140,8 @@ FocusScope {
|
||||||
BigButton {
|
BigButton {
|
||||||
id: digitButton
|
id: digitButton
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
implicitWidth: Math.round(60 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(60)
|
||||||
implicitHeight: Math.round(60 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(60)
|
||||||
|
|
||||||
onClicked: mainItem.buttonPressed(pressText.text)
|
onClicked: mainItem.buttonPressed(pressText.text)
|
||||||
onPressAndHold: mainItem.buttonPressed(longPressText.text)
|
onPressAndHold: mainItem.buttonPressed(longPressText.text)
|
||||||
|
|
@ -149,7 +150,7 @@ FocusScope {
|
||||||
KeyNavigation.right: numPadGrid.getButtonAt((index + 1)+9)
|
KeyNavigation.right: numPadGrid.getButtonAt((index + 1)+9)
|
||||||
KeyNavigation.up: numPadGrid.getButtonAt((index - 3)+9)
|
KeyNavigation.up: numPadGrid.getButtonAt((index - 3)+9)
|
||||||
KeyNavigation.down: numPadGrid.getButtonAt((index + 3)+9)
|
KeyNavigation.down: numPadGrid.getButtonAt((index + 3)+9)
|
||||||
radius: Math.round(71 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(71)
|
||||||
style: ButtonStyle.numericPad
|
style: ButtonStyle.numericPad
|
||||||
|
|
||||||
contentItem: Item {
|
contentItem: Item {
|
||||||
|
|
@ -163,7 +164,7 @@ FocusScope {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
Component.onCompleted: {if (modelData.longPressText === undefined) anchors.centerIn= parent}
|
Component.onCompleted: {if (modelData.longPressText === undefined) anchors.centerIn= parent}
|
||||||
text: modelData.pressText
|
text: modelData.pressText
|
||||||
font.pixelSize: Math.round(32 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(32)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
id: longPressText
|
id: longPressText
|
||||||
|
|
@ -175,7 +176,7 @@ FocusScope {
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
visible: modelData.longPressText ? modelData.longPressText.length > 0 : false
|
visible: modelData.longPressText ? modelData.longPressText.length > 0 : false
|
||||||
text: modelData.longPressText ? modelData.longPressText : ""
|
text: modelData.longPressText ? modelData.longPressText : ""
|
||||||
font.pixelSize: Math.round(22 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(22)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -187,12 +188,12 @@ FocusScope {
|
||||||
Button {
|
Button {
|
||||||
id: launchCallButton
|
id: launchCallButton
|
||||||
visible: mainItem.lastRowVisible
|
visible: mainItem.lastRowVisible
|
||||||
implicitWidth: Math.round(75 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(75)
|
||||||
implicitHeight: Math.round(55 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(55)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
icon.width: Math.round(32 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(32)
|
||||||
icon.height: Math.round(32 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(32)
|
||||||
radius: Math.round(71 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(71)
|
||||||
style: ButtonStyle.phoneGreen
|
style: ButtonStyle.phoneGreen
|
||||||
|
|
||||||
onClicked: mainItem.launchCall()
|
onClicked: mainItem.launchCall()
|
||||||
|
|
@ -205,17 +206,17 @@ FocusScope {
|
||||||
Button {
|
Button {
|
||||||
id: eraseButton
|
id: eraseButton
|
||||||
visible: mainItem.lastRowVisible
|
visible: mainItem.lastRowVisible
|
||||||
leftPadding: Math.round(5 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
rightPadding: Math.round(5 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
topPadding: Math.round(5 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
bottomPadding: Math.round(5 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
icon.source: AppIcons.backspaceFill
|
icon.source: AppIcons.backspaceFill
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
icon.width: Math.round(38 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(38)
|
||||||
icon.height: Math.round(38 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(38)
|
||||||
Layout.Layout.preferredWidth: Math.round(38 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(38)
|
||||||
Layout.Layout.preferredHeight: Math.round(38 * DefaultStyle.dp)
|
Layout.Layout.preferredHeight: Utils.getSizeWithScreenRatio(38)
|
||||||
|
|
||||||
onClicked: mainItem.wipe()
|
onClicked: mainItem.wipe()
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import CustomControls 1.0
|
import CustomControls 1.0
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -19,7 +20,7 @@ ColumnLayout {
|
||||||
property string defaultCallingCode
|
property string defaultCallingCode
|
||||||
property bool keyboardFocus: FocusHelper.keyboardFocus
|
property bool keyboardFocus: FocusHelper.keyboardFocus
|
||||||
|
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
visible: label.length > 0
|
visible: label.length > 0
|
||||||
|
|
@ -34,12 +35,12 @@ ColumnLayout {
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
Layout.preferredWidth: mainItem.width
|
Layout.preferredWidth: mainItem.width
|
||||||
Layout.preferredHeight: Math.round(49 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(49)
|
||||||
leftPadding: Math.round(16 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(16)
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
id: contentBackground
|
id: contentBackground
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(63 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(63)
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
border.color: mainItem.errorMessage.length > 0
|
border.color: mainItem.errorMessage.length > 0
|
||||||
? DefaultStyle.danger_500_main
|
? DefaultStyle.danger_500_main
|
||||||
|
|
@ -50,7 +51,7 @@ ColumnLayout {
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
CountryIndicatorCombobox {
|
CountryIndicatorCombobox {
|
||||||
id: combobox
|
id: combobox
|
||||||
implicitWidth: Math.round(110 * DefaultStyle.dp)
|
implicitWidth: Utils.getSizeWithScreenRatio(110)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
defaultCallingCode: mainItem.defaultCallingCode
|
defaultCallingCode: mainItem.defaultCallingCode
|
||||||
property bool keyboardFocus: FocusHelper.keyboardFocus
|
property bool keyboardFocus: FocusHelper.keyboardFocus
|
||||||
|
|
@ -58,10 +59,10 @@ ColumnLayout {
|
||||||
Accessible.name: qsTr("prefix_phone_number_accessible_name").arg(mainItem.Accessible.name)
|
Accessible.name: qsTr("prefix_phone_number_accessible_name").arg(mainItem.Accessible.name)
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.preferredWidth: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(1)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.topMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.bottomMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
color: DefaultStyle.main2_600
|
color: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
TextField {
|
TextField {
|
||||||
|
|
@ -80,7 +81,7 @@ ColumnLayout {
|
||||||
TemporaryText {
|
TemporaryText {
|
||||||
id: errorText
|
id: errorText
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.topMargin: Math.round(-3 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(-3)
|
||||||
// visible: mainItem.enableErrorText
|
// visible: mainItem.enableErrorText
|
||||||
text: mainItem.errorMessage
|
text: mainItem.errorMessage
|
||||||
color: DefaultStyle.danger_500_main
|
color: DefaultStyle.danger_500_main
|
||||||
|
|
@ -88,7 +89,7 @@ ColumnLayout {
|
||||||
elide: Text.ElideRight
|
elide: Text.ElideRight
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(13 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(13)
|
||||||
family: DefaultStyle.defaultFont
|
family: DefaultStyle.defaultFont
|
||||||
bold: true
|
bold: true
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ FocusScope {
|
||||||
// Text properties
|
// Text properties
|
||||||
property string placeholderText: ""
|
property string placeholderText: ""
|
||||||
property color placeholderTextColor: DefaultStyle.main2_400
|
property color placeholderTextColor: DefaultStyle.main2_400
|
||||||
property real textInputWidth: Math.round(350 * DefaultStyle.dp)
|
property real textInputWidth: Utils.getSizeWithScreenRatio(350)
|
||||||
property string text: textField.searchText
|
property string text: textField.searchText
|
||||||
|
|
||||||
signal openNumericPadRequested()// Useful for redirection before displaying numeric pad.
|
signal openNumericPadRequested()// Useful for redirection before displaying numeric pad.
|
||||||
|
|
@ -45,12 +45,12 @@ FocusScope {
|
||||||
|
|
||||||
|
|
||||||
implicitWidth: mainItem.textInputWidth
|
implicitWidth: mainItem.textInputWidth
|
||||||
implicitHeight: Math.round(50 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(50)
|
||||||
|
|
||||||
Rectangle{
|
Rectangle{
|
||||||
id: backgroundItem
|
id: backgroundItem
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
radius: Math.round(28 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(28)
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
border.color: textField.keyboardFocus ? mainItem.keyboardFocusedBorderColor : textField.activeFocus ? mainItem.focusedBorderColor : mainItem.borderColor
|
border.color: textField.keyboardFocus ? mainItem.keyboardFocusedBorderColor : textField.activeFocus ? mainItem.focusedBorderColor : mainItem.borderColor
|
||||||
border.width: textField.keyboardFocus ? mainItem.keyboardFocusedBorderWidth : mainItem.borderWidth
|
border.width: textField.keyboardFocus ? mainItem.keyboardFocusedBorderWidth : mainItem.borderWidth
|
||||||
|
|
@ -61,15 +61,15 @@ FocusScope {
|
||||||
colorizationColor: DefaultStyle.main2_500_main
|
colorizationColor: DefaultStyle.main2_500_main
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.leftMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
imageSource: AppIcons.magnifier
|
imageSource: AppIcons.magnifier
|
||||||
width: Math.round(20 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(20)
|
||||||
height: Math.round(20 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(20)
|
||||||
}
|
}
|
||||||
Control.TextField {
|
Control.TextField {
|
||||||
id: textField
|
id: textField
|
||||||
anchors.left: magnifier.visible ? magnifier.right : parent.left
|
anchors.left: magnifier.visible ? magnifier.right : parent.left
|
||||||
anchors.leftMargin: magnifier.visible ? 0 : Math.round(10 * DefaultStyle.dp)
|
anchors.leftMargin: magnifier.visible ? 0 : Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.right: clearTextButton.left
|
anchors.right: clearTextButton.left
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
property bool keyboardFocus: FocusHelper.keyboardFocus
|
property bool keyboardFocus: FocusHelper.keyboardFocus
|
||||||
|
|
@ -96,7 +96,7 @@ FocusScope {
|
||||||
cursorDelegate: Rectangle {
|
cursorDelegate: Rectangle {
|
||||||
visible: textField.cursorVisible
|
visible: textField.cursorVisible
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
width: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
width: Utils.getSizeWithScreenRatio(1)
|
||||||
}
|
}
|
||||||
Timer{
|
Timer{
|
||||||
id: delayTimer
|
id: delayTimer
|
||||||
|
|
@ -113,13 +113,13 @@ FocusScope {
|
||||||
icon.source: AppIcons.dialer
|
icon.source: AppIcons.dialer
|
||||||
contentImageColor: checked ? DefaultStyle.main1_500_main : DefaultStyle.main2_600
|
contentImageColor: checked ? DefaultStyle.main1_500_main : DefaultStyle.main2_600
|
||||||
hoveredImageColor: contentImageColor
|
hoveredImageColor: contentImageColor
|
||||||
width: Math.round(30 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(30)
|
||||||
height: Math.round(30* DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(30)
|
||||||
icon.width: Utils.getSizeWithScreenRatio(24)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Utils.getSizeWithScreenRatio(24)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(20 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
//: "Open dialer"
|
//: "Open dialer"
|
||||||
Accessible.name: qsTr("open_dialer_acccessibility_label")
|
Accessible.name: qsTr("open_dialer_acccessibility_label")
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -132,14 +132,14 @@ FocusScope {
|
||||||
Button {
|
Button {
|
||||||
id: clearTextButton
|
id: clearTextButton
|
||||||
visible: textField.text.length > 0 && mainItem.enabled
|
visible: textField.text.length > 0 && mainItem.enabled
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(20 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
//: "Clear text input"
|
//: "Clear text input"
|
||||||
Accessible.name: qsTr("clear_text_input_acccessibility_label")
|
Accessible.name: qsTr("clear_text_input_acccessibility_label")
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
TextEdit {
|
TextEdit {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -14,8 +15,8 @@ TextEdit {
|
||||||
property alias background: background.data
|
property alias background: background.data
|
||||||
property bool hoverEnabled: true
|
property bool hoverEnabled: true
|
||||||
property bool hovered: mouseArea.hoverEnabled && mouseArea.containsMouse
|
property bool hovered: mouseArea.hoverEnabled && mouseArea.containsMouse
|
||||||
topPadding: Math.round(5 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
bottomPadding: Math.round(5 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(5)
|
||||||
activeFocusOnTab: true
|
activeFocusOnTab: true
|
||||||
KeyNavigation.priority: KeyNavigation.BeforeItem
|
KeyNavigation.priority: KeyNavigation.BeforeItem
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@ import "qrc:/qt/qml/Linphone/view/Style/buttonStyle.js" as ButtonStyle
|
||||||
Control.TextField {
|
Control.TextField {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
property var customWidth
|
property var customWidth
|
||||||
width: Math.round((customWidth ? customWidth - 1 : 360) * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(customWidth ? customWidth - 1 : 360)
|
||||||
height: Utils.getSizeWithScreenRatio(49)
|
height: Utils.getSizeWithScreenRatio(49)
|
||||||
leftPadding: Utils.getSizeWithScreenRatio(15)
|
leftPadding: Utils.getSizeWithScreenRatio(15)
|
||||||
rightPadding: eyeButton.visible
|
rightPadding: eyeButton.visible
|
||||||
|
|
@ -136,7 +136,7 @@ Control.TextField {
|
||||||
cursorDelegate: Rectangle {
|
cursorDelegate: Rectangle {
|
||||||
id: cursor
|
id: cursor
|
||||||
color: DefaultStyle.main1_500_main
|
color: DefaultStyle.main1_500_main
|
||||||
width: Math.max(Utils.getSizeWithScreenRatio(1), 1)
|
width: Utils.getSizeWithScreenRatio(1)
|
||||||
anchors.verticalCenter: mainItem.verticalCenter
|
anchors.verticalCenter: mainItem.verticalCenter
|
||||||
|
|
||||||
SequentialAnimation {
|
SequentialAnimation {
|
||||||
|
|
|
||||||
|
|
@ -1,10 +1,11 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ComboBox {
|
ComboBox {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
indicatorRightMargin: Math.round(10 * DefaultStyle.dp)
|
indicatorRightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
property var selectedDateTime
|
property var selectedDateTime
|
||||||
onSelectedDateTimeChanged: {
|
onSelectedDateTimeChanged: {
|
||||||
if (minTime != undefined) {
|
if (minTime != undefined) {
|
||||||
|
|
@ -22,10 +23,10 @@ ComboBox {
|
||||||
property alias contentText: input
|
property alias contentText: input
|
||||||
property var minTime
|
property var minTime
|
||||||
property var maxTime
|
property var maxTime
|
||||||
popup.width: Math.round(73 * DefaultStyle.dp)
|
popup.width: Utils.getSizeWithScreenRatio(73)
|
||||||
listView.model: 48
|
listView.model: 48
|
||||||
listView.height: Math.min(Math.round(204 * DefaultStyle.dp), listView.contentHeight)
|
listView.height: Math.min(Utils.getSizeWithScreenRatio(204), listView.contentHeight)
|
||||||
popup.height: Math.min(Math.round(204 * DefaultStyle.dp), listView.contentHeight)
|
popup.height: Math.min(Utils.getSizeWithScreenRatio(204), listView.contentHeight)
|
||||||
editable: true
|
editable: true
|
||||||
popup.closePolicy: Popup.PressOutsideParent | Popup.CloseOnPressOutside
|
popup.closePolicy: Popup.PressOutsideParent | Popup.CloseOnPressOutside
|
||||||
onCurrentTextChanged: input.text = currentText
|
onCurrentTextChanged: input.text = currentText
|
||||||
|
|
@ -74,7 +75,7 @@ ComboBox {
|
||||||
text: Qt.formatDateTime(currentDateTime, "hh:mm")
|
text: Qt.formatDateTime(currentDateTime, "hh:mm")
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
visible: mainItem.minTime == undefined || UtilsCpp.timeOffset(mainItem.minTime, currentDateTime) > 0
|
visible: mainItem.minTime == undefined || UtilsCpp.timeOffset(mainItem.minTime, currentDateTime) > 0
|
||||||
height: visible ? Math.round(25 * DefaultStyle.dp) : 0
|
height: visible ? Utils.getSizeWithScreenRatio(25) : 0
|
||||||
verticalAlignment: TextInput.AlignVCenter
|
verticalAlignment: TextInput.AlignVCenter
|
||||||
horizontalAlignment: TextInput.AlignHCenter
|
horizontalAlignment: TextInput.AlignHCenter
|
||||||
font {
|
font {
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Dialog {
|
Dialog {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -17,11 +18,11 @@ Dialog {
|
||||||
readonly property string password: passwordEdit.text
|
readonly property string password: passwordEdit.text
|
||||||
property var callback// Define cb(var) function
|
property var callback// Define cb(var) function
|
||||||
|
|
||||||
topPadding:Math.round( 20 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
bottomPadding:Math.round( 20 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
leftPadding:Math.round( 20 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
rightPadding:Math.round( 20 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(20)
|
||||||
width:Math.round( 637 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(637)
|
||||||
modal: true
|
modal: true
|
||||||
closePolicy: Popup.NoAutoClose
|
closePolicy: Popup.NoAutoClose
|
||||||
|
|
||||||
|
|
@ -33,11 +34,11 @@ Dialog {
|
||||||
Component.onDestruction: if(callback) callback.destroy()
|
Component.onDestruction: if(callback) callback.destroy()
|
||||||
|
|
||||||
content: ColumnLayout {
|
content: ColumnLayout {
|
||||||
spacing:Math.round( 20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
id: contentLayout
|
id: contentLayout
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredWidth:Math.round( 250 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(250)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
|
|
@ -50,13 +51,13 @@ Dialog {
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredWidth:Math.round( 250 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(250)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
wrapMode: Text.Wrap
|
wrapMode: Text.Wrap
|
||||||
//: La connexion a échoué pour le compte %1. Vous pouvez renseigner votre mot de passe à nouveau ou bien vérifier les options de configuration de votre compte.
|
//: La connexion a échoué pour le compte %1. Vous pouvez renseigner votre mot de passe à nouveau ou bien vérifier les options de configuration de votre compte.
|
||||||
text: qsTr("account_settings_dialog_invalid_password_message").arg(mainItem.identity)
|
text: qsTr("account_settings_dialog_invalid_password_message").arg(mainItem.identity)
|
||||||
font.pixelSize:Math.round( 16 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(16)
|
||||||
font {
|
font {
|
||||||
pixelSize: Typography.h4.pixelSize
|
pixelSize: Typography.h4.pixelSize
|
||||||
weight: Typography.h4.weight
|
weight: Typography.h4.weight
|
||||||
|
|
@ -80,7 +81,7 @@ Dialog {
|
||||||
buttons: [
|
buttons: [
|
||||||
MediumButton {
|
MediumButton {
|
||||||
id: cancelButton
|
id: cancelButton
|
||||||
Layout.topMargin: Math.round( 10 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
//: "Annuler
|
//: "Annuler
|
||||||
text: qsTr("cancel")
|
text: qsTr("cancel")
|
||||||
style: ButtonStyle.secondary
|
style: ButtonStyle.secondary
|
||||||
|
|
@ -90,7 +91,7 @@ Dialog {
|
||||||
},
|
},
|
||||||
MediumButton {
|
MediumButton {
|
||||||
id: connectButton
|
id: connectButton
|
||||||
Layout.topMargin:Math.round( 10 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
//: Connexion
|
//: Connexion
|
||||||
text: qsTr("assistant_account_login")
|
text: qsTr("assistant_account_login")
|
||||||
style: ButtonStyle.main
|
style: ButtonStyle.main
|
||||||
|
|
|
||||||
|
|
@ -4,18 +4,19 @@ import QtQuick.Effects
|
||||||
import QtQuick.Layouts
|
import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Popup {
|
Popup {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
modal: true
|
modal: true
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
closePolicy: Control.Popup.NoAutoClose
|
closePolicy: Control.Popup.NoAutoClose
|
||||||
leftPadding: title.length === 0 ? Math.round(10 * DefaultStyle.dp) : Math.round(33 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(title.length === 0 ? 10 : 33)
|
||||||
rightPadding: title.length === 0 ? Math.round(10 * DefaultStyle.dp) : Math.round(33 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(title.length === 0 ? 10 : 33)
|
||||||
topPadding: title.length === 0 ? Math.round(10 * DefaultStyle.dp) : Math.round(37 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(title.length === 0 ? 10 : 37)
|
||||||
bottomPadding: title.length === 0 ? Math.round(10 * DefaultStyle.dp) : Math.round(37 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(title.length === 0 ? 10 : 37)
|
||||||
underlineColor: DefaultStyle.main1_500_main
|
underlineColor: DefaultStyle.main1_500_main
|
||||||
radius: title.length === 0 ? Math.round(16 * DefaultStyle.dp) : 0
|
radius: title.length === 0 ? Utils.getSizeWithScreenRatio(16) : 0
|
||||||
property string title
|
property string title
|
||||||
property var titleColor: DefaultStyle.main1_500_main
|
property var titleColor: DefaultStyle.main1_500_main
|
||||||
property string text
|
property string text
|
||||||
|
|
@ -51,7 +52,7 @@ Popup {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: child
|
id: child
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
|
|
||||||
Text{
|
Text{
|
||||||
id: titleText
|
id: titleText
|
||||||
|
|
@ -90,7 +91,7 @@ Popup {
|
||||||
id: detailsText
|
id: detailsText
|
||||||
visible: text.length != 0
|
visible: text.length != 0
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
//Layout.preferredWidth: Math.round(278 * DefaultStyle.dp)
|
//Layout.preferredWidth: Utils.getSizeWithScreenRatio(278)
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
text: mainItem.details
|
text: mainItem.details
|
||||||
font {
|
font {
|
||||||
|
|
@ -111,7 +112,7 @@ Popup {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: buttonsLayout
|
id: buttonsLayout
|
||||||
Layout.alignment: Qt.AlignBottom | ( titleText.visible ? Qt.AlignRight : Qt.AlignHCenter)
|
Layout.alignment: Qt.AlignBottom | ( titleText.visible ? Qt.AlignRight : Qt.AlignHCenter)
|
||||||
spacing: titleText.visible ? Math.round(20 * DefaultStyle.dp) : Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(titleText.visible ? 20 : 10)
|
||||||
|
|
||||||
// Default buttons only visible if no other children
|
// Default buttons only visible if no other children
|
||||||
// have been set
|
// have been set
|
||||||
|
|
|
||||||
|
|
@ -5,15 +5,16 @@ import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp 1.0
|
import UtilsCpp 1.0
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
Dialog {
|
Dialog {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
width: Math.round(436 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(436)
|
||||||
rightPadding: Math.round(0 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(0)
|
||||||
leftPadding: Math.round(0 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(0)
|
||||||
topPadding: Math.round(85 * DefaultStyle.dp) + Math.round(24 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(85 + 24)
|
||||||
bottomPadding: Math.round(24 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(24)
|
||||||
modal: true
|
modal: true
|
||||||
closePolicy: Popup.NoAutoClose
|
closePolicy: Popup.NoAutoClose
|
||||||
|
|
||||||
|
|
@ -39,10 +40,10 @@ Dialog {
|
||||||
radius: mainItem.radius
|
radius: mainItem.radius
|
||||||
Layout.ColumnLayout {
|
Layout.ColumnLayout {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
Item {
|
Item {
|
||||||
// spacing: Math.round(14 * DefaultStyle.dp)
|
// spacing: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.Layout.preferredWidth: childrenRect.width
|
Layout.Layout.preferredWidth: childrenRect.width
|
||||||
Layout.Layout.preferredHeight: childrenRect.height
|
Layout.Layout.preferredHeight: childrenRect.height
|
||||||
Layout.Layout.fillWidth: true
|
Layout.Layout.fillWidth: true
|
||||||
|
|
@ -50,19 +51,19 @@ Dialog {
|
||||||
id: trustShield
|
id: trustShield
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
source: AppIcons.trustedWhite
|
source: AppIcons.trustedWhite
|
||||||
sourceSize.width: Math.round(24 * DefaultStyle.dp)
|
sourceSize.width: Utils.getSizeWithScreenRatio(24)
|
||||||
sourceSize.height: Math.round(24 * DefaultStyle.dp)
|
sourceSize.height: Utils.getSizeWithScreenRatio(24)
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
anchors.left: trustShield.right
|
anchors.left: trustShield.right
|
||||||
anchors.leftMargin: Math.round(14 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(14)
|
||||||
visible: mainItem.securityError
|
visible: mainItem.securityError
|
||||||
imageSource: AppIcons.shieldWarning
|
imageSource: AppIcons.shieldWarning
|
||||||
colorizationColor: DefaultStyle.main2_700
|
colorizationColor: DefaultStyle.main2_700
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -81,8 +82,8 @@ Dialog {
|
||||||
visible: !mainItem.securityError
|
visible: !mainItem.securityError
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.topMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.rightMargin: Math.round(17 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(17)
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
//: "Passer"
|
//: "Passer"
|
||||||
text: qsTr("call_zrtp_sas_validation_skip")
|
text: qsTr("call_zrtp_sas_validation_skip")
|
||||||
|
|
@ -99,9 +100,9 @@ Dialog {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
z: 1
|
z: 1
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: parent.height - Math.round(85 * DefaultStyle.dp)
|
height: Math.round(parent.height - Utils.getSizeWithScreenRatio(85))
|
||||||
x: parent.x
|
x: parent.x
|
||||||
y: parent.y + Math.round(85 * DefaultStyle.dp)
|
y: Math.round(parent.y + Utils.getSizeWithScreenRatio(85))
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
radius: mainItem.radius
|
radius: mainItem.radius
|
||||||
}
|
}
|
||||||
|
|
@ -118,14 +119,14 @@ Dialog {
|
||||||
content: [
|
content: [
|
||||||
Layout.ColumnLayout {
|
Layout.ColumnLayout {
|
||||||
visible: !mainItem.securityError
|
visible: !mainItem.securityError
|
||||||
spacing: Math.round(20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.Layout.fillWidth: true
|
Layout.Layout.fillWidth: true
|
||||||
Layout.ColumnLayout {
|
Layout.ColumnLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Text {
|
Text {
|
||||||
Layout.Layout.preferredWidth: Math.round(343 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(343)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
text: !mainItem.isTokenVerified && mainItem.isCaseMismatch
|
text: !mainItem.isTokenVerified && mainItem.isCaseMismatch
|
||||||
|
|
@ -134,7 +135,7 @@ Dialog {
|
||||||
//: "Pour garantir le chiffrement, nous avons besoin d’authentifier l’appareil de votre correspondant. Veuillez échanger vos codes : "
|
//: "Pour garantir le chiffrement, nous avons besoin d’authentifier l’appareil de votre correspondant. Veuillez échanger vos codes : "
|
||||||
: qsTr("call_dialog_zrtp_validate_trust_message")
|
: qsTr("call_dialog_zrtp_validate_trust_message")
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
Layout.ColumnLayout {
|
Layout.ColumnLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
@ -144,7 +145,7 @@ Dialog {
|
||||||
text: qsTr("call_dialog_zrtp_validate_trust_local_code_label")
|
text: qsTr("call_dialog_zrtp_validate_trust_local_code_label")
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.call && mainItem.call.core.localToken || ""
|
text: mainItem.call && mainItem.call.core.localToken || ""
|
||||||
|
|
@ -160,18 +161,18 @@ Dialog {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: "transparent"
|
color: "transparent"
|
||||||
border.color: DefaultStyle.main2_200
|
border.color: DefaultStyle.main2_200
|
||||||
border.width: Math.max(1, Math.round(1 * DefaultStyle.dp))
|
border.width: Utils.getSizeWithScreenRatio(1)
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
Layout.Layout.preferredWidth: Math.round(292 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(292)
|
||||||
Layout.Layout.preferredHeight: Math.round(233 * DefaultStyle.dp)
|
Layout.Layout.preferredHeight: Utils.getSizeWithScreenRatio(233)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.ColumnLayout {
|
Layout.ColumnLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.topMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
Text {
|
Text {
|
||||||
//: "Code correspondant :"
|
//: "Code correspondant :"
|
||||||
text: qsTr("call_dialog_zrtp_validate_trust_remote_code_label")
|
text: qsTr("call_dialog_zrtp_validate_trust_remote_code_label")
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
}
|
}
|
||||||
Layout.GridLayout {
|
Layout.GridLayout {
|
||||||
|
|
@ -179,23 +180,23 @@ Dialog {
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
rows: 2
|
rows: 2
|
||||||
columns: 2
|
columns: 2
|
||||||
rowSpacing: Math.round(32 * DefaultStyle.dp)
|
rowSpacing: Utils.getSizeWithScreenRatio(32)
|
||||||
columnSpacing: Math.round(32 * DefaultStyle.dp)
|
columnSpacing: Utils.getSizeWithScreenRatio(32)
|
||||||
property var correctIndex
|
property var correctIndex
|
||||||
property var modelList
|
property var modelList
|
||||||
Repeater {
|
Repeater {
|
||||||
model: mainItem.call && mainItem.call.core.remoteTokens || ""
|
model: mainItem.call && mainItem.call.core.remoteTokens || ""
|
||||||
Button {
|
Button {
|
||||||
Layout.Layout.preferredWidth: Math.round(70 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(70)
|
||||||
Layout.Layout.preferredHeight: Math.round(70 * DefaultStyle.dp)
|
Layout.Layout.preferredHeight: Utils.getSizeWithScreenRatio(70)
|
||||||
width: Math.round(70 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(70)
|
||||||
height: Math.round(70 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(70)
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
textSize: Math.round(32 * DefaultStyle.dp)
|
textSize: Utils.getSizeWithScreenRatio(32)
|
||||||
textWeight: Math.round(400 * DefaultStyle.dp)
|
textWeight: Utils.getSizeWithScreenRatio(400)
|
||||||
text: modelData
|
text: modelData
|
||||||
shadowEnabled: true
|
shadowEnabled: true
|
||||||
radius: Math.round(71 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(71)
|
||||||
textColor: DefaultStyle.main2_600
|
textColor: DefaultStyle.main2_600
|
||||||
onClicked: {
|
onClicked: {
|
||||||
console.log("CHECK TOKEN", modelData)
|
console.log("CHECK TOKEN", modelData)
|
||||||
|
|
@ -212,26 +213,26 @@ Dialog {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
width: Math.round(303 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(303)
|
||||||
// Layout.Layout.preferredWidth: Math.round(343 * DefaultStyle.dp)
|
// Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(343)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.Layout.fillWidth: true
|
Layout.Layout.fillWidth: true
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
//: "Le code fourni ne correspond pas."
|
//: "Le code fourni ne correspond pas."
|
||||||
text: qsTr("call_dialog_zrtp_validate_trust_letters_do_not_match_text")
|
text: qsTr("call_dialog_zrtp_validate_trust_letters_do_not_match_text")
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
width: Math.round(303 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(303)
|
||||||
// Layout.Layout.preferredWidth: Math.round(343 * DefaultStyle.dp)
|
// Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(343)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.Layout.fillWidth: true
|
Layout.Layout.fillWidth: true
|
||||||
horizontalAlignment: Text.AlignHCenter
|
horizontalAlignment: Text.AlignHCenter
|
||||||
//: "La confidentialité de votre appel peut être compromise !"
|
//: "La confidentialité de votre appel peut être compromise !"
|
||||||
text: qsTr("call_dialog_zrtp_security_alert_message")
|
text: qsTr("call_dialog_zrtp_security_alert_message")
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
@ -240,7 +241,7 @@ Dialog {
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
MediumButton {
|
MediumButton {
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.Layout.preferredWidth: Math.round(247 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(247)
|
||||||
//: "Aucune correspondance"
|
//: "Aucune correspondance"
|
||||||
text: qsTr("call_dialog_zrtp_validate_trust_letters_do_not_match")
|
text: qsTr("call_dialog_zrtp_validate_trust_letters_do_not_match")
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
|
|
@ -252,12 +253,12 @@ Dialog {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
MediumButton {
|
MediumButton {
|
||||||
Layout.Layout.preferredWidth: Math.round(247 * DefaultStyle.dp)
|
Layout.Layout.preferredWidth: Utils.getSizeWithScreenRatio(247)
|
||||||
Layout.Layout.alignment: Qt.AlignHCenter
|
Layout.Layout.alignment: Qt.AlignHCenter
|
||||||
visible: mainItem.securityError
|
visible: mainItem.securityError
|
||||||
style: ButtonStyle.phoneRed
|
style: ButtonStyle.phoneRed
|
||||||
onClicked: mainItem.call.core.lTerminate()
|
onClicked: mainItem.call.core.lTerminate()
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
//: "Raccrocher"
|
//: "Raccrocher"
|
||||||
text: qsTr("call_action_hang_up")
|
text: qsTr("call_action_hang_up")
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Controls.Basic
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Popup {
|
Popup {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -18,9 +19,9 @@ Popup {
|
||||||
closePolicy: Popup.NoAutoClose
|
closePolicy: Popup.NoAutoClose
|
||||||
x : parent.x + parent.width - width
|
x : parent.x + parent.width - width
|
||||||
// y : parent.y + parent.height - height
|
// y : parent.y + parent.height - height
|
||||||
rightMargin: Math.round(20 * DefaultStyle.dp)
|
rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
bottomMargin: Math.round(20 * DefaultStyle.dp)
|
bottomMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
padding: Math.round(20 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(20)
|
||||||
underlineColor: mainItem.isSuccess ? DefaultStyle.success_500_main : DefaultStyle.danger_500_main
|
underlineColor: mainItem.isSuccess ? DefaultStyle.success_500_main : DefaultStyle.danger_500_main
|
||||||
radius: 0
|
radius: 0
|
||||||
focus: true
|
focus: true
|
||||||
|
|
@ -37,24 +38,24 @@ Popup {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(24 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(24)
|
||||||
Accessible.role: Accessible.AlertMessage
|
Accessible.role: Accessible.AlertMessage
|
||||||
Accessible.name: "%1, %2".arg(mainItem.title).arg(mainItem.description)
|
Accessible.name: "%1, %2".arg(mainItem.title).arg(mainItem.description)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: mainItem.isSuccess ? AppIcons.smiley : AppIcons.smileySad
|
imageSource: mainItem.isSuccess ? AppIcons.smiley : AppIcons.smileySad
|
||||||
colorizationColor: mainItem.isSuccess ? DefaultStyle.success_500_main : DefaultStyle.danger_500_main
|
colorizationColor: mainItem.isSuccess ? DefaultStyle.success_500_main : DefaultStyle.danger_500_main
|
||||||
Layout.preferredWidth: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(32)
|
||||||
Layout.preferredHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
width: Math.round(32 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(32)
|
||||||
height: Math.round(32 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(32)
|
||||||
}
|
}
|
||||||
Rectangle {
|
Rectangle {
|
||||||
Layout.preferredWidth: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(1)
|
||||||
Layout.preferredHeight: parent.height
|
Layout.preferredHeight: parent.height
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(2 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -67,10 +68,10 @@ Popup {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
Layout.preferredWidth: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.preferredHeight: Math.round(20 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
icon.width: Math.round(20 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(20)
|
||||||
icon.height: Math.round(20 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.alignment: Qt.AlignTop | Qt.AlignRight
|
Layout.alignment: Qt.AlignTop | Qt.AlignRight
|
||||||
visible: mainItem.hovered || hovered
|
visible: mainItem.hovered || hovered
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
|
|
@ -81,13 +82,13 @@ Popup {
|
||||||
Text {
|
Text {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.maximumWidth: Math.round(300 * DefaultStyle.dp)
|
Layout.maximumWidth: Utils.getSizeWithScreenRatio(300)
|
||||||
text: mainItem.description
|
text: mainItem.description
|
||||||
wrapMode: Text.WordWrap
|
wrapMode: Text.WordWrap
|
||||||
color: DefaultStyle.main2_500_main
|
color: DefaultStyle.main2_500_main
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Math.round(300 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(300)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic
|
import QtQuick.Controls.Basic
|
||||||
import Linphone
|
import Linphone
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Popup {
|
Popup {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -12,18 +13,18 @@ Popup {
|
||||||
modal: true
|
modal: true
|
||||||
closePolicy: Control.Popup.NoAutoClose
|
closePolicy: Control.Popup.NoAutoClose
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
padding: Math.round(20 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(20)
|
||||||
underlineColor: DefaultStyle.main1_500_main
|
underlineColor: DefaultStyle.main1_500_main
|
||||||
radius: Math.round(15 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(15)
|
||||||
// onAboutToShow: width = contentText.implicitWidth
|
// onAboutToShow: width = contentText.implicitWidth
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(15 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(15)
|
||||||
// width: childrenRect.width
|
// width: childrenRect.width
|
||||||
// height: childrenRect.height
|
// height: childrenRect.height
|
||||||
BusyIndicator{
|
BusyIndicator{
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.preferredWidth: Math.round(33 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(33)
|
||||||
Layout.preferredHeight: Math.round(33 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(33)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
id: contentText
|
id: contentText
|
||||||
|
|
@ -31,7 +32,7 @@ Popup {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
text: mainItem.text
|
text: mainItem.text
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
MediumButton {
|
MediumButton {
|
||||||
visible: mainItem.cancelButtonVisible
|
visible: mainItem.cancelButtonVisible
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,7 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
|
|
@ -11,8 +12,8 @@ DesktopPopup {
|
||||||
property var notificationData: ({
|
property var notificationData: ({
|
||||||
timelineModel : null
|
timelineModel : null
|
||||||
})
|
})
|
||||||
property real overriddenHeight: Math.round(120 * DefaultStyle.dp)
|
property real overriddenHeight: Utils.getSizeWithScreenRatio(120)
|
||||||
property real overriddenWidth: Math.round(300 * DefaultStyle.dp)
|
property real overriddenWidth: Utils.getSizeWithScreenRatio(300)
|
||||||
property double radius: 0
|
property double radius: 0
|
||||||
property color backgroundColor: DefaultStyle.grey_0
|
property color backgroundColor: DefaultStyle.grey_0
|
||||||
property double backgroundOpacity: 1
|
property double backgroundOpacity: 1
|
||||||
|
|
@ -56,7 +57,7 @@ DesktopPopup {
|
||||||
opacity: mainItem.backgroundOpacity
|
opacity: mainItem.backgroundOpacity
|
||||||
// border {
|
// border {
|
||||||
// color: DefaultStyle.grey_400
|
// color: DefaultStyle.grey_400
|
||||||
// width: Math.round(1 * DefaultStyle.dp)
|
// width: Utils.getSizeWithScreenRatio(1)
|
||||||
// }
|
// }
|
||||||
}
|
}
|
||||||
MultiEffect {
|
MultiEffect {
|
||||||
|
|
|
||||||
|
|
@ -3,15 +3,16 @@ import QtQuick.Layouts
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
Notification {
|
Notification {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
backgroundColor: DefaultStyle.grey_600
|
backgroundColor: DefaultStyle.grey_600
|
||||||
backgroundOpacity: 0.8
|
backgroundOpacity: 0.8
|
||||||
overriddenWidth: Math.round(400 * DefaultStyle.dp)
|
overriddenWidth: Utils.getSizeWithScreenRatio(400)
|
||||||
overriddenHeight: content.height
|
overriddenHeight: content.height
|
||||||
|
|
||||||
readonly property var call: notificationData && notificationData.call
|
readonly property var call: notificationData && notificationData.call
|
||||||
|
|
@ -32,41 +33,41 @@ Notification {
|
||||||
Popup {
|
Popup {
|
||||||
id: content
|
id: content
|
||||||
visible: mainItem.visible
|
visible: mainItem.visible
|
||||||
leftPadding: Math.round(32 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
rightPadding: Math.round(32 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
topPadding: Math.round(9 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(9)
|
||||||
bottomPadding: Math.round(18 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
anchors.centerIn: parent
|
anchors.centerIn: parent
|
||||||
background: Item{}
|
background: Item{}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
anchors.verticalCenter: parent.verticalCenter
|
anchors.verticalCenter: parent.verticalCenter
|
||||||
spacing: Math.round(9 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(9)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(4 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(4)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: Math.round(12 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(12)
|
||||||
Layout.preferredHeight: Math.round(12 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(12)
|
||||||
source: AppIcons.logo
|
source: AppIcons.logo
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: "Linphone"
|
text: "Linphone"
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Typography.b3.weight
|
weight: Typography.b3.weight
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(17 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(17)
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(14 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(14)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(60 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(60)
|
||||||
Layout.preferredHeight: Math.round(60 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(60)
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
call: mainItem.call
|
call: mainItem.call
|
||||||
displayNameVal: mainItem.displayName
|
displayNameVal: mainItem.displayName
|
||||||
|
|
@ -84,7 +85,7 @@ Notification {
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Typography.b3.weight
|
weight: Typography.b3.weight
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
|
|
@ -95,8 +96,8 @@ Notification {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(14 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
weight: Math.round(500 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(500)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -104,19 +105,19 @@ Notification {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.alignment: Qt.AlignHCenter
|
Layout.alignment: Qt.AlignHCenter
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
spacing: Math.round(26 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(26)
|
||||||
Button {
|
Button {
|
||||||
spacing: Math.round(6 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(6)
|
||||||
style: ButtonStyle.phoneGreen
|
style: ButtonStyle.phoneGreen
|
||||||
Layout.preferredWidth: Math.round(118 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(118)
|
||||||
Layout.preferredHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
asynchronous: false
|
asynchronous: false
|
||||||
icon.width: Math.round(19 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(19)
|
||||||
icon.height: Math.round(19 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(19)
|
||||||
//: "Accepter"
|
//: "Accepter"
|
||||||
text: qsTr("dialog_accept")
|
text: qsTr("dialog_accept")
|
||||||
textSize: Math.round(14 * DefaultStyle.dp)
|
textSize: Utils.getSizeWithScreenRatio(14)
|
||||||
textWeight: Math.round(500 * DefaultStyle.dp)
|
textWeight: Utils.getSizeWithScreenRatio(500)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
console.debug("[NotificationReceivedCall] Accept click")
|
console.debug("[NotificationReceivedCall] Accept click")
|
||||||
UtilsCpp.openCallsWindow(mainItem.call)
|
UtilsCpp.openCallsWindow(mainItem.call)
|
||||||
|
|
@ -124,17 +125,17 @@ Notification {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
spacing: Math.round(6 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(6)
|
||||||
style: ButtonStyle.phoneRed
|
style: ButtonStyle.phoneRed
|
||||||
Layout.preferredWidth: Math.round(118 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(118)
|
||||||
Layout.preferredHeight: Math.round(32 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(32)
|
||||||
asynchronous: false
|
asynchronous: false
|
||||||
icon.width: Math.round(19 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(19)
|
||||||
icon.height: Math.round(19 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(19)
|
||||||
//: "Refuser
|
//: "Refuser
|
||||||
text: qsTr("dialog_deny")
|
text: qsTr("dialog_deny")
|
||||||
textSize: Math.round(14 * DefaultStyle.dp)
|
textSize: Utils.getSizeWithScreenRatio(14)
|
||||||
textWeight: Math.round(500 * DefaultStyle.dp)
|
textWeight: Utils.getSizeWithScreenRatio(500)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
console.debug("[NotificationReceivedCall] Decline click")
|
console.debug("[NotificationReceivedCall] Decline click")
|
||||||
mainItem.call.core.lDecline()
|
mainItem.call.core.lDecline()
|
||||||
|
|
|
||||||
|
|
@ -4,15 +4,16 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import QtQuick.Controls as Control
|
import QtQuick.Controls as Control
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// =============================================================================
|
// =============================================================================
|
||||||
|
|
||||||
Notification {
|
Notification {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
radius: Math.round(10 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(10)
|
||||||
backgroundColor: DefaultStyle.grey_600
|
backgroundColor: DefaultStyle.grey_600
|
||||||
backgroundOpacity: 0.8
|
backgroundOpacity: 0.8
|
||||||
overriddenWidth: Math.round(400 * DefaultStyle.dp)
|
overriddenWidth: Utils.getSizeWithScreenRatio(400)
|
||||||
overriddenHeight: content.height
|
overriddenHeight: content.height
|
||||||
|
|
||||||
property var chat: notificationData ? notificationData.chat : null
|
property var chat: notificationData ? notificationData.chat : null
|
||||||
|
|
@ -35,27 +36,27 @@ Notification {
|
||||||
id: content
|
id: content
|
||||||
visible: mainItem.visible
|
visible: mainItem.visible
|
||||||
width: parent.width
|
width: parent.width
|
||||||
leftPadding: Math.round(18 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
rightPadding: Math.round(18 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
topPadding: Math.round(32 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
bottomPadding: Math.round(18 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
background: Item {
|
background: Item {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
RowLayout {
|
RowLayout {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.topMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
spacing: Math.round(4 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(4)
|
||||||
Image {
|
Image {
|
||||||
Layout.preferredWidth: Math.round(12 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(12)
|
||||||
Layout.preferredHeight: Math.round(12 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(12)
|
||||||
source: AppIcons.logo
|
source: AppIcons.logo
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: "Linphone"
|
text: "Linphone"
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(12 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
weight: Typography.b3.weight
|
weight: Typography.b3.weight
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
|
|
@ -64,16 +65,16 @@ Notification {
|
||||||
Button {
|
Button {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.topMargin: Math.round(9 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(9)
|
||||||
anchors.rightMargin: Math.round(12 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(12)
|
||||||
padding: 0
|
padding: 0
|
||||||
z: mousearea.z + 1
|
z: mousearea.z + 1
|
||||||
background: Item{anchors.fill: parent}
|
background: Item{anchors.fill: parent}
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
width: Math.round(14 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(14)
|
||||||
height: Math.round(14 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(14)
|
||||||
icon.width: Math.round(14 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(14)
|
||||||
icon.height: Math.round(14 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(14)
|
||||||
contentImageColor: DefaultStyle.grey_0
|
contentImageColor: DefaultStyle.grey_0
|
||||||
onPressed: {
|
onPressed: {
|
||||||
mainItem.close()
|
mainItem.close()
|
||||||
|
|
@ -89,12 +90,12 @@ Notification {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(9 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(9)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(14 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(14)
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(60 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(60)
|
||||||
Layout.preferredHeight: Math.round(60 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(60)
|
||||||
// Layout.alignment: Qt.AlignHCenter
|
// Layout.alignment: Qt.AlignHCenter
|
||||||
property var contactObj: UtilsCpp.findFriendByAddress(mainItem.remoteAddress)
|
property var contactObj: UtilsCpp.findFriendByAddress(mainItem.remoteAddress)
|
||||||
contact: contactObj?.value || null
|
contact: contactObj?.value || null
|
||||||
|
|
|
||||||
|
|
@ -1,16 +1,17 @@
|
||||||
import QtQuick
|
import QtQuick
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
// width: Math.round(269 * DefaultStyle.dp)
|
// width: Utils.getSizeWithScreenRatio(269)
|
||||||
y: -height
|
y: -height
|
||||||
z: 1
|
z: 1
|
||||||
topPadding: Math.round(8 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(8)
|
||||||
bottomPadding: Math.round(8 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(8)
|
||||||
leftPadding: Math.round(37 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(37)
|
||||||
rightPadding: Math.round(37 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(37)
|
||||||
anchors.horizontalCenter: parent.horizontalCenter
|
anchors.horizontalCenter: parent.horizontalCenter
|
||||||
clip: true
|
clip: true
|
||||||
|
|
||||||
|
|
@ -41,15 +42,15 @@ Control.Control {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
border.color: mainItem.contentColor
|
border.color: mainItem.contentColor
|
||||||
border.width: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
border.width: Utils.getSizeWithScreenRatio(1)
|
||||||
radius: Math.round(50 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(50)
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
Image {
|
Image {
|
||||||
visible: mainItem.imageSource != undefined
|
visible: mainItem.imageSource != undefined
|
||||||
source: mainItem.imageSource
|
source: mainItem.imageSource
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
|
|
@ -58,7 +59,7 @@ Control.Control {
|
||||||
text: mainItem.text
|
text: mainItem.text
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(14 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -5,14 +5,15 @@ import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.Popup {
|
Control.Popup {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
closePolicy: Control.Popup.CloseOnEscape
|
closePolicy: Control.Popup.CloseOnEscape
|
||||||
leftPadding: Math.round(72 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(72)
|
||||||
rightPadding: Math.round(72 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(72)
|
||||||
topPadding: Math.round(41 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(41)
|
||||||
bottomPadding: Math.round(18 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(18)
|
||||||
property bool closeButtonVisible: true
|
property bool closeButtonVisible: true
|
||||||
property bool roundedBottom: false
|
property bool roundedBottom: false
|
||||||
property bool lastRowVisible: true
|
property bool lastRowVisible: true
|
||||||
|
|
@ -29,7 +30,7 @@ Control.Popup {
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: parent.height
|
height: parent.height
|
||||||
color: DefaultStyle.grey_100
|
color: DefaultStyle.grey_100
|
||||||
radius: Math.round(20 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(20)
|
||||||
}
|
}
|
||||||
MultiEffect {
|
MultiEffect {
|
||||||
id: effect
|
id: effect
|
||||||
|
|
@ -57,11 +58,11 @@ Control.Popup {
|
||||||
visible: mainItem.closeButtonVisible
|
visible: mainItem.closeButtonVisible
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.topMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
anchors.rightMargin: Math.round(10 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
onClicked: mainItem.close()
|
onClicked: mainItem.close()
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -3,12 +3,13 @@ import QtQuick.Controls.Basic as Control
|
||||||
import QtQuick.Effects
|
import QtQuick.Effects
|
||||||
import Linphone
|
import Linphone
|
||||||
import CustomControls 1.0
|
import CustomControls 1.0
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
Control.Popup{
|
Control.Popup{
|
||||||
id: mainItem
|
id: mainItem
|
||||||
padding: 0
|
padding: 0
|
||||||
property color underlineColor : DefaultStyle.main1_500_main
|
property color underlineColor : DefaultStyle.main1_500_main
|
||||||
property real radius: Math.round(16 * DefaultStyle.dp)
|
property real radius: Utils.getSizeWithScreenRatio(16)
|
||||||
property bool hovered: mouseArea.containsMouse
|
property bool hovered: mouseArea.containsMouse
|
||||||
property bool keyboardFocus: FocusHelper.keyboardFocus
|
property bool keyboardFocus: FocusHelper.keyboardFocus
|
||||||
|
|
||||||
|
|
@ -16,7 +17,7 @@ Control.Popup{
|
||||||
Rectangle {
|
Rectangle {
|
||||||
visible: mainItem.underlineColor != undefined
|
visible: mainItem.underlineColor != undefined
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
height: mainItem.height + Math.round(2 * DefaultStyle.dp)
|
height: mainItem.height +Utils.getSizeWithScreenRatio(2)
|
||||||
color: mainItem.underlineColor
|
color: mainItem.underlineColor
|
||||||
radius: mainItem.radius
|
radius: mainItem.radius
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -871,10 +871,9 @@ function codepointFromFilename(filename) {
|
||||||
// -----------------------------------------------------------------------------
|
// -----------------------------------------------------------------------------
|
||||||
|
|
||||||
function getSizeWithScreenRatio(size){
|
function getSizeWithScreenRatio(size){
|
||||||
if (size == 0) {
|
return (size == 0)
|
||||||
return size;
|
? 0
|
||||||
}
|
: size > 0
|
||||||
return size > 0
|
|
||||||
? Math.max(Math.round(size * Linphone.DefaultStyle.dp), 1)
|
? Math.max(Math.round(size * Linphone.DefaultStyle.dp), 1)
|
||||||
: Math.min(Math.round(size * Linphone.DefaultStyle.dp), -1);
|
: Math.min(Math.round(size * Linphone.DefaultStyle.dp), -1);
|
||||||
}
|
}
|
||||||
|
|
@ -3,6 +3,7 @@ import QtQuick.Layouts
|
||||||
import QtQuick.Controls.Basic as Control
|
import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
// Snippet
|
// Snippet
|
||||||
Window {
|
Window {
|
||||||
|
|
@ -129,7 +130,7 @@ Window {
|
||||||
TextField {
|
TextField {
|
||||||
id: usernameToCall
|
id: usernameToCall
|
||||||
label: "Username to call"
|
label: "Username to call"
|
||||||
Layout.preferredWidth: Math.round(250 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(250)
|
||||||
}
|
}
|
||||||
Button{
|
Button{
|
||||||
text: 'Call'
|
text: 'Call'
|
||||||
|
|
|
||||||
|
|
@ -8,6 +8,7 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope {
|
FocusScope {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -70,27 +71,27 @@ FocusScope {
|
||||||
panelColor: DefaultStyle.grey_0
|
panelColor: DefaultStyle.grey_0
|
||||||
header.visible: !mainItem.call
|
header.visible: !mainItem.call
|
||||||
clip: true
|
clip: true
|
||||||
header.leftPadding: Math.round(32 * DefaultStyle.dp)
|
header.leftPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
header.rightPadding: Math.round(32 * DefaultStyle.dp)
|
header.rightPadding: Utils.getSizeWithScreenRatio(32)
|
||||||
header.topPadding: Math.round(6 * DefaultStyle.dp)
|
header.topPadding: Utils.getSizeWithScreenRatio(6)
|
||||||
header.bottomPadding: searchBarLayout.visible ? Math.round(3 * DefaultStyle.dp) : Math.round(6 * DefaultStyle.dp)
|
header.bottomPadding: Utils.getSizeWithScreenRatio(searchBarLayout.visible ? 3 : 6)
|
||||||
|
|
||||||
header.contentItem: ColumnLayout {
|
header.contentItem: ColumnLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.leftMargin: mainItem.call ? 0 : Math.round(31 * DefaultStyle.dp)
|
Layout.leftMargin: mainItem.call ? 0 : Utils.getSizeWithScreenRatio(31)
|
||||||
Layout.rightMargin: Math.round(41 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(41)
|
||||||
spacing: searchBarLayout.visible ? Math.round(9 * DefaultStyle.dp) : 0
|
spacing: searchBarLayout.visible ? Utils.getSizeWithScreenRatio(9) : 0
|
||||||
RowLayout {
|
RowLayout {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: chatHeader
|
id: chatHeader
|
||||||
spacing: Math.round(12 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(12)
|
||||||
Avatar {
|
Avatar {
|
||||||
property var contactObj: mainItem.chat ? UtilsCpp.findFriendByAddress(mainItem.chat?.core.peerAddress) : null
|
property var contactObj: mainItem.chat ? UtilsCpp.findFriendByAddress(mainItem.chat?.core.peerAddress) : null
|
||||||
contact: contactObj?.value || null
|
contact: contactObj?.value || null
|
||||||
displayNameVal: mainItem.chat?.core.avatarUri
|
displayNameVal: mainItem.chat?.core.avatarUri
|
||||||
secured: mainItem.chat && mainItem.chat.core.isSecured
|
secured: mainItem.chat && mainItem.chat.core.isSecured
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
text: mainItem.chat?.core.title || ""
|
text: mainItem.chat?.core.title || ""
|
||||||
|
|
@ -98,16 +99,16 @@ FocusScope {
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
font {
|
font {
|
||||||
pixelSize: Typography.h4.pixelSize
|
pixelSize: Typography.h4.pixelSize
|
||||||
weight: Math.round(400 * DefaultStyle.dp)
|
weight: Utils.getSizeWithScreenRatio(400)
|
||||||
capitalization: Font.Capitalize
|
capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
visible: mainItem.chat != undefined && mainItem.chat.core.isBasic
|
visible: mainItem.chat != undefined && mainItem.chat.core.isBasic
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
Layout.preferredWidth: visible ? 14 * DefaultStyle.dp : 0
|
Layout.preferredWidth: visible ? Utils.getSizeWithScreenRatio(14) : 0
|
||||||
Layout.preferredHeight: 14 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(14)
|
||||||
colorizationColor: DefaultStyle.warning_700
|
colorizationColor: DefaultStyle.warning_700
|
||||||
imageSource: AppIcons.lockSimpleOpen
|
imageSource: AppIcons.lockSimpleOpen
|
||||||
}
|
}
|
||||||
|
|
@ -124,16 +125,16 @@ FocusScope {
|
||||||
}
|
}
|
||||||
EffectImage {
|
EffectImage {
|
||||||
visible: mainItem.chat?.core.muted || false
|
visible: mainItem.chat?.core.muted || false
|
||||||
Layout.preferredWidth: 20 * DefaultStyle.dp
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.alignment: Qt.AlignVCenter
|
Layout.alignment: Qt.AlignVCenter
|
||||||
Layout.preferredHeight: 20 * DefaultStyle.dp
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(20)
|
||||||
colorizationColor: DefaultStyle.main1_500_main
|
colorizationColor: DefaultStyle.main1_500_main
|
||||||
imageSource: AppIcons.bellSlash
|
imageSource: AppIcons.bellSlash
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Item{Layout.fillWidth: true}
|
Item{Layout.fillWidth: true}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
RoundButton {
|
RoundButton {
|
||||||
visible: !mainItem.call
|
visible: !mainItem.call
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
|
|
@ -185,8 +186,8 @@ FocusScope {
|
||||||
if(!visible) chatMessagesSearchBar.clearText()
|
if(!visible) chatMessagesSearchBar.clearText()
|
||||||
else chatMessagesSearchBar.forceActiveFocus()
|
else chatMessagesSearchBar.forceActiveFocus()
|
||||||
}
|
}
|
||||||
spacing: Math.round(50 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(50)
|
||||||
height: Math.round(65 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(65)
|
||||||
Connections {
|
Connections {
|
||||||
target: mainItem
|
target: mainItem
|
||||||
function onChatChanged() {searchBarLayout.visible = false}
|
function onChatChanged() {searchBarLayout.visible = false}
|
||||||
|
|
@ -194,7 +195,7 @@ FocusScope {
|
||||||
SearchBar {
|
SearchBar {
|
||||||
id: chatMessagesSearchBar
|
id: chatMessagesSearchBar
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.rightMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
property ChatMessageGui messageFound
|
property ChatMessageGui messageFound
|
||||||
delaySearch: false
|
delaySearch: false
|
||||||
Keys.onPressed: (event) => {
|
Keys.onPressed: (event) => {
|
||||||
|
|
@ -217,7 +218,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
RoundButton {
|
RoundButton {
|
||||||
icon.source: AppIcons.upArrow
|
icon.source: AppIcons.upArrow
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
|
|
@ -241,7 +242,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
RoundButton {
|
RoundButton {
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
Layout.rightMargin: Math.round(20 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
onClicked: {
|
onClicked: {
|
||||||
chatMessagesListView.filterText = ""
|
chatMessagesListView.filterText = ""
|
||||||
searchBarLayout.visible = false
|
searchBarLayout.visible = false
|
||||||
|
|
@ -257,7 +258,7 @@ FocusScope {
|
||||||
handle: Rectangle {
|
handle: Rectangle {
|
||||||
visible: !mainItem.chat?.core.isReadOnly
|
visible: !mainItem.chat?.core.isReadOnly
|
||||||
enabled: visible
|
enabled: visible
|
||||||
implicitHeight: Math.round(8 * DefaultStyle.dp)
|
implicitHeight: Utils.getSizeWithScreenRatio(8)
|
||||||
color: Control.SplitHandle.hovered ? DefaultStyle.grey_200 : DefaultStyle.grey_100
|
color: Control.SplitHandle.hovered ? DefaultStyle.grey_200 : DefaultStyle.grey_100
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
|
|
@ -273,8 +274,8 @@ FocusScope {
|
||||||
width: parent.width - anchors.leftMargin - anchors.rightMargin
|
width: parent.width - anchors.leftMargin - anchors.rightMargin
|
||||||
chat: mainItem.chat
|
chat: mainItem.chat
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.leftMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
anchors.rightMargin: Math.round(18 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
Control.ScrollBar.vertical: scrollbar
|
Control.ScrollBar.vertical: scrollbar
|
||||||
onShowReactionsForMessageRequested: (chatMessage) => {
|
onShowReactionsForMessageRequested: (chatMessage) => {
|
||||||
mainItem.chatMessage = chatMessage
|
mainItem.chatMessage = chatMessage
|
||||||
|
|
@ -303,13 +304,13 @@ FocusScope {
|
||||||
anchors.top: chatMessagesListView.top
|
anchors.top: chatMessagesListView.top
|
||||||
anchors.bottom: chatMessagesListView.bottom
|
anchors.bottom: chatMessagesListView.bottom
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.rightMargin: Math.round(5 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(5)
|
||||||
policy: Control.ScrollBar.AsNeeded
|
policy: Control.ScrollBar.AsNeeded
|
||||||
}
|
}
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: participantListPopup
|
id: participantListPopup
|
||||||
width: parent.width
|
width: parent.width
|
||||||
height: Math.min(participantInfoList.height, Math.round(200 * DefaultStyle.dp))
|
height: Math.min(participantInfoList.height, Utils.getSizeWithScreenRatio(200))
|
||||||
visible: false
|
visible: false
|
||||||
anchors.bottom: chatMessagesListView.bottom
|
anchors.bottom: chatMessagesListView.bottom
|
||||||
anchors.left: chatMessagesListView.left
|
anchors.left: chatMessagesListView.left
|
||||||
|
|
@ -323,7 +324,7 @@ FocusScope {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
radius: Math.round(20 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(20)
|
||||||
height: parent.height
|
height: parent.height
|
||||||
}
|
}
|
||||||
MultiEffect {
|
MultiEffect {
|
||||||
|
|
@ -360,10 +361,10 @@ FocusScope {
|
||||||
visible: selectedFiles.count > 0 || mainItem.replyingToMessage
|
visible: selectedFiles.count > 0 || mainItem.replyingToMessage
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: implicitHeight
|
Layout.preferredHeight: implicitHeight
|
||||||
topPadding: Math.round(12 * DefaultStyle.dp)
|
topPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
bottomPadding: Math.round(12 * DefaultStyle.dp)
|
bottomPadding: Utils.getSizeWithScreenRatio(12)
|
||||||
leftPadding: Math.round(19 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(19)
|
||||||
rightPadding: Math.round(19 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(19)
|
||||||
|
|
||||||
Button {
|
Button {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
|
@ -382,7 +383,7 @@ FocusScope {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
color: DefaultStyle.grey_0
|
color: DefaultStyle.grey_0
|
||||||
border.color: DefaultStyle.main2_100
|
border.color: DefaultStyle.main2_100
|
||||||
border.width: Math.round(2 * DefaultStyle.dp)
|
border.width: Utils.getSizeWithScreenRatio(2)
|
||||||
height: parent.height / 2
|
height: parent.height / 2
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
|
|
@ -396,7 +397,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
contentItem: ColumnLayout {
|
contentItem: ColumnLayout {
|
||||||
spacing: Math.round(5 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(5)
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: replyLayout
|
id: replyLayout
|
||||||
spacing: 0
|
spacing: 0
|
||||||
|
|
@ -425,38 +426,38 @@ FocusScope {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
visible: replyLayout.visible && selectedFiles.visible
|
visible: replyLayout.visible && selectedFiles.visible
|
||||||
color: DefaultStyle.main2_300
|
color: DefaultStyle.main2_300
|
||||||
Layout.preferredHeight: Math.max(1, Math.round(1 * DefaultStyle.dp))
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
}
|
}
|
||||||
ListView {
|
ListView {
|
||||||
id: selectedFiles
|
id: selectedFiles
|
||||||
orientation: ListView.Horizontal
|
orientation: ListView.Horizontal
|
||||||
visible: count > 0
|
visible: count > 0
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(104 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(104)
|
||||||
model: ChatMessageContentProxy {
|
model: ChatMessageContentProxy {
|
||||||
id: contents
|
id: contents
|
||||||
filterType: ChatMessageContentProxy.FilterContentType.File
|
filterType: ChatMessageContentProxy.FilterContentType.File
|
||||||
}
|
}
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
width: Math.round(80 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(80)
|
||||||
height: Math.round(80 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(80)
|
||||||
FileView {
|
FileView {
|
||||||
contentGui: modelData
|
contentGui: modelData
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
width: Math.round(69 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(69)
|
||||||
height: Math.round(69 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(69)
|
||||||
}
|
}
|
||||||
RoundButton {
|
RoundButton {
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
icon.width: Math.round(12 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(12)
|
||||||
icon.height: Math.round(12 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(12)
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
style: ButtonStyle.numericPad
|
style: ButtonStyle.numericPad
|
||||||
shadowEnabled: true
|
shadowEnabled: true
|
||||||
padding: Math.round(3 * DefaultStyle.dp)
|
padding: Utils.getSizeWithScreenRatio(3)
|
||||||
onClicked: contents.removeContent(modelData)
|
onClicked: contents.removeContent(modelData)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -475,7 +476,7 @@ FocusScope {
|
||||||
ChatDroppableTextArea {
|
ChatDroppableTextArea {
|
||||||
id: messageSender
|
id: messageSender
|
||||||
Control.SplitView.preferredHeight: mainItem.chat?.core.isReadOnly ? 0 : height
|
Control.SplitView.preferredHeight: mainItem.chat?.core.isReadOnly ? 0 : height
|
||||||
Control.SplitView.minimumHeight: mainItem.chat?.core.isReadOnly ? 0 : Math.round(79 * DefaultStyle.dp)
|
Control.SplitView.minimumHeight: mainItem.chat?.core.isReadOnly ? 0 : Utils.getSizeWithScreenRatio(79)
|
||||||
chat: mainItem.chat
|
chat: mainItem.chat
|
||||||
selectedFilesCount: contents.count
|
selectedFilesCount: contents.count
|
||||||
callOngoing: mainItem.call != null
|
callOngoing: mainItem.call != null
|
||||||
|
|
@ -511,14 +512,14 @@ FocusScope {
|
||||||
Rectangle {
|
Rectangle {
|
||||||
visible: detailsPanel.visible
|
visible: detailsPanel.visible
|
||||||
color: DefaultStyle.main2_200
|
color: DefaultStyle.main2_200
|
||||||
Layout.preferredWidth: Math.round(1 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(1)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
}
|
}
|
||||||
Control.Control {
|
Control.Control {
|
||||||
id: detailsPanel
|
id: detailsPanel
|
||||||
visible: false
|
visible: false
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.preferredWidth: Math.round(387 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(387)
|
||||||
onVisibleChanged: if(!visible) {
|
onVisibleChanged: if(!visible) {
|
||||||
contentLoader.panelType = SelectedChatView.PanelType.None
|
contentLoader.panelType = SelectedChatView.PanelType.None
|
||||||
}
|
}
|
||||||
|
|
@ -533,8 +534,8 @@ FocusScope {
|
||||||
property int panelType: SelectedChatView.PanelType.None
|
property int panelType: SelectedChatView.PanelType.None
|
||||||
// anchors.top: parent.top
|
// anchors.top: parent.top
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
anchors.topMargin: Math.round(39 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(39)
|
||||||
anchors.rightMargin: Math.round(15 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
sourceComponent: panelType === SelectedChatView.PanelType.EphemeralSettings
|
sourceComponent: panelType === SelectedChatView.PanelType.EphemeralSettings
|
||||||
? ephemeralSettingsComponent
|
? ephemeralSettingsComponent
|
||||||
: panelType === SelectedChatView.PanelType.MessageReactions
|
: panelType === SelectedChatView.PanelType.MessageReactions
|
||||||
|
|
@ -643,7 +644,7 @@ FocusScope {
|
||||||
mainItem.chatMessage = null
|
mainItem.chatMessage = null
|
||||||
}
|
}
|
||||||
content: ColumnLayout {
|
content: ColumnLayout {
|
||||||
spacing: Math.round(31 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(31)
|
||||||
SearchBar {
|
SearchBar {
|
||||||
id: forwardSearchBar
|
id: forwardSearchBar
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -655,7 +656,7 @@ FocusScope {
|
||||||
// width: parent.width
|
// width: parent.width
|
||||||
// Control.ScrollBar.vertical: ScrollBar {
|
// Control.ScrollBar.vertical: ScrollBar {
|
||||||
// id: scrollbar
|
// id: scrollbar
|
||||||
// topPadding: Math.round(24 * DefaultStyle.dp) // Avoid to be on top of collapse button
|
// topPadding: Utils.getSizeWithScreenRatio(24) // Avoid to be on top of collapse button
|
||||||
// active: true
|
// active: true
|
||||||
// interactive: true
|
// interactive: true
|
||||||
// visible: parent.contentHeight > parent.height
|
// visible: parent.contentHeight > parent.height
|
||||||
|
|
@ -664,8 +665,8 @@ FocusScope {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
// width: parent.width //- scrollbar.width - Math.round(5 * DefaultStyle.dp)
|
// width: parent.width //- scrollbar.width - Utils.getSizeWithScreenRatio(5)
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Text {
|
Text {
|
||||||
//: Conversations
|
//: Conversations
|
||||||
|
|
|
||||||
|
|
@ -5,6 +5,7 @@ import QtQuick.Controls.Basic
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
ColumnLayout{
|
ColumnLayout{
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -33,8 +34,8 @@ ColumnLayout{
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
verticalAlignment: (topTextItem.visible?Text.AlignTop:Text.AlignVCenter)
|
verticalAlignment: (topTextItem.visible?Text.AlignTop:Text.AlignVCenter)
|
||||||
visible: text != ''
|
visible: text != ''
|
||||||
font.weight: Math.round(300 * DefaultStyle.dp)
|
font.weight: Utils.getSizeWithScreenRatio(300)
|
||||||
font.pixelSize: Math.round(12 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(12)
|
||||||
color: DefaultStyle.main2_400
|
color: DefaultStyle.main2_400
|
||||||
text: mainItem.bottomText
|
text: mainItem.bottomText
|
||||||
maximumLineCount: 1
|
maximumLineCount: 1
|
||||||
|
|
|
||||||
|
|
@ -173,7 +173,7 @@ MainRightPanel {
|
||||||
]
|
]
|
||||||
content: Flickable {
|
content: Flickable {
|
||||||
id: editionLayout
|
id: editionLayout
|
||||||
contentWidth: Math.round(Math.min(parent.width, 421 * DefaultStyle.dp))
|
contentWidth: Math.min(parent.width, Utils.getSizeWithScreenRatio(421))
|
||||||
width: parent.width
|
width: parent.width
|
||||||
contentY: 0
|
contentY: 0
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -55,7 +55,7 @@ LoginLayout {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
visible: !SettingsCpp.assistantHideCreateAccount
|
visible: !SettingsCpp.assistantHideCreateAccount
|
||||||
spacing: Utils.getSizeWithScreenRatio(20)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.rightMargin: Math.round(Math.max(10 * DefaultStyle.dp, (51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp))
|
Layout.rightMargin: Math.max(Utils.getSizeWithScreenRatio(10), Utils.getSizeWithScreenRatio(51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))))
|
||||||
|
|
||||||
Text {
|
Text {
|
||||||
Layout.rightMargin: Utils.getSizeWithScreenRatio(15)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
|
|
|
||||||
|
|
@ -15,14 +15,14 @@ LoginLayout {
|
||||||
|
|
||||||
titleContent: [
|
titleContent: [
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Layout.leftMargin: Math.round(119 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(119)
|
||||||
visible: !SettingsCpp.assistantHideThirdPartyAccount
|
visible: !SettingsCpp.assistantHideThirdPartyAccount
|
||||||
spacing: Math.round(21 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(21)
|
||||||
Button {
|
Button {
|
||||||
id: backButton
|
id: backButton
|
||||||
visible: mainItem.showBackButton
|
visible: mainItem.showBackButton
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.source: AppIcons.leftArrow
|
icon.source: AppIcons.leftArrow
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -35,8 +35,8 @@ LoginLayout {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.profile
|
imageSource: AppIcons.profile
|
||||||
Layout.preferredHeight: Math.round(34 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(34)
|
||||||
Layout.preferredWidth: Math.round(34 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(34)
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -54,10 +54,10 @@ LoginLayout {
|
||||||
},
|
},
|
||||||
RowLayout {
|
RowLayout {
|
||||||
visible: !SettingsCpp.assistantHideCreateAccount
|
visible: !SettingsCpp.assistantHideCreateAccount
|
||||||
Layout.rightMargin: Math.round(51 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(51)
|
||||||
spacing: Math.round(20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
Text {
|
Text {
|
||||||
Layout.rightMargin: Math.round(15 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
//: Pas encore de compte ?
|
//: Pas encore de compte ?
|
||||||
text: qsTr("assistant_no_account_yet")
|
text: qsTr("assistant_no_account_yet")
|
||||||
font {
|
font {
|
||||||
|
|
@ -81,7 +81,7 @@ LoginLayout {
|
||||||
Component {
|
Component {
|
||||||
id: firstItem
|
id: firstItem
|
||||||
Flickable {
|
Flickable {
|
||||||
width: Math.round(361 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(361)
|
||||||
contentWidth: content.implicitWidth
|
contentWidth: content.implicitWidth
|
||||||
contentHeight: content.implicitHeight
|
contentHeight: content.implicitHeight
|
||||||
clip: true
|
clip: true
|
||||||
|
|
@ -93,11 +93,11 @@ LoginLayout {
|
||||||
id: content
|
id: content
|
||||||
// rightMargin is negative margin
|
// rightMargin is negative margin
|
||||||
width: parent.width - scrollbar.width*2
|
width: parent.width - scrollbar.width*2
|
||||||
spacing: Math.round(85 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(85)
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: 0
|
spacing: 0
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(28 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(28)
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredWidth: rootStackView.width
|
Layout.preferredWidth: rootStackView.width
|
||||||
|
|
@ -113,7 +113,7 @@ LoginLayout {
|
||||||
SmallButton {
|
SmallButton {
|
||||||
id: openLinkButton
|
id: openLinkButton
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
Layout.topMargin: Math.round(18 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(18)
|
||||||
text: "linphone.org/contact"
|
text: "linphone.org/contact"
|
||||||
style: ButtonStyle.secondary
|
style: ButtonStyle.secondary
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -124,7 +124,7 @@ LoginLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
BigButton {
|
BigButton {
|
||||||
id: createAccountButton
|
id: createAccountButton
|
||||||
style: ButtonStyle.secondary
|
style: ButtonStyle.secondary
|
||||||
|
|
@ -160,7 +160,7 @@ LoginLayout {
|
||||||
id: secondItem
|
id: secondItem
|
||||||
Flickable {
|
Flickable {
|
||||||
id: formFlickable
|
id: formFlickable
|
||||||
width: Math.round(770 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(770)
|
||||||
contentWidth: content.implicitWidth
|
contentWidth: content.implicitWidth
|
||||||
contentHeight: content.implicitHeight
|
contentHeight: content.implicitHeight
|
||||||
clip: true
|
clip: true
|
||||||
|
|
@ -171,19 +171,19 @@ LoginLayout {
|
||||||
RowLayout {
|
RowLayout {
|
||||||
id: content
|
id: content
|
||||||
width: formFlickable.width - scrollbar.width*2
|
width: formFlickable.width - scrollbar.width*2
|
||||||
spacing: Math.round(50 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(50)
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(2 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(2)
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(22 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(22)
|
||||||
// alignment item
|
// alignment item
|
||||||
Item {
|
Item {
|
||||||
Layout.preferredHeight: advancedParametersTitle.implicitHeight
|
Layout.preferredHeight: advancedParametersTitle.implicitHeight
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
FormItemLayout {
|
FormItemLayout {
|
||||||
id: username
|
id: username
|
||||||
//: "Nom d'utilisateur"
|
//: "Nom d'utilisateur"
|
||||||
|
|
@ -194,7 +194,7 @@ LoginLayout {
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: usernameEdit
|
id: usernameEdit
|
||||||
isError: username.errorTextVisible || (LoginPageCpp.badIds && errorText.isVisible)
|
isError: username.errorTextVisible || (LoginPageCpp.badIds && errorText.isVisible)
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
KeyNavigation.down: passwordEdit
|
KeyNavigation.down: passwordEdit
|
||||||
//: "%1 mandatory"
|
//: "%1 mandatory"
|
||||||
Accessible.name: qsTr("mandatory_field_accessible_name").arg(qsTr("username"))
|
Accessible.name: qsTr("mandatory_field_accessible_name").arg(qsTr("username"))
|
||||||
|
|
@ -210,7 +210,7 @@ LoginLayout {
|
||||||
id: passwordEdit
|
id: passwordEdit
|
||||||
isError: password.errorTextVisible || (LoginPageCpp.badIds && errorText.isVisible)
|
isError: password.errorTextVisible || (LoginPageCpp.badIds && errorText.isVisible)
|
||||||
hidden: true
|
hidden: true
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
KeyNavigation.up: usernameEdit
|
KeyNavigation.up: usernameEdit
|
||||||
KeyNavigation.down: domainEdit
|
KeyNavigation.down: domainEdit
|
||||||
Accessible.name: qsTr("password")
|
Accessible.name: qsTr("password")
|
||||||
|
|
@ -227,7 +227,7 @@ LoginLayout {
|
||||||
id: domainEdit
|
id: domainEdit
|
||||||
isError: domain.errorTextVisible
|
isError: domain.errorTextVisible
|
||||||
initialText: SettingsCpp.assistantThirdPartySipAccountDomain
|
initialText: SettingsCpp.assistantThirdPartySipAccountDomain
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
KeyNavigation.up: passwordEdit
|
KeyNavigation.up: passwordEdit
|
||||||
KeyNavigation.down: displayName
|
KeyNavigation.down: displayName
|
||||||
//: "%1 mandatory"
|
//: "%1 mandatory"
|
||||||
|
|
@ -246,7 +246,7 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: displayName
|
id: displayName
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
KeyNavigation.up: domainEdit
|
KeyNavigation.up: domainEdit
|
||||||
KeyNavigation.down: transportCbox
|
KeyNavigation.down: transportCbox
|
||||||
Accessible.name: qsTr("sip_address_display_name")
|
Accessible.name: qsTr("sip_address_display_name")
|
||||||
|
|
@ -258,8 +258,8 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
contentItem: ComboBox {
|
contentItem: ComboBox {
|
||||||
id: transportCbox
|
id: transportCbox
|
||||||
height: Math.round(49 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(49)
|
||||||
width: Math.round(360 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(360)
|
||||||
textRole: "text"
|
textRole: "text"
|
||||||
valueRole: "value"
|
valueRole: "value"
|
||||||
model: [
|
model: [
|
||||||
|
|
@ -292,7 +292,7 @@ LoginLayout {
|
||||||
|
|
||||||
BigButton {
|
BigButton {
|
||||||
id: connectionButton
|
id: connectionButton
|
||||||
Layout.topMargin: Math.round(15 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
style: ButtonStyle.main
|
style: ButtonStyle.main
|
||||||
property Item tabTarget
|
property Item tabTarget
|
||||||
Accessible.name: qsTr("assistant_account_login")
|
Accessible.name: qsTr("assistant_account_login")
|
||||||
|
|
@ -315,7 +315,7 @@ LoginLayout {
|
||||||
implicitHeight: parent.height
|
implicitHeight: parent.height
|
||||||
Layout.alignment: Qt.AlignCenter
|
Layout.alignment: Qt.AlignCenter
|
||||||
indicatorColor: DefaultStyle.grey_0
|
indicatorColor: DefaultStyle.grey_0
|
||||||
indicatorWidth: Math.round(25 * DefaultStyle.dp)
|
indicatorWidth: Utils.getSizeWithScreenRatio(25)
|
||||||
}
|
}
|
||||||
Connections {
|
Connections {
|
||||||
target: LoginPageCpp
|
target: LoginPageCpp
|
||||||
|
|
@ -373,9 +373,9 @@ LoginLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
spacing: Math.round(22 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(22)
|
||||||
Text {
|
Text {
|
||||||
id: advancedParametersTitle
|
id: advancedParametersTitle
|
||||||
//: Advanced parameters
|
//: Advanced parameters
|
||||||
|
|
@ -383,7 +383,7 @@ LoginLayout {
|
||||||
font: Typography.h3m
|
font: Typography.h3m
|
||||||
}
|
}
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
spacing: Math.round(10 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(10)
|
||||||
FormItemLayout {
|
FormItemLayout {
|
||||||
id: outboundProxyUri
|
id: outboundProxyUri
|
||||||
//: "Outbound SIP Proxy URI"
|
//: "Outbound SIP Proxy URI"
|
||||||
|
|
@ -393,7 +393,7 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: outboundProxyUriEdit
|
id: outboundProxyUriEdit
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
Accessible.name: qsTr("login_proxy_server_url")
|
Accessible.name: qsTr("login_proxy_server_url")
|
||||||
KeyNavigation.up: transportCbox
|
KeyNavigation.up: transportCbox
|
||||||
KeyNavigation.down: registrarUriEdit
|
KeyNavigation.down: registrarUriEdit
|
||||||
|
|
@ -406,7 +406,7 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: registrarUriEdit
|
id: registrarUriEdit
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
Accessible.name: qsTr("login_registrar_uri")
|
Accessible.name: qsTr("login_registrar_uri")
|
||||||
KeyNavigation.up: outboundProxyUriEdit
|
KeyNavigation.up: outboundProxyUriEdit
|
||||||
KeyNavigation.down: connectionIdEdit
|
KeyNavigation.down: connectionIdEdit
|
||||||
|
|
@ -419,7 +419,7 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
contentItem: TextField {
|
contentItem: TextField {
|
||||||
id: connectionIdEdit
|
id: connectionIdEdit
|
||||||
Layout.preferredWidth: Math.round(360 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(360)
|
||||||
KeyNavigation.up: registrarUriEdit
|
KeyNavigation.up: registrarUriEdit
|
||||||
Accessible.name: qsTr("login_id")
|
Accessible.name: qsTr("login_id")
|
||||||
}
|
}
|
||||||
|
|
@ -444,9 +444,9 @@ LoginLayout {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
// Layout.leftMargin: Math.round(119 * DefaultStyle.dp)
|
// Layout.leftMargin: Utils.getSizeWithScreenRatio(119)
|
||||||
// anchors.leftMargin: Math.round(119 * DefaultStyle.dp)
|
// anchors.leftMargin: Utils.getSizeWithScreenRatio(119)
|
||||||
// anchors.rightMargin: -8 * DefaultStyle.dp
|
// anchors.rightMargin: - Utils.getSizeWithScreenRatio(8)
|
||||||
},
|
},
|
||||||
Control.StackView {
|
Control.StackView {
|
||||||
id: rootStackView
|
id: rootStackView
|
||||||
|
|
@ -454,24 +454,24 @@ LoginLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.bottom: parent.bottom
|
anchors.bottom: parent.bottom
|
||||||
anchors.leftMargin: Math.round(127 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(127)
|
||||||
width: currentItem ? currentItem.width : 0
|
width: currentItem ? currentItem.width : 0
|
||||||
},
|
},
|
||||||
// Item {
|
// Item {
|
||||||
// id: sipItem
|
// id: sipItem
|
||||||
// // spacing: Math.round(8 * Defaultstyle.dp)
|
// // spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
// anchors.fill: parent
|
// anchors.fill: parent
|
||||||
// anchors.rightMargin: Math.round(50 * DefaultStyle.dp) + image.width
|
// anchors.rightMargin: Utils.getSizeWithScreenRatio(50) + image.width
|
||||||
// },
|
// },
|
||||||
Image {
|
Image {
|
||||||
id: image
|
id: image
|
||||||
z: -1
|
z: -1
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.topMargin: Math.round(129 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(129)
|
||||||
anchors.rightMargin: Math.round(127 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(127)
|
||||||
width: Math.round(395 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(395)
|
||||||
height: Math.round(350 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(350)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
source: AppIcons.loginImage
|
source: AppIcons.loginImage
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -34,7 +34,7 @@ FocusScope {
|
||||||
Layout.preferredHeight: contentHeight
|
Layout.preferredHeight: contentHeight
|
||||||
Layout.maximumHeight: mainItem.height / 3
|
Layout.maximumHeight: mainItem.height / 3
|
||||||
width: mainItem.width
|
width: mainItem.width
|
||||||
cellWidth: Math.round((50 + 18) * DefaultStyle.dp)
|
cellWidth: Utils.getSizeWithScreenRatio((50 + 18))
|
||||||
cellHeight: Utils.getSizeWithScreenRatio(80)
|
cellHeight: Utils.getSizeWithScreenRatio(80)
|
||||||
// columnCount: Math.floor(width/cellWidth)
|
// columnCount: Math.floor(width/cellWidth)
|
||||||
model: mainItem.selectedParticipants
|
model: mainItem.selectedParticipants
|
||||||
|
|
|
||||||
|
|
@ -6,6 +6,7 @@ import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import SettingsCpp
|
import SettingsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
FocusScope {
|
FocusScope {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -16,7 +17,7 @@ FocusScope {
|
||||||
|
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
id: formLayout
|
id: formLayout
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
|
|
@ -29,14 +30,14 @@ FocusScope {
|
||||||
|
|
||||||
RowLayout {
|
RowLayout {
|
||||||
visible: mainItem.isCreation && !SettingsCpp.disableBroadcastFeature
|
visible: mainItem.isCreation && !SettingsCpp.disableBroadcastFeature
|
||||||
Layout.topMargin: Math.round(20 * DefaultStyle.dp)
|
Layout.topMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.bottomMargin: Math.round(20 * DefaultStyle.dp)
|
Layout.bottomMargin: Utils.getSizeWithScreenRatio(20)
|
||||||
spacing: Math.round(18 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(18)
|
||||||
CheckableButton {
|
CheckableButton {
|
||||||
Layout.preferredWidth: Math.round(151 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(151)
|
||||||
icon.source: AppIcons.usersThree
|
icon.source: AppIcons.usersThree
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
enabled: false
|
enabled: false
|
||||||
//: "Réunion"
|
//: "Réunion"
|
||||||
text: qsTr("meeting_schedule_meeting_label")
|
text: qsTr("meeting_schedule_meeting_label")
|
||||||
|
|
@ -45,11 +46,11 @@ FocusScope {
|
||||||
style: ButtonStyle.secondary
|
style: ButtonStyle.secondary
|
||||||
}
|
}
|
||||||
CheckableButton {
|
CheckableButton {
|
||||||
Layout.preferredWidth: Math.round(151 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(151)
|
||||||
enabled: false
|
enabled: false
|
||||||
icon.source: AppIcons.slide
|
icon.source: AppIcons.slide
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
//: "Webinar"
|
//: "Webinar"
|
||||||
text: qsTr("meeting_schedule_broadcast_label")
|
text: qsTr("meeting_schedule_broadcast_label")
|
||||||
autoExclusive: true
|
autoExclusive: true
|
||||||
|
|
@ -60,14 +61,14 @@ FocusScope {
|
||||||
visible: mainItem.isCreation
|
visible: mainItem.isCreation
|
||||||
spacing: formLayout.spacing
|
spacing: formLayout.spacing
|
||||||
content: RowLayout {
|
content: RowLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.usersThree
|
imageSource: AppIcons.usersThree
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
width: Math.round(24 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(24)
|
||||||
height: Math.round(24 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
TextInput {
|
TextInput {
|
||||||
id: confTitle
|
id: confTitle
|
||||||
|
|
@ -79,7 +80,7 @@ FocusScope {
|
||||||
text: conferenceInfoGui.core.subject ? conferenceInfoGui.core.subject : ""
|
text: conferenceInfoGui.core.subject ? conferenceInfoGui.core.subject : ""
|
||||||
color: DefaultStyle.main2_600
|
color: DefaultStyle.main2_600
|
||||||
font {
|
font {
|
||||||
pixelSize: Math.round(20 * DefaultStyle.dp)
|
pixelSize: Utils.getSizeWithScreenRatio(20)
|
||||||
weight: Typography.h3.weight
|
weight: Typography.h3.weight
|
||||||
}
|
}
|
||||||
focus: true
|
focus: true
|
||||||
|
|
@ -100,16 +101,16 @@ FocusScope {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.clock
|
imageSource: AppIcons.clock
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
CalendarComboBox {
|
CalendarComboBox {
|
||||||
id: startDate
|
id: startDate
|
||||||
background.visible: mainItem.isCreation
|
background.visible: mainItem.isCreation
|
||||||
indicator.visible: mainItem.isCreation
|
indicator.visible: mainItem.isCreation
|
||||||
contentText.font.weight: Math.min(Math.round((isCreation ? 700 : 400) * DefaultStyle.dp), 1000)
|
contentText.font.weight: Math.min(Utils.getSizeWithScreenRatio(isCreation ? 700 : 400), 1000)
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
KeyNavigation.up: confTitle
|
KeyNavigation.up: confTitle
|
||||||
KeyNavigation.down: startHour
|
KeyNavigation.down: startHour
|
||||||
onSelectedDateChanged: {
|
onSelectedDateChanged: {
|
||||||
|
|
@ -123,17 +124,17 @@ FocusScope {
|
||||||
},
|
},
|
||||||
RowLayout {
|
RowLayout {
|
||||||
Item {
|
Item {
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
TimeComboBox {
|
TimeComboBox {
|
||||||
id: startHour
|
id: startHour
|
||||||
// indicator.visible: mainItem.isCreation
|
// indicator.visible: mainItem.isCreation
|
||||||
Layout.preferredWidth: Math.round(94 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(94)
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
background.visible: mainItem.isCreation
|
background.visible: mainItem.isCreation
|
||||||
contentText.font.weight: Math.min(Math.round((isCreation ? 700 : 400) * DefaultStyle.dp), 1000)
|
contentText.font.weight: Math.min(Utils.getSizeWithScreenRatio(isCreation ? 700 : 400), 1000)
|
||||||
KeyNavigation.up: startDate
|
KeyNavigation.up: startDate
|
||||||
KeyNavigation.down: timeZoneCbox
|
KeyNavigation.down: timeZoneCbox
|
||||||
KeyNavigation.left: endHour
|
KeyNavigation.left: endHour
|
||||||
|
|
@ -150,10 +151,10 @@ FocusScope {
|
||||||
TimeComboBox {
|
TimeComboBox {
|
||||||
id: endHour
|
id: endHour
|
||||||
// indicator.visible: mainItem.isCreation
|
// indicator.visible: mainItem.isCreation
|
||||||
Layout.preferredWidth: Math.round(94 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(94)
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
background.visible: mainItem.isCreation
|
background.visible: mainItem.isCreation
|
||||||
contentText.font.weight: Math.min(Math.round((isCreation ? 700 : 400) * DefaultStyle.dp), 1000)
|
contentText.font.weight: Math.min(Utils.getSizeWithScreenRatio(isCreation ? 700 : 400), 1000)
|
||||||
onSelectedDateTimeChanged: mainItem.conferenceInfoGui.core.endDateTime = selectedDateTime
|
onSelectedDateTimeChanged: mainItem.conferenceInfoGui.core.endDateTime = selectedDateTime
|
||||||
KeyNavigation.up: startDate
|
KeyNavigation.up: startDate
|
||||||
KeyNavigation.down: timeZoneCbox
|
KeyNavigation.down: timeZoneCbox
|
||||||
|
|
@ -179,10 +180,10 @@ FocusScope {
|
||||||
ComboBox {
|
ComboBox {
|
||||||
id: timeZoneCbox
|
id: timeZoneCbox
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
hoverEnabled: true
|
hoverEnabled: true
|
||||||
oneLine: true
|
oneLine: true
|
||||||
listView.implicitHeight: Math.round(250 * DefaultStyle.dp)
|
listView.implicitHeight: Utils.getSizeWithScreenRatio(250)
|
||||||
constantImageSource: AppIcons.globe
|
constantImageSource: AppIcons.globe
|
||||||
weight: Typography.p2l.weight
|
weight: Typography.p2l.weight
|
||||||
leftMargin: 0
|
leftMargin: 0
|
||||||
|
|
@ -206,20 +207,20 @@ FocusScope {
|
||||||
Section {
|
Section {
|
||||||
spacing: formLayout.spacing
|
spacing: formLayout.spacing
|
||||||
content: RowLayout {
|
content: RowLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.note
|
imageSource: AppIcons.note
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
TextArea {
|
TextArea {
|
||||||
id: descriptionEdit
|
id: descriptionEdit
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredWidth: Math.round(275 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(275)
|
||||||
Layout.preferredHeight: contentHeight
|
Layout.preferredHeight: contentHeight
|
||||||
leftPadding: Math.round(8 * DefaultStyle.dp)
|
leftPadding: Utils.getSizeWithScreenRatio(8)
|
||||||
rightPadding: Math.round(8 * DefaultStyle.dp)
|
rightPadding: Utils.getSizeWithScreenRatio(8)
|
||||||
//: "Ajouter une description"
|
//: "Ajouter une description"
|
||||||
placeholderText: qsTr("meeting_schedule_description_hint")
|
placeholderText: qsTr("meeting_schedule_description_hint")
|
||||||
placeholderTextColor: DefaultStyle.main2_600
|
placeholderTextColor: DefaultStyle.main2_600
|
||||||
|
|
@ -243,7 +244,7 @@ FocusScope {
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: descriptionEdit.hovered || descriptionEdit.activeFocus ? DefaultStyle.grey_100 : "transparent"
|
color: descriptionEdit.hovered || descriptionEdit.activeFocus ? DefaultStyle.grey_100 : "transparent"
|
||||||
radius: Math.round(4 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(4)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -254,20 +255,20 @@ FocusScope {
|
||||||
Button {
|
Button {
|
||||||
id: addParticipantsButton
|
id: addParticipantsButton
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: Math.round(30 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(30)
|
||||||
leftPadding: 0
|
leftPadding: 0
|
||||||
background: Rectangle {
|
background: Rectangle {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
color: addParticipantsButton.hovered || addParticipantsButton.activeFocus ? DefaultStyle.grey_100 : "transparent"
|
color: addParticipantsButton.hovered || addParticipantsButton.activeFocus ? DefaultStyle.grey_100 : "transparent"
|
||||||
radius: Math.round(4 * DefaultStyle.dp)
|
radius: Utils.getSizeWithScreenRatio(4)
|
||||||
}
|
}
|
||||||
contentItem: RowLayout {
|
contentItem: RowLayout {
|
||||||
spacing: Math.round(8 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(8)
|
||||||
EffectImage {
|
EffectImage {
|
||||||
imageSource: AppIcons.usersThree
|
imageSource: AppIcons.usersThree
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
|
|
@ -285,7 +286,7 @@ FocusScope {
|
||||||
id: participantList
|
id: participantList
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
Layout.preferredHeight: contentHeight
|
Layout.preferredHeight: contentHeight
|
||||||
Layout.maximumHeight: Math.round(250 * DefaultStyle.dp)
|
Layout.maximumHeight: Utils.getSizeWithScreenRatio(250)
|
||||||
clip: true
|
clip: true
|
||||||
model: mainItem.conferenceInfoGui.core.participants
|
model: mainItem.conferenceInfoGui.core.participants
|
||||||
Control.ScrollBar.vertical: ScrollBar {
|
Control.ScrollBar.vertical: ScrollBar {
|
||||||
|
|
@ -296,14 +297,14 @@ FocusScope {
|
||||||
visible: participantList.height < participantList.contentHeight
|
visible: participantList.height < participantList.contentHeight
|
||||||
}
|
}
|
||||||
delegate: Item {
|
delegate: Item {
|
||||||
height: Math.round(56 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(56)
|
||||||
width: participantList.width - participantScrollBar.width
|
width: participantList.width - participantScrollBar.width
|
||||||
RowLayout {
|
RowLayout {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
spacing: Math.round(16 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(16)
|
||||||
Avatar {
|
Avatar {
|
||||||
Layout.preferredWidth: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(45)
|
||||||
Layout.preferredHeight: Math.round(45 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(45)
|
||||||
_address: modelData.address
|
_address: modelData.address
|
||||||
secured: friendSecurityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
secured: friendSecurityLevel === LinphoneEnums.SecurityLevel.EndToEndEncryptedAndVerified
|
||||||
shadowEnabled: false
|
shadowEnabled: false
|
||||||
|
|
@ -311,18 +312,18 @@ FocusScope {
|
||||||
Text {
|
Text {
|
||||||
property var displayNameObj: UtilsCpp.getDisplayName(modelData.address)
|
property var displayNameObj: UtilsCpp.getDisplayName(modelData.address)
|
||||||
text: displayNameObj?.value || ""
|
text: displayNameObj?.value || ""
|
||||||
font.pixelSize: Math.round(14 * DefaultStyle.dp)
|
font.pixelSize: Utils.getSizeWithScreenRatio(14)
|
||||||
font.capitalization: Font.Capitalize
|
font.capitalization: Font.Capitalize
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
}
|
}
|
||||||
Button {
|
Button {
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.width: Math.round(24 * DefaultStyle.dp)
|
icon.width: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.height: Math.round(24 * DefaultStyle.dp)
|
icon.height: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.rightMargin: Math.round(10 * DefaultStyle.dp)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(10)
|
||||||
icon.source: AppIcons.closeX
|
icon.source: AppIcons.closeX
|
||||||
style: ButtonStyle.noBackgroundOrange
|
style: ButtonStyle.noBackgroundOrange
|
||||||
onClicked: mainItem.conferenceInfoGui.core.removeParticipant(index)
|
onClicked: mainItem.conferenceInfoGui.core.removeParticipant(index)
|
||||||
|
|
@ -341,7 +342,7 @@ FocusScope {
|
||||||
}
|
}
|
||||||
Item {
|
Item {
|
||||||
Layout.fillHeight: true
|
Layout.fillHeight: true
|
||||||
Layout.minimumHeight: Math.max(Math.round(1 * DefaultStyle.dp), 1)
|
Layout.minimumHeight: Utils.getSizeWithScreenRatio(1)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -4,6 +4,7 @@ import QtQuick.Controls.Basic as Control
|
||||||
import Linphone
|
import Linphone
|
||||||
import UtilsCpp
|
import UtilsCpp
|
||||||
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
import 'qrc:/qt/qml/Linphone/view/Style/buttonStyle.js' as ButtonStyle
|
||||||
|
import "qrc:/qt/qml/Linphone/view/Control/Tool/Helper/utils.js" as Utils
|
||||||
|
|
||||||
LoginLayout {
|
LoginLayout {
|
||||||
id: mainItem
|
id: mainItem
|
||||||
|
|
@ -17,11 +18,11 @@ LoginLayout {
|
||||||
onCtrlIsPressedChanged: console.log("ctrl is pressed", ctrlIsPressed)
|
onCtrlIsPressedChanged: console.log("ctrl is pressed", ctrlIsPressed)
|
||||||
titleContent: [
|
titleContent: [
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(21 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(21)
|
||||||
Layout.leftMargin: Math.round(119 * DefaultStyle.dp)
|
Layout.leftMargin: Utils.getSizeWithScreenRatio(119)
|
||||||
Button {
|
Button {
|
||||||
Layout.preferredHeight: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(24)
|
||||||
Layout.preferredWidth: Math.round(24 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(24)
|
||||||
icon.source: AppIcons.leftArrow
|
icon.source: AppIcons.leftArrow
|
||||||
style: ButtonStyle.noBackground
|
style: ButtonStyle.noBackground
|
||||||
onClicked: {
|
onClicked: {
|
||||||
|
|
@ -32,8 +33,8 @@ LoginLayout {
|
||||||
EffectImage {
|
EffectImage {
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
imageSource: AppIcons.profile
|
imageSource: AppIcons.profile
|
||||||
Layout.preferredHeight: Math.round(34 * DefaultStyle.dp)
|
Layout.preferredHeight: Utils.getSizeWithScreenRatio(34)
|
||||||
Layout.preferredWidth: Math.round(34 * DefaultStyle.dp)
|
Layout.preferredWidth: Utils.getSizeWithScreenRatio(34)
|
||||||
colorizationColor: DefaultStyle.main2_600
|
colorizationColor: DefaultStyle.main2_600
|
||||||
}
|
}
|
||||||
Text {
|
Text {
|
||||||
|
|
@ -62,8 +63,8 @@ LoginLayout {
|
||||||
ColumnLayout {
|
ColumnLayout {
|
||||||
anchors.left: parent.left
|
anchors.left: parent.left
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.leftMargin: Math.round(127 * DefaultStyle.dp)
|
anchors.leftMargin: Utils.getSizeWithScreenRatio(127)
|
||||||
spacing: Math.round(104 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(104)
|
||||||
Text {
|
Text {
|
||||||
font {
|
font {
|
||||||
bold: true
|
bold: true
|
||||||
|
|
@ -78,7 +79,7 @@ LoginLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(45 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(45)
|
||||||
Repeater {
|
Repeater {
|
||||||
model: 4
|
model: 4
|
||||||
id: repeater
|
id: repeater
|
||||||
|
|
@ -143,7 +144,7 @@ LoginLayout {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Math.round(20 * DefaultStyle.dp)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
Text {
|
Text {
|
||||||
//: "Vous n'avez pas reçu le code ?"
|
//: "Vous n'avez pas reçu le code ?"
|
||||||
text: qsTr("assistant_account_creation_confirmation_did_not_receive_code")
|
text: qsTr("assistant_account_creation_confirmation_did_not_receive_code")
|
||||||
|
|
@ -164,10 +165,10 @@ LoginLayout {
|
||||||
Image {
|
Image {
|
||||||
anchors.top: parent.top
|
anchors.top: parent.top
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
anchors.topMargin: Math.round(140 * DefaultStyle.dp)
|
anchors.topMargin: Utils.getSizeWithScreenRatio(140)
|
||||||
anchors.rightMargin: Math.round(97 * DefaultStyle.dp)
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(97)
|
||||||
width: Math.round(477 * DefaultStyle.dp)
|
width: Utils.getSizeWithScreenRatio(477)
|
||||||
height: Math.round(345 * DefaultStyle.dp)
|
height: Utils.getSizeWithScreenRatio(345)
|
||||||
fillMode: Image.PreserveAspectFit
|
fillMode: Image.PreserveAspectFit
|
||||||
source: AppIcons.verif_page_image
|
source: AppIcons.verif_page_image
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -69,7 +69,7 @@ LoginLayout {
|
||||||
},
|
},
|
||||||
RowLayout {
|
RowLayout {
|
||||||
spacing: Utils.getSizeWithScreenRatio(20)
|
spacing: Utils.getSizeWithScreenRatio(20)
|
||||||
Layout.rightMargin: Math.round(Math.max(10 * DefaultStyle.dp,(51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp))
|
Layout.rightMargin: Math.max(Utils.getSizeWithScreenRatio(10), Utils.getSizeWithScreenRatio(51 - ((51/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))))
|
||||||
Text {
|
Text {
|
||||||
Layout.rightMargin: Utils.getSizeWithScreenRatio(15)
|
Layout.rightMargin: Utils.getSizeWithScreenRatio(15)
|
||||||
color: DefaultStyle.main2_700
|
color: DefaultStyle.main2_700
|
||||||
|
|
@ -102,7 +102,7 @@ LoginLayout {
|
||||||
Layout.fillWidth: true
|
Layout.fillWidth: true
|
||||||
id: bar
|
id: bar
|
||||||
spacing: Utils.getSizeWithScreenRatio(40)
|
spacing: Utils.getSizeWithScreenRatio(40)
|
||||||
Layout.rightMargin: Math.round(Math.max(5 * DefaultStyle.dp,(127 - ((127/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))) * DefaultStyle.dp))
|
Layout.rightMargin: Math.max(Utils.getSizeWithScreenRatio(5), Utils.getSizeWithScreenRatio(127 - ((127/(DefaultStyle.defaultWidth - mainWindow.minimumWidth))*(DefaultStyle.defaultWidth-mainWindow.width))))
|
||||||
// "S'inscrire avec un numéro de téléphone"
|
// "S'inscrire avec un numéro de téléphone"
|
||||||
model: [qsTr("assistant_account_register_with_phone_number"),
|
model: [qsTr("assistant_account_register_with_phone_number"),
|
||||||
// "S'inscrire avec un email"
|
// "S'inscrire avec un email"
|
||||||
|
|
@ -122,7 +122,7 @@ LoginLayout {
|
||||||
interactive: true
|
interactive: true
|
||||||
visible: parent.contentHeight > parent.height
|
visible: parent.contentHeight > parent.height
|
||||||
policy: Control.ScrollBar.AsNeeded
|
policy: Control.ScrollBar.AsNeeded
|
||||||
anchors.rightMargin: 8 * DefaultStyle.dp
|
anchors.rightMargin: Utils.getSizeWithScreenRatio(8)
|
||||||
anchors.right: parent.right
|
anchors.right: parent.right
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue