Diffusion KIO c451327bd0aa

Extend getExtensionFromPatternList reg exp filtering

Authored by davidedmundson on Dec 22 2018, 10:27 PM.

Description

Extend getExtensionFromPatternList reg exp filtering

Summary:
getExtensionFromPatternList turns a filter string such "*.cpp" etc into
an extension ".cpp".

It tries to filter out any filter string that could be a glob pattern.
However it didn't handle "[]" characters.

See https://phabricator.kde.org/D17677 and D17738

Test Plan:
Modified kfilewidgettest_gui test and confirmed
that "automatically select file extension" checkbox didn't
insert irrelevant chars in the filename.

Subscribers: kde-frameworks-devel

Tags: Frameworks

Differential Revision: https://phabricator.kde.org/D17743