[Service Runner] Don't use KRun::runService
ClosedPublic

Authored by broulik on Jun 5 2016, 4:44 PM.

Details

Summary

It blocks KRunner while the application is loading and in some cases (like Kate's session selection dialog) might never return.

CCBUG: 361917

Test Plan

Works. KRunner now always closes right away when launching the appliation rather than sometimes staying longer when the app takes a while or even never closing in case of Kate.

Diff Detail

Repository
R120 Plasma Workspace
Lint
Lint Skipped
Unit
Unit Tests Skipped
broulik updated this revision to Diff 4211.Jun 5 2016, 4:44 PM
broulik retitled this revision from to [Service Runner] Don't use KRun::runService.
broulik updated this object.
broulik edited the test plan for this revision. (Show Details)
broulik added a reviewer: Plasma.
broulik set the repository for this revision to R120 Plasma Workspace.
Restricted Application added a project: Plasma. · View Herald TranscriptJun 5 2016, 4:44 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
apol added a subscriber: apol.Jun 6 2016, 7:41 AM

Would it make sense to add such API in KRun@KIOWidgets?

This now matches what Icon is doing, but Kicker is using:

new KRun(QUrl::fromLocalFile(service->entryPath()), 0, true, ...);

This puts the kservice parsing into being done by klauncher/kinit which seems more "right".
Does using ->exec() skip the KAuthorised check?

It'll also be even faster as it'll return straight away, this still blocks a tiiiny amount until we roundtrip to kinit.

broulik updated this revision to Diff 4246.Jun 6 2016, 1:48 PM

Use "new KRun"

davidedmundson accepted this revision.Jun 6 2016, 2:06 PM
davidedmundson added a reviewer: davidedmundson.
This revision is now accepted and ready to land.Jun 6 2016, 2:06 PM
This revision was automatically updated to reflect the committed changes.