Thanks a lot Eskil !!!!!!!!!! It works just fine. This is precisely the point I was missing.
To sum up : - To be able to drop an item between items, one must enable the ItemIsDropEnabled flag *on the parent item*. - The space between items is associated to the parent item index Regards. Julien. 2009/7/8 Eskil Abrahamsen Blomfeldt <eblom...@trolltech.com> > Julien Gaubert wrote: > >> The problem is that with this implementation of the flags() method, no >> drop action is accepted at all (drop indicator show a "forbidden" image). >> Moreover, I read the C++ code of dropIndicatorPosition() (see below) and >> it seems that with "ItemIsDropEnabled" not being flagged, I should get a >> dropIndicator "AboveItem" or "BelowItem". (I didn't try to test my example >> in C++ though) >> > > The parent index of the items has to be drop enabled. You can do this in > your code by adding the following to the end of your flags() implementation > in DraggableListModel: > > if (index == null) > result.set(ItemFlag.ItemIsDropEnabled); > > Hope this helps. > > -- Eskil > > > >
_______________________________________________ Qt-jambi-interest mailing list Qt-jambi-interest@trolltech.com http://lists.trolltech.com/mailman/listinfo/qt-jambi-interest