D6513: Add support for Attica tags support

Christoph Feck noreply at phabricator.kde.org
Thu Aug 2 15:09:02 BST 2018


cfeck added inline comments.

INLINE COMMENTS

> atticaprovider.cpp:276
>      Q_FOREACH (const Content &content, contents) {
> -        mCachedContent.insert(content.id(), content);
> -        entries.append(entryFromAtticaContent(content));
> +        if(checker.filterAccepts(content.tags())) {
> +            bool filterAcceptsDownloads = true;

Coding style: Space after `if` (multiple occurences).

> atticaprovider.cpp:280
> +                filterAcceptsDownloads = false;
> +                foreach(const Attica::DownloadDescription & dli, content.downloadUrlDescriptions()) {
> +                    if(downloadschecker.filterAccepts(dli.tags())) {

Space after `foreach`. No space after `&`.

> atticaprovider.cpp:291
> +            }
> +            else {
> +                qCDebug(KNEWSTUFFCORE) << "Filter has excluded" << content.name() << "on download filter" << mCurrentRequest.downloadTagFilter;

Frameworks coding style:

  if (...) {
      ...
  } else {
      ...
  }

> engine.h:239
> +     */
> +    void addTagFilter(const QString& filter);
> +    /**

const QString &filter

> tagsfilterchecker.cpp:27
> +
> +class TagsFilterChecker::Private
> +{

This could be marked non-exported.

Please also check this and all other new files for coding style issues. If unsure, run it through the `astyle-kdelibs` or `uncrustify-kf5` script from `kde-dev-scripts.git`.

> khotnewstuff_test.knsrc.in:3
>  #ProvidersUrl=http://edu.kde.org/kalzium/molecules.xml
> -ProvidersUrl=http://new.kstuff.org/provider-kalzium.xml
> +#ProvidersUrl=http://new.kstuff.org/provider-kalzium.xml
> +ProvidersUrl=file://@CMAKE_CURRENT_SOURCE_DIR@/testdata/provider.xml

Do we still need the kalzium references?

REPOSITORY
  R304 KNewStuff

REVISION DETAIL
  https://phabricator.kde.org/D6513

To: leinir, #knewstuff, apol, #kde_store, whiting, ahiemstra, mlaurent
Cc: cfeck, mlaurent, ngraham, ahiemstra, kde-frameworks-devel, #knewstuff, michaelh, ZrenBot, bruns
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kde-frameworks-devel/attachments/20180802/8d2f0066/attachment-0001.html>


More information about the Kde-frameworks-devel mailing list