Summary:
Hitting again a bug where switching desktops shows a delay of several seconds
before the taskbar updates, I noticed that this code path was called 81
times in 7 seconds (!) for kmail (maybe because I start it from cmdline
rather than via a .desktop file).
After the 4 slow calls to KWindowSystem::icon it seems definitely worth
it to cache the result.
Overall the main performance bug is still there though, switching
desktops is still slow, but now all backtraces show QML triggered
by model/view dataChanged signals, no idea yet, other than hoping
for the pending QSFPM patches to help with this (no need to re-sort
when the dataChanged roles are unrelated to the roles used for sorting).
Reviewers: hein
Reviewed By: hein
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D4600
Summary:
As this happens the screen filtering higher up in the proxy chain
culimating in TasksModel needs to be re-executed, as it compares
ScreenGeometry against a property value set on the model. Without
this update, tasks may disappear from views using TasksModel.
Mapping the trigger conditions to affected rows is deliberately
maximally coarse; see implementation comment in code.
BUG:373075
Reviewers: #plasma, davidedmundson
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D3628
If our regular expression matching found a service but there was also some non-regular expression rule in the file,
it would overwrite a potentially valid service match.
CCBUG: 372211
Differential Revision: https://phabricator.kde.org/D3309
Summary:
This adds support for app ids which are absolute paths to .desktop
files to WaylandTasksModel, matching the heuristic in XWindowsTasksModel.
Behavior between the two models is made more similar in various ways,
such as matching codepaths for generating the ids inserted into the
KActivities database in requestNewInstance/requestOpenUrls (also the
X11 model was missing the notifyAccessed calls) and producing launcher
URLs.
Icons are still left to KWin however, instead of reading them from
KService (which is what KWin does in any case on Wayland) or from the
.desktop file. The latter might make sense, but to avoid duplicated
code would then best be done in KWin.
Reviewers: #plasma, graesslin, broulik
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D3292
Summary:
The former depends on https://git.reviewboard.kde.org/r/129327/
The latter is a thematically related cleanup I did along the way.
The strange original code was probably to handle the NULL_UUID, but
TaskFilterProxyModel (where this data role becomes relevant)
developed the ability to do this since.
Reviewers: #plasma, graesslin
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D3262
Summary:
Utility windows (NET::Utility/_NET_WM_WINDOW_TYPE_UTILITY) should
not be on the Task Manager, but they should be on the Pager. This
patch achieves this by evaluating the window type in the
AbstractTasksModel::SkipTaskBar data role.
I considered the alternative approach of making a new
AbstractTasksModel::IsUtilityWindow (or similar) data role and
adding a pass to evaluate it to TaskFilterProxyModel, then
configuring the filter models in TasksModel and the Pager backend
differently. But this is not very extensible. Then I realized that
AbstractTasksModel data roles do not and should not reflect X11
idioms anyway; the point of the library is to abstract for the
purpose of UI, and what XWindowTasksModel considers "SkipTaskBar"
is really an implementation detail. This makes all the more sense
considering on Wayland we have no notion of window types (beyond
"popup") yet, and don't quite now how it's going to evolve.
Various API docstrings have been changed to better reflect that
the meaning of the data role doesn't map to anything specific in
the tasks.
BUG:368956
Reviewers: #plasma, davidedmundson, broulik
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D2807
Summary:
This makes grouping work for apps we can't find on the system and
can't produce a launcher URL for, such as wine clients. Any better
app will use our superior codepath, the wonky ones like wine then
get left to making sure their WM_CLASS Class makes sense as per the
ICCCM spec.
Of course this doesn't work for XWayland clients on Wayland though.
BUG:368078
Also nixes an obsolete FIXME and adds a small check to avoid
producing launcher URLs that are only the window icon pixmap
query element.
Reviewers: #plasma, davidedmundson, broulik
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D2804
Summary: For use by desktop pagers using libtaskmanager.
Reviewers: #plasma, davidedmundson
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D2674
Summary:
We've had bad experiences with state() in a plasma-framework testcase
and this is more readable regardless.
Reviewers: #plasma, graesslin
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D2181
Summary:
Avoids problems stemming from libtaskmanager and plasma-framework's
AppletInterface::screen numbering screens differently (QScreen order
vs. who knows what).
CCBUG:365246
Reviewers: #plasma, graesslin, mart
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D2143
Summary:
Acts like requestVirtualDesktops only with a QStringList
make runningActivities invokable
Test Plan: See subsequent plasma-desktop review
Reviewers: hein, #plasma
Reviewed By: hein, #plasma
Subscribers: hein, mart, plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D1814
Summary:
Changes the test from "client rect intersects with screen rect"
to "screen that contains the center of the client+deco rect or
screen this point is cloest to".
This is a behavior change also vs. libtaskmanager-old and should
address user bug reports like bug 364280.
BUG:364280
Reviewers: #plasma
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D1925
Summary:
Makes the API more complex, but it's worth it as it allows
knowledgable users to opt into avoding costly work and/or
data copies in very common use cases.
Significantly speeds up a lot of work in the models in the
presence of X apps that can't be identified and fall back to
the window icon.
Based on profiling by David.
Reviewers: dfaure, davidedmundson
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D1920
Summary:
Makes the API more complex, but it's worth it as it allows
knowledgable users to opt into avoding costly work and/or
data copies in very common use cases.
Significantly speeds up a lot of work in the models in the
presence of X apps that can't be identified and fall back to
the window icon.
Based on profiling by David.
Reviewers: dfaure, davidedmundson
Subscribers: plasma-devel
Tags: #plasma
Differential Revision: https://phabricator.kde.org/D1920
This allows more complicated rules, useful for matching Chrome webapps to their
respective desktop file where we need to change crx_foo to chrome-foo-default.
BUG: 358277
CCBUG: 356609
FIXED-IN: 5.7.0
Differential Revision: https://phabricator.kde.org/D1673