summaryrefslogtreecommitdiffstats
path: root/app/Phone.qml
diff options
context:
space:
mode:
Diffstat (limited to 'app/Phone.qml')
-rw-r--r--app/Phone.qml58
1 files changed, 44 insertions, 14 deletions
diff --git a/app/Phone.qml b/app/Phone.qml
index 0a23f2a..15af5b4 100644
--- a/app/Phone.qml
+++ b/app/Phone.qml
@@ -1,5 +1,6 @@
/*
* Copyright (C) 2016 The Qt Company Ltd.
+ * Copyright (C) 2018 Konsulko Group
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -15,29 +16,58 @@
*/
import QtQuick 2.6
-import QtQuick.Layouts 1.1
+import QtQuick.Layouts 1.3
import QtQuick.Controls 2.0
ApplicationWindow {
id: root
- StackView {
- id: stack
- anchors.fill: parent
- initialItem: dialer
- }
- Dialer {
- id: dialer
- onShowContacts: stack.push(contacts)
+ TabBar {
+ id: bar
+ width: parent.width
+ contentHeight: 160
+
+ TabImageButton {
+ icon: "./images/ic_contacts_48px.svg"
+ text: "Contacts"
+ font.pixelSize: 50
+ }
+
+ TabImageButton {
+ icon: "./images/ic_schedule_48px.svg"
+ text: "Recents"
+ font.pixelSize: 50
+ }
+
+ TabImageButton {
+ icon: "./images/ic_dialpad_48px.svg"
+ text: "Dialpad"
+ font.pixelSize: 50
+ }
+
}
- Component {
- id: contacts
+
+ StackLayout {
+ anchors.top: bar.bottom
+ width: parent.width
+ height:parent.height - bar.height
+ currentIndex: bar.currentIndex
ContactsView {
- onCancel: stack.pop()
+ id: contacts
+ onCall: {
+ dialer.call(cname, cnumber)
+ bar.setCurrentIndex(2)
+ }
+ }
+ Recents {
+ id: recents
onCall: {
- dialer.call(contact)
- stack.pop()
+ dialer.call(cname, cnumber)
+ bar.setCurrentIndex(2)
}
}
+ Dialer {
+ id: dialer
+ }
}
}