From b0c0cbbc738397ced160ae3cd2c0989e7b30eb37 Mon Sep 17 00:00:00 2001 From: Jens Bache-Wiig <jens.bache-wiig@digia.com> Date: Wed, 15 May 2013 11:03:01 +0200 Subject: [PATCH] Don't draw anything in TableView unless there is a column I was really confused because after assigning a model it looked like the table view was showing the data, while in reality it was just filling up with alternating row colors. I think it is better not to draw anything to ensure that people correctly add a TableViewColumn. Change-Id: I353b478f4af80410aca3f94439a02ed7ab53f6d6 Reviewed-by: J-P Nurmi <jpnurmi@digia.com> Reviewed-by: Caroline Chao <caroline.chao@digia.com> --- src/controls/TableView.qml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/controls/TableView.qml b/src/controls/TableView.qml index 3f95ec195..e48885ff7 100644 --- a/src/controls/TableView.qml +++ b/src/controls/TableView.qml @@ -304,8 +304,9 @@ ScrollView { anchors.topMargin: tableHeader.height anchors.fill: parent currentIndex: -1 - + visible: columns.length > 0 interactive: false + SystemPalette { id: palette colorGroup: enabled ? SystemPalette.Active : SystemPalette.Disabled -- GitLab