framework/source/loadenv/loadenv.cxx | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-)
New commits: commit 52882fc33d5234428656516bdfc88b60ff7f6607 Author: Kohei Yoshida <[email protected]> Date: Tue Apr 9 17:08:36 2013 -0400 Use environment variable LIBO_USE_ORCUS to decide whether or not to use orcus. This way we won't need to re-compile every time we need to switch between. Change-Id: I7d56a838c420a645ce8bebe0f0d9beaa78476fd6 diff --git a/framework/source/loadenv/loadenv.cxx b/framework/source/loadenv/loadenv.cxx index c824222..1820254 100644 --- a/framework/source/loadenv/loadenv.cxx +++ b/framework/source/loadenv/loadenv.cxx @@ -80,6 +80,7 @@ #include <unotools/ucbhelper.hxx> #include <comphelper/configurationhelper.hxx> #include <rtl/ustrbuf.hxx> +#include "rtl/bootstrap.hxx" #include <vcl/svapp.hxx> const char PROP_TYPES[] = "Types"; @@ -734,6 +735,10 @@ bool queryOrcusTypeAndFilter(const uno::Sequence<beans::PropertyValue>& rDescrip if (aURL.isEmpty() || aURL.copy(0,8).equalsIgnoreAsciiCase("private:")) return false; + OUString aUseOrcus; + rtl::Bootstrap::get("LIBO_USE_ORCUS", aUseOrcus); + bool bUseOrcus = (aUseOrcus == "YES"); + // TODO : Type must be set to be generic_Text (or any other type that // exists) in order to find a usable loader. Exploit it as a temporary // hack. @@ -744,7 +749,11 @@ bool queryOrcusTypeAndFilter(const uno::Sequence<beans::PropertyValue>& rDescrip rFilter = "gnumeric"; return true; } - else if (aURL.endsWith(".xlsx")) + + if (!bUseOrcus) + return false; + + if (aURL.endsWith(".xlsx")) { rType = "generic_Text"; rFilter = "xlsx"; _______________________________________________ Libreoffice-commits mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits
