[scripting] Make DBus invokable run method return result after execution
AcceptedPublic

Authored by davidedmundson on Wed, Jan 9, 4:00 PM.

Details

Reviewers
graesslin
Group Reviewers
KWin
Summary

In 403038 the user expected the DBus call to run to finish before
processing the next request. For a singleshot script that makes a lot of
sense, otherwise you have no idea when it finishes.

This also allows us to return errors.

CCBUG: 403038

Test Plan

NUM=$(qdbus org.kde.KWin /Scripting org.kde.kwin.Scripting.loadScript /noFile.js Minimize)
qdbus org.kde.KWin /$NUM org.kde.kwin.Scripting.run

Error: org.kde.kwin.Scripting.FileError
Could not open /noFile.js

Running a real script behaved effectively the same as before.

Diff Detail

Repository
R108 KWin
Branch
master
Lint
Lint OK
Unit
No Unit Test Coverage
Build Status
Buildable 6863
Build 6881: arc lint + arc unit
davidedmundson created this revision.Wed, Jan 9, 4:00 PM
Restricted Application added a project: KWin. · View Herald TranscriptWed, Jan 9, 4:00 PM
Restricted Application added a subscriber: kwin. · View Herald Transcript
davidedmundson requested review of this revision.Wed, Jan 9, 4:00 PM
graesslin accepted this revision.Wed, Jan 9, 5:26 PM
This revision is now accepted and ready to land.Wed, Jan 9, 5:26 PM