svtools/source/dialogs/PlaceEditDialog.cxx | 7 +++++++ 1 file changed, 7 insertions(+)
New commits: commit f875364d5bf2207410814efe39e1b41f3c283356 Author: Aditya <adityasahu1...@gmail.com> AuthorDate: Thu Jan 31 03:50:55 2019 +0530 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Sat Feb 2 10:37:08 2019 +0100 tdf#119812: Hide "Windows Share" server type in Windows OS. The "Windows Share" server type is non-functional in Windows OS but still shown in the File Services (PlaceEditDialog) dialog. This patch removes its entry from dialog on Windows only so that no more non-functional service can be created. Change-Id: I440c637dd2a566f820a6e8fac826f35cabb9c05f Reviewed-on: https://gerrit.libreoffice.org/66055 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/svtools/source/dialogs/PlaceEditDialog.cxx b/svtools/source/dialogs/PlaceEditDialog.cxx index dfaba1f22488..df8f6f46fddb 100644 --- a/svtools/source/dialogs/PlaceEditDialog.cxx +++ b/svtools/source/dialogs/PlaceEditDialog.cxx @@ -223,10 +223,17 @@ void PlaceEditDialog::InitDetails( ) xSshDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); m_aDetailsContainers.push_back(xSshDetails); + // Remove Windows Share entry from dialog on Windows OS, where it's non-functional +#if defined(_WIN32) + // nPos is the position of first item that is pre-defined in svtools/uiconfig/ui/placeedit.ui, + // after other CMIS types were inserted + m_xLBServerType->remove(nPos + 3); +#else // Create Windows Share control std::shared_ptr<DetailsContainer> xSmbDetails(std::make_shared<SmbDetailsContainer>(this)); xSmbDetails->setChangeHdl( LINK( this, PlaceEditDialog, EditHdl ) ); m_aDetailsContainers.push_back(xSmbDetails); +#endif // Set default to first value m_xLBServerType->set_active(0); _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits