Hi folks,<br><br>I've been trying to find the root of all problems that I'm going to describe now, but I didn't succeed, at least totally. We all know there is an advantage having separated the part of the jobs that do the work itself, and the "graphical part" of the jobs (the delegate). It seems there are strange behaviours. Let's see:
<br><br>In job.cpp I have this code:<br><br>Job::Job(bool showProgressInfo) : KCompositeJob(0), m_speedTimer(0), d( new JobPrivate )<br>{<br>    JobUiDelegate *jobUiDelegate = new JobUiDelegate( showProgressInfo );<br><br>

    kDebug() << "LOOK: Before setUiDelegate(). uiDelegate() = " << uiDelegate() << ". jobUiDelegate = " << jobUiDelegate << endl;<br><br>    setUiDelegate( jobUiDelegate );
<br><br>    kDebug() << "LOOK: After setUiDelegate(). uiDelegate() = " << uiDelegate() << endl;<br>}<br><br>In my Observer::newJob, I have the next:<br><br>int Observer::newJob( KIO::Job * job, bool showProgress )
<br>{<br>    // Tell the UI Server about this new job, and give it the application id<br>    // at the same time<br><br>    int progressId;<br><br>    if (job->ui())<br>    {<br>        progressId  = m_uiserver->newJob( QDBusConnection::sessionBus().baseService(), showProgress,
<br>                                             job->ui()->internalAppName(), job->ui()->jobIcon(), job->ui()->appName() );<br>    }<br>    else<br>    {<br>        progressId  = m_uiserver->newJob( QDBusConnection::sessionBus().baseService(), showProgress,
<br>                                             QString(), QString(), QString() );<br>    }<br><br>    // Keep the result in a dict<br>    m_dctJobs.insert( progressId, job );<br><br>    return progressId;<br>}<br><br>What amazes me is that when a job that is meant to be shown on the kio_uiserver, it always go through the else, because it seems that ui() is null. Even more, when taking a look at the debug output, I have the next:
<br><br>konqueror: LOOK: KJob::uiDelegate() returned QObject(0x0)<br>konqueror: LOOK: Before setUiDelegate(). uiDelegate() = QObject(0x0)  . jobUiDelegate = KIO::JobUiDelegate(0x6e93a0)<br>kio (KIOJob): kio_uiserver registered
<br>konqueror: LOOK: KJob::uiDelegate() returned QObject(0x0)<br>konqueror: LOOK: KIO::Job::ui() returned QObject(0x0)<br>konqueror: LOOK: KJob::uiDelegate() returned QObject(0x0)<br><br>Hey !!! I'm not getting kDebug() << "LOOK: After setUiDelegate(). uiDelegate() = " << uiDelegate() << endl;. What's happening ? Why it writes "kio (KIOJob): kio_uiserver registered" before "After setUiDelegate().....", and even more, "After setUiDelegate()....." is never written.
<br><br>I have visited setUiDelegate and I don't find (at a first look) anything that should be calling Observer constructor (or Observer::self()) there (that is the one that writes that on the debug information).<br>
<br>The result is that the kio_uiserver is always getting nulls strings on the icon, internalAppName, and appName.<br><br>Bye,<br>Rafael Fernández López.<br>