Commit b30371d1 authored by Albert Vaca Cintora's avatar Albert Vaca Cintora

Telephony "notifications" are now called "events"

parent 12c0c940
......@@ -35,24 +35,24 @@ TelephonyPlugin::TelephonyPlugin(QObject *parent, const QVariantList &args)
KNotification* TelephonyPlugin::createNotification(const NetworkPackage& np)
{
QString npType = np.get<QString>("notificationType");
QString event = np.get<QString>("event");
QString title, content, type, icon;
bool transient;
title = device()->name();
if (npType == "ringing") {
if (event == "ringing") {
type = "callReceived";
icon = "call-start";
content = "Incoming call from " + np.get<QString>("phoneNumber","unknown number");
transient = false;
} else if (npType == "missedCall") {
} else if (event == "missedCall") {
type = "missedCall";
icon = "call-start";
content = "Missed call from " + np.get<QString>("phoneNumber","unknown number");
transient = true;
} else if (npType == "sms") {
} else if (event == "sms") {
type = "smsReceived";
icon = "mail-receive";
content = "SMS from "
......@@ -64,7 +64,7 @@ KNotification* TelephonyPlugin::createNotification(const NetworkPackage& np)
//TODO: return NULL if !debug
type = "unknownEvent";
icon = "pda";
content = "Unknown notification type: " + npType;
content = "Unknown notification type: " + event;
transient = false;
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment