diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2019-12-14 11:48:27 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2019-12-14 12:45:15 +0100 |
commit | c0ac7ae73480cd2b01f24e88c01bee507e8638f9 (patch) | |
tree | b511e2e7d5230c0d000df589f7cebf03d72678e9 /jvmfwk | |
parent | 6f5dcd30d4035652d4ee3cf9708f481cd2f53977 (diff) |
Remove JFW_PLUGIN_DO_NOT_CHECK_ACCESSIBILITY, JFW_PLUGIN_FORCE_ACCESSIBILITY
JFW_PLUGIN_DO_NOT_CHECK_ACCESSIBILITY is no longer set anywhere since
6dcb3d4ef46312729bb6f16c473b433474863f68 "Related fdo#51252: No more prereg, no
more unopkg sync" in 2012. JFW_PLUGIN_FORCE_ACCESSIBILITY had been introduced
with 72b954df59d64fa47f6380e4322243401afb683f "Avoid using gconftool. Atk
provides a11y not Java on Unix" in 2013, as a means for users on Unix-like
systems to still force a JVM with a11y support, even though that should no
longer be necessary for LO a11y.
Both environment variables were documented as "unofficial", with the warning
that the "may be removed in the future." Theoretically, they could still be set
by some users, but the likelihood of their relevance today is considered low.
Change-Id: Ib718fb275b67a6de7fd7bc88ae428fd60168f4f4
Reviewed-on: https://gerrit.libreoffice.org/85140
Reviewed-by: Michael Meeks <michael.meeks@collabora.com>
Tested-by: Jenkins
Diffstat (limited to 'jvmfwk')
-rw-r--r-- | jvmfwk/plugins/sunmajor/pluginlib/util.cxx | 58 | ||||
-rw-r--r-- | jvmfwk/plugins/sunmajor/pluginlib/util.hxx | 3 | ||||
-rw-r--r-- | jvmfwk/source/fwkutil.cxx | 8 |
3 files changed, 3 insertions, 66 deletions
diff --git a/jvmfwk/plugins/sunmajor/pluginlib/util.cxx b/jvmfwk/plugins/sunmajor/pluginlib/util.cxx index 3afa7fcbbd07..d630a84dd904 100644 --- a/jvmfwk/plugins/sunmajor/pluginlib/util.cxx +++ b/jvmfwk/plugins/sunmajor/pluginlib/util.cxx @@ -26,9 +26,7 @@ #include <osl/module.hxx> #include <osl/diagnose.h> #include <osl/getglobalmutex.hxx> -#include <rtl/bootstrap.hxx> #include <rtl/ustrbuf.hxx> -#include <rtl/instance.hxx> #include <sal/log.hxx> #include <salhelper/linkhelper.hxx> #include <salhelper/thread.hxx> @@ -150,47 +148,6 @@ bool getAndAddJREInfoByPath( } } - OUString getLibraryLocation() - { - OUString libraryFileUrl; - OSL_VERIFY(osl::Module::getUrlFromAddress(reinterpret_cast<void *>(getLibraryLocation), libraryFileUrl)); - return getDirFromFile(libraryFileUrl); - } - - struct InitBootstrap - { - rtl::Bootstrap * operator()(const OUString& sIni) - { - static rtl::Bootstrap aInstance(sIni); - return & aInstance; - - } - }; - - struct InitBootstrapData - { - OUString const & operator()() - { - static OUString sIni; - OUStringBuffer buf( 255); - buf.append( getLibraryLocation()); -#ifdef MACOSX - buf.append( "/../" LIBO_ETC_FOLDER ); -#endif - buf.append( SAL_CONFIGFILE("/sunjavaplugin") ); - sIni = buf.makeStringAndClear(); - JFW_TRACE2("Using configuration file " << sIni); - return sIni; - } - }; -} - -rtl::Bootstrap * getBootstrap() -{ - return rtl_Instance< rtl::Bootstrap, InitBootstrap, - ::osl::MutexGuard, ::osl::GetGlobalMutex, - OUString, InitBootstrapData >::create( - InitBootstrap(), ::osl::GetGlobalMutex(), InitBootstrapData()); } namespace { @@ -389,13 +346,6 @@ void AsynchReader::execute() } } -static bool isEnvVarSetToOne(const OUString &aVar) -{ - OUString aValue; - getBootstrap()->getFrom(aVar, aValue); - return aValue == "1"; -} - bool getJavaProps(const OUString & exePath, #ifdef JVM_ONE_PATH_CHECK const OUString & homePath, @@ -436,13 +386,9 @@ bool getJavaProps(const OUString & exePath, #ifdef UNX // Java is no longer required for a11y - we use atk directly. - bool bNoAccessibility = !isEnvVarSetToOne("JFW_PLUGIN_FORCE_ACCESSIBILITY"); + bool bNoAccessibility = true; #else - //check if we shall examine a Java for accessibility support - //If the bootstrap variable is "1" then we pass the argument - //"noaccessibility" to JREProperties.class. This will prevent - //that it calls java.awt.Toolkit.getDefaultToolkit(); - bool bNoAccessibility = isEnvVarSetToOne("JFW_PLUGIN_DO_NOT_CHECK_ACCESSIBILITY"); + bool bNoAccessibility = false; #endif //prepare the arguments diff --git a/jvmfwk/plugins/sunmajor/pluginlib/util.hxx b/jvmfwk/plugins/sunmajor/pluginlib/util.hxx index 7f10e2748f7a..78df074f9de3 100644 --- a/jvmfwk/plugins/sunmajor/pluginlib/util.hxx +++ b/jvmfwk/plugins/sunmajor/pluginlib/util.hxx @@ -23,8 +23,6 @@ #include <vector> #include <vendorbase.hxx> -namespace rtl { class Bootstrap; } - namespace jfw_plugin { @@ -111,7 +109,6 @@ bool getJavaProps( void bubbleSortVersion(std::vector<rtl::Reference<VendorBase> >& vec); -rtl::Bootstrap* getBootstrap(); } #endif diff --git a/jvmfwk/source/fwkutil.cxx b/jvmfwk/source/fwkutil.cxx index a52013871340..fad1268feee1 100644 --- a/jvmfwk/source/fwkutil.cxx +++ b/jvmfwk/source/fwkutil.cxx @@ -28,7 +28,6 @@ #include <osl/module.hxx> #include <rtl/ustring.hxx> -#include <rtl/bootstrap.hxx> #include <osl/file.hxx> #include <sal/log.hxx> @@ -44,11 +43,6 @@ namespace jfw bool isAccessibilitySupportDesired() { - OUString sValue; - if (::rtl::Bootstrap::get( "JFW_PLUGIN_DO_NOT_CHECK_ACCESSIBILITY", sValue) && - sValue == "1" ) - return false; - #ifdef _WIN32 bool retVal = false; HKEY hKey = nullptr; @@ -89,7 +83,7 @@ bool isAccessibilitySupportDesired() } #elif defined UNX // Java is no longer required for a11y - we use atk directly. - bool retVal = ::rtl::Bootstrap::get( "JFW_PLUGIN_FORCE_ACCESSIBILITY", sValue) && sValue == "1"; + bool retVal = false; #endif return retVal; |