[Libreoffice-commits] core.git: uui/source
Henry Castro (via logerrit)
logerrit at kemper.freedesktop.org
Wed Apr 7 14:44:50 UTC 2021
uui/source/secmacrowarnings.cxx | 18 +++++-------------
1 file changed, 5 insertions(+), 13 deletions(-)
New commits:
commit bcecb778172f043239d07bb52dd5a6503ede1570
Author: Henry Castro <hcastro at collabora.com>
AuthorDate: Fri Mar 5 06:45:45 2021 -0400
Commit: Henry Castro <hcastro at collabora.com>
CommitDate: Wed Apr 7 16:44:04 2021 +0200
lok: show only the filename of the Macro Security dialog
Apply the patch for desktop case too.
Change-Id: Ia4cf6d2cefd0e02e11e48ca017f8af9f81600b16
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/112003
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice at gmail.com>
Reviewed-by: Jan Holesovsky <kendy at collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/113688
Tested-by: Jenkins
Reviewed-by: Henry Castro <hcastro at collabora.com>
diff --git a/uui/source/secmacrowarnings.cxx b/uui/source/secmacrowarnings.cxx
index 932c4723ab21..7c853cf2f8e0 100644
--- a/uui/source/secmacrowarnings.cxx
+++ b/uui/source/secmacrowarnings.cxx
@@ -19,8 +19,6 @@
#include <com/sun/star/xml/crypto/XSecurityEnvironment.hpp>
#include <com/sun/star/security/DocumentDigitalSignatures.hpp>
-#include <comphelper/documentconstants.hxx>
-#include <comphelper/lok.hxx>
#include <comphelper/processfactory.hxx>
#include <vcl/svapp.hxx>
#include <osl/file.hxx>
@@ -29,8 +27,6 @@
#include <tools/debug.hxx>
#include <unotools/securityoptions.hxx>
#include <tools/urlobj.hxx>
-#include <unotools/resmgr.hxx>
-#include <com/sun/star/security/NoPasswordException.hpp>
using namespace ::com::sun::star::security;
@@ -92,15 +88,11 @@ IMPL_STATIC_LINK_NOARG(MacroWarning, InstallLOKNotifierHdl, void*, vcl::ILibreOf
void MacroWarning::SetDocumentURL( const OUString& rDocURL )
{
- OUString aAbbreviatedPath;
- if (comphelper::LibreOfficeKit::isActive())
- {
- osl::FileBase::getFileURLFromSystemPath(rDocURL, aAbbreviatedPath);
- aAbbreviatedPath = INetURLObject(aAbbreviatedPath).GetLastName();
- }
- else
- osl_abbreviateSystemPath(rDocURL.pData, &aAbbreviatedPath.pData, 50, nullptr);
- m_xDialog->set_primary_text(aAbbreviatedPath);
+ OUString aPath;
+
+ osl::FileBase::getFileURLFromSystemPath(rDocURL, aPath);
+ aPath = INetURLObject(aPath).GetLastName();
+ m_xDialog->set_primary_text(aPath);
}
IMPL_LINK_NOARG(MacroWarning, ViewSignsBtnHdl, weld::Button&, void)
More information about the Libreoffice-commits
mailing list