Port rcc to QCommandLineParser.

Before:
=======
Qt resource compiler
Usage: rcc  [options] <inputs>

Options:
  -o file              write output to file rather than stdout
  -name name           create an external initialization function with name
  -threshold level     threshold to consider compressing files
  -compress level      compress input files by level
  -root path           prefix resource access path with root path
  -no-compress         disable all compression
  -binary              output a binary file for use as a dynamic resource
  -namespace           turn off namespace macros
  -project             Output a resource file containing all
                       files from the current directory
  -version             display version
  -help                display this information

Undocumented: -verbose and -list !

After:
======
Usage: rcc [options] inputs
Qt Resource Compiler version 5.2.0

Options:
  -h, --help          Displays this help.
  -v, --version       Displays version information.
  -o, --output <file> Write output to <file> rather than stdout.
  --name <name>       Create an external initialization function with <name>.
  --root <path>       Prefix resource access path with root path.
  --compress <level>  Compress input files by <level>.
  --no-compress       Disable all compression.
  --threshold <level> Threshold to consider compressing files.
  --binary            Output a binary file for use as a dynamic resource.
  --namespace         Turn off namespace macros.
  --verbose           Enable verbose mode.
  --list              Only list the files, do not generate code.
  --project           Output a resource file containing all files from the current directory.

Arguments:
  inputs              Input files (*.qrc).

Change-Id: If20958afd6c01df5d0d755e13e8581bc1cb9af51
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
tst_qthreadpool: fix flaky test I introduced in last commit

(dacf9961da86)
In order to see 2 active threads, we must check activeThreadCount() before
the runnable finishes.

Change-Id: I1a48b41e0c1fd81a65d915b9bd1e741ff267ed2b
Reviewed-by: Olivier Goffart <ogoffart@woboq.com>
Port uic to QCommandLineParser

Before:
=======
Qt User Interface Compiler version 5.2.0
Usage: uic [options] <uifile>

  -h, -help                 display this help and exit
  -v, -version              display version
  -d, -dependencies         display the dependencies
  -o <file>                 place the output into <file>
  -tr <func>                use func() for i18n
  -p, -no-protection        disable header protection
  -n, -no-implicit-includes disable generation of #include-directives
                            for forms generated by uic3
  -g <name>                 change generator

After:
======
Usage: uic [options] [uifile]
Qt User Interface Compiler version 5.2.0

Options:
  -h, --help                    Displays this help.
  -v, --version                 Displays version information.
  -d, --dependencies            Display the dependencies.
  -o, --output <file>           Place the output into <file>
  -p, --no-protection           Disable header protection.
  -n, --no-implicit-includes    Disable generation of #include-directives.
  --postfix <postfix>           Postfix to add to all generated classnames.
  --tr, --translate <function>  Use <function> for i18n.
  -g, --generator <java|cpp>    Select generator.

Arguments:
  [uifile]                      Input file (*.ui), otherwise stdin.

Notes:
* "-dependencies" etc. still work.
* -n option still has effect, but technically not only for ui3 files
* the fact that the <uifile> parameter is optional wasn't documented
* -postfix option was undocumented
* -translate alternative for -tr was undocumented
The last two points show the benefit of using QCommandLineParser.

Change-Id: Ie05cfb9bbe50f4ac2788aa7b6011b2daa1acde6a
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
Reviewed-by: Laszlo Papp <lpapp@kde.org>
Reviewed-by: Friedemann Kleint <Friedemann.Kleint@digia.com>
QFileDialog: add MIME Type filters

Currently just a convenience method for setNameFilters(), it uses
QMimeType to create a name filter from the glob patterns and
description defined in each MIME type.

In the longer term, this API could be used to do proper mimetype-based
filtering using QMimeDatabase::mimeTypeForFile() in the builtin
QFileDialog (aka "not native"), instead of only looking at globs via the
name filters.

Change-Id: I0edccf5f30c514481b47cd100d743d1ed7a24024
Reviewed-by: Frederik Gladhorn <frederik.gladhorn@digia.com>