"Fossies" - the Fresh Open Source Software Archive  

Source code changes of the file "src/app/qgslayerstylingwidget.cpp" between
QGIS-final-3_10_11.tar.gz and QGIS-final-3_10_12.tar.gz

About: QGIS (Quantum GIS) is a Geographic Information System that supports vector, raster, and database formats. Long-term release (3.10.x series).

qgslayerstylingwidget.cpp  (QGIS-final-3_10_11):qgslayerstylingwidget.cpp  (QGIS-final-3_10_12)
skipping to change at line 134 skipping to change at line 134
{ {
connect( mCurrentLayer, &QgsMapLayer::styleChanged, this, &QgsLayerStylingWi dget::updateCurrentWidgetLayer ); connect( mCurrentLayer, &QgsMapLayer::styleChanged, this, &QgsLayerStylingWi dget::updateCurrentWidgetLayer );
} }
} }
void QgsLayerStylingWidget::setLayer( QgsMapLayer *layer ) void QgsLayerStylingWidget::setLayer( QgsMapLayer *layer )
{ {
if ( layer == mCurrentLayer ) if ( layer == mCurrentLayer )
return; return;
// when current layer is changed, apply the main panel stack to allow it to gr
acefully clean up
mWidgetStack->acceptAllPanels();
if ( mCurrentLayer ) if ( mCurrentLayer )
{ {
disconnect( mCurrentLayer, &QgsMapLayer::styleChanged, this, &QgsLayerStylin gWidget::updateCurrentWidgetLayer ); disconnect( mCurrentLayer, &QgsMapLayer::styleChanged, this, &QgsLayerStylin gWidget::updateCurrentWidgetLayer );
} }
if ( !layer || !layer->isSpatial() || !QgsProject::instance()->layerIsEmbedded ( layer->id() ).isEmpty() ) if ( !layer || !layer->isSpatial() || !QgsProject::instance()->layerIsEmbedded ( layer->id() ).isEmpty() )
{ {
mLayerCombo->setLayer( nullptr ); mLayerCombo->setLayer( nullptr );
mStackedWidget->setCurrentIndex( mNotSupportedPage ); mStackedWidget->setCurrentIndex( mNotSupportedPage );
mLastStyleXml.clear(); mLastStyleXml.clear();
skipping to change at line 604 skipping to change at line 607
mOptionsListWidget->setCurrentRow( i ); mOptionsListWidget->setCurrentRow( i );
return; return;
} }
} }
} }
void QgsLayerStylingWidget::layerAboutToBeRemoved( QgsMapLayer *layer ) void QgsLayerStylingWidget::layerAboutToBeRemoved( QgsMapLayer *layer )
{ {
if ( layer == mCurrentLayer ) if ( layer == mCurrentLayer )
{ {
// when current layer is removed, apply the main panel stack to allow it to
gracefully clean up
mWidgetStack->acceptAllPanels();
mAutoApplyTimer->stop(); mAutoApplyTimer->stop();
setLayer( nullptr ); setLayer( nullptr );
} }
} }
void QgsLayerStylingWidget::liveApplyToggled( bool value ) void QgsLayerStylingWidget::liveApplyToggled( bool value )
{ {
QgsSettings settings; QgsSettings settings;
settings.setValue( QStringLiteral( "UI/autoApplyStyling" ), value ); settings.setValue( QStringLiteral( "UI/autoApplyStyling" ), value );
} }
 End of changes. 2 change blocks. 
0 lines changed or deleted 8 lines changed or added

Home  |  About  |  Features  |  All  |  Newest  |  Dox  |  Diffs  |  RSS Feeds  |  Screenshots  |  Comments  |  Imprint  |  Privacy  |  HTTP(S)