@ -43,9 +43,7 @@
# include "ntqdatastream.h"
# include "ntqvaluelist.h"
# if defined(TQT_THREAD_SUPPORT)
# include "ntqmutex.h"
# endif // defined(TQT_THREAD_SUPPORT)
# include "ntqmutex.h"
/*!
\ class TQLNode ntqglist . h
@ -225,7 +223,7 @@ TQDataStream &TQGList::write( TQDataStream &s, TQPtrCollection::Item ) const
TQGList : : TQGList ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex = new TQMutex(true);
# endif
firstNode = lastNode = curNode = 0 ; // initialize list
@ -241,7 +239,7 @@ TQGList::TQGList()
TQGList : : TQGList ( const TQGList & list )
: TQPtrCollection ( list )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex = new TQMutex(true);
# endif
firstNode = lastNode = curNode = 0 ; // initialize list
@ -268,7 +266,7 @@ TQGList::~TQGList()
// twice on the same address! This is insane but let's try not to crash
// here.
iterators = 0 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//delete mutex;
# endif
}
@ -337,11 +335,11 @@ bool TQGList::operator==( const TQGList &list ) const
TQLNode * TQGList : : locate ( uint index )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( index = = ( uint ) curIndex ) { // current node ?
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curNode ;
@ -355,7 +353,7 @@ TQLNode *TQGList::locate( uint index )
bool forward ; // direction to traverse
if ( index > = numNodes ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -388,7 +386,7 @@ TQLNode *TQGList::locate( uint index )
}
}
curIndex = index ; // must update index
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curNode = node ;
@ -401,7 +399,7 @@ TQLNode *TQGList::locate( uint index )
void TQGList : : inSort ( TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
int index = 0 ;
@ -411,7 +409,7 @@ void TQGList::inSort( TQPtrCollection::Item d )
index + + ;
}
insertAt ( index , d ) ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -423,7 +421,7 @@ void TQGList::inSort( TQPtrCollection::Item d )
void TQGList : : prepend ( TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = new TQLNode ( newItem ( d ) ) ;
@ -436,7 +434,7 @@ void TQGList::prepend( TQPtrCollection::Item d )
firstNode = curNode = n ; // curNode affected
numNodes + + ;
curIndex = 0 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -448,7 +446,7 @@ void TQGList::prepend( TQPtrCollection::Item d )
void TQGList : : append ( TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = new TQLNode ( newItem ( d ) ) ;
@ -463,7 +461,7 @@ void TQGList::append( TQPtrCollection::Item d )
lastNode = curNode = n ; // curNode affected
curIndex = numNodes ;
numNodes + + ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -475,26 +473,26 @@ void TQGList::append( TQPtrCollection::Item d )
bool TQGList : : insertAt ( uint index , TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( index = = 0 ) {
prepend ( d ) ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
}
else if ( index = = numNodes ) {
append ( d ) ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
}
TQLNode * nextNode = locate ( index ) ;
if ( ! nextNode ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
@ -509,7 +507,7 @@ bool TQGList::insertAt( uint index, TQPtrCollection::Item d )
n - > next = nextNode ;
curNode = n ; // curIndex set by locate()
numNodes + + ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -522,11 +520,11 @@ bool TQGList::insertAt( uint index, TQPtrCollection::Item d )
void TQGList : : relinkNode ( TQLNode * n )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( n = = firstNode ) { // already first
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return ;
@ -543,7 +541,7 @@ void TQGList::relinkNode( TQLNode *n )
firstNode = curNode = n ; // curNode affected
numNodes + + ;
curIndex = 0 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -555,11 +553,11 @@ void TQGList::relinkNode( TQLNode *n )
TQLNode * TQGList : : unlink ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( curNode = = 0 ) { // null current node
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -593,7 +591,7 @@ TQLNode *TQGList::unlink()
iterators - > notifyRemove ( n , curNode ) ;
}
numNodes - - ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return n ;
@ -606,7 +604,7 @@ TQLNode *TQGList::unlink()
bool TQGList : : removeNode ( TQLNode * n )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
# if defined(QT_CHECK_NULL)
@ -622,7 +620,7 @@ bool TQGList::removeNode( TQLNode *n )
delete n ;
curNode = firstNode ;
curIndex = curNode ? 0 : - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -636,25 +634,25 @@ bool TQGList::removeNode( TQLNode *n )
bool TQGList : : remove ( TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( d & & find ( d ) = = - 1 ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
TQLNode * n = unlink ( ) ;
if ( ! n ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
deleteItem ( n - > data ) ;
delete n ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -666,25 +664,25 @@ bool TQGList::remove( TQPtrCollection::Item d )
bool TQGList : : removeRef ( TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( findRef ( d ) = = - 1 ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
TQLNode * n = unlink ( ) ;
if ( ! n ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
deleteItem ( n - > data ) ;
delete n ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -708,25 +706,25 @@ bool TQGList::removeRef( TQPtrCollection::Item d )
bool TQGList : : removeAt ( uint index )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( ! locate ( index ) ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
TQLNode * n = unlink ( ) ;
if ( ! n ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
}
deleteItem ( n - > data ) ;
delete n ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -738,12 +736,12 @@ bool TQGList::removeAt( uint index )
*/
bool TQGList : : replaceAt ( uint index , TQPtrCollection : : Item d )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = locate ( index ) ;
if ( ! n ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return FALSE ;
@ -752,7 +750,7 @@ bool TQGList::replaceAt( uint index, TQPtrCollection::Item d )
deleteItem ( n - > data ) ;
n - > data = newItem ( d ) ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return TRUE ;
@ -766,14 +764,14 @@ bool TQGList::replaceAt( uint index, TQPtrCollection::Item d )
TQPtrCollection : : Item TQGList : : takeNode ( TQLNode * n )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
# if defined(QT_CHECK_NULL)
if ( n = = 0 | | ( n - > prev & & n - > prev - > next ! = n ) | |
( n - > next & & n - > next - > prev ! = n ) ) {
tqWarning ( " TQGList::takeNode: Corrupted node " ) ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -785,7 +783,7 @@ TQPtrCollection::Item TQGList::takeNode( TQLNode *n )
delete n ; // delete the node, not data
curNode = firstNode ;
curIndex = curNode ? 0 : - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return d ;
@ -797,13 +795,13 @@ TQPtrCollection::Item TQGList::takeNode( TQLNode *n )
TQPtrCollection : : Item TQGList : : take ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = unlink ( ) ; // unlink node
Item d = n ? n - > data : 0 ;
delete n ; // delete node, keep contents
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return d ;
@ -815,11 +813,11 @@ TQPtrCollection::Item TQGList::take()
TQPtrCollection : : Item TQGList : : takeAt ( uint index )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( ! locate ( index ) ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -827,7 +825,7 @@ TQPtrCollection::Item TQGList::takeAt( uint index )
TQLNode * n = unlink ( ) ; // unlink node
Item d = n ? n - > data : 0 ;
delete n ; // delete node, keep contents
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return d ;
@ -839,14 +837,14 @@ TQPtrCollection::Item TQGList::takeAt( uint index )
TQPtrCollection : : Item TQGList : : takeFirst ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
first ( ) ;
TQLNode * n = unlink ( ) ; // unlink node
Item d = n ? n - > data : 0 ;
delete n ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return d ;
@ -858,14 +856,14 @@ TQPtrCollection::Item TQGList::takeFirst()
TQPtrCollection : : Item TQGList : : takeLast ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
last ( ) ;
TQLNode * n = unlink ( ) ; // unlink node
Item d = n ? n - > data : 0 ;
delete n ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return d ;
@ -878,7 +876,7 @@ TQPtrCollection::Item TQGList::takeLast()
void TQGList : : clear ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = firstNode ;
@ -898,7 +896,7 @@ void TQGList::clear()
n = n - > next ;
delete prevNode ; // deallocate node
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -911,7 +909,7 @@ void TQGList::clear()
int TQGList : : findRef ( TQPtrCollection : : Item d , bool fromStart )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n ;
@ -929,7 +927,7 @@ int TQGList::findRef( TQPtrCollection::Item d, bool fromStart )
}
curNode = n ;
curIndex = n ? index : - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curIndex ; // return position of item
@ -943,7 +941,7 @@ int TQGList::findRef( TQPtrCollection::Item d, bool fromStart )
int TQGList : : find ( TQPtrCollection : : Item d , bool fromStart )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n ;
@ -961,7 +959,7 @@ int TQGList::find( TQPtrCollection::Item d, bool fromStart )
}
curNode = n ;
curIndex = n ? index : - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curIndex ; // return position of item
@ -974,7 +972,7 @@ int TQGList::find( TQPtrCollection::Item d, bool fromStart )
uint TQGList : : containsRef ( TQPtrCollection : : Item d ) const
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = firstNode ;
@ -984,7 +982,7 @@ uint TQGList::containsRef( TQPtrCollection::Item d ) const
count + + ;
n = n - > next ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return count ;
@ -997,7 +995,7 @@ uint TQGList::containsRef( TQPtrCollection::Item d ) const
uint TQGList : : contains ( TQPtrCollection : : Item d ) const
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = firstNode ;
@ -1008,7 +1006,7 @@ uint TQGList::contains( TQPtrCollection::Item d ) const
count + + ;
n = n - > next ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return count ;
@ -1058,17 +1056,17 @@ uint TQGList::contains( TQPtrCollection::Item d ) const
TQPtrCollection : : Item TQGList : : first ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( firstNode ) {
curIndex = 0 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return ( curNode = firstNode ) - > data ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -1080,17 +1078,17 @@ TQPtrCollection::Item TQGList::first()
TQPtrCollection : : Item TQGList : : last ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( lastNode ) {
curIndex = numNodes - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return ( curNode = lastNode ) - > data ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -1102,14 +1100,14 @@ TQPtrCollection::Item TQGList::last()
TQPtrCollection : : Item TQGList : : next ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( curNode ) {
if ( curNode - > next ) {
curIndex + + ;
curNode = curNode - > next ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curNode - > data ;
@ -1117,7 +1115,7 @@ TQPtrCollection::Item TQGList::next()
curIndex = - 1 ;
curNode = 0 ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -1129,14 +1127,14 @@ TQPtrCollection::Item TQGList::next()
TQPtrCollection : : Item TQGList : : prev ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
if ( curNode ) {
if ( curNode - > prev ) {
curIndex - - ;
curNode = curNode - > prev ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return curNode - > data ;
@ -1144,7 +1142,7 @@ TQPtrCollection::Item TQGList::prev()
curIndex = - 1 ;
curNode = 0 ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return 0 ;
@ -1157,12 +1155,12 @@ TQPtrCollection::Item TQGList::prev()
void TQGList : : toVector ( TQGVector * vector ) const
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
vector - > clear ( ) ;
if ( ! vector - > resize ( count ( ) ) ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return ;
@ -1174,14 +1172,14 @@ void TQGList::toVector( TQGVector *vector ) const
n = n - > next ;
i + + ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
void TQGList : : heapSortPushDown ( TQPtrCollection : : Item * heap , int first , int last )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
int r = first ;
@ -1218,7 +1216,7 @@ void TQGList::heapSortPushDown( TQPtrCollection::Item* heap, int first, int last
}
}
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -1233,12 +1231,12 @@ void TQGList::heapSortPushDown( TQPtrCollection::Item* heap, int first, int last
void TQGList : : sort ( )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
uint n = count ( ) ;
if ( n < 2 ) {
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return ;
@ -1273,7 +1271,7 @@ void TQGList::sort()
}
delete [ ] realheap ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
}
@ -1300,7 +1298,7 @@ TQDataStream &operator<<( TQDataStream &s, const TQGList &list )
TQDataStream & TQGList : : read ( TQDataStream & s )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
uint num ;
@ -1326,7 +1324,7 @@ TQDataStream &TQGList::read( TQDataStream &s )
}
curNode = firstNode ;
curIndex = curNode ? 0 : - 1 ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return s ;
@ -1338,7 +1336,7 @@ TQDataStream &TQGList::read( TQDataStream &s )
TQDataStream & TQGList : : write ( TQDataStream & s ) const
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
s < < count ( ) ; // write number of items
@ -1347,7 +1345,7 @@ TQDataStream &TQGList::write( TQDataStream &s ) const
write ( s , n - > data ) ;
n = n - > next ;
}
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return s ;
@ -1361,13 +1359,13 @@ TQDataStream &TQGList::write( TQDataStream &s ) const
*/
TQLNode * TQGList : : erase ( TQLNode * it )
{
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->lock();
# endif
TQLNode * n = it ;
it = it - > next ;
removeNode ( n ) ;
# if defined(TQT_THREAD_SUPPORT)
# if ndef TQT_NO_THREAD
//mutex->unlock();
# endif
return it ;