summaryrefslogtreecommitdiffstats
path: root/src/widgets/widgets/qcombobox.cpp
diff options
context:
space:
mode:
authorStephan Binner <stephan.binner@basyskom.com>2017-07-09 16:53:58 +0200
committerStephan Binner <stephan.binner@basyskom.com>2017-07-11 02:52:35 +0000
commit01703d026420cd0964bec872f7af54fd077b82ad (patch)
tree183252845f8c6220eac3c1476cacb02066533bbf /src/widgets/widgets/qcombobox.cpp
parent6cd46c9a61c3493b975416ec4309af75db5dafaf (diff)
Convert features.tableview to QT_[REQUIRE_]CONFIG
Change-Id: I7ab479deff7bbf3083d1efa196e0480b181548c5 Reviewed-by: Oswald Buddenhagen <oswald.buddenhagen@qt.io>
Diffstat (limited to 'src/widgets/widgets/qcombobox.cpp')
-rw-r--r--src/widgets/widgets/qcombobox.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/widgets/widgets/qcombobox.cpp b/src/widgets/widgets/qcombobox.cpp
index 5520e9d28f..84d81fa089 100644
--- a/src/widgets/widgets/qcombobox.cpp
+++ b/src/widgets/widgets/qcombobox.cpp
@@ -47,7 +47,9 @@
#include <qapplication.h>
#include <qdesktopwidget.h>
#include <qlistview.h>
+#if QT_CONFIG(tableview)
#include <qtableview.h>
+#endif
#include <qitemdelegate.h>
#include <qmap.h>
#include <qmenu.h>
@@ -598,7 +600,7 @@ int QComboBoxPrivateContainer::topMargin() const
{
if (const QListView *lview = qobject_cast<const QListView*>(view))
return lview->spacing();
-#ifndef QT_NO_TABLEVIEW
+#if QT_CONFIG(tableview)
if (const QTableView *tview = qobject_cast<const QTableView*>(view))
return tview->showGrid() ? 1 : 0;
#endif
@@ -613,7 +615,7 @@ int QComboBoxPrivateContainer::spacing() const
QListView *lview = qobject_cast<QListView*>(view);
if (lview)
return 2 * lview->spacing(); // QListView::spacing is the padding around the item.
-#ifndef QT_NO_TABLEVIEW
+#if QT_CONFIG(tableview)
QTableView *tview = qobject_cast<QTableView*>(view);
if (tview)
return tview->showGrid() ? 1 : 0;