mirror of
https://invent.kde.org/marcoa/shift-shell.git
synced 2026-04-29 15:03:09 +00:00
[dialer] Pass the phone number to dial through a property
This commit is contained in:
parent
3bde0c3a7c
commit
3f1bfac8e7
1 changed files with 4 additions and 1 deletions
|
|
@ -62,6 +62,7 @@ Item {
|
||||||
id: contactsList
|
id: contactsList
|
||||||
|
|
||||||
property bool delegateSelected: false
|
property bool delegateSelected: false
|
||||||
|
property string numberToCall
|
||||||
|
|
||||||
|
|
||||||
section.property: "display"
|
section.property: "display"
|
||||||
|
|
@ -101,9 +102,11 @@ Item {
|
||||||
if (contactsList.delegateSelected) {
|
if (contactsList.delegateSelected) {
|
||||||
contactsList.currentIndex = -1;
|
contactsList.currentIndex = -1;
|
||||||
contactsList.delegateSelected = false;
|
contactsList.delegateSelected = false;
|
||||||
|
contactsList.numberToCall = "";
|
||||||
} else {
|
} else {
|
||||||
contactsList.currentIndex = index;
|
contactsList.currentIndex = index;
|
||||||
contactsList.delegateSelected = true;
|
contactsList.delegateSelected = true;
|
||||||
|
contactsList.numberToCall = model.phoneNumber;
|
||||||
}
|
}
|
||||||
|
|
||||||
contactsList.toggleOverlayButtons(contactsList.delegateSelected);
|
contactsList.toggleOverlayButtons(contactsList.delegateSelected);
|
||||||
|
|
@ -214,7 +217,7 @@ Item {
|
||||||
MouseArea {
|
MouseArea {
|
||||||
anchors.fill: parent
|
anchors.fill: parent
|
||||||
//TODO: needs the proper number
|
//TODO: needs the proper number
|
||||||
onClicked: call(model.phoneNumber)
|
onClicked: call(contactsList.numberToCall)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue