[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer.changes
|
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer.spec
^
|
|
[-]
[+]
|
Changed |
_service
^
|
@@ -6,7 +6,7 @@
<service name="tar_git">
<param name="url">https://github.com/nemomobile-ux/glacier-dialer.git</param>
<param name="branch">master</param>
- <param name="revision">7a9c5ba1ddee9800b7b6340adf31e7004c3f84cf</param>
+ <param name="revision">f8a6877b3c067e21ce0aed671dfbed6db3911a36</param>
<param name="token"/>
<param name="debian">N</param>
<param name="dumb">N</param>
|
[-]
[+]
|
Added |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/com.nokia.telephony.callhistory.service
^
|
@@ -0,0 +1,3 @@
+[D-BUS Service]
+Name=com.nokia.telephony.callhistory
+Exec=/usr/bin/invoker --type=nemomobile -s /usr/bin/glacier-dialer
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/glacier-dialer.desktop
^
|
@@ -7,7 +7,7 @@
X-MeeGo-Logical-Id=voicecall-ap-name
X-MeeGo-Translation-Catalog=voicecall
Exec=invoker --type=nemomobile -s /usr/bin/glacier-dialer
-Icon=icon-app-dialer
+Icon=/usr/share/glacier-dialer/qml/images/glacier-dialer.png
X-Window-Icon=
X-HildonDesk-ShowInToolbar=true
X-Osso-Type=application/x-executable
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/glacier-dialer.pro
^
|
@@ -9,18 +9,20 @@
HEADERS += src/dbusadaptor.h
OTHER_FILES += qml/glacier-dialer.qml \
- qml/pages/FirstPage.qml \
qml/pages/CallLogPage.qml \
qml/pages/CallView.qml \
- qml/pages/DialerPage.qml \
qml/pages/ContactsPage.qml \
qml/pages/ContactDelegate.qml \
qml/pages/ContactDetails.qml \
+ qml/pages/DialerPage.qml \
+ qml/pages/FirstPage.qml \
+ qml/components/SearchBox.qml \
qml/components/DialerButton.qml \
- qml/components/LogDelegate.qml \
+ qml/components/VoicecallService.qml \
rpm/glacier-dialer.spec \
glacier-dialer.desktop \
- org.glacier.voicecall.ui.service
+ org.glacier.voicecall.ui.service \
+ com.nokia.telephony.callhistory.service
target.path = /usr/bin
@@ -34,7 +36,8 @@
pages.path = /usr/share/glacier-dialer/
systemd_dbus_service.path = $${INSTALL_ROOT}/usr/share/dbus-1/services
-systemd_dbus_service.files = org.glacier.voicecall.ui.service
+systemd_dbus_service.files = org.glacier.voicecall.ui.service \
+ com.nokia.telephony.callhistory.service
systemd_ui_prestart_service.path = $${INSTALL_ROOT}/usr/lib/systemd/user
systemd_ui_prestart_service.files = voicecall-ui-prestart.service
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/components/DialerButton.qml
^
|
@@ -53,13 +53,11 @@
anchors.centerIn: parent
font.bold: true
text: btn.text
- style: Text.Outline
- styleColor : "black"
}
MouseArea {
anchors.fill: parent
- onClicked: {
+ onPressed: {
dialedNumber.insert(dialedNumber.cursorPosition,btn.text)
btn.color = Theme.accentColor
}
|
[-]
[+]
|
Added |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/components/SearchBox.qml
^
|
@@ -0,0 +1,118 @@
+/****************************************************************************
+ **
+ ** Copyright (C) 2011 Nokia Corporation and/or its subsidiary(-ies).
+ ** Copyright (C) 2012 Robin Burchell <robin+mer@viroteck.net>
+ ** Copyright (C) 2018 Chupligin Sergey <neochapay@gmail.com>
+ **
+ ** $QT_BEGIN_LICENSE:BSD$
+ ** You may use this file under the terms of the BSD license as follows:
+ **
+ ** "Redistribution and use in source and binary forms, with or without
+ ** modification, are permitted provided that the following conditions are
+ ** met:
+ ** * Redistributions of source code must retain the above copyright
+ ** notice, this list of conditions and the following disclaimer.
+ ** * Redistributions in binary form must reproduce the above copyright
+ ** notice, this list of conditions and the following disclaimer in
+ ** the documentation and/or other materials provided with the
+ ** distribution.
+ ** * Neither the name of Nokia Corporation and its Subsidiary(-ies) nor
+ ** the names of its contributors may be used to endorse or promote
+ ** products derived from this software without specific prior written
+ ** permission.
+ **
+ ** THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+ ** "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+ ** LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+ ** A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+ ** OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+ ** SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+ ** LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ ** DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ ** THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ ** (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+ ** OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE."
+ ** $QT_END_LICENSE$
+ **
+ ****************************************************************************/
+
+import QtQuick 2.6
+
+import QtQuick.Controls 1.0
+import QtQuick.Controls.Nemo 1.0
+import QtQuick.Controls.Styles.Nemo 1.0
+
+Item {
+ id: root
+
+ // Declared properties
+ property alias searchText: searchTextInput.text
+ property alias placeHolderText: searchTextInput.placeholderText
+ property alias maximumLength: searchTextInput.maximumLength
+
+ // Signals & functions
+ signal backClicked
+
+ // Attribute definitions
+ width: parent ? parent.width : 0
+ height: Theme.itemHeightLarge
+
+ TextField {
+ id: searchTextInput
+ height: parent.height
+
+ inputMethodHints: Qt.ImhNoPredictiveText
+
+ anchors {
+ left: parent.left
+ right: searchIcon.left
+ verticalCenter: parent.verticalCenter
+ margins: Theme.itemSpacingMedium
+ }
+
+ font.pixelSize: Theme.fontSizeLarge
+ }
+ // Search icon, just for styling the SearchBox a bit.
+ Image {
+ id: searchIcon
+
+ height: parent.height*0.8
+ width: height
+
+ anchors {
+ right: parent.right
+ verticalCenter: parent.verticalCenter
+ margins: Theme.itemSpacingMedium
+ }
+
+ fillMode: Image.PreserveAspectFit
+ source: "image://theme/search"
+ }
+
+ // A trash can image, clicking it allows the user to quickly
+ // remove the typed text.
+ Image {
+ id: clearTextIcon
+
+ height: parent.height*0.8
+ width: height
+
+ source: "image://theme/chevron-left"
+
+ anchors {
+ right: searchTextInput.right
+ verticalCenter: parent.verticalCenter
+ margins: Theme.itemSpacingMedium
+ }
+
+ visible: searchTextInput.text.length > 0
+
+ MouseArea {
+ anchors.fill: parent
+ onClicked: {
+ searchTextInput.text = ""
+ searchTextInput.forceActiveFocus()
+ }
+ }
+ }
+}
|
[-]
[+]
|
Added |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/components/VoicecallService.qml
^
|
@@ -0,0 +1,23 @@
+import QtQuick 2.6
+import org.nemomobile.dbus 2.0
+
+DBusAdaptor {
+ id: callhistoryAdaptor
+ service: "com.nokia.telephony.callhistory"
+ path: "/org/maemo/m"
+ iface: "com.nokia.MApplicationIf"
+
+ xml: ' <interface name="com.nokia.MApplicationIf">\n' +
+ ' <method name="launch" />\n' +
+ ' <arg name="type" type="s" direction="in"/>\n' +
+ ' </method>\n' +
+ ' </interface>\n'
+
+ signal openCallHistory
+
+ function launch(type) {
+ if(type === "callHistory") {
+ openCallHistory()
+ }
+ }
+}
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/glacier-dialer.qml
^
|
@@ -27,6 +27,7 @@
import org.nemomobile.commhistory 1.0
import "pages"
+import "components"
ApplicationWindow
{
@@ -34,17 +35,19 @@
initialPage: FirstPage {
id: pageItem
}
+
contentOrientation: Screen.orientation
property Person activeVoiceCallPerson
property string activationReason: 'invoked'
property bool speedDialEditor: false
property alias page: pageItem
+
VoiceCallManager {
id: telephone
onActiveVoiceCallChanged: {
if(activeVoiceCall) {
main.activeVoiceCallPerson = peopleModel.personByPhoneNumber(activeVoiceCall.lineId, true);
- console.error(JSON.stringify(main.activeVoiceCallPerson))
+
pageItem.pageStack.push({
"item": Qt.resolvedUrl("pages/CallView.qml"),
"properties": {
@@ -53,23 +56,21 @@
},
"immediate": true
})
- if(!__window.visible)
+ if(!main.visible)
{
main.activationReason = "activeVoiceCallChanged"
- __window.showFullScreen()
+ main.showFullScreen()
} else {
- __window.raise()
+ main.raise()
}
} else {
- pageItem.pageStack.pop({"immediate":true})
+ pageItem.pageStack.pop()
main.activeVoiceCallPerson = null
- if (main.activationReason != "invoked") {
- main.activationReason = "invoked"
- __window.close()
- }
+ main.hide();
}
}
}
+
function secondsToTimeString(seconds) {
var h = Math.floor(seconds / 3600);
var m = Math.floor((seconds - (h * 3600)) / 60);
@@ -88,6 +89,15 @@
groupBy: CommCallModel.GroupByContact
resolveContacts: true
}
+
+ VoicecallService{
+ id: voicecallService
+
+ onOpenCallHistory: {
+ pageStack.push(Qt.resolvedUrl("pages/CallLogPage.qml"))
+ main.raise()
+ }
+ }
}
|
|
Added |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/images/glacier-dialer.png
^
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/pages/CallLogPage.qml
^
|
@@ -41,18 +41,70 @@
onClicked: {
commCallModel.markAllRead()
}
+ visible: historyList.count != 0
}
]
}
ListView {
- id: list
+ id: historyList
anchors.fill: parent
anchors.topMargin: 20
clip: true
model: commCallModel
- delegate: LogDelegate {
+ delegate: ListViewItemWithActions {
+ property Person contact
+
+ showNext: false
+
contact: model.contactIds.length ? peopleModel.personById(model.contactIds[0]) : null
+ label: contact ? contact.displayLabel : model.remoteUid
+ description: refreshTimestamp(model.startTime)
+ icon: "image://theme/phone"
+
+ onClicked: {
+ telephone.dial(telephone.defaultProviderId, model.remoteUid)
+ }
+ }
+ }
+
+ Label{
+ id: emptyHistory
+ text: qsTr("Call journal empty")
+ anchors.centerIn: parent
+ visible: historyList.count == 0
+ }
+
+ function refreshTimestamp(time) {
+ var timeAgo;
+
+ var seconds = Math.floor((new Date() - time) / 1000)
+ var years = Math.floor(seconds / (365*24*60*60))
+ var months = Math.floor(seconds / (30*24*60*60))
+ var days = Math.floor(seconds / (24*60*60))
+ var hours = Math.floor(seconds / (60*60))
+ var minutes = Math.floor(seconds / 60)
+
+ if (months >= 1) {
+ timeAgo = qsTr("long time ago")
+ }else if (days >= 1) {
+ if (days > 1) {
+ timeAgo = days + " " + qsTr("days ago")
+ } else {
+ timeAgo = days + " " + qsTr("day ago")
+ }
+ }else if (hours >= 1) {
+ if (hours > 1) {
+ timeAgo = hours + " " + qsTr("hours ago")
+ } else {
+ timeAgo = hours + " " + qsTr("hour ago")
+ }
+ } else if (minutes >= 1) {
+ timeAgo = minutes + " " + qsTr("min ago")
+
+ } else {
+ timeAgo = qsTr("Just now")
}
+ return timeAgo;
}
}
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/pages/ContactsPage.qml
^
|
@@ -23,14 +23,51 @@
import QtQuick.Controls.Styles.Nemo 1.0
import QtQuick.Layouts 1.0
+import org.nemomobile.contacts 1.0
+import org.nemomobile.qmlcontacts 1.0
+
+import "../components"
+
Page {
id: contacts
- ListView {
- model: peopleModel
- anchors.fill: parent
- anchors.topMargin: 20
- delegate: ContactDelegate {
- person: modelData.personByRow(index)
+
+ signal selectContact(string number)
+
+ headerTools: HeaderToolsLayout {
+ id: tools
+ title: qsTr("Contacts")
+ showBackButton: true;
+ }
+
+ PeopleModel {
+ id: contactsModel
+ }
+
+ SearchBox {
+ id: searchbox
+ placeHolderText: qsTr("Search")
+ anchors.top: parent.top
+ width: parent.width
+ onSearchTextChanged: {
+ app.contactListModel.search(searchbox.searchText);
+ }
+ }
+
+ ContactListWidget {
+ id: contactsList
+
+ anchors.top: searchbox.bottom
+ width: parent.width
+ anchors.bottom: parent.bottom
+ clip: true
+
+ model: contactsModel
+ delegate: ContactListDelegate {
+ showNext: false
+ onClicked: {
+ console.log(model.person.phoneDetails[0].number)
+ selectContact(model.person.phoneDetails[0].number)
+ }
}
}
}
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/pages/DialerPage.qml
^
|
@@ -28,6 +28,8 @@
Page {
id: dialer
+ property alias dialerNumber: dialedNumber.text
+
Item {
id: numForDialing
height: Theme.itemHeightLarge
|
[-]
[+]
|
Changed |
_service:tar_git:glacier-dialer-0.2.1.tar.bz2/qml/pages/FirstPage.qml
^
|
@@ -48,6 +48,7 @@
}
]
}
+
DialerPage {
id: dialer_page
}
|
[-]
[+]
|
Deleted |
_service:tar_git:glacier-dialer-0.2.tar.bz2/qml/components/LogDelegate.qml
^
|
@@ -1,116 +0,0 @@
-/*
- * Copyright 2014 Aleksi Suomalainen <suomalainen.aleksi@gmail.com>
- *
- * This library is free software; you can redistribute it and/or
- * modify it under the terms of the GNU Library General Public
- * License as published by the Free Software Foundation; either
- * version 2 of the License, or (at your option) any later version.
- *
- * This library is distributed in the hope that it will be useful,
- * but WITHOUT ANY WARRANTY; without even the implied warranty of
- * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
- * Library General Public License for more details.
- *
- * You should have received a copy of the GNU Library General Public License
- * along with this library; see the file COPYING.LIB. If not, write to
- * the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
- * Boston, MA 02110-1301, USA.
-*/
-
-import QtQuick 2.6
-import QtQuick.Controls 1.0
-import QtQuick.Controls.Nemo 1.0
-import QtQuick.Controls.Styles.Nemo 1.0
-import org.nemomobile.contacts 1.0
-import org.nemomobile.commhistory 1.0
-
-
-Item {
- id: root
- width: parent.width
- height: Theme.itemHeightExtraLarge
- property Person contact
-
- Image{
- id: callRoute
- width: parent.height*0.8
- height: width
- source: "image://theme/phone"
- anchors{
- left: parent.left
- leftMargin: parent.height*0.1
- top: parent.top
- topMargin: parent.height*0.1
- }
- }
-
- /*Label {
- id: directionLabel
- Layout.fillWidth: true
- Layout.fillHeight: true
- text: model.isMissedCall ? qsTr('missed') : (model.direction == CommCallModel.Inbound ? qsTr('received') : qsTr('initiated'))
- }*/
-
- Label {
- id: contactLabel
- text: contact ? contact.displayLabel.substring(0,10): model.remoteUid
- anchors{
- left: callRoute.right
- leftMargin: parent.height*0.1
- verticalCenter: parent.verticalCenter
- }
- width: parent.width-callRoute.width-dateLabel.width-parent.height*0.4
- }
- Label {
- id: dateLabel
- text: refreshTimestamp(model.startTime)
- anchors{
- right: parent.right
- leftMargin: parent.height*0.1
- verticalCenter: parent.verticalCenter
- }
- }
-
- MouseArea {
- anchors.fill: parent
- onClicked: {
- telephone.dial(telephone.defaultProviderId, model.remoteUid)
- }
- onPressAndHold: {
- commCallModel.deleteAt(model.index)
- }
- }
-
- function refreshTimestamp(time) {
- var timeAgo;
-
- var seconds = Math.floor((new Date() - time) / 1000)
- var years = Math.floor(seconds / (365*24*60*60))
- var months = Math.floor(seconds / (30*24*60*60))
- var days = Math.floor(seconds / (24*60*60))
- var hours = Math.floor(seconds / (60*60))
- var minutes = Math.floor(seconds / 60)
-
- if (months >= 1) {
- timeAgo = qsTr("long time ago")
- }else if (days >= 1) {
- if (days > 1) {
- timeAgo = days + " " + qsTr("days ago")
- } else {
- timeAgo = days + " " + qsTr("day ago")
- }
- }else if (hours >= 1) {
- if (hours > 1) {
- timeAgo = hours + " " + qsTr("hours ago")
- } else {
- timeAgo = hours + " " + qsTr("hour ago")
- }
- } else if (minutes >= 1) {
- timeAgo = minutes + " " + qsTr("min ago")
-
- } else {
- timeAgo = qsTr("Just now")
- }
- return timeAgo;
- }
-}
|