Skip to content

Commit

Permalink
Removed a bit of duplicated code
Browse files Browse the repository at this point in the history
git-svn-id: http://svn.osgeo.org/qgis/trunk/qgis@5543 c8812cc2-4d05-0410-92ff-de0c093fc19c
  • Loading branch information
g_j_m committed Jun 24, 2006
1 parent 7e3491e commit 901ad5b
Showing 1 changed file with 4 additions and 10 deletions.
14 changes: 4 additions & 10 deletions src/raster/qgsrasterlayer.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -335,23 +335,17 @@ void QgsRasterLayer::buildSupportedRasterFileFilter(QString & theFileFiltersStri
theFileFiltersString += "JPEG 2000 (" + glob.lower() + " " + glob.upper() + ");;";
}

// A number of drivers support JPEG 2000. Add it in for those.
if ( myGdalDriverDescription.startsWith("MrSID")
|| myGdalDriverDescription.startsWith("ECW")
|| myGdalDriverDescription.startsWith("JPEG2000")
|| myGdalDriverDescription.startsWith("JP2KAK") )
{
QString glob = "*.jp2 *.j2k";
theFileFiltersString += "JPEG 2000 (" + glob.lower() + " " + glob.upper() + ");;";
}

myGdalDriverExtension = myGdalDriverLongName = ""; // reset for next driver

} // each loaded GDAL driver

// can't forget the default case
theFileFiltersString += catchallFilter + "All other files (*)";
QgsDebugMsg("Raster filter list built: " + theFileFiltersString);


std::cerr << theFileFiltersString.toLocal8Bit().data() << '\n';

} // buildSupportedRasterFileFilter_()


Expand Down

0 comments on commit 901ad5b

Please sign in to comment.