I have a QFileInfoList (list) that contains information about the directory and its file
QFileInfoList list = directory.entryInfoList();
How can I apply filters to delete everything except the image file (jpg, gif, png, etc.)?
Here is a simple foreach loop that removes everything that is not a file
foreach (QFileInfo f, list){ if (!f.isFile()){ list.removeOne(f); }
How can I apply filters to delete everything except the image file (jpg, gif, png, etc.)?
c ++ qt qt4
Sharethefun
source share