[import] Fix leaking AbstractFileFilters
Summary:
Fix memory leaks due to recreation of AbstractFileFilter for each call
of ImportFileWidget::currentFileFilter(). The filter now is cached
as a member of ImportFileWidget and reused if the file type does not change.
A new method AbstractFileFilter::type() returns the type of the
current filter.
Test Plan:
- import different files
- output (during debugging) the number of newly created filter instances
Reviewers: LabPlot, asemke
Reviewed By: LabPlot, asemke
Subscribers: asemke, kde-edu
Tags: KDE Edu
Differential Revision: https://phabricator.kde.org/D16663