Skip to content

Rework the way CopyJob finds the AskUserActionInterface implementation

David Faure requested to merge work/dfaure/extension_child_objects into master

JobUiDelegate deriving from N interfaces in KF 6.0 was not going to be an flexible solution, we wouldn't have been able to add more interfaces afterwards. Instead let's reuse the KParts solution: extensibility by composition, looking up the child QObject that implements a given interface.

KIO::JobUiDelegate (the misnamed Widgets-based one) creates a child object, which also means we don't have the risk of mixing up the signals between jobs (the delegate is job-specific).

This is less hackish in unittests, which can just set a null delegate (no interaction, default replies) or a basic KJobUiDelegate with the desired child object for a canned response.

The overall design goal would be to port all handlers to this mechanism, as well as what's left of the old "delegate extension".

Merge request reports