From e80a3b49c0aac237104e1696fc64b3a924c89ca1 Mon Sep 17 00:00:00 2001 From: Giuseppe D'Angelo Date: Thu, 15 Jun 2017 16:43:43 +0200 Subject: Item widgets: API cleanups A few functions ended up in the wrong visibility section. For instance, it should be perfectly fine to call indexFromItem even from non-subclasses. We can't change that in Qt 5, make a note for Qt 6. Change-Id: I277d831ef1a4b3dcae99bef299ea334954d5b0d3 Reviewed-by: David Faure --- src/widgets/itemviews/qtablewidget.h | 8 ++++++++ 1 file changed, 8 insertions(+) (limited to 'src/widgets/itemviews/qtablewidget.h') diff --git a/src/widgets/itemviews/qtablewidget.h b/src/widgets/itemviews/qtablewidget.h index 8b827bc16b..092ce77306 100644 --- a/src/widgets/itemviews/qtablewidget.h +++ b/src/widgets/itemviews/qtablewidget.h @@ -329,10 +329,18 @@ protected: #endif virtual bool dropMimeData(int row, int column, const QMimeData *data, Qt::DropAction action); virtual Qt::DropActions supportedDropActions() const; + +#if QT_VERSION >= QT_VERSION_CHECK(6, 0, 0) +public: +#else +protected: +#endif QList items(const QMimeData *data) const; QModelIndex indexFromItem(QTableWidgetItem *item) const; QTableWidgetItem *itemFromIndex(const QModelIndex &index) const; + +protected: #if QT_CONFIG(draganddrop) void dropEvent(QDropEvent *event) Q_DECL_OVERRIDE; #endif -- cgit v1.2.3