[Libreoffice-commits] core.git: sc/source
Tamas Bunth
tamas.bunth at collabora.co.uk
Fri Jun 30 07:45:33 UTC 2017
sc/source/ui/vba/vbaapplication.cxx | 15 ++++++++++++---
1 file changed, 12 insertions(+), 3 deletions(-)
New commits:
commit 5c5a49eda1555db7b7519e9b0398cfd469c9bcb5
Author: Tamas Bunth <tamas.bunth at collabora.co.uk>
Date: Thu Jun 29 11:46:31 2017 +0200
oovbaapi: implement Application.GetOperatingSystem
Without version number of the system for now.
Documentation:
https://msdn.microsoft.com/en-us/vba/excel-vba/articles/application-operatingsystem-property-excel
Change-Id: I0c76ea3909ecaa3896823136b3a3ebf2a2fdb4d1
Reviewed-on: https://gerrit.libreoffice.org/39383
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Tamás Bunth <btomi96 at gmail.com>
diff --git a/sc/source/ui/vba/vbaapplication.cxx b/sc/source/ui/vba/vbaapplication.cxx
index e678d58a67d4..f751ccff7f65 100644
--- a/sc/source/ui/vba/vbaapplication.cxx
+++ b/sc/source/ui/vba/vbaapplication.cxx
@@ -917,9 +917,18 @@ ScVbaApplication::getPathSeparator()
OUString SAL_CALL
ScVbaApplication::getOperatingSystem()
{
- // TODO implement
- SAL_WARN("sc", "not implemented");
- return OUString();
+ // TODO Solution should contain the version number of the operating system
+ // too.
+#if defined(_WIN32)
+ return OUString("Windows");
+#elif defined(MACOSX)
+ return OUString("Macintosh");
+#elif defined(UNX)
+ // M. Office is not available on Unix systems, so it is not documented.
+ return OUString("Unix");
+#else
+ return OUString("Unknown");
+#endif
}
// Helpers for Intersect and Union
More information about the Libreoffice-commits
mailing list