Skip to content

Commit

Permalink
Same behaviour for all layer types: style applied after loading
Browse files Browse the repository at this point in the history
  • Loading branch information
Djedouas committed Apr 11, 2023
1 parent c6eec2a commit 72bb868
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/gui/mesh/qgsmeshlayerproperties.cpp
Expand Up @@ -259,6 +259,7 @@ void QgsMeshLayerProperties::loadDefaultStyle()
if ( defaultLoadedFlag )
{
syncToLayer();
apply();
}
else
{
Expand Down Expand Up @@ -318,6 +319,7 @@ void QgsMeshLayerProperties::loadStyle()
{
settings.setValue( QStringLiteral( "style/lastStyleDir" ), QFileInfo( fileName ).absolutePath() );
syncToLayer();
apply();
}
else
{
Expand Down
5 changes: 5 additions & 0 deletions src/gui/vector/qgsvectorlayerproperties.cpp
Expand Up @@ -1011,6 +1011,7 @@ void QgsVectorLayerProperties::loadDefaultStyle_clicked()
else
{
syncToLayer();
apply();
}

return;
Expand All @@ -1026,6 +1027,7 @@ void QgsVectorLayerProperties::loadDefaultStyle_clicked()
{
// all worked OK so no need to inform user
syncToLayer();
apply();
}
else
{
Expand Down Expand Up @@ -1494,6 +1496,7 @@ void QgsVectorLayerProperties::loadStyle()
if ( defaultLoadedFlag )
{
syncToLayer();
apply();
}
else
{
Expand All @@ -1519,6 +1522,7 @@ void QgsVectorLayerProperties::loadStyle()
if ( mLayer->importNamedStyle( myDocument, errorMsg, categories ) )
{
syncToLayer();
apply();
}
else
{
Expand All @@ -1535,6 +1539,7 @@ void QgsVectorLayerProperties::loadStyle()
if ( defaultLoadedFlag )
{
syncToLayer();
apply();
}
else
{
Expand Down

0 comments on commit 72bb868

Please sign in to comment.