Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package kcalendarcore for openSUSE:Factory checked in at 2022-08-15 19:57:04 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/kcalendarcore (Old) and /work/SRC/openSUSE:Factory/.kcalendarcore.new.1521 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "kcalendarcore" Mon Aug 15 19:57:04 2022 rev:35 rq:994953 version:5.97.0 Changes: -------- --- /work/SRC/openSUSE:Factory/kcalendarcore/kcalendarcore.changes 2022-07-11 19:09:34.679624489 +0200 +++ /work/SRC/openSUSE:Factory/.kcalendarcore.new.1521/kcalendarcore.changes 2022-08-15 19:59:01.397194470 +0200 @@ -1,0 +2,11 @@ +Sun Aug 7 22:27:12 UTC 2022 - Christophe Giboudeaux <christo...@krop.fr> + +- Update to 5.97.0 + * New feature release + * For more details please see: + * https://kde.org/announcements/frameworks/5/5.97.0 +- Changes since 5.96.0: + * Deprecate deletion tracking support in CalFormat::fromString + * Add plugin loader for KCalendarCore::CalendarPlugin + +------------------------------------------------------------------- Old: ---- kcalendarcore-5.96.0.tar.xz kcalendarcore-5.96.0.tar.xz.sig New: ---- kcalendarcore-5.97.0.tar.xz kcalendarcore-5.97.0.tar.xz.sig ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ kcalendarcore.spec ++++++ --- /var/tmp/diff_new_pack.mNPxgS/_old 2022-08-15 19:59:01.817195642 +0200 +++ /var/tmp/diff_new_pack.mNPxgS/_new 2022-08-15 19:59:01.825195663 +0200 @@ -16,14 +16,14 @@ # -%define _tar_path 5.96 +%define _tar_path 5.97 # Full KF5 version (e.g. 5.33.0) %{!?_kf5_version: %global _kf5_version %{version}} # Last major and minor KF5 version (e.g. 5.33) %{!?_kf5_bugfix_version: %define _kf5_bugfix_version %(echo %{_kf5_version} | awk -F. '{print $1"."$2}')} %bcond_without released Name: kcalendarcore -Version: 5.96.0 +Version: 5.97.0 Release: 0 Summary: Library to access and handle calendar data License: LGPL-2.0-or-later ++++++ kcalendarcore-5.96.0.tar.xz -> kcalendarcore-5.97.0.tar.xz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/CMakeLists.txt new/kcalendarcore-5.97.0/CMakeLists.txt --- old/kcalendarcore-5.96.0/CMakeLists.txt 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/CMakeLists.txt 2022-08-07 14:14:21.000000000 +0200 @@ -1,11 +1,11 @@ cmake_minimum_required(VERSION 3.16) -set(KF_VERSION "5.96.0") # handled by release scripts +set(KF_VERSION "5.97.0") # handled by release scripts project(KCalendarCore VERSION ${KF_VERSION}) # ECM setup include(FeatureSummary) -find_package(ECM 5.96.0 NO_MODULE) +find_package(ECM 5.97.0 NO_MODULE) set_package_properties(ECM PROPERTIES TYPE REQUIRED DESCRIPTION "Extra CMake Modules." URL "https://commits.kde.org/extra-cmake-modules") feature_summary(WHAT REQUIRED_PACKAGES_NOT_FOUND FATAL_ON_MISSING_REQUIRED_PACKAGES) diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/CMakeLists.txt new/kcalendarcore-5.97.0/src/CMakeLists.txt --- old/kcalendarcore-5.96.0/src/CMakeLists.txt 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/CMakeLists.txt 2022-08-07 14:14:21.000000000 +0200 @@ -19,6 +19,8 @@ calendar_p.h calendarplugin.cpp calendarplugin.h + calendarpluginloader.cpp + calendarpluginloader.h calfilter.cpp calfilter.h calformat.cpp @@ -101,7 +103,7 @@ GROUP_BASE_NAME KF VERSION ${KF_VERSION} DEPRECATED_BASE_VERSION 0 - DEPRECATION_VERSIONS 5.64 5.89 5.91 5.95 5.96 + DEPRECATION_VERSIONS 5.64 5.89 5.91 5.95 5.96 5.97 EXCLUDE_DEPRECATED_BEFORE_AND_AT ${EXCLUDE_DEPRECATED_BEFORE_AND_AT} ) @@ -134,6 +136,7 @@ CalStorage Calendar CalendarPlugin + CalendarPluginLoader Conference CustomProperties Duration diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/calendarpluginloader.cpp new/kcalendarcore-5.97.0/src/calendarpluginloader.cpp --- old/kcalendarcore-5.96.0/src/calendarpluginloader.cpp 1970-01-01 01:00:00.000000000 +0100 +++ new/kcalendarcore-5.97.0/src/calendarpluginloader.cpp 2022-08-07 14:14:21.000000000 +0200 @@ -0,0 +1,60 @@ +/* + SPDX-FileCopyrightText: 2022 Volker Krause <vkra...@kde.org> + SPDX-License-Identifier: LGPL-2.0-or-later +*/ + +#include "calendarpluginloader.h" + +#include <QCoreApplication> +#include <QDirIterator> +#include <QPluginLoader> + +using namespace KCalendarCore; + +struct PluginLoader { + PluginLoader(); + std::unique_ptr<KCalendarCore::CalendarPlugin> plugin; +}; + +PluginLoader::PluginLoader() +{ + // static plugins + const auto staticPluginData = QPluginLoader::staticPlugins(); + for (const auto &data : staticPluginData) { + if (data.metaData().value(QLatin1String("IID")).toString() == QLatin1String("org.kde.kcalendarcore.CalendarPlugin")) { + plugin.reset(qobject_cast<KCalendarCore::CalendarPlugin *>(data.instance())); + } + if (plugin) { + return; + } + } + + // dynamic plugins + QStringList searchPaths(QCoreApplication::applicationDirPath()); + searchPaths += QCoreApplication::libraryPaths(); + + for (const auto &searchPath : std::as_const(searchPaths)) { + const QString pluginPath = searchPath + QLatin1String("/kf" QT_STRINGIFY(QT_VERSION_MAJOR) "/org.kde.kcalendarcore.calendars"); + for (QDirIterator it(pluginPath, QDir::Files); it.hasNext() && !plugin;) { + it.next(); + QPluginLoader loader(it.fileInfo().absoluteFilePath()); + if (loader.load()) { + plugin.reset(qobject_cast<KCalendarCore::CalendarPlugin *>(loader.instance())); + } else { + qDebug() << loader.errorString(); + } + } + } +} + +Q_GLOBAL_STATIC(PluginLoader, s_pluginLoader) + +bool CalendarPluginLoader::hasPlugin() +{ + return (bool)s_pluginLoader->plugin; +} + +KCalendarCore::CalendarPlugin *CalendarPluginLoader::plugin() +{ + return s_pluginLoader->plugin.get(); +} diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/calendarpluginloader.h new/kcalendarcore-5.97.0/src/calendarpluginloader.h --- old/kcalendarcore-5.96.0/src/calendarpluginloader.h 1970-01-01 01:00:00.000000000 +0100 +++ new/kcalendarcore-5.97.0/src/calendarpluginloader.h 2022-08-07 14:14:21.000000000 +0200 @@ -0,0 +1,36 @@ +/* + SPDX-FileCopyrightText: 2022 Volker Krause <vkra...@kde.org> + SPDX-License-Identifier: LGPL-2.0-or-later +*/ + +#ifndef KCALENDARCORE_CALENDARPLUGINLOADER_H +#define KCALENDARCORE_CALENDARPLUGINLOADER_H + +#include "kcalendarcore_export.h" + +#include <KCalendarCore/CalendarPlugin> + +namespace KCalendarCore +{ + +/** + * Provides access to a KCalendarCore::CalendarPlugin instance, if available. + * @since 5.97 + */ +class KCALENDARCORE_EXPORT CalendarPluginLoader +{ + Q_GADGET + Q_PROPERTY(bool hasPlugin READ hasPlugin) + Q_PROPERTY(KCalendarCore::CalendarPlugin *plugin READ plugin) + +public: + /** Returns @c true if there is a platform calendar available. */ + static bool hasPlugin(); + + /** Returns the platform calendar plugin. */ + static KCalendarCore::CalendarPlugin *plugin(); +}; + +} + +#endif // KCALENDARCORE_CALENDARPLUGINLOADER_H diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/calformat.cpp new/kcalendarcore-5.97.0/src/calformat.cpp --- old/kcalendarcore-5.96.0/src/calformat.cpp 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/calformat.cpp 2022-08-07 14:14:21.000000000 +0200 @@ -46,6 +46,11 @@ clearException(); } +bool CalFormat::fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook) +{ + return fromRawString(calendar, string.toUtf8(), false, notebook); +} + void CalFormat::clearException() { d_ptr->mException.reset(); diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/calformat.h new/kcalendarcore-5.97.0/src/calformat.h --- old/kcalendarcore-5.96.0/src/calformat.h 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/calformat.h 2022-08-07 14:14:21.000000000 +0200 @@ -72,6 +72,7 @@ */ virtual bool save(const Calendar::Ptr &calendar, const QString &fileName) = 0; +#if KCALENDARCORE_BUILD_DEPRECATED_SINCE(5, 97) /** Loads a calendar from a string. When a notebook is given, incidences are added to this notebook, otherwise no notebook is associated to loaded incidences. The notebook @@ -84,8 +85,27 @@ @return true if successful; false otherwise. @see fromRawString(), toString(). + + @deprecated since 5.97, use fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook) instead. + */ + KCALENDARCORE_DEPRECATED_VERSION(5, 97, "use fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook)") + virtual bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted, const QString ¬ebook = {}) = 0; +#endif + /** + Loads a calendar from a string. When a notebook is given, incidences are added to this + notebook, otherwise no notebook is associated to loaded incidences. The notebook + should already be added to the calendar, see Calendar::addNotebook(). + + @param calendar is the Calendar to be loaded. + @param string is the QString containing the Calendar data. + @param notebook notebook uid + + @return true if successful; false otherwise. + @see fromRawString(), toString(). + + @since 5.97 */ - virtual bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted = false, const QString ¬ebook = QString()) = 0; + bool fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook = {}); /** Parses a utf8 encoded string, returning the first iCal component diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/icalformat.cpp new/kcalendarcore-5.97.0/src/icalformat.cpp --- old/kcalendarcore-5.96.0/src/icalformat.cpp 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/icalformat.cpp 2022-08-07 14:14:21.000000000 +0200 @@ -137,10 +137,12 @@ return true; } +#if KCALENDARCORE_BUILD_DEPRECATED_SINCE(5, 97) bool ICalFormat::fromString(const Calendar::Ptr &cal, const QString &string, bool deleted, const QString ¬ebook) { return fromRawString(cal, string.toUtf8(), deleted, notebook); } +#endif Incidence::Ptr ICalFormat::readIncidence(const QByteArray &string) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/icalformat.h new/kcalendarcore-5.97.0/src/icalformat.h --- old/kcalendarcore-5.96.0/src/icalformat.h 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/icalformat.h 2022-08-07 14:14:21.000000000 +0200 @@ -66,11 +66,15 @@ */ bool save(const Calendar::Ptr &calendar, const QString &fileName) override; +#if KCALENDARCORE_BUILD_DEPRECATED_SINCE(5, 97) /** @copydoc CalFormat::fromString() */ - bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted = false, const QString ¬ebook = QString()) override; + KCALENDARCORE_DEPRECATED_VERSION(5, 97, "use fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook)") + bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted, const QString ¬ebook) override; + using CalFormat::fromString; +#endif /** Parses a string, returning the first iCal component as an Incidence. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/vcalformat.cpp new/kcalendarcore-5.97.0/src/vcalformat.cpp --- old/kcalendarcore-5.96.0/src/vcalformat.cpp 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/vcalformat.cpp 2022-08-07 14:14:21.000000000 +0200 @@ -126,10 +126,12 @@ return false; } +#if KCALENDARCORE_BUILD_DEPRECATED_SINCE(5, 97) bool VCalFormat::fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted, const QString ¬ebook) { return fromRawString(calendar, string.toUtf8(), deleted, notebook); } +#endif bool VCalFormat::fromRawString(const Calendar::Ptr &calendar, const QByteArray &string, bool deleted, const QString ¬ebook) { diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/kcalendarcore-5.96.0/src/vcalformat.h new/kcalendarcore-5.97.0/src/vcalformat.h --- old/kcalendarcore-5.96.0/src/vcalformat.h 2022-07-02 16:29:36.000000000 +0200 +++ new/kcalendarcore-5.97.0/src/vcalformat.h 2022-08-07 14:14:21.000000000 +0200 @@ -82,11 +82,15 @@ */ bool save(const Calendar::Ptr &calendar, const QString &fileName) override; +#if KCALENDARCORE_BUILD_DEPRECATED_SINCE(5, 97) /** @copydoc CalFormat::fromString() */ - Q_REQUIRED_RESULT bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted = false, const QString ¬ebook = QString()) override; + KCALENDARCORE_DEPRECATED_VERSION(5, 97, "use fromString(const Calendar::Ptr &calendar, const QString &string, const QString ¬ebook)") + Q_REQUIRED_RESULT bool fromString(const Calendar::Ptr &calendar, const QString &string, bool deleted, const QString ¬ebook = QString()) override; + using CalFormat::fromString; +#endif /** @copydoc