diff options
author | Matthias Huetsch [mhu] <matthias.huetsch@oracle.com> | 2011-01-27 18:16:28 +0100 |
---|---|---|
committer | Matthias Huetsch [mhu] <matthias.huetsch@oracle.com> | 2011-01-27 18:16:28 +0100 |
commit | 45893f9a2740eb9c291476df4eaa3700003f0efd (patch) | |
tree | a7e2381af1a4136eb18b89b55af639306c9fc2c0 /svtools/source/java | |
parent | e3f92103a5a14baf81c7f4fca6bc8fb4f3741e1d (diff) | |
parent | ffd600e777970df0908125da66b280e1b00dbec9 (diff) |
Update from master repository (DEV300_m98).
Diffstat (limited to 'svtools/source/java')
-rw-r--r-- | svtools/source/java/javainteractionhandler.cxx | 109 | ||||
-rw-r--r-- | svtools/source/java/makefile.mk | 54 | ||||
-rw-r--r-- | svtools/source/java/patchjavaerror.src | 93 |
3 files changed, 10 insertions, 246 deletions
diff --git a/svtools/source/java/javainteractionhandler.cxx b/svtools/source/java/javainteractionhandler.cxx index ec34ed07f25d..a7420dbc388f 100644 --- a/svtools/source/java/javainteractionhandler.cxx +++ b/svtools/source/java/javainteractionhandler.cxx @@ -147,28 +147,10 @@ void SAL_CALL JavaInteractionHandler::handle( const Reference< XInteractionReque // No suitable JRE found vos::OGuard aSolarGuard( Application::GetSolarMutex() ); m_bJavaNotFound_Handled = true; - //We first try to get the patch resource svp680xxx.res - //If the resource is not found then svt680xxx.res is used - ResId idWBX = SvtResId(WARNINGBOX_JAVANOTFOUND); - SvpResId pidPatchWBX(WARNINGBOX_JAVANOTFOUND); - pidPatchWBX.SetRT(RSC_WARNINGBOX); - ResMgr *pMgrWB = pidPatchWBX.GetResMgr(); - if (pMgrWB && pMgrWB->IsAvailable(pidPatchWBX)) - idWBX = pidPatchWBX; - WarningBox aWarningBox( NULL, idWBX); - - String aTitle; - SvpResId pidString(STR_WARNING_JAVANOTFOUND); - pidString.SetRT(RSC_STRING); - ResMgr *pmgr = pidString.GetResMgr(); - if ( pmgr && pmgr->IsAvailable(pidString)) - aTitle = String(pidString); - else - aTitle = String( SvtResId( STR_WARNING_JAVANOTFOUND )); - + WarningBox aWarningBox( NULL, SvtResId( WARNINGBOX_JAVANOTFOUND ) ); + String aTitle( SvtResId( STR_WARNING_JAVANOTFOUND ) ); aWarningBox.SetText( aTitle ); nResult = aWarningBox.Execute(); - } else { @@ -182,25 +164,8 @@ void SAL_CALL JavaInteractionHandler::handle( const Reference< XInteractionReque // javavendors.xml was updated and Java has not been configured yet vos::OGuard aSolarGuard( Application::GetSolarMutex() ); m_bInvalidSettings_Handled = true; - //We first try to get the patch resource svp680xxx.res - //If the resource is not found then svt680xxx.res is used - ResId idWBX = SvtResId(WARNINGBOX_INVALIDJAVASETTINGS); - SvpResId pidPatchWBX(WARNINGBOX_INVALIDJAVASETTINGS); - pidPatchWBX.SetRT(RSC_WARNINGBOX); - ResMgr *pMgrWB = pidPatchWBX.GetResMgr(); - if (pMgrWB && pMgrWB->IsAvailable(pidPatchWBX)) - idWBX = pidPatchWBX; - WarningBox aWarningBox( NULL, idWBX); - - String aTitle; - SvpResId pidString(STR_WARNING_INVALIDJAVASETTINGS); - pidString.SetRT(RSC_STRING); - ResMgr *pmgr = pidString.GetResMgr(); - if ( pmgr && pmgr->IsAvailable(pidString)) - aTitle = String(pidString); - else - aTitle = String( SvtResId(STR_WARNING_INVALIDJAVASETTINGS)); - + WarningBox aWarningBox( NULL, SvtResId( WARNINGBOX_INVALIDJAVASETTINGS ) ); + String aTitle( SvtResId(STR_WARNING_INVALIDJAVASETTINGS)); aWarningBox.SetText( aTitle ); nResult = aWarningBox.Execute(); } @@ -216,28 +181,8 @@ void SAL_CALL JavaInteractionHandler::handle( const Reference< XInteractionReque vos::OGuard aSolarGuard( Application::GetSolarMutex() ); m_bJavaDisabled_Handled = true; // Java disabled. Give user a chance to enable Java inside Office. - //We first try to get the patch resource svp680xxx.res - //If the resource is not found then svt680xxx.res is used - ResId idQBX = SvtResId( QBX_JAVADISABLED ); - SvpResId pidPatchQBX(QBX_JAVADISABLED); - pidPatchQBX.SetRT(RSC_QUERYBOX); - ResMgr *pMgrQB = pidPatchQBX.GetResMgr(); - - if (pMgrQB && pMgrQB->IsAvailable(pidPatchQBX)) - idQBX = pidPatchQBX; - - QueryBox aQueryBox(NULL, idQBX); - - String aTitle; - - SvpResId pidString(STR_QUESTION_JAVADISABLED); - pidString.SetRT(RSC_STRING); - ResMgr *pmgr = pidString.GetResMgr(); - if ( pmgr && pmgr->IsAvailable(pidString)) - aTitle = String(pidString); - else - aTitle = String( SvtResId( STR_QUESTION_JAVADISABLED )); - + QueryBox aQueryBox( NULL, SvtResId( QBX_JAVADISABLED ) ); + String aTitle( SvtResId( STR_QUESTION_JAVADISABLED ) ); aQueryBox.SetText( aTitle ); nResult = aQueryBox.Execute(); if ( nResult == RET_YES ) @@ -260,25 +205,8 @@ void SAL_CALL JavaInteractionHandler::handle( const Reference< XInteractionReque // Java not correctly installed, or damaged vos::OGuard aSolarGuard( Application::GetSolarMutex() ); m_bVMCreationFailure_Handled = true; - //We first try to get the patch resource svp680xxx.res - //If the resource is not found then svt680xxx.res is used - ResId idEBX = SvtResId(ERRORBOX_JVMCREATIONFAILED); - SvpResId pidPatchEBX(ERRORBOX_JVMCREATIONFAILED); - pidPatchEBX.SetRT(RSC_ERRORBOX); - ResMgr *pMgrEB = pidPatchEBX.GetResMgr(); - if (pMgrEB && pMgrEB->IsAvailable(pidPatchEBX)) - idEBX = pidPatchEBX; - ErrorBox aErrorBox( NULL, idEBX); - - String aTitle; - SvpResId pidString(STR_ERROR_JVMCREATIONFAILED); - pidString.SetRT(RSC_STRING); - ResMgr *pmgr = pidString.GetResMgr(); - if ( pmgr && pmgr->IsAvailable(pidString)) - aTitle = String(pidString); - else - aTitle = String( SvtResId(STR_ERROR_JVMCREATIONFAILED)); - + ErrorBox aErrorBox( NULL, SvtResId( ERRORBOX_JVMCREATIONFAILED ) ); + String aTitle( SvtResId( STR_ERROR_JVMCREATIONFAILED ) ); aErrorBox.SetText( aTitle ); nResult = aErrorBox.Execute(); } @@ -295,25 +223,8 @@ void SAL_CALL JavaInteractionHandler::handle( const Reference< XInteractionReque //before it can be used. vos::OGuard aSolarGuard( Application::GetSolarMutex() ); m_bRestartRequired_Handled = true; - //We first try to get the patch resource svp680xxx.res - //If the resource is not found then svt680xxx.res is used - ResId idEBX = SvtResId(ERRORBOX_RESTARTREQUIRED); - SvpResId pidPatchEBX(ERRORBOX_RESTARTREQUIRED); - pidPatchEBX.SetRT(RSC_ERRORBOX); - ResMgr *pMgrEB = pidPatchEBX.GetResMgr(); - if (pMgrEB && pMgrEB->IsAvailable(pidPatchEBX)) - idEBX = pidPatchEBX; - ErrorBox aErrorBox(NULL, idEBX); - - String aTitle; - SvpResId pidString(STR_ERROR_RESTARTREQUIRED); - pidString.SetRT(RSC_STRING); - ResMgr *pmgr = pidString.GetResMgr(); - if ( pmgr && pmgr->IsAvailable(pidString)) - aTitle = String(pidString); - else - aTitle = String( SvtResId(STR_ERROR_RESTARTREQUIRED)); - + ErrorBox aErrorBox(NULL, SvtResId( ERRORBOX_RESTARTREQUIRED ) ); + String aTitle( SvtResId( STR_ERROR_RESTARTREQUIRED ) ); aErrorBox.SetText( aTitle ); nResult = aErrorBox.Execute(); } diff --git a/svtools/source/java/makefile.mk b/svtools/source/java/makefile.mk deleted file mode 100644 index 6db57388dca0..000000000000 --- a/svtools/source/java/makefile.mk +++ /dev/null @@ -1,54 +0,0 @@ -#************************************************************************* -# -# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. -# -# Copyright 2000, 2010 Oracle and/or its affiliates. -# -# OpenOffice.org - a multi-platform office productivity suite -# -# This file is part of OpenOffice.org. -# -# OpenOffice.org is free software: you can redistribute it and/or modify -# it under the terms of the GNU Lesser General Public License version 3 -# only, as published by the Free Software Foundation. -# -# OpenOffice.org is distributed in the hope that it will be useful, -# but WITHOUT ANY WARRANTY; without even the implied warranty of -# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -# GNU Lesser General Public License version 3 for more details -# (a copy is included in the LICENSE file that accompanied this code). -# -# You should have received a copy of the GNU Lesser General Public License -# version 3 along with OpenOffice.org. If not, see -# <http://www.openoffice.org/license.html> -# for a copy of the LGPLv3 License. -# -#************************************************************************* - -PRJ=..$/.. - -PRJNAME=svtools -TARGET=java -ENABLE_EXCEPTIONS=TRUE - -# --- Settings ----------------------------------------------------- - -.INCLUDE : settings.mk -.INCLUDE : $(PRJ)$/util$/svt.pmk - -# --- Files -------------------------------------------------------- - -SRS1NAME= javaerror -SRC1FILES= javaerror.src - -SRS2NAME= patchjavaerror -SRC2FILES= patchjavaerror.src - - -SLOFILES= \ - $(SLO)$/javainteractionhandler.obj \ - $(SLO)$/javacontext.obj - -# --- Targets ------------------------------------------------------ - -.INCLUDE : target.mk diff --git a/svtools/source/java/patchjavaerror.src b/svtools/source/java/patchjavaerror.src deleted file mode 100644 index d5990c05a663..000000000000 --- a/svtools/source/java/patchjavaerror.src +++ /dev/null @@ -1,93 +0,0 @@ -/************************************************************************* - * - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * Copyright 2000, 2010 Oracle and/or its affiliates. - * - * OpenOffice.org - a multi-platform office productivity suite - * - * This file is part of OpenOffice.org. - * - * OpenOffice.org is free software: you can redistribute it and/or modify - * it under the terms of the GNU Lesser General Public License version 3 - * only, as published by the Free Software Foundation. - * - * OpenOffice.org is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU Lesser General Public License version 3 for more details - * (a copy is included in the LICENSE file that accompanied this code). - * - * You should have received a copy of the GNU Lesser General Public License - * version 3 along with OpenOffice.org. If not, see - * <http://www.openoffice.org/license.html> - * for a copy of the LGPLv3 License. - * - ************************************************************************/ - -#include <svtools/svtools.hrc> - -WarningBox WARNINGBOX_JAVANOTFOUND -{ - Buttons = WB_OK ; - DefButton = WB_DEF_OK ; - Message[ en-US ] ="%PRODUCTNAME requires a Java runtime environment (JRE) to perform this task. Please install a JRE and restart %PRODUCTNAME."; -}; - -WarningBox WARNINGBOX_INVALIDJAVASETTINGS -{ - Buttons = WB_OK ; - DefButton = WB_DEF_OK ; - Message[ en-US ] ="The %PRODUCTNAME configuration has been changed. Under Tools - Options - %PRODUCTNAME - Java, select the Java runtime environment you want to have used by %PRODUCTNAME."; -}; - -QueryBox QBX_JAVADISABLED -{ - Buttons = WB_YES_NO_CANCEL ; - DefButton = WB_DEF_YES ; - Message[ en-US ] = "%PRODUCTNAME requires a Java runtime environment (JRE) to perform this task. However, use of a JRE has been disabled. Do you want to enable the use of a JRE now?"; -}; - -ErrorBox ERRORBOX_JVMCREATIONFAILED -{ - Buttons = WB_OK; - DefButton = WB_DEF_OK ; - Message[ en-US ] = "%PRODUCTNAME requires a Java runtime environment (JRE) to perform this task. The selected JRE is defective. Please select another version or install a new JRE and select it under Tools - Options - %PRODUCTNAME - Java."; -}; - -ErrorBox ERRORBOX_RESTARTREQUIRED -{ - Buttons = WB_OK; - DefButton = WB_DEF_OK ; - Message[ en-US ] = "For the selected Java runtime environment to work properly, %PRODUCTNAME must be restarted. Please restart %PRODUCTNAME now."; -}; - - - -String STR_WARNING_JAVANOTFOUND -{ - Text[ en-US ] = "JRE Required" ; -}; - -String STR_WARNING_INVALIDJAVASETTINGS -{ - Text[ en-US ] = "Select JRE"; -}; - -String STR_ERROR_RESTARTREQUIRED -{ - Text[ en-US ] = "Restart Required"; -}; - -String STR_QUESTION_JAVADISABLED -{ - Text[ en-US ] = "Enable JRE" ; -}; - - -String STR_ERROR_JVMCREATIONFAILED -{ - Text[ en-US ] = "JRE is Defective" ; -}; - - |