title: QFileDialog: Selecting directories and files
body: <p>I'm using the code below to build a qstringlist of filenames:</p>
  
  <pre><code>QStringList filenames = QFileDialog::getOpenFileNames(this,"",QDir::currentPath() );
  </code></pre>
  
  <p>How can I change this so I can select directories as well?</p>
  
  <p>I looked at:</p>
  
  <pre><code>      dialog.setFileMode(QFileDialog::AnyFile);
  </code></pre>
  
  <p>but I don't get how to use it with my code.</p>