Windows: Trim filter specification of the native file dialog.
In the event customer code (namely Qt Creator) does not pass a clean specification (corresponding to 4.8 behaviour). Change-Id: I8271e3a45bea4bea912fcdf0b7c0aae6c022c6a8 Reviewed-by: Friedemann Kleint <Friedemann.Kleint@nokia.com>
This commit is contained in:
parent
4c3a35adec
commit
5031aee972
@ -870,7 +870,8 @@ void QWindowsNativeFileDialogBase::setNameFilters(const QStringList &filters)
|
||||
const int closingParenPos = openingParenPos != -1 ?
|
||||
filterString.indexOf(QLatin1Char(')'), openingParenPos + 1) : -1;
|
||||
QString filterSpec = closingParenPos == -1 ?
|
||||
QString(QLatin1Char('*')) : filterString.mid(openingParenPos + 1, closingParenPos - openingParenPos - 1);
|
||||
QString(QLatin1Char('*')) :
|
||||
filterString.mid(openingParenPos + 1, closingParenPos - openingParenPos - 1).trimmed();
|
||||
filterSpec.replace(filterSeparatorRE, separator);
|
||||
if (m_hideFiltersDetails) {
|
||||
// Do not show pattern in description
|
||||
|
Loading…
Reference in New Issue
Block a user