sfx2/source/doc/docmacromode.cxx | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-)
New commits: commit f1151648b3df1b76e3308c288f12b4dd1414e92e Author: Mike Kaganski <mike.kagan...@collabora.com> AuthorDate: Sun Jan 1 14:21:34 2023 +0000 Commit: Mike Kaganski <mike.kagan...@collabora.com> CommitDate: Sun Jan 1 16:03:10 2023 +0000 Avoid unneeded initialization, and use URLZONE ids Change-Id: I8c6f31865b992fab0739fbefed5d39f21d0fa664 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/144904 Tested-by: Jenkins Reviewed-by: Mike Kaganski <mike.kagan...@collabora.com> diff --git a/sfx2/source/doc/docmacromode.cxx b/sfx2/source/doc/docmacromode.cxx index cbd720132323..976fc53414ed 100644 --- a/sfx2/source/doc/docmacromode.cxx +++ b/sfx2/source/doc/docmacromode.cxx @@ -303,25 +303,25 @@ namespace sfx2 { // no Security Zone info found -> assume a local file, not // from the internet - dwZone = 0; + dwZone = URLZONE_LOCAL_MACHINE; } // determine action from zone and settings - sal_Int32 nAction = 0; + sal_Int32 nAction; switch (dwZone) { - case 0: + case URLZONE_LOCAL_MACHINE: nAction = officecfg::Office::Common::Security::Scripting::WindowsSecurityZone::ZoneLocal::get(); break; - case 1: + case URLZONE_INTRANET: nAction = officecfg::Office::Common::Security::Scripting::WindowsSecurityZone::ZoneIntranet::get(); break; - case 2: + case URLZONE_TRUSTED: nAction = officecfg::Office::Common::Security::Scripting::WindowsSecurityZone::ZoneTrusted::get(); break; - case 3: + case URLZONE_INTERNET: nAction = officecfg::Office::Common::Security::Scripting::WindowsSecurityZone::ZoneInternet::get(); break; - case 4: + case URLZONE_UNTRUSTED: nAction = officecfg::Office::Common::Security::Scripting::WindowsSecurityZone::ZoneUntrusted::get(); break; default: