[SCM] kdeconnect packaging branch, master, updated. debian/0.9g-1-1183-g9d69498

Maximiliano Curia maxy at moszumanska.debian.org
Fri Oct 14 14:29:54 UTC 2016


Gitweb-URL: http://git.debian.org/?p=pkg-kde/kde-extras/kdeconnect.git;a=commitdiff;h=7af35b0

The following commit has been merged in the master branch:
commit 7af35b00f2a818ea85a12c7e24d8b01aca4c8534
Author: Albert Vaca <albertvaka at gmail.com>
Date:   Wed Jun 22 12:19:24 2016 +0200

    Send sms to a number, not a contact name. Use the contact name for display.
    
    CCMAIL: david at davidedmundson.co.uk
---
 plugins/telepathy/telepathy-cm/connection.cpp | 12 ++++++------
 plugins/telepathy/telepathy-cm/connection.h   |  2 +-
 plugins/telepathy/telepathy-cm/protocol.cpp   |  4 ++--
 plugins/telepathy/telepathy-cm/protocol.h     |  2 +-
 plugins/telephony/telephonyplugin.cpp         |  2 +-
 5 files changed, 11 insertions(+), 11 deletions(-)

diff --git a/plugins/telepathy/telepathy-cm/connection.cpp b/plugins/telepathy/telepathy-cm/connection.cpp
index 6a91cfc..12aea6f 100644
--- a/plugins/telepathy/telepathy-cm/connection.cpp
+++ b/plugins/telepathy/telepathy-cm/connection.cpp
@@ -268,7 +268,7 @@ uint ConnectConnection::addContact(const QString &identifier)
 }
 
 /* Receive message from someone to ourself */
-bool ConnectConnection::receiveMessage(const QString &sender, const QString &message)
+bool ConnectConnection::receiveMessage(const QString &sender, const QString& senderName, const QString &message)
 {
     uint senderHandle, targetHandle;
 
@@ -305,11 +305,11 @@ bool ConnectConnection::receiveMessage(const QString &sender, const QString &mes
 
     Tp::MessagePartList partList;
     Tp::MessagePart header;
-    header["message-received"]      = QDBusVariant(timestamp);
-    header["message-sender"]        = QDBusVariant(senderHandle);
-    header["message-sender-id"]     = QDBusVariant(sender);
-    //header["sender-nickname"]       = QDBusVariant(pushName);
-    header["message-type"]          = QDBusVariant(Tp::ChannelTextMessageTypeNormal);
+    header["message-received"]  = QDBusVariant(timestamp);
+    header["message-sender"]    = QDBusVariant(senderHandle);
+    header["message-sender-id"] = QDBusVariant(sender);
+    header["sender-nickname"]   = QDBusVariant(senderName);
+    header["message-type"]      = QDBusVariant(Tp::ChannelTextMessageTypeNormal);
 
     partList << header << body;
     textChannel->addReceivedMessage(partList);
diff --git a/plugins/telepathy/telepathy-cm/connection.h b/plugins/telepathy/telepathy-cm/connection.h
index 7819cd4..2f05f7b 100644
--- a/plugins/telepathy/telepathy-cm/connection.h
+++ b/plugins/telepathy/telepathy-cm/connection.h
@@ -43,7 +43,7 @@ public:
     uint ensureContact(const QString &identifier);
 
 public Q_SLOTS:
-    bool receiveMessage(const QString &sender, const QString &message);
+    bool receiveMessage(const QString &sender, const QString &senderName, const QString &message);
     void setContactList(const QStringList &identifiers);
 
 Q_SIGNALS:
diff --git a/plugins/telepathy/telepathy-cm/protocol.cpp b/plugins/telepathy/telepathy-cm/protocol.cpp
index eb4fbb3..167b667 100644
--- a/plugins/telepathy/telepathy-cm/protocol.cpp
+++ b/plugins/telepathy/telepathy-cm/protocol.cpp
@@ -63,10 +63,10 @@ void KDEConnectTelepathyProtocol::setConnectionManagerName(const QString &newNam
     m_connectionManagerName = newName;
 }
 
-bool KDEConnectTelepathyProtocol::sendMessage(QString sender, QString message)
+bool KDEConnectTelepathyProtocol::sendMessage(QString sender, QString senderName, QString message)
 {
     if (m_connection) {
-        return m_connection->receiveMessage(sender, message);
+        return m_connection->receiveMessage(sender, senderName, message);
     }
     return false;
 }
diff --git a/plugins/telepathy/telepathy-cm/protocol.h b/plugins/telepathy/telepathy-cm/protocol.h
index adde5d5..c4b8ffd 100644
--- a/plugins/telepathy/telepathy-cm/protocol.h
+++ b/plugins/telepathy/telepathy-cm/protocol.h
@@ -32,7 +32,7 @@ public:
     void setConnectionManagerName(const QString &newName);
 
 public Q_SLOTS:
-    bool sendMessage(QString sender, QString message);
+    bool sendMessage(QString sender, QString senderName, QString message);
     void setContactList(QStringList list);
 
 Q_SIGNALS:
diff --git a/plugins/telephony/telephonyplugin.cpp b/plugins/telephony/telephonyplugin.cpp
index c682ec7..5942873 100644
--- a/plugins/telephony/telephonyplugin.cpp
+++ b/plugins/telephony/telephonyplugin.cpp
@@ -51,7 +51,7 @@ KNotification* TelephonyPlugin::createNotification(const NetworkPackage& np)
     if (event == QLatin1String("sms") && m_telepathyInterface.isValid()) {
         qCDebug(KDECONNECT_PLUGIN_TELEPHONY) << "Passing a text message to the telepathy interface";
         const QString messageBody = np.get<QString>("messageBody","");
-        m_telepathyInterface.asyncCall("sendMessage", contactName, messageBody);
+        m_telepathyInterface.asyncCall("sendMessage", phoneNumber, contactName, messageBody);
         return nullptr;
     }
 

-- 
kdeconnect packaging



More information about the pkg-kde-commits mailing list