mirror of
https://gitlab.linphone.org/BC/public/linphone-desktop.git
synced 2026-02-07 15:08:24 +00:00
Introduce ObjectCore, ObjectGui, ObjectModel. Simulate addAccount signals on adding account (in waiting for SDK callback).
54 lines
1.2 KiB
QML
54 lines
1.2 KiB
QML
import QtQuick 2.7
|
|
import QtQuick.Layouts 1.3
|
|
import Linphone
|
|
|
|
// =============================================================================
|
|
|
|
Notification {
|
|
id: notification
|
|
|
|
// ---------------------------------------------------------------------------
|
|
|
|
readonly property var call: notificationData && notificationData.call
|
|
property var state: call.core.state
|
|
onStateChanged:{
|
|
if(state != LinphoneEnums.CallState.IncomingReceived){
|
|
close()
|
|
}
|
|
}
|
|
// ---------------------------------------------------------------------------
|
|
ColumnLayout {
|
|
anchors.fill: parent
|
|
anchors.leftMargin: 15
|
|
anchors.rightMargin: 15
|
|
anchors.bottomMargin:15
|
|
spacing: 0
|
|
|
|
// ---------------------------------------------------------------------
|
|
// Action buttons.
|
|
// ---------------------------------------------------------------------
|
|
|
|
RowLayout {
|
|
Layout.fillHeight: true
|
|
Layout.fillWidth: true
|
|
Button {
|
|
text: 'Accept'
|
|
Layout.rightMargin: 20
|
|
onClicked: {
|
|
notification.call.core.lAccept(true)
|
|
}
|
|
}
|
|
Item{
|
|
Layout.fillWidth: true
|
|
Layout.fillHeight: true
|
|
}
|
|
Button {
|
|
text: 'Reject'
|
|
Layout.rightMargin: 20
|
|
onClicked: {
|
|
notification.call.core.lDecline()
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|