Logo Search packages:      
Sourcecode: qt4-x11 version File versions  Download package

Q3GList & Q3GList::operator= ( const Q3GList list  )  [protected]

Assigns list to this list.

Definition at line 269 of file q3glist.cpp.

References append(), clear(), count(), Q3LNode::data, firstNode, and Q3LNode::next.

{
    if ( &list == this )
      return *this;

    clear();
    if ( list.count() > 0 ) {
      Q3LNode *n = list.firstNode;
      while ( n ) {                       // copy all items from list
          append( n->data );
          n = n->next;
      }
      curNode      = firstNode;
      curIndex = 0;
    }
    return *this;
}


Generated by  Doxygen 1.6.0   Back to index