Skip to content

Commit

Permalink
Hide import/export buttons for arcgis services as they do not work (f…
Browse files Browse the repository at this point in the history
…ixes #15637)

(cherry picked from commit 1c2f0de)
  • Loading branch information
wonder-sk committed Nov 1, 2016
1 parent b798040 commit 629ca8b
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 24 deletions.
23 changes: 1 addition & 22 deletions src/gui/qgssourceselectdialog.cpp
Expand Up @@ -412,28 +412,7 @@ void QgsSourceSelectDialog::on_cmbConnections_activated( int index )
QgsOwsConnection::setSelectedConnection( mServiceName, cmbConnections->currentText() );
}

void QgsSourceSelectDialog::on_btnSave_clicked()
{
QgsManageConnectionsDialog dlg( this, QgsManageConnectionsDialog::Export, QgsManageConnectionsDialog::WFS );
dlg.exec();
}

void QgsSourceSelectDialog::on_btnLoad_clicked()
{
QString fileName = QFileDialog::getOpenFileName( this, tr( "Load connections" ), QStringLiteral( "." ),
tr( "XML files (*.xml *XML)" ) );
if ( fileName.isEmpty() )
{
return;
}

QgsManageConnectionsDialog dlg( this, QgsManageConnectionsDialog::Import, QgsManageConnectionsDialog::WFS, fileName );
dlg.exec();
populateConnectionList();
emit connectionsChanged();
}

void QgsSourceSelectDialog::treeWidgetItemDoubleClicked( const QModelIndex& index )
void QgsSourceSelectDialog::treeWidgetItemDoubleClicked( const QModelIndex & index )
{
QgsDebugMsg( "double click called" );
QgsOwsConnection connection( mServiceName, cmbConnections->currentText() );
Expand Down
2 changes: 0 additions & 2 deletions src/gui/qgssourceselectdialog.h
Expand Up @@ -99,8 +99,6 @@ class GUI_EXPORT QgsSourceSelectDialog : public QDialog, protected Ui::QgsSource
void changeCrsFilter();
void connectToServer();
void filterChanged( const QString &text );
void on_btnLoad_clicked();
void on_btnSave_clicked();
void on_cmbConnections_activated( int index );
void on_buttonBox_helpRequested() const;
void treeWidgetItemDoubleClicked( const QModelIndex & index );
Expand Down
4 changes: 4 additions & 0 deletions src/providers/arcgisrest/qgsafssourceselect.cpp
Expand Up @@ -33,6 +33,10 @@ QgsAfsSourceSelect::QgsAfsSourceSelect( QWidget* parent, Qt::WindowFlags fl, boo
{
buttonBox->button( QDialogButtonBox::Close )->hide();
}

// import/export of connections not supported yet
btnLoad->hide();
btnSave->hide();
}

bool QgsAfsSourceSelect::connectToService( const QgsOwsConnection &connection )
Expand Down
4 changes: 4 additions & 0 deletions src/providers/arcgisrest/qgsamssourceselect.cpp
Expand Up @@ -32,6 +32,10 @@ QgsAmsSourceSelect::QgsAmsSourceSelect( QWidget* parent, Qt::WindowFlags fl, boo
{
buttonBox->button( QDialogButtonBox::Close )->hide();
}

// import/export of connections not supported yet
btnLoad->hide();
btnSave->hide();
}

bool QgsAmsSourceSelect::connectToService( const QgsOwsConnection &connection )
Expand Down

0 comments on commit 629ca8b

Please sign in to comment.