From 283f97ac27c3cfe5c72682b0843503e31643a612 Mon Sep 17 00:00:00 2001 From: Peter Penz Date: Sat, 15 Oct 2011 22:55:01 +0200 Subject: Interface cleanups to prepare the return of "grouped sorting" - Rename setCategorizedSorting() to setGroupedSorting() - Change the model interface to allow enabling/disabling grouping without the need to declare a role (the sort role will be taken). - Add dummy group role implementation in KFileItemModel The grouping code itself requires some cleanups and might crash at the moment or lead to weird layouts. --- src/tests/kfileitemmodeltest.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/tests') diff --git a/src/tests/kfileitemmodeltest.cpp b/src/tests/kfileitemmodeltest.cpp index f56ef9033..4f2f2f8ec 100644 --- a/src/tests/kfileitemmodeltest.cpp +++ b/src/tests/kfileitemmodeltest.cpp @@ -41,7 +41,7 @@ private slots: void testDefaultRoles(); void testDefaultSortRole(); - void testDefaultGroupRole(); + void testDefaultGroupedSorting(); void testNewItems(); void testRemoveItems(); void testModelConsistencyWhenInsertingItems(); @@ -113,9 +113,9 @@ void KFileItemModelTest::testDefaultSortRole() QCOMPARE(m_model->data(2)["name"].toString(), QString("c.txt")); } -void KFileItemModelTest::testDefaultGroupRole() +void KFileItemModelTest::testDefaultGroupedSorting() { - QVERIFY(m_model->groupRole().isEmpty()); + QCOMPARE(m_model->groupedSorting(), false); } void KFileItemModelTest::testNewItems() -- cgit v1.3