diff options
Diffstat (limited to 'fpicker')
-rw-r--r-- | fpicker/source/office/RemoteFilesDialog.cxx | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/fpicker/source/office/RemoteFilesDialog.cxx b/fpicker/source/office/RemoteFilesDialog.cxx index 1b541ba9096e..4d1cc1515716 100644 --- a/fpicker/source/office/RemoteFilesDialog.cxx +++ b/fpicker/source/office/RemoteFilesDialog.cxx @@ -822,6 +822,30 @@ IMPL_LINK_TYPED ( RemoteFilesDialog, EditServiceMenuHdl, MenuButton *, pButton, if( aBox->Execute() == RET_YES ) { + // remove password + try + { + if( m_xMasterPasswd->isPersistentStoringAllowed() ) + { + OUString sUrl( m_aServices[nPos]->GetUrl() ); + + Reference< XInteractionHandler > xInteractionHandler( + InteractionHandler::createWithParent( m_xContext, 0 ), + UNO_QUERY ); + + UrlRecord aURLEntries = m_xMasterPasswd->find( sUrl, xInteractionHandler ); + + if( aURLEntries.Url == sUrl && aURLEntries.UserList.getLength() ) + { + OUString sUserName = aURLEntries.UserList[0].UserName; + + m_xMasterPasswd->removePersistent( sUrl, sUserName ); + } + } + } + catch( const Exception& ) + {} + m_aServices.erase( m_aServices.begin() + nPos ); m_pServices_lb->RemoveEntry( nSelected ); |