KDirModel: fix hasChildren() regression for trees with files shown
The logic I introduced in commit ebe77143 assumed that only subdirs were shown in the tree (konqueror sidebar use case). However KDirOperator can also show files, so this introduced bug 419434. Now implemented correctly for both use cases, with unittest.
BUG: 419434 FIXED-IN: 5.71