Skip to content

Commit

Permalink
[ui] add hyperlink to saved vector/raster in the message bar
Browse files Browse the repository at this point in the history
  • Loading branch information
nirvn committed Jan 17, 2018
1 parent 163c278 commit 8bb6fde
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions src/app/qgisapp.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -6852,9 +6852,9 @@ void QgisApp::saveAsRasterFile( QgsRasterLayer *rasterLayer )
if ( rlWeakPointer )
emit layerSavedAs( rlWeakPointer, fileName );

messageBar()->pushMessage( tr( "Saving done" ),
tr( "Export to raster file has been completed" ),
QgsMessageBar::INFO, messageTimeout() );
messageBar()->pushMessage( tr( "Saving Done" ),
tr( "Successfully saved raster layer to <a href=\"%1\">%2</a>" ).arg( QUrl::fromLocalFile( QFileInfo( newFilename ).path() ).toString() ).arg( newFilename ),
QgsMessageBar::SUCCESS, messageTimeout() );
} );

// when an error occurs:
Expand Down Expand Up @@ -7055,9 +7055,9 @@ void QgisApp::saveAsVectorFileGeneral( QgsVectorLayer *vlayer, bool symbologyOpt
this->addVectorLayers( QStringList( uri ), encoding, QStringLiteral( "file" ) );
}
this->emit layerSavedAs( vlayer, vectorFilename );
this->messageBar()->pushMessage( tr( "Saving done" ),
tr( "Export to vector file has been completed" ),
QgsMessageBar::INFO, messageTimeout() );
this->messageBar()->pushMessage( tr( "Saving Done" ),
tr( "Successfully saved vector layer to <a href=\"%1\">%2</a>" ).arg( QUrl::fromLocalFile( QFileInfo( newFilename ).path() ).toString() ).arg( newFilename ),
QgsMessageBar::SUCCESS, messageTimeout() );
}
);

Expand Down

0 comments on commit 8bb6fde

Please sign in to comment.