Uploaded image for project: 'Qt'
  1. Qt
  2. QTBUG-31061

Itemviews: disappearing items with "internal move" drag'n'drop mode

    XMLWordPrintable

Details

    • Bug
    • Resolution: Done
    • P3: Somewhat important
    • 5.1.0
    • 5.0.2
    • Widgets: Itemviews
    • None
    • Mac OS X 10.8, latest qt5/stable
    • qtbase/stable: 00859fe32f90154bb934644ec067d4406a8aa821

    Description

      Drag and drop the items around the view, and items just disappear while dropping.

      #include <QtWidgets>
      
      int main(int argc, char *argv[])
      {
          QApplication app(argc, argv);
          QListWidget list;
          list.setDragEnabled(true);
          list.setDropIndicatorShown(true);
          list.setDragDropMode(QAbstractItemView::InternalMove);
          for (int i = 0; i < 10; ++i) {
              list.addItem(QString::number(i));
              list.item(i)->setFlags(Qt::ItemIsEnabled | Qt::ItemIsSelectable | Qt::ItemIsDragEnabled);
          }
          list.show();
          return app.exec();
      }
      

      Attachments

        No reviews matched the request. Check your Options in the drop-down menu of this sections header.

        Activity

          People

            Unassigned Unassigned
            jpnurmi J-P Nurmi
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Gerrit Reviews

                There are no open Gerrit changes