gcc -Woverloaded-virtual
Aurélien Gâteau
aurelien.gateau at free.fr
Mon Nov 26 13:36:04 GMT 2007
David Faure wrote:
>> Maybe the opposite : something like
>> void addJobWithoutMerge(KJob *job)
>>
>> So we will use the compile error to help us to port.
>> This is also better API than using a meaningless bool.
>
> Yes, addSubjobNoMetadataMerge is a good solution.
> We'll also find out if that's really used anywhere... I don't see any use
> within kio, for instance... Hmm... so maybe we should first try to compile
> KDE without that bool to find out if that's really used anywhere. Copying
> the metadata into the subjob gives it the right window-id and
> user-timestamp for instance, I don't know of a case where we don't want to
> copy the metadata to the subjob.
I just ran a search for addSubjob(.*, .*) on my KDE checkout (kdesupport,
kdelibs, kdepimlibs, kdebase and kdegraphics) and did not find any match
except for the method implementation. Of course, one should check other
modules as well. Still it's a good indication that removing the boolean
parameter is probably the simplest solution.
As for removeSubjob(), I found two calls to removeSubjob(job, true). Those
are in copyjob.cpp. In the case of removeSubjob(), the default behavior is
to not merge metadata, so it we can either:
- add a removeSubjobAndMergeMetadata() method
- add a separate mergeMetadata() method
Aurélien
More information about the kde-core-devel
mailing list