diff options
author | Elvis Angelaccio <elvis.angelaccio@kde.org> | 2016-09-12 18:48:17 +0200 |
---|---|---|
committer | Elvis Angelaccio <elvis.angelaccio@kde.org> | 2017-01-08 16:11:34 +0000 |
commit | 3f455a4b53254b3ebbafae91600a63caebee3e0e (patch) | |
tree | 5e63f750d03de84307369c66c0bfac144b238adf /dist/changes-3.0.4 | |
parent | 5311d481c2159c0076afc31c1276e1bd5b674fc4 (diff) |
Introduce QDir::isEmpty()
A directory is empty when it doesn't contain files or folders.
We can exploit QDirIterator::hasNext() to check whether this is the
case. This is efficient since it doesn't list the whole folder (in the
non-empty case).
Test cases are added for both the empty and non-empty cases.
Change-Id: I0f7e26782c0f97f9c16f928dab6cae37927875d8
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Diffstat (limited to 'dist/changes-3.0.4')
0 files changed, 0 insertions, 0 deletions