Skip to content

Commit

Permalink
Use QgsMessageBar instead of QMessageBox
Browse files Browse the repository at this point in the history
  • Loading branch information
m-kuhn committed May 13, 2013
1 parent 142223b commit fe072c5
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/app/qgisapp.cpp
Expand Up @@ -2540,14 +2540,14 @@ bool QgisApp::addVectorLayers( QStringList const & theLayerQStringList, const QS
else
{
QString msg = tr( "%1 doesn't have any layers" ).arg( src );
QMessageBox::critical( this, tr( "Invalid Data Source" ), msg );
messageBar()->pushMessage( tr( "Invalid Data Source" ), msg, QgsMessageBar::CRITICAL, messageTimeout() );
delete layer;
}
}
else
{
QString msg = tr( "%1 is not a valid or recognized data source" ).arg( src );
QMessageBox::critical( this, tr( "Invalid Data Source" ), msg );
messageBar()->pushMessage( tr( "Invalid Data Source" ), msg, QgsMessageBar::CRITICAL, messageTimeout() );

// since the layer is bad, stomp on it
delete layer;
Expand Down

0 comments on commit fe072c5

Please sign in to comment.