void QgsAuthConfigSelect::loadConfig() { clearConfig(); if ( !mAuthCfg.isEmpty() && mConfigs.contains( mAuthCfg ) ) { QgsAuthMethodConfig config = mConfigs.value( mAuthCfg ); QgsAuthMethod *authmethod = QgsAuthManager::instance()->configAuthMethod( mAuthCfg ); QString methoddesc = tr( "Missing authentication method description" ); if ( authmethod ) { methoddesc = authmethod->description(); } cmbConfigSelect->setToolTip( tr( "<ul><li><b>Method type:</b> %1</li>" "<li><b>Configuration ID:</b> %2</li></ul>" ).arg( methoddesc, config.id( ) ) ); btnConfigEdit->setEnabled( true ); btnConfigRemove->setEnabled( true ); } emit selectedConfigIdChanged( mAuthCfg ); }
void QgsAuthConfigSelect::loadConfig() { clearConfig(); if ( !mAuthCfg.isEmpty() && mConfigs.contains( mAuthCfg ) ) { QgsAuthMethodConfig config = mConfigs.value( mAuthCfg ); QgsAuthMethod * authmethod = QgsAuthManager::instance()->configAuthMethod( mAuthCfg ); QString methoddesc = tr( "Missing authentication method description" ); if ( authmethod ) { methoddesc = authmethod->description(); } leConfigMethodDesc->setText( methoddesc ); leConfigMethodDesc->setCursorPosition( 0 ); // left justify leConfigId->setText( config.id() ); btnConfigEdit->setEnabled( true ); btnConfigRemove->setEnabled( true ); } emit selectedConfigIdChanged( mAuthCfg ); }