summaryrefslogtreecommitdiffstats
path: root/qt-ui/tableview.cpp
diff options
context:
space:
mode:
authorGravatar Tomaz Canabrava <tcanabrava@kde.org>2013-12-11 21:44:05 -0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2013-12-12 03:26:39 +0100
commit0b5f9512efb8d861b3d935278f22d0cc5d6b8d4a (patch)
tree8d0a08e2411e45519eb9a6aed707c3b2db5300dd /qt-ui/tableview.cpp
parentc5c44e3a829d25227f623bd0e6211a4ff5d91b69 (diff)
downloadsubsurface-0b5f9512efb8d861b3d935278f22d0cc5d6b8d4a.tar.gz
Fix TableWidget ( equipment ones ) on dark scheme.
This patch uses the class created by the previous patch to get rid of the CSS and be really desktop native. it fixes a lot of stuff in non-blue-styles and throws a lot of code away. <3 Signed-off-by: Tomaz Canabrava <tcanabrava@kde.org> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'qt-ui/tableview.cpp')
-rw-r--r--qt-ui/tableview.cpp7
1 files changed, 2 insertions, 5 deletions
diff --git a/qt-ui/tableview.cpp b/qt-ui/tableview.cpp
index c79a23491..7c72b4bce 100644
--- a/qt-ui/tableview.cpp
+++ b/qt-ui/tableview.cpp
@@ -1,5 +1,6 @@
#include "tableview.h"
#include "models.h"
+#include "modeldelegates.h"
#include <QPushButton>
#include <QLayout>
@@ -10,11 +11,7 @@
TableView::TableView(QWidget *parent) : QWidget(parent)
{
ui.setupUi(this);
- QFile cssFile(":table-css");
- cssFile.open(QIODevice::ReadOnly);
- QTextStream reader(&cssFile);
- QString css = reader.readAll();
- ui.tableView->setStyleSheet(css);
+ ui.tableView->setItemDelegate(new DiveListDelegate);
/* There`s mostly a need for a Mac fix here too. */
if (qApp->style()->objectName() == "gtk+")
ui.groupBox->layout()->setContentsMargins(0, 9, 0, 0);