I have made the following changes intended for : CE:MW:Shared / commhistory-daemon
Please review and accept or decline. BOSS has already run some checks on this request. See the "Messages from BOSS" section below. https://build.pub.meego.com//request/show/6740 Thank You, John Brooks [This message was auto-generated] --- Request # 6740: Messages from BOSS: State: review at 2012-09-12T16:01:22 by bossbot Reviews: accepted by bossbot : Prechecks succeeded. new for CE-maintainers : Please replace this text with a review and approve/reject the review (not the SR). BOSS will take care of the rest Changes: submit: home:special:branches:CE:MW:Shared / commhistory-daemon -> CE:MW:Shared / commhistory-daemon changes files: -------------- --- commhistory-daemon.changes +++ commhistory-daemon.changes @@ -0,0 +1,5 @@ +* Wed Sep 12 2012 John Brooks <[email protected]> - 0.4.0 +- Imported patches to git and bumped version for fork +- Fix assertation in ContactAuthorizer caused by lookupContactByHandle fix +- Use org.nemomobile.qmlmessages for MESSAGING_SERVICE_NAME + old: ---- 0001-Some-defines-renamed-in-new-tp-qt.patch 0001-lookupContactByHandle-is-now-private.patch commhistory-daemon-0.3.2-fix-ignored-return-with-warn_unused_result.patch commhistory-daemon-0.3.2.tar.gz new: ---- commhistory-daemon-0.4.0.tar.bz2 spec files: ----------- --- commhistory-daemon.spec +++ commhistory-daemon.spec @@ -1,14 +1,11 @@ Name: commhistory-daemon Summary: Communications event history database daemon -Version: 0.3.2 +Version: 0.4.0 Release: 1 Group: Communications/Telephony and IM License: LGPL URL: http://gitorious.org/commhistory/commhistory-daemon -Source0: %{name}-%{version}.tar.gz -Patch0: commhistory-daemon-0.3.2-fix-ignored-return-with-warn_unused_result.patch -Patch1: 0001-Some-defines-renamed-in-new-tp-qt.patch -Patch2: 0001-lookupContactByHandle-is-now-private.patch +Source0: %{name}-%{version}.tar.bz2 BuildRequires: pkgconfig(QtCore) >= 4.7.0 BuildRequires: pkgconfig(QtContacts) BuildRequires: pkgconfig(commhistory) @@ -34,11 +31,7 @@ Daemon for logging communications (IM, SMS and call) in history database. %prep -%setup -q -n %{name}-%{version} - -%patch0 -p1 -%patch1 -p1 -%patch2 -p1 +%setup -q -n %{name} %build unset LD_AS_NEEDED other changes: -------------- ++++++ commhistory-daemon-0.3.2.tar.gz -> commhistory-daemon-0.4.0.tar.bz2 --- src/channellistener.cpp +++ src/channellistener.cpp @@ -141,7 +141,7 @@ void ChannelListener::invocationContextError() { - finishedWithError(QLatin1String(TELEPATHY_ERROR_INVALID_ARGUMENT),QString()); + finishedWithError(QLatin1String(TP_QT_ERROR_INVALID_ARGUMENT),QString()); } CommHistory::EventModel& ChannelListener::eventModel() @@ -161,8 +161,8 @@ if (properties.contains(TELEPATHY_CHANNEL_INTERFACE_PERSISTENT_ID)) { targetId = properties.value(TELEPATHY_CHANNEL_INTERFACE_PERSISTENT_ID).toString(); - } else if (properties.contains(QLatin1String(TELEPATHY_INTERFACE_CHANNEL ".TargetID"))) { - targetId = properties.value(QLatin1String(TELEPATHY_INTERFACE_CHANNEL ".TargetID")).toString(); + } else if (properties.contains(TP_QT_IFACE_CHANNEL+QLatin1String(".TargetID"))) { + targetId = properties.value(TP_QT_IFACE_CHANNEL+QLatin1String(".TargetID")).toString(); } return targetId; --- src/constants.h +++ src/constants.h @@ -39,9 +39,9 @@ #define COMM_HISTORY_OBJECT_PATH QLatin1String("/com/nokia/CommHistory") #define COMM_HISTORY_INTERFACE QLatin1String("com.nokia.CommHistoryIf") -#define MESSAGING_SERVICE_NAME QLatin1String("com.nokia.Messaging") -#define MESSAGING_INTERFACE QLatin1String("com.nokia.MessagingIf") -#define SHOW_INBOX_METHOD QLatin1String("showInbox") +#define MESSAGING_SERVICE_NAME QLatin1String("org.nemomobile.qmlmessages") +#define MESSAGING_INTERFACE QLatin1String("org.nemomobile.qmlmessages") +#define SHOW_INBOX_METHOD QLatin1String("showGroupsWindow") #define START_CONVERSATION_METHOD QLatin1String("startConversation") #define CALL_HISTORY_SERVICE_NAME QLatin1String("com.nokia.telephony.callhistory") --- src/contactauthorizer.cpp +++ src/contactauthorizer.cpp @@ -376,7 +376,7 @@ Tp::Contact *contact = qobject_cast<Tp::Contact*>(sender()); if (contact) { - Tp::ContactPtr contactPtr (m_pContactManager->lookupContactByHandle(contact->handle().first())); + Tp::ContactPtr contactPtr(m_pContactManager->contactsForHandles(contact->handle())->contacts().first()); queueAuthorization(contactPtr, data.fileName); } } --- src/logger.cpp +++ src/logger.cpp @@ -87,7 +87,7 @@ if ( m_Channels.contains( channelObjectPath ) && !channelType.isEmpty() && !channelObjectPath.isEmpty() ) { - context->setFinishedWithError(QLatin1String(TELEPATHY_ERROR_INVALID_ARGUMENT), QString()); + context->setFinishedWithError(QLatin1String(TP_QT_ERROR_INVALID_ARGUMENT), QString()); return; } @@ -99,11 +99,11 @@ qDebug() << "creating listener for: " << channelObjectPath << " type " << channelType; ChannelListener* listener = 0; - if( channelType == QLatin1String(TELEPATHY_INTERFACE_CHANNEL_TYPE_TEXT) ) { + if( channelType == QLatin1String(TP_QT_IFACE_CHANNEL_TYPE_TEXT) ) { listener = new TextChannelListener(account, channel, context, this); connect(listener, SIGNAL(savingFailed(const Tp::ConnectionPtr&)), m_Reviver, SLOT(checkConnection(const Tp::ConnectionPtr&))); - } else if ( channelType == QLatin1String(TELEPATHY_INTERFACE_CHANNEL_TYPE_STREAMED_MEDIA) ) { + } else if ( channelType == QLatin1String(TP_QT_IFACE_CHANNEL_TYPE_STREAMED_MEDIA) ) { listener = new StreamChannelListener(account, channel, context, this); } --- src/loggerclientobserver.cpp +++ src/loggerclientobserver.cpp @@ -54,7 +54,7 @@ if(m_pLogger) { foreach(Tp::ChannelPtr channel, channels) { QVariantMap properties = channel->immutableProperties(); - QString channelType = properties.value(QLatin1String(TELEPATHY_INTERFACE_CHANNEL ".ChannelType")).toString(); + QString channelType = properties.value(TP_QT_IFACE_CHANNEL+QLatin1String(".ChannelType")).toString(); if( !channelType.isNull() && !channelType.isEmpty()) { m_pLogger->createChannelListener(channelType, context, account, channel); } --- src/main.cpp +++ src/main.cpp @@ -88,7 +88,10 @@ void termSignalHandler(int) { char a = 1; - ::write(sigtermFd[0], &a, sizeof(a)); + if(write(sigtermFd[0], &a, sizeof(a)) < 1) + { + qWarning("Failed to handle term signal."); + } } void setupSigtermHandler() --- src/streamchannellistener.cpp +++ src/streamchannellistener.cpp @@ -34,8 +34,8 @@ #include <TelepathyQt4/StreamedMediaChannel> #define CURRENT_SERVICE_POINT_PROPERTY_NAME ("CurrentServicePoint") -#define INITIAL_SERVICE_POINT_PROPERTY QLatin1String(TELEPATHY_INTERFACE_CHANNEL_INTERFACE_SERVICE_POINT ".InitialServicePoint") -#define STREAM_CHANNEL_INITIAL_VIDEO_PROPERTY QLatin1String(TELEPATHY_INTERFACE_CHANNEL_TYPE_STREAMED_MEDIA ".InitialVideo") +#define INITIAL_SERVICE_POINT_PROPERTY TP_QT_IFACE_CHANNEL_INTERFACE_SERVICE_POINT+QLatin1String(".InitialServicePoint") +#define STREAM_CHANNEL_INITIAL_VIDEO_PROPERTY TP_QT_IFACE_CHANNEL_TYPE_STREAMED_MEDIA+QLatin1String(".InitialVideo") #define SAVING_INTERVAL 5*60000 // 5 minute @@ -73,8 +73,8 @@ m_Direction = CommHistory::Event::Inbound; QVariantMap properties = m_Channel->immutableProperties(); - if (properties.contains(QLatin1String(TELEPATHY_INTERFACE_CHANNEL ".Requested"))) { - if (properties.value(QLatin1String(TELEPATHY_INTERFACE_CHANNEL ".Requested")).toBool()) + if (properties.contains(TP_QT_IFACE_CHANNEL+QLatin1String(".Requested"))) { + if (properties.value(TP_QT_IFACE_CHANNEL+QLatin1String(".Requested")).toBool()) m_Direction = CommHistory::Event::Outbound; } m_Event.setDirection(m_Direction); @@ -305,7 +305,7 @@ // means "hung up by local user", but if the remote hangs up before // we get MembersChanged, tpqt probably returns the same error. if ( (m_Direction == CommHistory::Event::Inbound) && (!m_CallStarted)) { - if (!errorName.isEmpty() && errorName != TELEPATHY_ERROR_CANCELLED) + if (!errorName.isEmpty() && errorName != TP_QT_ERROR_CANCELLED) m_Event.setIsMissedCall(true); } --- src/textchannellistener.cpp +++ src/textchannellistener.cpp @@ -1984,7 +1984,7 @@ m_GroupHandleType = Tp::HandleTypeRoom; } else if (m_Channel->targetHandleType() == Tp::HandleTypeNone && m_Channel->interfaces().contains( - TELEPATHY_INTERFACE_CHANNEL_INTERFACE_GROUP)) { + TP_QT_IFACE_CHANNEL_INTERFACE_GROUP)) { m_IsGroupChat = true; m_GroupHandleType = Tp::HandleTypeNone; m_PersistentId = m_Channel->immutableProperties().value( @@ -1998,7 +1998,7 @@ } } - if (m_Channel->interfaces().contains(TELEPATHY_INTERFACE_CHANNEL_INTERFACE_GROUP)) + if (m_Channel->interfaces().contains(TP_QT_IFACE_CHANNEL_INTERFACE_GROUP)) connect(m_Channel.data(), SIGNAL(groupMembersChanged(const Tp::Contacts &, const Tp::Contacts &, --- tests/stubs/TelepathyQt4/constants.h +++ tests/stubs/TelepathyQt4/constants.h @@ -3164,6 +3164,7 @@ * building with Q_NO_CAST_FROM_ASCII defined. */ #define TP_QT4_IFACE_CHANNEL QLatin1String("org.freedesktop.Telepathy.Channel") +#define TP_QT_IFACE_CHANNEL QLatin1String("org.freedesktop.Telepathy.Channel") /** * \ingroup ifacestrconsts @@ -3224,6 +3225,7 @@ * building with Q_NO_CAST_FROM_ASCII defined. */ #define TP_QT4_IFACE_CHANNEL_TYPE_STREAMED_MEDIA QLatin1String("org.freedesktop.Telepathy.Channel.Type.StreamedMedia") +#define TP_QT_IFACE_CHANNEL_TYPE_STREAMED_MEDIA QLatin1String("org.freedesktop.Telepathy.Channel.Type.StreamedMedia") /** * \ingroup ifacestrconsts @@ -3389,6 +3391,7 @@ * building with Q_NO_CAST_FROM_ASCII defined. */ #define TP_QT4_IFACE_CHANNEL_INTERFACE_GROUP QLatin1String("org.freedesktop.Telepathy.Channel.Interface.Group") +#define TP_QT_IFACE_CHANNEL_INTERFACE_GROUP QLatin1String("org.freedesktop.Telepathy.Channel.Interface.Group") /** * \ingroup ifacestrconsts @@ -3464,6 +3467,7 @@ * building with Q_NO_CAST_FROM_ASCII defined. */ #define TP_QT4_IFACE_CHANNEL_INTERFACE_SERVICE_POINT QLatin1String("org.freedesktop.Telepathy.Channel.Interface.ServicePoint") +#define TP_QT_IFACE_CHANNEL_INTERFACE_SERVICE_POINT QLatin1String("org.freedesktop.Telepathy.Channel.Interface.ServicePoint") /** * \ingroup ifacestrconsts @@ -3808,6 +3812,7 @@ * Raised when one of the provided arguments is invalid. */ #define TP_QT4_ERROR_INVALID_ARGUMENT QLatin1String("org.freedesktop.Telepathy.Error.InvalidArgument") +#define TP_QT_ERROR_INVALID_ARGUMENT QLatin1String("org.freedesktop.Telepathy.Error.InvalidArgument") /** * \ingroup errorstrconsts @@ -4015,6 +4020,7 @@ * event queue. */ #define TP_QT4_ERROR_CANCELLED QLatin1String("org.freedesktop.Telepathy.Error.Cancelled") +#define TP_QT_ERROR_CANCELLED QLatin1String("org.freedesktop.Telepathy.Error.Cancelled") /** * \ingroup errorstrconsts ++++++ deleted files: --- 0001-Some-defines-renamed-in-new-tp-qt.patch --- 0001-lookupContactByHandle-is-now-private.patch --- commhistory-daemon-0.3.2-fix-ignored-return-with-warn_unused_result.patch
