X-Git-Url: https://vcs.maemo.org/git/?a=blobdiff_plain;f=EventTypes%2FPhoneCall.cpp;h=7997fc2dbb4d252efe06b03c70aef834decf9797;hb=ede40b26168c61bd22caae822aac44fd15da74bc;hp=bfed790aab8228685a9d02ef5719c120017a7875;hpb=09cf284409d11f5269cbc106429046f993bffa68;p=qwerkisync diff --git a/EventTypes/PhoneCall.cpp b/EventTypes/PhoneCall.cpp index bfed790..7997fc2 100644 --- a/EventTypes/PhoneCall.cpp +++ b/EventTypes/PhoneCall.cpp @@ -61,7 +61,7 @@ PhoneCall::~PhoneCall() PhoneCall::PhoneCall(const Settings &settings, const RTComElEvent &event, const QList attachments) : m_Settings(settings) { - setDestination(event.fld_outgoing ? OUTGOING : INCOMING); + setDestination(event.fld_outgoing ? Settings::OUTGOING : Settings::INCOMING); setTimestamp(QDateTime::fromTime_t(event.fld_start_time).toUTC()); setDurationInSeconds(QDateTime::fromTime_t(event.fld_start_time).toUTC().secsTo(QDateTime::fromTime_t(event.fld_end_time).toUTC())); setTel(event.fld_remote_uid); @@ -75,7 +75,7 @@ PhoneCall::PhoneCall(const Settings &settings, const RTComElEvent &event, const qDebug() << "Created new Phone Call from RtCom:\n" << *this; } -PhoneCall::PhoneCall(const Settings &settings, const eDestination destination, const QDateTime ×tamp, const QString &tel, int durationInSeconds, const AttachmentCollection &attachments) : +PhoneCall::PhoneCall(const Settings &settings, const Settings::eDirection destination, const QDateTime ×tamp, const QString &tel, int durationInSeconds, const AttachmentCollection &attachments) : m_Settings(settings), m_Destination(destination), m_Timestamp(timestamp), m_Tel(tel), m_DurationInSeconds(durationInSeconds), m_Attachments(attachments) { @@ -129,7 +129,7 @@ RTComElEvent * PhoneCall::toRTComEvent(const NumberToNameLookup &numberToNameLoo RTCOM_EL_EVENT_SET_FIELD (event, end_time, Timestamp().addSecs(DurationInSeconds()).toUTC().toTime_t()); RTCOM_EL_EVENT_SET_FIELD (event, storage_time, Timestamp().addSecs(DurationInSeconds()).toUTC().toTime_t()); //RTCOM_EL_EVENT_SET_FIELD (event, is_read, 0); - RTCOM_EL_EVENT_SET_FIELD (event, outgoing, Destination() == PhoneCall::OUTGOING ? 1 : 0); + RTCOM_EL_EVENT_SET_FIELD (event, outgoing, Destination() == Settings::OUTGOING ? 1 : 0); //if(local_uid) // Voicemail local_uid transform needed here RTCOM_EL_EVENT_SET_FIELD (event, local_uid, g_strdup("ring/tel/ring")); //RTCOM_EL_EVENT_SET_FIELD (&event, local_name, g_strdup("")); @@ -175,7 +175,8 @@ void PhoneCall::Export(const QString &baseDirectory) const QDebug operator<<(QDebug dbg, PhoneCall& event) { - dbg.nospace() << "\tDirection:\t\t" << (event.Destination() == PhoneCall::OUTGOING ? "Made" : "Recieved") << "\n"; + dbg.nospace() << "\tHash:\t\t" << event.HashCode() << "\n"; + dbg.nospace() << "\tDirection:\t\t" << (event.Destination() == Settings::OUTGOING ? "Made" : "Recieved") << "\n"; dbg.nospace() << "\tTimestamp:\t" << event.Timestamp().toUTC() << "\n"; dbg.nospace() << "\tDuration:\t\t" << event.DurationInSeconds() << " seconds\n"; dbg.nospace() << "\tRemote-Tel:\t" << event.Tel() << "\n";