summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/svtools/PlaceEditDialog.hxx2
-rw-r--r--svtools/source/dialogs/PlaceEditDialog.cxx17
2 files changed, 19 insertions, 0 deletions
diff --git a/include/svtools/PlaceEditDialog.hxx b/include/svtools/PlaceEditDialog.hxx
index dc8840ae0423..de321a21abe2 100644
--- a/include/svtools/PlaceEditDialog.hxx
+++ b/include/svtools/PlaceEditDialog.hxx
@@ -39,6 +39,8 @@ private :
VclPtr<PushButton> m_pBTDelete;
+ VclPtr<Button> m_pBTRepoRefresh;
+
VclPtr<VclGrid> m_pTypeGrid;
/** Vector holding the details UI control for each server type.
diff --git a/svtools/source/dialogs/PlaceEditDialog.cxx b/svtools/source/dialogs/PlaceEditDialog.cxx
index 1028a560e598..12a5a491758c 100644
--- a/svtools/source/dialogs/PlaceEditDialog.cxx
+++ b/svtools/source/dialogs/PlaceEditDialog.cxx
@@ -27,6 +27,7 @@ PlaceEditDialog::PlaceEditDialog(vcl::Window* pParent)
get( m_pBTOk, "ok" );
get( m_pBTCancel, "cancel" );
get( m_pBTDelete, "delete" );
+ get( m_pBTRepoRefresh, "repositoriesRefresh" );
m_pBTOk->SetClickHdl( LINK( this, PlaceEditDialog, OKHdl) );
m_pBTOk->Enable( false );
@@ -184,7 +185,23 @@ void PlaceEditDialog::InitDetails( )
IMPL_LINK ( PlaceEditDialog, OKHdl, Button *, )
{
+ if (m_xCurrentDetails.get())
+ {
+ OUString sUrl = m_xCurrentDetails->getUrl().GetHost(INetURLObject::DECODE_WITH_CHARSET);
+ OUString sGDriveHost( GDRIVE_BASE_URL );
+ OUString sAlfrescoHost( ALFRESCO_CLOUD_BASE_URL );
+ OUString sOneDriveHost( ONEDRIVE_BASE_URL );
+
+ if( sUrl.compareTo(sGDriveHost, sGDriveHost.getLength()) == 0
+ || sUrl.compareTo(sAlfrescoHost, sAlfrescoHost.getLength()) == 0
+ || sUrl.compareTo(sOneDriveHost, sOneDriveHost.getLength()) == 0 )
+ {
+ m_pBTRepoRefresh->Click();
+ }
+ }
+
EndDialog( RET_OK );
+
return 1;
}