Index: parts/autoproject/targetoptionsdlg.cpp
===================================================================
RCS file: /home/kde/kdevelop/parts/autoproject/targetoptionsdlg.cpp,v
retrieving revision 1.18
diff -u -r1.18 targetoptionsdlg.cpp
--- parts/autoproject/targetoptionsdlg.cpp	27 Feb 2003 13:24:41 -0000	1.18
+++ parts/autoproject/targetoptionsdlg.cpp	17 Mar 2003 18:19:55 -0000
@@ -98,11 +98,17 @@
 
     QListViewItem *lastItem = 0;
     QStringList::Iterator l2it;
+    QCheckListItem *flitem = static_cast<QCheckListItem*>(insidelib_listview->firstChild());
     for (l2it = l2.begin(); l2it != l2.end(); ++l2it) {
         QCheckListItem *clitem = static_cast<QCheckListItem*>(insidelib_listview->firstChild());
         while (clitem) {
             if (*l2it == ("$(top_builddir)/" + clitem->text())) {
                 clitem->setOn(true);
+                // move this item to the "top of the list"
+                if (flitem != clitem)
+                  clitem->moveItem(flitem); 
+                // move the "top of the list" one item down
+                flitem = static_cast<QCheckListItem*>(flitem->nextSibling());
                 break;
             }
             clitem = static_cast<QCheckListItem*>(clitem->nextSibling());
