[QGIS Commit] r15717 - trunk/qgis/src/app
svn_qgis at osgeo.org
svn_qgis at osgeo.org
Fri Apr 15 15:46:44 EDT 2011
Author: brushtyler
Date: 2011-04-15 12:46:44 -0700 (Fri, 15 Apr 2011)
New Revision: 15717
Modified:
trunk/qgis/src/app/qgsrasterlayerproperties.cpp
Log:
fix #2810
Modified: trunk/qgis/src/app/qgsrasterlayerproperties.cpp
===================================================================
--- trunk/qgis/src/app/qgsrasterlayerproperties.cpp 2011-04-15 19:41:47 UTC (rev 15716)
+++ trunk/qgis/src/app/qgsrasterlayerproperties.cpp 2011-04-15 19:46:44 UTC (rev 15717)
@@ -521,8 +521,16 @@
if ( mRasterLayer->dataProvider()->dataType( 1 ) == QgsRasterDataProvider::ARGBDataType )
{
- delete tabPageSymbology;
- delete tabPageColormap;
+ if ( tabPageSymbology != NULL )
+ {
+ delete tabPageSymbology;
+ tabPageSymbology = NULL;
+ }
+ if ( tabPageColormap != NULL )
+ {
+ delete tabPageColormap;
+ tabPageColormap = NULL;
+ }
gboxNoDataValue->setEnabled( false );
gboxCustomTransparency->setEnabled( false );
tabBar->setCurrentWidget( tabPageMetadata );
@@ -530,12 +538,20 @@
if ( !( mRasterLayer->dataProvider()->capabilities() & QgsRasterDataProvider::BuildPyramids ) )
{
- delete tabPagePyramids;
+ if ( tabPagePyramids != NULL )
+ {
+ delete tabPagePyramids;
+ tabPagePyramids = NULL;
+ }
}
if ( !( mRasterLayer->dataProvider()->capabilities() & QgsRasterDataProvider::Histogram ) )
{
- delete tabPageHistogram;
+ if ( tabPageHistogram != NULL )
+ {
+ delete tabPageHistogram;
+ tabPageHistogram = NULL;
+ }
}
#if 0
More information about the QGIS-commit
mailing list