From ae675f3d6f0c13ef589f97750cf5a94c6260adc8 Mon Sep 17 00:00:00 2001 From: Charles Kerr Date: Wed, 2 Sep 2009 15:34:18 +0000 Subject: [PATCH] Qt 4.4 is still pretty new, so don't use QList.removeOne() yet. (build error reported by kklimonda) --- qt/file-tree.cc | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/qt/file-tree.cc b/qt/file-tree.cc index 494f6e3e2..600f314b5 100644 --- a/qt/file-tree.cc +++ b/qt/file-tree.cc @@ -43,9 +43,13 @@ FileTreeItem :: ~FileTreeItem( ) { assert( myChildren.isEmpty( ) ); - if( myParent ) - if( !myParent->myChildren.removeOne( this ) ) + if( myParent ) { + const int pos = myParent->myChildren.indexOf( this ); + if( pos >= 0 ) + myParent->myChildren.removeAt( pos ); + else assert( 0 && "failed to remove" ); + } } void