Runcontroller KJobs question

Andreas Pakulat apaku at gmx.de
Wed Feb 18 08:16:35 UTC 2009


On 18.02.09 00:09:16, Vladimir Prus wrote:
> On Tuesday 17 February 2009 23:35:29 Andreas Pakulat wrote:
> > On 17.02.09 23:25:24, Vladimir Prus wrote:
> > > On Tuesday 17 February 2009 22:58:38 Andreas Pakulat wrote:
> > > > On 17.02.09 20:56:07, Vladimir Prus wrote:
> > > > > the runcontroller passes an KJob* to IRunProvider::execute. In case of 
> > > > > debugger, I want to mark this job as done when debugger exits, either
> > > > > normally or due to GDB crash. How can I do that, given that all
> > > > > of KJob methods of interest are protected?
> > > > 
> > > > Well, at some point that job is created and that is most probably not a
> > > > KJob, but  some subclass. That subclass should call emitResult() when
> > > > its "done" and also set any errors via setError and setErrorText before
> > > > that.
> > > 
> > > That is created in runcontroller.cpp and the actual class is RunJob and IRunProvider
> > > is not in position to intercept construction of that class. 
> > > 
> > > But I've already found the right way -- it appears that if IRunProvider implementatation
> > > has a finished(KJob*) signal, it will be used. Of course, this is not documented anywhere :-P
> > 
> > Maybe I'm missing something, but doesn't gdb-plugin create a job and tell
> > runcontroller to start it? 
> 
> No.

Having seen your commit now I think the fact I was missing is that the
gdbplugin is actually a run-provider, instead of providing a special
run-app-in-gdb job.
 
Andreas

-- 
Write yourself a threatening letter and pen a defiant reply.




More information about the KDevelop-devel mailing list