Date: prev next · Thread: first prev next last
2012 Archives by date, by thread · List index


Hi there,

        This is not really my sphere of expertise, so review appreciated.
Rather than clobber the DesktopContext with some out-of band magic
(which creates the JavaInteractionHandler that in the end complains). I
thought I'd just give this guy a nil context - which seems to work
reasonably.

        On master you can also export STOC_FORCE_NO_JRE=1 # to debug this stuff
on Linux (it's harder to provoke a non-working JRE otherwise).

        I'd like to get this into 3.5.1 - thoughts appreciated :-) IMHO it is
rather better not to show this warning, than provide two scary looking,
and ultimately bogus dialogs there.

        All the best,

                Michael.

From 3675980cc1804e842b955b656fc03133ffbecea8 Mon Sep 17 00:00:00 2001
From: Michael Meeks <michael.meeks@suse.com>
Date: Thu, 16 Feb 2012 12:44:56 +0000
Subject: [PATCH] disable JRE warnings during help compilation on first start

---
 .../source/deployment/registry/help/dp_help.cxx    |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/desktop/source/deployment/registry/help/dp_help.cxx 
b/desktop/source/deployment/registry/help/dp_help.cxx
index d121833..adc2875 100644
--- a/desktop/source/deployment/registry/help/dp_help.cxx
+++ b/desktop/source/deployment/registry/help/dp_help.cxx
@@ -38,6 +38,7 @@
 #include "comphelper/servicedecl.hxx"
 #include "svl/inettype.hxx"
 #include "unotools/pathoptions.hxx"
+#include "uno/current_context.hxx"
 
 #if !defined(ANDROID) && !defined(IOS)
 #include <l10ntools/compilehelp.hxx>
@@ -420,6 +421,10 @@ void BackendImpl::implProcessHelp(
                 Reference< script::XInvocation > xInvocation;
                 if( xContext.is() )
                 {
+                    // Ignore the missing JRE scenario on upgrade/first-start without
+                    // horrible end-user warnings that are ignorable,and cause grief.
+                    Reference< XCurrentContext > xNoContext;
+                    com::sun::star::uno::ContextLayer dummyLayer( xNoContext );
                     try
                     {
                         xInvocation = Reference< script::XInvocation >(
-- 
1.7.3.4

-- 
michael.meeks@suse.com  <><, Pseudo Engineer, itinerant idiot


Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.