mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-05-07 14:44:01 +00:00
feat(ui/modules/Linphone/Calls/Calls): deal with call clicks & display correctly current call
This commit is contained in:
parent
bc6a75ad49
commit
3d83700fd9
3 changed files with 23 additions and 1 deletions
|
|
@ -25,10 +25,20 @@ Rectangle {
|
|||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
signal clicked
|
||||
|
||||
// ---------------------------------------------------------------------------
|
||||
|
||||
color: CallControlsStyle.color
|
||||
height: CallControlsStyle.height
|
||||
width: CallControlsStyle.width
|
||||
|
||||
MouseArea {
|
||||
anchors.fill: parent
|
||||
|
||||
onClicked: callControls.clicked()
|
||||
}
|
||||
|
||||
RowLayout {
|
||||
anchors {
|
||||
fill: parent
|
||||
|
|
|
|||
|
|
@ -54,6 +54,7 @@ ListView {
|
|||
name: qsTr('terminateCall')
|
||||
}],
|
||||
component: callActions,
|
||||
icon: 'hangup',
|
||||
string: 'connected'
|
||||
}
|
||||
|
||||
|
|
@ -214,10 +215,14 @@ ListView {
|
|||
delegate: CallControls {
|
||||
id: _callControls
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
|
||||
function useColorStatus () {
|
||||
return calls.currentIndex === index && $call && $call.status !== CallModel.CallStatusEnded
|
||||
}
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
|
||||
color: useColorStatus()
|
||||
? CallsStyle.entry.color.selected
|
||||
: CallsStyle.entry.color.normal
|
||||
|
|
@ -232,6 +237,13 @@ ListView {
|
|||
sipAddress: $call.sipAddress
|
||||
width: parent.width
|
||||
|
||||
onClicked: {
|
||||
smartConnect.selectedCall = $call
|
||||
calls.currentIndex = index
|
||||
}
|
||||
|
||||
// -------------------------------------------------------------------------
|
||||
|
||||
Loader {
|
||||
property int callId: index
|
||||
property var call: $call
|
||||
|
|
|
|||
|
|
@ -153,7 +153,7 @@ Window {
|
|||
anchors.fill: parent
|
||||
sourceComponent: {
|
||||
var status = window.call.status
|
||||
if (!status) {
|
||||
if (status == null) {
|
||||
return null
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue