diff options
Diffstat (limited to 'src/kernel/tqthread_unix.cpp')
| -rw-r--r-- | src/kernel/tqthread_unix.cpp | 40 |
1 files changed, 20 insertions, 20 deletions
diff --git a/src/kernel/tqthread_unix.cpp b/src/kernel/tqthread_unix.cpp index 27b8ec7af..4f4ec8d79 100644 --- a/src/kernel/tqthread_unix.cpp +++ b/src/kernel/tqthread_unix.cpp @@ -98,10 +98,10 @@ void TQThreadInstance::init(unsigned int stackSize) stacksize = stackSize; args[0] = args[1] = 0; thread_storage = 0; - finished = FALSE; - running = FALSE; - orphan = FALSE; - disableThreadPostedEvents = FALSE; + finished = false; + running = false; + orphan = false; + disableThreadPostedEvents = false; pthread_cond_init(&thread_done, nullptr); thread_id = 0; @@ -132,7 +132,7 @@ void *TQThreadInstance::start( void *_arg ) ( (TQThread *) arg[0] )->run(); - pthread_cleanup_pop( TRUE ); + pthread_cleanup_pop( true ); return 0; } @@ -154,8 +154,8 @@ void TQThreadInstance::finish( void * ) TQApplication::threadTerminationHandler((TQThread*)d->args[0]); TQMutexLocker locker( d->mutex() ); - d->running = FALSE; - d->finished = TRUE; + d->running = false; + d->finished = true; d->args[0] = d->args[1] = 0; @@ -210,9 +210,9 @@ TQt::HANDLE TQThread::currentThread() void TQThread::initialize() { if ( ! tqt_global_mutexpool ) - tqt_global_mutexpool = new TQMutexPool( TRUE, 73 ); + tqt_global_mutexpool = new TQMutexPool( true, 73 ); if ( ! qt_thread_mutexpool ) - qt_thread_mutexpool = new TQMutexPool( FALSE, 127 ); + qt_thread_mutexpool = new TQMutexPool( false, 127 ); } /*! \internal @@ -321,8 +321,8 @@ void TQThread::start(Priority priority) pthread_cond_wait(&d->thread_done, &locker.mutex()->d->handle); } - d->running = TRUE; - d->finished = FALSE; + d->running = true; + d->finished = false; int ret; pthread_attr_t attr; @@ -401,8 +401,8 @@ void TQThread::start(Priority priority) // we failed to set the stacksize, and as the documentation states, // the thread will fail to run... - d->running = FALSE; - d->finished = FALSE; + d->running = false; + d->finished = false; return; } } @@ -423,8 +423,8 @@ void TQThread::start(Priority priority) tqWarning( "TQThread::start: thread creation error: %s", strerror( ret ) ); #endif // QT_CHECK_STATE - d->running = FALSE; - d->finished = FALSE; + d->running = false; + d->finished = false; d->args[0] = d->args[1] = 0; } } @@ -441,11 +441,11 @@ void TQThread::start() \list \i The thread associated with this TQThread object has finished execution (i.e. when it returns from \l{run()}). This function - will return TRUE if the thread has finished. It also returns - TRUE if the thread has not been started yet. + will return true if the thread has finished. It also returns + true if the thread has not been started yet. \i \a time milliseconds has elapsed. If \a time is ULONG_MAX (the default), then the wait will never timeout (the thread must - return from \l{run()}). This function will return FALSE if the + return from \l{run()}). This function will return false if the wait timed out. \endlist @@ -460,11 +460,11 @@ bool TQThread::wait( unsigned long time ) tqWarning( "TQThread::wait: thread tried to wait on itself" ); #endif // QT_CHECK_STATE - return FALSE; + return false; } if ( d->finished || ! d->running ) { - return TRUE; + return true; } int ret; |
