It's used from KService, which works with desktop files, add support to parse xdg lists.
Details
- Reviewers
- None
- Group Reviewers
Frameworks
Enabled it from kservice and used:
ktraderclient5 --servicetype Application --constraint "exist Exec and (exist [X-Flatpak-RenamedFrom] and 'telegramdesktop.desktop' in [X-Flatpak-RenamedFrom])"
Diff Detail
- Repository
- R237 KConfig
- Branch
- master
- Lint
No Linters Available - Unit
No Unit Test Coverage - Build Status
Buildable 15670 Build 15688: arc lint + arc unit
src/core/kconfiggroup.h | ||
---|---|---|
653 | No bool flags, please :) https://community.kde.org/Policies/Library_Code_Policy#Flags |
src/core/kconfiggroup.h | ||
---|---|---|
653 | Thought about it, it's private API, are you sure it makes sense to have an enum just for this? |
src/core/kconfiggroup.h | ||
---|---|---|
655 | this must be kept non-inline, otherwise it's a symbol loss (and thus a BIC change) |
src/core/kconfiggroup.h | ||
---|---|---|
653 | Still helps readers of codes which calls this method. IMHO one should not make a difference in API style for public and private users, both deserve same nice treatment. My 2 cents. |
How exactly are you using ths from KService? If just by passing the flag set, won't this break any existing custom properties which are relying on "," as separator?
grep "Type=QStringList" /usr/share/kservicetypes5/ -r hints there are quite some properties which no longer would be properly parsed then for existing desktop files?
diff --git a/src/services/kservice.cpp b/src/services/kservice.cpp index f89c1f1..7d85153 100644 --- a/src/services/kservice.cpp +++ b/src/services/kservice.cpp @@ -560,7 +560,7 @@ QVariant KServicePrivate::property(const QString &_name, QVariant::Type t) const // All others // For instance properties defined as StringList, like MimeTypes. // XXX This API is accessible only through a friend declaration. - return KConfigGroup::convertToQVariant(_name.toUtf8().constData(), it->toString().toUtf8(), t); + return KConfigGroup::convertToQVariant(_name.toUtf8().constData(), it->toString().toUtf8(), t, true);
grep "Type=QStringList" /usr/share/kservicetypes5/ -r hints there are quite some properties which no longer would be properly parsed then for existing desktop files?
Yes, there's a lot of misconstructed desktop files in KDE due to this bug (and similar, I presume). Hence the e-mail I sent.