I have QTreeWidget based class and need to do sorting by Qt::UserRole. How can I do this ? I know that QStandartItemModel has such method and treeWidget has model() method which return model, but it’s QAbstractItemModel type which has no setSortRole method.
↧