Commit b3173058 authored by Martin Heistermann's avatar Martin Heistermann
Browse files

Fix bug in File loader plugin selection.

Bug example: OVM loads *.volumemesh files, however the previous logic would
also try to use this plugin to load a *.mesh file, because "mesh" is a
suffix of "volumemesh"

This change adopts the same logic exhibited in Core/ to
require an advertised filetype to have a suffix of "*.ext", not of "ext"
when trying to load a file "foo.ext".
parent a9209798
......@@ -212,7 +212,7 @@ void LoadWidget::loadFile(){
for ( int filterId = 0 ; filterId < separateFilters.size(); ++filterId ) {
if (separateFilters[filterId].endsWith(ext[i],Qt::CaseInsensitive)){
if (separateFilters[filterId].endsWith("*." + ext[i],Qt::CaseInsensitive)){
pluginForExtension_[ ext[i] ] = t;
found = true;
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment