[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: [PATCH] KIO::SlaveBase and the event loop
From:       Thiago Macieira <thiago () kde ! org>
Date:       2008-07-15 15:44:58
Message-ID: 200807151244.59101.thiago () kde ! org
[Download RAW message or body]


Sebastian Trüg wrote:
>I create a local event loop in the listDir method and execute it after
>starting my thread that does all the dbus communication. DBus signals
> come in via a queued connection and are handled in the main thread
> (they create listEntry calls). Once the initial listing is done
> (search) I disconnect the dbus signals and reconnect them directly.
> That is because once my local event loop is done I still need to get
> the dbus signals to update my internal state and emit KDirNotify
> signals.
>It works but with a rather bis delay for the update signals that are to
> be delivered directly. I don't really understand that since my thread
> runs its own event loop.
>
>I hope this was not too confusing. ;)

If you're going to use a separate thread for handling a D-Bus connection, 
do not use QDBusConnection::sessionBus() nor 
QDBusConnection::systemBus(). You must connect on your own.

-- 
  Thiago Macieira  -  thiago (AT) macieira.info - thiago (AT) kde.org
    PGP/GPG: 0x6EF45358; fingerprint:
    E067 918B B660 DBD1 105C  966C 33F5 F005 6EF4 5358

["signature.asc" (application/pgp-signature)]

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic