[prev in list] [next in list] [prev in thread] [next in thread]
List: kde-devel
Subject: Re: KDE & Multithreading
From: Thiago Macieira <thiagom () wanadoo ! fr>
Date: 2002-02-09 19:01:56
[Download RAW message or body]
Jay Cornwall wrote
>On Saturday 09 February 2002 12:43 am, Charles Samuels wrote:
>> So, I assume you're using the posix network calls (and not the Qt ones),
>> since the Qt ones are all non-blocking, and require an event loop to
>> select() the file descriptor. (btw, QSocketDevice doesn't need an event
>> loop). Anything that needs an event loop needs to be in the main thread.
>
>Yes, I'm using the POSIX socket functions. To be honest, I've never really
>liked the way QT tries to abstract almost everything into classes. It seems
>unnecessary to me, and in some cases makes the code more cluttered than
>otherwise. Then again, I've never really been a fan of OO programming. ;)
Just a network side note:
if you're going to use low-level functions instead of the KDE and Qt
implementations, you need to be very careful. Some implementations just do
things differently than what you're used to.
I recommend the following, if even to keep more compatible with the expected
behaviour of a KDE application:
- instead of using the low-level functions directly, use their implementations
in KSocks. That way, you'll benefit from automatic proxy support if the user
configured it
- do the lookups using KExtendedSocket::lookup
--
Thiago Macieira - UFOT Registry number: 1001
thiagom@mail.com
ICQ UIN: 1967141 PGP: 0x8F2978D5 and 0xEA9037A5 (PGP 2.x)
Registered Linux user #65028
>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic