Needs c815c7a9bc
Currently the logic is very fragile and depends on the data being an url.
However the data of the match is an implementation detail and is in case of the KCM matches
a KPluginMetaData instance.
To avoid this issue the first url of the QueryMatch::urls() return value is checked.
This data is intended for mime-type/scheme related operations.
In the future we need an extra url for systemsettings & should consistently use the
urls of the query match. I will work on this before continuing to port the
plasma KCMs from KServiceTypeTrader.
BUG: 442522
This was deprecated, because having string based key-actions values
does not fit the usecases we have.
Consequently we should check if the runner has any QAction children, this
works if the runner created the QActions manually or if the actions
are registered in the abstract runner.
Also we can drop the ugly hack.
Add explicit find_package() and #include's that are required and were
pulled in by KDELibs4Support.
krdb: remove one redundant #include, KColorUtils
kcm_fonts: send dbus message directly to org.kde.KDEPlatformTheme to
'refreshFonts'
kcm_style:
- use KToolBar::emitToolbarStyleChanged() to notify of toolbar style changes
For the rest use the notifyKcmChange() private method to send the dbus
signal.
[1] https://invent.kde.org/frameworks/kdelibs4support/-/blob/master/src/kdeui/kglobalsettings.cpp#L860
Fixes regression caused by me meddling with data in 6e660cf92d
Unfortunately KRunner has no notion of "this is application xyz" so Kicker has to make assumptions, which broke here.
Differential Revision: https://phabricator.kde.org/D29744
Summary:
RunnerMatchesModel is backed by a list. When this list changes
RunnerManagerModel add/removes the new number of rows then called
dataChanged on everything that remained.
It's a common pattern, but not a great one. Especially with QtQuick
where moving a delegate is faster than updating all the properties of an
existing one - unfortunately I can't find a nice solution to do this
properly in linear time.
The problem with the current code is we update the entire list in the
insert/remove rows. This is a violation of the model rules as we're
updating rows outside the rows listed inside begin/remove rows.
It works, but Qt's model test fails.
We also have a lot of duplicates of a crash in QtQuick after runner
model changes, bug 369430. I think it could be related, but can't
prove anything.
This patch updates the rows that exist in both the before and after
models before adding/removing the remaining rows.
BUG: 402439
Test Plan:
Added Qt model tester in https://phabricator.kde.org/P283
It now passes.
Reviewers: #plasma, hein
Reviewed By: #plasma, hein
Subscribers: hein, apol, plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D17725
For KCMs we get a relative entryPath() for our KService resulting in an invalid URL being created.
BUG: 397070
FIXED-IN: 5.14.0
Differential Revision: https://phabricator.kde.org/D14647
Summary:
When the code was refactored to show this action also for runner
matches, proper care wasn't taken to test for this, so the action
was shown for document matches as well. It's not safe to use for
docs currently (which should probably be fixed in
KPropertiesDialog) and at any rate isn't meant to be a generic
editing feature as per the action name.
BUG:388340
Reviewers: #plasma, broulik, davidedmundson
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D9612
* Not just apps, also documents and contacts can now be added
to the favorites. All types of content have their full context
menu action list available also in the favorites sidebar.
* Contact favorites use the contact photo as icon, with a circular
alpha mask and the presence status icon as overlay badge.
* Adding/removing favorites from context menus now works every-
where, e.g. also in KRunner-based search results.
* Far fewer actions now cause a full rebuild of the model tree
and instead only delta updates, as a side-effect of adding a
mechanism for this to e.g. handle status changes for contact
items.
* Various bugs around hiding/unhiding apps got fixed.
* Lots of code cleanup + less coupling all around.
This version is a mostly-from-scratch reimplementation of
the Plasma 1 version.
Some minor-in-scope loose ends are left, both external and
internal to the code; check TODO for whether your issue is
already known.