[PATCH] applets/kicker: fix filenames containing # in history
authorChristoph Wolk <cwo.kde@posteo.net>
Thu, 5 Jun 2025 18:33:29 +0000 (18:33 +0000)
committerAurélien COUDERC <coucouf@debian.org>
Mon, 21 Jul 2025 16:21:10 +0000 (18:21 +0200)
commita353537b2531b41ef72fe03ebde325e7133bd04f
treeecc707586598d21cc85a5d3b4ea569426e46d1b4
parent3212a53fd585ad2fb574df45691c17455b618a80
[PATCH] applets/kicker: fix filenames containing # in history

Kicker takes the resource name as provided by PlasmaActivities.Stats and
interprets it as an URL, setting the 'file' url scheme if necessary.
This fails when the filenames contain a '#' character, as QUrl will
interpret them as url fragments if not percent-encoded (which they are
not for local files, but are for remote urls). This makes display and
opening of such files fail in both Kicker and Kickoff.

Instead, we test whether it's an absolute path (the local history
entries are) and if so, use QUrl.fromLocalFile to get the correct url.
This is also what PlasmaActivities.Stats does in ResultSet (which is
what the Task Manager uses, so everything works there already, but we
want a real model here).

BUG: 419449
BUG: 437960
FIXED-IN: 6.4.0

(cherry picked from commit c6c0a68416b5042032853a6f673bddbe475567b7)

Co-authored-by: Christoph Wolk <cwo.kde@posteo.net>
Gbp-Pq: Name upstream_ab55c53e_applets-kicker-fix-filenames-containing-in-history.patch
applets/kicker/plugin/recentusagemodel.cpp