mirror of
https://gitlab.alpinelinux.org/alpine/aports.git
synced 2025-07-23 03:05:48 +03:00
111 lines
3.6 KiB
Diff
111 lines
3.6 KiB
Diff
From 092dffc1afc65e4decc23d8f28b06ebb4ddbd2d2 Mon Sep 17 00:00:00 2001
|
|
From: Sergey Chupligin <s.chupligin@omprussia.ru>
|
|
Date: Tue, 15 Oct 2019 13:05:33 +0300
|
|
Subject: [PATCH] [nemo-qml-contacts] Update API for QtPim 5.9
|
|
|
|
---
|
|
rpm/nemo-qml-plugin-contacts-qt5.spec | 9 ++++++---
|
|
src/seasideperson.cpp | 2 ++
|
|
tools/contacts-tool/main.cpp | 8 +++++---
|
|
tools/vcardconverter/main.cpp | 2 ++
|
|
4 files changed, 15 insertions(+), 6 deletions(-)
|
|
|
|
diff --git a/rpm/nemo-qml-plugin-contacts-qt5.spec b/rpm/nemo-qml-plugin-contacts-qt5.spec
|
|
index 55ea2f6..ea6ff5b 100644
|
|
--- a/rpm/nemo-qml-plugin-contacts-qt5.spec
|
|
+++ b/rpm/nemo-qml-plugin-contacts-qt5.spec
|
|
@@ -1,7 +1,7 @@
|
|
Name: nemo-qml-plugin-contacts-qt5
|
|
|
|
Summary: Nemo QML contacts plugin
|
|
-Version: 0.2.25
|
|
+Version: 0.2.26
|
|
Release: 1
|
|
Group: System/Libraries
|
|
License: BSD
|
|
@@ -10,7 +10,6 @@ Source0: %{name}-%{version}.tar.bz2
|
|
Requires: qtcontacts-sqlite-qt5 >= 0.1.37
|
|
BuildRequires: pkgconfig(Qt5Core)
|
|
BuildRequires: pkgconfig(Qt5Qml)
|
|
-BuildRequires: pkgconfig(Qt5Contacts)
|
|
BuildRequires: pkgconfig(Qt5Versit)
|
|
BuildRequires: pkgconfig(Qt5Test)
|
|
BuildRequires: pkgconfig(qtcontacts-sqlite-qt5-extensions) >= 0.2.31
|
|
@@ -19,13 +18,17 @@ BuildRequires: pkgconfig(mlocale5)
|
|
BuildRequires: pkgconfig(mlite5)
|
|
BuildRequires: qt5-qttools-linguist
|
|
BuildRequires: qt5-qttools
|
|
+#Because pkgconfig QtContacts always return 5.0.0 use packages version
|
|
+BuildRequires: qt5-qtpim-contacts-devel >= 5.8
|
|
+Requires: qt5-qtpim-contacts >= 5.8
|
|
+
|
|
|
|
%description
|
|
%{summary}.
|
|
|
|
%package ts-devel
|
|
Summary: Translation source for nemo-qml-plugin-contacts-qt5
|
|
-Group: System/Libraries
|
|
+Group: Development/Languages
|
|
|
|
%description ts-devel
|
|
Translation source for nemo-qml-plugin-contacts-qt5
|
|
diff --git a/src/seasideperson.cpp b/src/seasideperson.cpp
|
|
index 77a9048..69c0c6c 100644
|
|
--- a/src/seasideperson.cpp
|
|
+++ b/src/seasideperson.cpp
|
|
@@ -53,6 +53,8 @@
|
|
#include <QVersitWriter>
|
|
#include <QVersitContactExporter>
|
|
|
|
+#include <QDebug>
|
|
+
|
|
QTVERSIT_USE_NAMESPACE
|
|
|
|
SeasidePersonAttached::SeasidePersonAttached(QObject *parent)
|
|
diff --git a/tools/contacts-tool/main.cpp b/tools/contacts-tool/main.cpp
|
|
index 93c2276..f942c19 100644
|
|
--- a/tools/contacts-tool/main.cpp
|
|
+++ b/tools/contacts-tool/main.cpp
|
|
@@ -64,6 +64,8 @@
|
|
#include <QContactTimestamp>
|
|
#include <QContactUrl>
|
|
|
|
+#include <QDebug>
|
|
+
|
|
QTCONTACTS_USE_NAMESPACE
|
|
|
|
namespace {
|
|
@@ -193,11 +195,11 @@ QString displayLabel(const QContact &contact)
|
|
|
|
void getRelatedContacts(const QContact &contact, QSet<quint32> *constituents, QSet<quint32> *aggregates)
|
|
{
|
|
- const quint32 id(numericId(contact));
|
|
+ const quint32 id(contact.id().localId().toInt());
|
|
|
|
foreach (const QContactRelationship &relationship, contact.relationships(QString::fromLatin1("Aggregates"))) {
|
|
- const quint32 firstId(numericId(relationship.first()));
|
|
- const quint32 secondId(numericId(relationship.second()));
|
|
+ const quint32 firstId(relationship.first().localId().toInt());
|
|
+ const quint32 secondId(relationship.second().localId().toInt());
|
|
if ((firstId == id) && constituents) {
|
|
constituents->insert(secondId);
|
|
} else if ((secondId == id) && aggregates) {
|
|
diff --git a/tools/vcardconverter/main.cpp b/tools/vcardconverter/main.cpp
|
|
index 1c57ea3..43a0ae6 100644
|
|
--- a/tools/vcardconverter/main.cpp
|
|
+++ b/tools/vcardconverter/main.cpp
|
|
@@ -37,11 +37,13 @@
|
|
#include <QFile>
|
|
#include <QTextStream>
|
|
#include <QTimer>
|
|
+#include <QDebug>
|
|
|
|
// Contacts
|
|
#include <QContactDetailFilter>
|
|
#include <QContactManager>
|
|
#include <QContactSyncTarget>
|
|
+#include <QContactDisplayLabel>
|
|
|
|
// Versit
|
|
#include <QVersitReader>
|