summaryrefslogtreecommitdiffstats
path: root/src/gui/qml/incoming_call.qml
blob: 8f1ae0eed6833b56ffd3f39db4f708dfa58b90ba (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
import QtQuick 2.0

Rectangle {
    id: rectanglePopup
    width: 400
    height: 70
    color: "black"

    signal moved

    Image {
        id: image1
        anchors.bottom: parent.bottom
        anchors.bottomMargin: 5
        anchors.top: parent.top
        anchors.topMargin: 5
        anchors.left: parent.left
        anchors.leftMargin: 5
        source: "qrc:/icons/images/twinkle48.png"
        width: height
    }

    Text {
        id: callerText
        objectName: "callerText"
        height: 22
        color: "#ffffff"
        text: "... calling"
        anchors.top: parent.top
        anchors.topMargin: 8
        anchors.left: image1.right
        anchors.leftMargin: 9
        anchors.right: parent.right
        anchors.rightMargin: 10
        font.pixelSize: 19
    }

    TextImageButton {
        id: buttonAnswer
        objectName: "buttonAnswer"
        x: 74
        y: 36
        width: 120
        height: 26
        color: "#00aa00"
        radius: 7
        text: qsTr("Answer")
        image: "qrc:/icons/images/popup_incoming_answer.png"
    }

    TextImageButton {
        id: buttonReject
        objectName: "buttonReject"
        y: 36
        width: 120
        height: 26
        radius: 7
        text: qsTr("Reject")
        anchors.left: buttonAnswer.right
        anchors.leftMargin: 15
        image: "qrc:/icons/images/popup_incoming_reject.png"
    }

    MouseArea {
        anchors.fill: parent
        property real lastMouseX: 0
        property real lastMouseY: 0
        onPressed: {
            lastMouseX = mouseX
            lastMouseY = mouseY
        }
        onMouseXChanged: viewerWidget.x += (mouseX - lastMouseX)
        onMouseYChanged: viewerWidget.y += (mouseY - lastMouseY)
    }
}