sb132: merged in DEV300_m89

This commit is contained in:
sb 2010-10-04 17:07:14 +02:00
commit a77fe39fbb
169 changed files with 3285 additions and 2590 deletions

View File

@ -3,3 +3,4 @@
..\%__SRC%\lib\*.sl %_DEST%\lib%_EXT%\*.sl
..\%__SRC%\bin\*.res %_DEST%\bin%_EXT%\*.res
..\%__SRC%\lib\*.dylib %_DEST%\lib%_EXT%\*.dylib
..\%__SRC%\misc\ctl.component %_DEST%\xml%_EXT%\ctl.component

View File

@ -92,59 +92,6 @@ using namespace ::com::sun::star::registry ;
return Reference< XInterface >( *(OWeakObject*)(new CLASS( rServiceManager )) ); \
}
//******************************************************************************************************************************
#define COMPONENT_INFO(CLASS) \
\
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t[start]\n" ) \
try \
{ \
/* Set default result of follow operations !!! */ \
bReturn = sal_False ; \
\
/* Do the follow only, if given key is valid ! */ \
if ( xKey.is () ) \
{ \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\txkey is valid ...\n" ) \
/* Build new keyname */ \
sKeyName = OUString::createFromAscii( "/" ) ; \
sKeyName += CLASS::impl_getStaticImplementationName() ; \
sKeyName += OUString::createFromAscii( "/UNO/SERVICES" ); \
\
/* Create new key with new name. */ \
xNewKey = xKey->createKey( sKeyName ); \
\
/* If this new key valid ... */ \
if ( xNewKey.is () ) \
{ \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\txNewkey is valid ...\n" ) \
/* Get information about supported services. */ \
seqServiceNames = CLASS::impl_getStaticSupportedServiceNames() ; \
pArray = seqServiceNames.getArray() ; \
nLength = seqServiceNames.getLength() ; \
nCounter = 0 ; \
\
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\tloop ..." ) \
/* Then set this information on this key. */ \
for ( nCounter = 0; nCounter < nLength; ++nCounter ) \
{ \
xNewKey->createKey( pArray [nCounter] ); \
} \
AS_DBG_OUT ( " OK\n" ) \
\
/* Result of this operations = OK. */ \
bReturn = sal_True ; \
} \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\t... leave xNewKey\n" ) \
} \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\t... leave xKey\n" ) \
} \
catch( InvalidRegistryException& ) \
{ \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t\tInvalidRegistryException detected!!!\n" ) \
bReturn = sal_False ; \
} \
AS_DBG_OUT ( "\tCOMPONENT_INFO():\t[end]\n" )
//******************************************************************************************************************************
#define CREATEFACTORY_ONEINSTANCE(CLASS) \
\
@ -217,53 +164,6 @@ extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_
*ppEnvironmentTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME ;
}
//______________________________________________________________________________________________________________
// write component info to registry
//______________________________________________________________________________________________________________
extern "C" sal_Bool SAL_CALL component_writeInfo( void* /*pServiceManager*/ ,
void* pRegistryKey )
{
AS_DBG_OUT ( "component_writeInfo():\t[start]\n" )
// Set default return value for this operation - if it failed.
sal_Bool bReturn = sal_False ;
if ( pRegistryKey != NULL )
{
AS_DBG_OUT ( "component_writeInfo():\t\tpRegistryKey is valid ... enter scope\n" )
// Define variables for following macros!
// bReturn is set automaticly.
Reference< XRegistryKey > xKey( reinterpret_cast< XRegistryKey* >( pRegistryKey ) ) ;
Reference< XRegistryKey > xNewKey ;
Sequence< OUString > seqServiceNames ;
const OUString* pArray ;
sal_Int32 nLength ;
sal_Int32 nCounter ;
OUString sKeyName ;
//=============================================================================
// Add new macro line to register new services.
//
// !!! ATTENTION !!!
// Write no ";" at end of line! (see macro)
//=============================================================================
COMPONENT_INFO ( FrameControl )
COMPONENT_INFO ( ProgressBar )
COMPONENT_INFO ( ProgressMonitor )
COMPONENT_INFO ( StatusIndicator )
//=============================================================================
AS_DBG_OUT ( "component_writeInfo():\t\t... leave pRegistryKey scope\n" )
}
AS_DBG_OUT ( "component_writeInfo():\t[end]\n" )
// Return with result of this operation.
return bReturn ;
}
//______________________________________________________________________________________________________________
// create right component factory
//______________________________________________________________________________________________________________

View File

@ -0,0 +1,43 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="stardiv.UnoControls.FrameControl">
<service name="com.sun.star.frame.FrameControl"/>
</implementation>
<implementation name="stardiv.UnoControls.ProgressBar">
<service name="com.sun.star.awt.XProgressBar"/>
</implementation>
<implementation name="stardiv.UnoControls.ProgressMonitor">
<service name="com.sun.star.awt.XProgressMonitor"/>
</implementation>
<implementation name="stardiv.UnoControls.StatusIndicator">
<service name="com.sun.star.task.XStatusIndicator"/>
</implementation>
</component>

View File

@ -59,3 +59,11 @@ SHL1LIBS= $(LIB1TARGET)
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
ALLTAR : $(MISC)/ctl.component
$(MISC)/ctl.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
ctl.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt ctl.component

View File

@ -142,11 +142,6 @@ public class AccessBridge {
return xSingleServiceFactory;
}
public static boolean __writeRegistryServiceInfo(XRegistryKey regKey) {
return FactoryHelper.writeRegistryServiceInfo(AccessBridge.class.getName(),
_AccessBridge._serviceName, regKey);
}
static public class _AccessBridge implements XTopWindowListener,
XInitialization, XComponent {
static final String _serviceName = "com.sun.star.accessibility.AccessBridge";

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.Java2"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="org.openoffice.accessibility.AccessBridge">
<service name="com.sun.star.accessibility.AccessBridge"/>
</implementation>
</component>

View File

@ -53,3 +53,10 @@ CUSTOMMANIFESTFILE = manifest
.INCLUDE : target.mk
ALLTAR : $(MISC)/java_uno_accessbridge.component
$(MISC)/java_uno_accessbridge.component .ERRREMOVE : \
$(SOLARENV)/bin/createcomponent.xslt java_uno_accessbridge.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_JAVA)$(JARTARGET)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt java_uno_accessbridge.component

View File

@ -5,4 +5,4 @@
..\%__SRC%\bin\*.res %_DEST%\bin%_EXT%\*.res
..\%__SRC%\lib\lib*.so %_DEST%\lib%_EXT%
..\%__SRC%\lib\*.dylib %_DEST%\lib%_EXT%\*.dylib
..\%__SRC%\misc\java_uno_accessbridge.component %_DEST%\xml\java_uno_accessbridge.component

View File

@ -21,3 +21,4 @@ mkdir: %_DEST%\inc%_EXT%\basctl
..\uiconfig\basicide\menubar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\BasicIDE\menubar\*.xml
..\uiconfig\basicide\toolbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\BasicIDE\toolbar\*.xml
..\uiconfig\basicide\statusbar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\BasicIDE\statusbar\*.xml
..\%__SRC%\misc\basctl.component %_DEST%\xml%_EXT%\basctl.component

View File

@ -52,28 +52,6 @@ SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(
*ppEnvironmentTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME ;
}
SAL_DLLPUBLIC_EXPORT
sal_Bool SAL_CALL component_writeInfo( void* pServiceManager ,
void* pRegistryKey )
{
(void)pServiceManager;
Reference< ::registry::XRegistryKey >
xKey( reinterpret_cast< ::registry::XRegistryKey* >( pRegistryKey ) ) ;
OUString aDelimiter( RTL_CONSTASCII_USTRINGPARAM("/") );
OUString aUnoServices( RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES") );
sal_Int32 i;
Reference< ::registry::XRegistryKey > xNewKey;
xNewKey = xKey->createKey( aDelimiter + SIDEModel::getImplementationName_Static() + aUnoServices );
Sequence< OUString > aServices = SIDEModel::getSupportedServiceNames_Static();
for(i = 0; i < aServices.getLength(); i++ )
xNewKey->createKey( aServices.getConstArray()[i] );
return sal_True;
}
SAL_DLLPUBLIC_EXPORT
void* SAL_CALL component_getFactory( const sal_Char* pImplementationName,
void* pServiceManager,

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.basic.BasicIDE">
<service name="com.sun.star.script.BasicIDE"/>
</implementation>
</component>

View File

@ -4,7 +4,6 @@ UDK_3_0_0 {
basicide_macro_organizer;
basicide_handle_basic_error;
component_getImplementationEnvironment;
component_writeInfo;
component_getFactory;
local:
*;

View File

@ -103,3 +103,11 @@ RESLIB1SRSFILES= $(SRSFILELIST)
.ENDIF # "$(header)" == ""
ALLTAR : $(MISC)/basctl.component
$(MISC)/basctl.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
basctl.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt basctl.component

View File

@ -129,12 +129,12 @@ static string trim_string( const string& rString )
{
string temp = rString;
while ( temp.length() && temp[0] == ' ' || temp[0] == '\t' )
while ( temp.length() && (temp[0] == ' ' || temp[0] == '\t') )
temp.erase( 0, 1 );
string::size_type len = temp.length();
while ( len && temp[len-1] == ' ' || temp[len-1] == '\t' )
while ( len && (temp[len-1] == ' ' || temp[len-1] == '\t') )
{
temp.erase( len - 1, 1 );
len = temp.length();

View File

@ -76,6 +76,8 @@ using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::linguistic2;
using ::rtl::OUString;
#define C2U(cChar) ::rtl::OUString::createFromAscii(cChar)
// struct SpellDialog_Impl ---------------------------------------------
@ -930,7 +932,7 @@ void SpellDialog::SetTitle_Impl(LanguageType nLang)
-----------------------------------------------------------------------*/
void SpellDialog::InitUserDicts()
{
sal_uInt16 nLang = aLanguageLB.GetSelectLanguage();
const LanguageType nLang = aLanguageLB.GetSelectLanguage();
const Reference< XDictionary > *pDic = 0;
@ -948,51 +950,50 @@ void SpellDialog::InitUserDicts()
pImpl->aDics = xDicList->getDictionaries();
}
// Benutzerbuecher anzeigen
SvtLinguConfig aCfg;
const bool bHC = Application::GetSettings().GetStyleSettings().GetHighContrastMode();
// list suitable dictionaries
bool bEnable = false;
const sal_Int32 nSize = pImpl->aDics.getLength();
pDic = pImpl->aDics.getConstArray();
sal_Int32 i;
delete aAddToDictMB.GetPopupMenu();
PopupMenu* pMenu = new PopupMenu;
for (i = 0; i < nSize; ++i )
pMenu->SetMenuFlags(MENU_FLAG_NOAUTOMNEMONICS);
USHORT nItemId = 1; // menu items should be enumerated from 1 and not 0
for (sal_Int32 i = 0; i < nSize; ++i)
{
Reference< XDictionary > xDic( pDic[i], UNO_QUERY );
if (!xDic.is() || SvxGetIgnoreAllList() == xDic)
uno::Reference< linguistic2::XDictionary > xDicTmp( pDic[i], uno::UNO_QUERY );
if (!xDicTmp.is() || SvxGetIgnoreAllList() == xDicTmp)
continue;
// add only active and not read-only dictionaries to list
// from which to choose from
Reference< frame::XStorable > xStor( xDic, UNO_QUERY );
if ( xDic->isActive() && (!xStor.is() || !xStor->isReadonly()) )
uno::Reference< frame::XStorable > xStor( xDicTmp, uno::UNO_QUERY );
LanguageType nActLanguage = SvxLocaleToLanguage( xDicTmp->getLocale() );
if( xDicTmp->isActive()
&& xDicTmp->getDictionaryType() != linguistic2::DictionaryType_NEGATIVE
&& (nLang == nActLanguage || LANGUAGE_NONE == nActLanguage )
&& (!xStor.is() || !xStor->isReadonly()) )
{
sal_Bool bNegativ = xDic->getDictionaryType() == DictionaryType_NEGATIVE;
pMenu->InsertItem( (USHORT)i + 1, ::GetDicInfoStr( xDic->getName(),
SvxLocaleToLanguage( xDic->getLocale() ), bNegativ ) );
pMenu->InsertItem( nItemId, xDicTmp->getName() );
bEnable = sal_True;
uno::Reference< lang::XServiceInfo > xSvcInfo( xDicTmp, uno::UNO_QUERY );
if (xSvcInfo.is())
{
OUString aDictionaryImageUrl( aCfg.GetSpellAndGrammarContextDictionaryImage(
xSvcInfo->getImplementationName(), bHC) );
if (aDictionaryImageUrl.getLength() > 0)
{
Image aImage( lcl_GetImageFromPngUrl( aDictionaryImageUrl ) );
pMenu->SetItemImage( nItemId, aImage );
}
}
++nItemId;
}
}
aAddToDictMB.SetPopupMenu(pMenu);
aAddToDictMB.Disable();
sal_uInt16 k;
for ( k = 0; k < pMenu->GetItemCount(); ++k )
{
sal_uInt16 nId = pMenu->GetItemId(k) - 1;
sal_Bool bFound = sal_False;
const sal_uInt16 nDicLang = SvxLocaleToLanguage( pDic[nId]->getLocale() );
const sal_Bool bDicNegativ =
pDic[nId]->getDictionaryType() == DictionaryType_NEGATIVE;
// Stimmt die Sprache "uberein, dann enable
if ((nDicLang == nLang || nDicLang == LANGUAGE_NONE) && !bDicNegativ)
bFound = sal_True;
if (bFound)
{
aAddToDictMB.Enable();
break;
}
}
aAddToDictMB.Enable( bEnable );
}
/*-- 20.10.2003 15:31:06---------------------------------------------------
@ -1000,31 +1001,39 @@ void SpellDialog::InitUserDicts()
IMPL_LINK(SpellDialog, AddToDictionaryHdl, MenuButton*, pButton )
{
aSentenceED.UndoActionStart( SPELLUNDO_CHANGE_GROUP );
USHORT nItem = pButton->GetCurItemId();
//GetErrorText() returns the current error even if the text is already
//manually changed
String sNewWord= aSentenceED.GetErrorText();
const String aNewWord= aSentenceED.GetErrorText();
USHORT nItemId = pButton->GetCurItemId();
PopupMenu *pMenu = pButton->GetPopupMenu();
String aDicName ( pMenu->GetItemText( nItemId ) );
uno::Reference< linguistic2::XDictionary > xDic;
uno::Reference< linguistic2::XDictionaryList > xDicList( SvxGetDictionaryList() );
if (xDicList.is())
xDic = xDicList->getDictionaryByName( aDicName );
Reference< XDictionary > xDic( pImpl->aDics.getConstArray()[ nItem - 1 ], UNO_QUERY );
sal_Int16 nAddRes = DIC_ERR_UNKNOWN;
if (xDic.is())
{
String sTmpTxt( sNewWord );
sal_Bool bNegEntry = xDic->getDictionaryType() == DictionaryType_NEGATIVE;
nAddRes = linguistic::AddEntryToDic( xDic, sTmpTxt, bNegEntry,
::rtl::OUString(), LANGUAGE_NONE );
nAddRes = linguistic::AddEntryToDic( xDic, aNewWord, FALSE, OUString(), LANGUAGE_NONE );
// save modified user-dictionary if it is persistent
uno::Reference< frame::XStorable > xSavDic( xDic, uno::UNO_QUERY );
if (xSavDic.is())
xSavDic->store();
if(nAddRes == DIC_ERR_NONE)
if (nAddRes == DIC_ERR_NONE)
{
SpellUndoAction_Impl* pAction = new SpellUndoAction_Impl(
SPELLUNDO_CHANGE_ADD_TO_DICTIONARY, aDialogUndoLink);
pAction->SetDictionary(xDic);
pAction->SetAddedWord(sTmpTxt);
aSentenceED.AddUndoAction(pAction);
pAction->SetDictionary( xDic );
pAction->SetAddedWord( aNewWord );
aSentenceED.AddUndoAction( pAction );
}
// failed because there is already an entry?
if (DIC_ERR_NONE != nAddRes && xDic->getEntry( sTmpTxt ).is())
if (DIC_ERR_NONE != nAddRes && xDic->getEntry( aNewWord ).is())
nAddRes = DIC_ERR_NONE;
}
if (DIC_ERR_NONE != nAddRes)
@ -1032,8 +1041,6 @@ IMPL_LINK(SpellDialog, AddToDictionaryHdl, MenuButton*, pButton )
SvxDicError( this, nAddRes );
return 0; // Nicht weitermachen
}
// nach dem Aufnehmen ggf. '='-Zeichen entfernen
sNewWord.EraseAllChars( sal_Unicode( '=' ) );
// go on
SpellContinue_Impl();

View File

@ -57,6 +57,7 @@
#include <i18npool/mslangid.hxx>
#include <comphelper/processfactory.hxx>
#include <osl/file.hxx>
#include <svl/lngmisc.hxx>
#include <stack>
@ -73,36 +74,6 @@ using ::rtl::OUString;
#define A2S(x) String::CreateFromAscii( x )
// GetReplaceEditString -------------------------------
static void GetReplaceEditString( String &rText )
{
// The strings returned by the thesaurus saometimes have some
// explanation text put in between '(' and ')' or a trailing '*'.
// These parts should not be put in the ReplaceEdit Text that may get
// inserted into the document. Thus we strip them from the text.
xub_StrLen nPos = rText.Search( sal_Unicode('(') );
while (STRING_NOTFOUND != nPos)
{
xub_StrLen nEnd = rText.Search( sal_Unicode(')'), nPos );
if (STRING_NOTFOUND != nEnd)
rText.Erase( nPos, nEnd-nPos+1 );
else
break;
nPos = rText.Search( sal_Unicode('(') );
}
nPos = rText.Search( sal_Unicode('*') );
if (STRING_NOTFOUND != nPos)
rText.Erase( nPos );
// remove any possible remaining ' ' that may confuse the thesaurus
// when it gets called with the text
rText.EraseLeadingAndTrailingChars( sal_Unicode(' ') );
}
// class LookUpComboBox_Impl --------------------------------------------------
LookUpComboBox_Impl::LookUpComboBox_Impl(
@ -488,7 +459,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, WordSelectHdl_Impl, ComboBox *, pBox )
{
USHORT nPos = pBox->GetSelectEntryPos();
String aStr( pBox->GetEntry( nPos ) );
GetReplaceEditString( aStr );
aStr = linguistic::GetThesaurusReplaceText( aStr );
aWordCB.SetText( aStr );
LookUp_Impl();
}
@ -507,7 +478,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, AlternativesSelectHdl_Impl, SvxCheckListBox
if (pData && !pData->IsHeader())
{
aStr = pData->GetText();
GetReplaceEditString( aStr );
aStr = linguistic::GetThesaurusReplaceText( aStr );
}
aReplaceEdit.SetText( aStr );
}
@ -525,7 +496,7 @@ IMPL_LINK( SvxThesaurusDialog_Impl, AlternativesDoubleClickHdl_Impl, SvxCheckLis
if (pData && !pData->IsHeader())
{
aStr = pData->GetText();
GetReplaceEditString( aStr );
aStr = linguistic::GetThesaurusReplaceText( aStr );
}
aWordCB.SetText( aStr );

6
cui/source/options/webconninfo.cxx Normal file → Executable file
View File

@ -311,10 +311,8 @@ IMPL_LINK( WebConnectionInfoDialog, ChangePasswordHdl, PushButton*, EMPTYARG )
::rtl::OUString aURL = m_aPasswordsLB.GetEntryText( pEntry, 0 );
::rtl::OUString aUserName = m_aPasswordsLB.GetEntryText( pEntry, 1 );
::comphelper::DocPasswordRequest* pPasswordRequest
= new ::comphelper::DocPasswordRequest(
::comphelper::DocPasswordRequestType_STANDARD,
task::PasswordRequestMode_PASSWORD_CREATE, aURL );
::comphelper::SimplePasswordRequest* pPasswordRequest
= new ::comphelper::SimplePasswordRequest( task::PasswordRequestMode_PASSWORD_CREATE );
uno::Reference< task::XInteractionRequest > rRequest( pPasswordRequest );
uno::Reference< task::XInteractionHandler > xInteractionHandler(

View File

@ -1 +1,2 @@
..\%__SRC%\bin\*.dll %_DEST%\bin%_EXT%\*.dll
..\%__SRC%\misc\emser.component %_DEST%\xml%_EXT%\emser.component

View File

@ -95,34 +95,6 @@ void * SAL_CALL component_getFactory( const sal_Char * pImplName, void * pServic
return pRet;
}
sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, void * pRegistryKey )
{
if (pRegistryKey)
{
try
{
uno::Reference< registry::XRegistryKey > xKey( reinterpret_cast< registry::XRegistryKey* >( pRegistryKey ) );
uno::Reference< registry::XRegistryKey > xNewKey;
xNewKey = xKey->createKey( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") ) +
EmbedServer_getImplementationName() +
::rtl::OUString(RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES") ) );
uno::Sequence< ::rtl::OUString > rServices = EmbedServer_getSupportedServiceNames();
for( sal_Int32 ind = 0; ind < rServices.getLength(); ind++ )
xNewKey->createKey( rServices.getConstArray()[ind] );
return sal_True;
}
catch (registry::InvalidRegistryException &)
{
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
}
}
return sal_False;
}
} // extern "C"
// Fix strange warnings about some
@ -130,4 +102,4 @@ sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, void * pRegis
// warning C4505: 'xxx' : unreferenced local function has been removed
#if defined(_MSC_VER)
#pragma warning(disable: 4505)
#endif
#endif

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.ole.EmbedServer">
<service name="com.sun.star.document.OleEmbeddedServerRegistration"/>
</implementation>
</component>

View File

@ -1,3 +1,2 @@
component_getImplementationEnvironment
component_writeInfo
component_getFactory

View File

@ -94,3 +94,11 @@ DEF1EXPORTFILE= exports.dxp
.INCLUDE : target.mk
ALLTAR : $(MISC)/emser.component
$(MISC)/emser.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
emser.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt emser.component

View File

@ -22,6 +22,7 @@ mkdir: %_DEST%\bin%_EXT%\so
..\%__SRC%\bin\npsoplugin_so.dll %_DEST%\bin%_EXT%\so\npsoplugin.dll
..\%__SRC%\bin\x64\so_activex.dll %_DEST%\bin%_EXT%\so_activex_x64.dll
..\%__SRC%\bin\mdibundle.zip %_DEST%\bin%_EXT%\mdibundle.zip
..\%__SRC%\misc\oleautobridge.component %_DEST%\xml%_EXT%\oleautobridge.component
..\source\bibliography\uiconfig\sbibliography\menubar\*.xml %_DEST%\xml%_EXT%\uiconfig\modules\sbibliography\menubar\*.xml
@ -39,3 +40,19 @@ mkdir: %_DEST%\xml%_EXT%\registry\spool\org\openoffice\Office\Logging
..\%__SRC%\misc\registry\spool\org\openoffice\Office\Logging\*.xcu %_DEST%\xml%_EXT%\registry\spool\org\openoffice\Office\Logging
..\%__SRC%\bin\*.oxt %_DEST%\pck%_EXT%\*
..\%__SRC%\misc\abp.component %_DEST%\xml%_EXT%\abp.component
..\%__SRC%\misc\bib.component %_DEST%\xml%_EXT%\bib.component
..\%__SRC%\misc\dbp.component %_DEST%\xml%_EXT%\dbp.component
..\%__SRC%\misc\ldapbe2.component %_DEST%\xml%_EXT%\ldapbe2.component
..\%__SRC%\misc\log.component %_DEST%\xml%_EXT%\log.component
..\%__SRC%\misc\oooimprovecore.component %_DEST%\xml%_EXT%\oooimprovecore.component
..\%__SRC%\misc\oooimprovement.component %_DEST%\xml%_EXT%\oooimprovement.component
..\%__SRC%\misc\pcr.component %_DEST%\xml%_EXT%\pcr.component
..\%__SRC%\misc\pl.component %_DEST%\xml%_EXT%\pl.component
..\%__SRC%\misc\preload.component %_DEST%\xml%_EXT%\preload.component
..\%__SRC%\misc\res.component %_DEST%\xml%_EXT%\res.component
..\%__SRC%\misc\scn.component %_DEST%\xml%_EXT%\scn.component
..\%__SRC%\misc\updatefeed.component %_DEST%\xml%_EXT%\updatefeed.component
..\%__SRC%\misc\updchk.component %_DEST%\xml%_EXT%\updchk.component
..\%__SRC%\misc\updchk.uno.component %_DEST%\xml%_EXT%\updchk.uno.component
..\%__SRC%\misc\xmx.component %_DEST%\xml%_EXT%\xmx.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="org.openoffice.comp.abp.OAddressBookSourcePilot">
<service name="com.sun.star.ui.dialogs.AddressBookSourcePilot"/>
</implementation>
</component>

View File

@ -65,27 +65,6 @@ component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo(
void* pServiceManager,
void* pRegistryKey
)
{
if (pRegistryKey)
try
{
return ::abp::OModule::writeComponentInfos(
static_cast<XMultiServiceFactory*>(pServiceManager),
static_cast<XRegistryKey*>(pRegistryKey));
}
catch (InvalidRegistryException& )
{
OSL_ASSERT("abp::component_writeInfo: could not create a registry key (InvalidRegistryException) !");
}
return sal_False;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,

View File

@ -1,3 +1,2 @@
component_getImplementationEnvironment
component_writeInfo
component_getFactory

View File

@ -104,3 +104,11 @@ DEF1EXPORTFILE= exports.dxp
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
ALLTAR : $(MISC)/abp.component
$(MISC)/abp.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
abp.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt abp.component

View File

@ -0,0 +1,35 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.extensions.Bibliography">
<service name="com.sun.star.frame.Bibliography"/>
<service name="com.sun.star.frame.FrameLoader"/>
</implementation>
</component>

View File

@ -225,36 +225,6 @@ extern "C"
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
sal_Bool SAL_CALL component_writeInfo( void * //pServiceManager
, registry::XRegistryKey * pRegistryKey )
{
try
{
rtl::OUString sKey = rtl::OUString::createFromAscii("/");
sKey += BibliographyLoader::getImplementationName_Static();
//creates the impl key: /com.sun.star.extensions.Bibliography
Reference< registry::XRegistryKey > xImplKey = pRegistryKey->createKey(sKey);
//sKey += rtl::OUString::createFromAscii("/UNO/SERVICES");
Reference< registry::XRegistryKey > xNewKey = xImplKey->createKey( C2U("/UNO/SERVICES") );
Sequence< rtl::OUString > aServices = BibliographyLoader::getSupportedServiceNames_Static();
for( INT32 i = 0; i < aServices.getLength(); i++ )
xNewKey->createKey( aServices.getConstArray()[i]);
xNewKey = xImplKey->createKey( C2U("/UNO/Loader"));
Reference< registry::XRegistryKey > xPatternKey = xImplKey->createKey( C2U("/Loader/Pattern" ));
xPatternKey->setAsciiValue( C2U( ".component:Bibliography/*" ) );
return sal_True;
}
catch (Exception &)
{
return sal_False;
}
}
void * SAL_CALL component_getFactory(
const sal_Char * pImplName, XMultiServiceFactory * pServiceManager, void * /*pRegistryKey*/ )
{

View File

@ -89,3 +89,11 @@ DEF1NAME= $(SHL1TARGET)
.INCLUDE : target.mk
ALLTAR : $(MISC)/bib.component
$(MISC)/bib.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
bib.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt bib.component

View File

@ -62,13 +62,6 @@ extern "C" void SAL_CALL component_getImplementationEnvironment(
}
//------------------------------------------------------------------------------
extern "C" sal_Bool SAL_CALL component_writeInfo(void *aServiceManager,
void *aRegistryKey) {
return cppu::component_writeInfoHelper(
aServiceManager, aRegistryKey, kImplementations_entries);
}
//------------------------------------------------------------------------------
extern "C" void *component_getFactory(const sal_Char *aImplementationName,
void *aServiceManager,
void *aRegistryKey) {

View File

@ -1,3 +1,2 @@
component_getImplementationEnvironment
component_writeInfo
component_getFactory

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.configuration.backend.LdapUserProfileBe">
<service name="com.sun.star.configuration.backend.LdapUserProfileBe"/>
</implementation>
</component>

View File

@ -95,3 +95,11 @@ DEF1DES=Configuration: LDAP User Profile Backend
.INCLUDE : target.mk
.INCLUDE : $(PRJ)$/util$/target.pmk
ALLTAR : $(MISC)/ldapbe2.component
$(MISC)/ldapbe2.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
ldapbe2.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt ldapbe2.component

View File

@ -0,0 +1,40 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="org.openoffice.comp.dbp.OGridWizard">
<service name="com.sun.star.sdb.GridControlAutoPilot"/>
</implementation>
<implementation name="org.openoffice.comp.dbp.OGroupBoxWizard">
<service name="com.sun.star.sdb.GroupBoxAutoPilot"/>
</implementation>
<implementation name="org.openoffice.comp.dbp.OListComboWizard">
<service name="com.sun.star.sdb.ListComboBoxAutoPilot"/>
</implementation>
</component>

View File

@ -69,27 +69,6 @@ component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo(
void* pServiceManager,
void* pRegistryKey
)
{
if (pRegistryKey)
try
{
return ::dbp::OModule::writeComponentInfos(
static_cast<XMultiServiceFactory*>(pServiceManager),
static_cast<XRegistryKey*>(pRegistryKey));
}
catch (InvalidRegistryException& )
{
OSL_ASSERT("dbp::component_writeInfo: could not create a registry key (InvalidRegistryException) !");
}
return sal_False;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,

View File

@ -101,3 +101,11 @@ DEF1NAME= $(SHL1TARGET)
# --- Targets ------------------------------------------------------
.INCLUDE : target.mk
ALLTAR : $(MISC)/dbp.component
$(MISC)/dbp.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
dbp.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt dbp.component

View File

@ -237,54 +237,6 @@ namespace COMPMOD_NAMESPACE
}
}
//--------------------------------------------------------------------------
sal_Bool OModule::writeComponentInfos(
const Reference< XMultiServiceFactory >& /*_rxServiceManager*/,
const Reference< XRegistryKey >& _rxRootKey)
{
OSL_ENSURE(_rxRootKey.is(), "OModule::writeComponentInfos : invalid argument !");
if (!s_pImplementationNames)
{
OSL_ASSERT("OModule::writeComponentInfos : have no class infos ! Are you sure called this method at the right time ?");
return sal_True;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
"OModule::writeComponentInfos : inconsistent state (the pointers) !");
OSL_ENSURE( (s_pImplementationNames->getLength() == s_pSupportedServices->getLength())
&& (s_pImplementationNames->getLength() == s_pCreationFunctionPointers->getLength())
&& (s_pImplementationNames->getLength() == s_pFactoryFunctionPointers->getLength()),
"OModule::writeComponentInfos : inconsistent state !");
sal_Int32 nLen = s_pImplementationNames->getLength();
const ::rtl::OUString* pImplName = s_pImplementationNames->getConstArray();
const Sequence< ::rtl::OUString >* pServices = s_pSupportedServices->getConstArray();
::rtl::OUString sRootKey("/", 1, RTL_TEXTENCODING_ASCII_US);
for (sal_Int32 i=0; i<nLen; ++i, ++pImplName, ++pServices)
{
::rtl::OUString aMainKeyName(sRootKey);
aMainKeyName += *pImplName;
aMainKeyName += ::rtl::OUString::createFromAscii("/UNO/SERVICES");
try
{
Reference< XRegistryKey > xNewKey( _rxRootKey->createKey(aMainKeyName) );
const ::rtl::OUString* pService = pServices->getConstArray();
for (sal_Int32 j=0; j<pServices->getLength(); ++j, ++pService)
xNewKey->createKey(*pService);
}
catch(Exception&)
{
OSL_ASSERT("OModule::writeComponentInfos : something went wrong while creating the keys !");
return sal_False;
}
}
return sal_True;
}
//--------------------------------------------------------------------------
Reference< XInterface > OModule::getComponentFactory(
const ::rtl::OUString& _rImplementationName,

View File

@ -121,21 +121,6 @@ typedef ::com::sun::star::uno::Reference< ::com::sun::star::lang::XSingleService
static void revokeComponent(
const ::rtl::OUString& _rImplementationName);
/** write the registration information of all known components
<p>writes the registration information of all components which are currently registered into the
specified registry.<p/>
<p>Usually used from within component_writeInfo.<p/>
@param _rxServiceManager
the service manager
@param _rRootKey
the registry key under which the information will be stored
@return
sal_True if the registration of all implementations was successfull, sal_False otherwise
*/
static sal_Bool writeComponentInfos(
const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxServiceManager,
const ::com::sun::star::uno::Reference< ::com::sun::star::registry::XRegistryKey >& _rRootKey);
/** creates a Factory for the component with the given implementation name.
<p>Usually used from within component_getFactory.<p/>
@param _rxServiceManager

View File

@ -0,0 +1,47 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.extensions.ConsoleHandler">
<service name="com.sun.star.logging.ConsoleHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.CsvFormatter">
<service name="com.sun.star.logging.CsvFormatter"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.FileHandler">
<service name="com.sun.star.logging.FileHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.LoggerPool">
<service name="com.sun.star.logging.LoggerPool"/>
<singleton name="com.sun.star.logging.LoggerPool"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.PlainTextFormatter">
<service name="com.sun.star.logging.PlainTextFormatter"/>
</implementation>
</component>

View File

@ -74,3 +74,11 @@ SHL1VERSIONMAP=$(SOLARENV)/src/component.map
.INCLUDE : target.mk
ALLTAR : $(MISC)/log.component
$(MISC)/log.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
log.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt log.component

View File

@ -129,3 +129,10 @@ DEF2EXPORTFILE=$(TARGET).dxp
.INCLUDE : target.mk
ALLTAR : $(MISC)/oleautobridge.component
$(MISC)/oleautobridge.component .ERRREMOVE : \
$(SOLARENV)/bin/createcomponent.xslt oleautobridge.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt oleautobridge.component

View File

@ -0,0 +1,46 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.ole.OleClient">
<service name="com.sun.star.bridge.OleObjectFactory"/>
<service name="com.sun.star.bridge.oleautomation.Factory"/>
</implementation>
<implementation name="com.sun.star.comp.ole.OleConverter2">
<service name="com.sun.star.bridge.OleBridgeSupplier2"/>
<service name="com.sun.star.bridge.oleautomation.BridgeSupplier"/>
</implementation>
<implementation name="com.sun.star.comp.ole.OleConverterVar1">
<service name="com.sun.star.bridge.OleBridgeSupplierVar1"/>
</implementation>
<implementation name="com.sun.star.comp.ole.OleServer">
<service name="com.sun.star.bridge.OleApplicationRegistration"/>
<service name="com.sun.star.bridge.oleautomation.ApplicationRegistration"/>
</implementation>
</component>

View File

@ -1,4 +1,3 @@
component_writeInfo @100
component_getFactory @101
component_getImplementationEnvironment @102
component_canUnload @103

View File

@ -119,47 +119,6 @@ extern "C" void * SAL_CALL component_getFactory(
}
extern "C" sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, void * pRegistryKey )
{
if (pRegistryKey)
{
try
{
//deprecated
Reference<XRegistryKey> xNewKey =
reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleConverter2/UNO/SERVICES"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleBridgeSupplier2"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.BridgeSupplier"));
//deprecated
xNewKey =
reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleConverterVar1/UNO/SERVICES"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleBridgeSupplierVar1"));
//deprecated
xNewKey =
reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleClient/UNO/SERVICES"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleObjectFactory"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.Factory"));
//deprecated
xNewKey =
reinterpret_cast<XRegistryKey*>( pRegistryKey)->createKey(reinterpret_cast<const sal_Unicode*>(L"/com.sun.star.comp.ole.OleServer/UNO/SERVICES"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.OleApplicationRegistration"));
xNewKey->createKey(reinterpret_cast<const sal_Unicode*>(L"com.sun.star.bridge.oleautomation.ApplicationRegistration"));
return sal_True;
}
catch (InvalidRegistryException &)
{
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
}
}
return sal_False;
}
extern "C" void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{

View File

@ -75,3 +75,11 @@ SHL1VERSIONMAP=$(SOLARENV)/src/component.map
.INCLUDE : target.mk
ALLTAR : $(MISC)/oooimprovecore.component
$(MISC)/oooimprovecore.component .ERRREMOVE : \
$(SOLARENV)/bin/createcomponent.xslt oooimprovecore.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt oooimprovecore.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.extensions.oooimprovecore.Core">
<service name="com.sun.star.oooimprovement.Core"/>
</implementation>
</component>

View File

@ -121,7 +121,7 @@ namespace oooimprovement
Sequence<OUString> SAL_CALL InviteJob::getSupportedServiceNames_static()
{
Sequence<OUString> aServiceNames(1);
aServiceNames[0] = OUString::createFromAscii("com.sun.star.task.XAsyncJob");
aServiceNames[0] = OUString::createFromAscii("com.sun.star.task.AsyncJob");
return aServiceNames;
}

View File

@ -102,3 +102,11 @@ $(SPOOLDIR)$/$(PACKAGEDIR)$/Jobs$/Jobs-oooimprovement.xcu : $(XCU_SOURCEDIR)$/Jo
$(SPOOLDIR)$/$(PACKAGEDIR)$/Logging$/Logging-oooimprovement.xcu : $(XCU_SOURCEDIR)$/Logging.xcu
@-$(MKDIRHIER) $(@:d)
@$(COPY) $< $@
ALLTAR : $(MISC)/oooimprovement.component
$(MISC)/oooimprovement.component .ERRREMOVE : \
$(SOLARENV)/bin/createcomponent.xslt oooimprovement.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt oooimprovement.component

View File

@ -223,7 +223,7 @@ namespace oooimprovement
Sequence<OUString> SAL_CALL OnLogRotateJob::getSupportedServiceNames_static()
{
Sequence<OUString> aServiceNames(1);
aServiceNames[0] = OUString::createFromAscii("com.sun.star.task.XAsyncJob");
aServiceNames[0] = OUString::createFromAscii("com.sun.star.task.AsyncJob");
return aServiceNames;
}

View File

@ -0,0 +1,38 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation
name="com.sun.star.comp.extensions.oooimprovement.CoreController">
<service name="com.sun.star.oooimprovement.CoreController"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.oooimprovement.InviteJob"/>
<implementation
name="com.sun.star.comp.extensions.oooimprovement.OnLogRotateJob"/>
</component>

View File

@ -65,28 +65,6 @@ extern "C"
void SAL_CALL component_getImplementationEnvironment(const sal_Char** env_type_name, uno_Environment**)
{ *env_type_name = CPPU_CURRENT_LANGUAGE_BINDING_NAME; }
sal_Bool SAL_CALL component_writeInfo(void*, void* p_reg_key)
{
if (!p_reg_key) return sal_False;
try
{
Reference<XRegistryKey> reg_key(reinterpret_cast<XRegistryKey*>(p_reg_key), UNO_QUERY);
writeInfo(reg_key,
CoreController::getImplementationName_static(),
CoreController::getSupportedServiceNames_static()[0]);
writeInfo(reg_key,
OnLogRotateJob::getImplementationName_static(),
OnLogRotateJob::getSupportedServiceNames_static()[0]);
writeInfo(reg_key,
InviteJob::getImplementationName_static(),
InviteJob::getSupportedServiceNames_static()[0]);
return sal_True;
}
catch(const InvalidRegistryException&)
{ OSL_ENSURE( sal_False, "### InvalidRegistryException!" ); }
return sal_False;
}
void* SAL_CALL component_getFactory(const sal_Char* pImplName, void* pServiceManager, void*)
{
if ( !pServiceManager || !pImplName ) return 0;

View File

@ -54,33 +54,6 @@ extern "C" {
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
sal_Bool SAL_CALL component_writeInfo( void* /*pServiceManager*/, void* pXUnoKey )
{
if( pXUnoKey )
{
try
{
Reference< ::com::sun::star::registry::XRegistryKey > xKey( reinterpret_cast< ::com::sun::star::registry::XRegistryKey* >( pXUnoKey ) );
::rtl::OUString aImplName = ::rtl::OUString::createFromAscii( "/" );
aImplName += XPluginManager_Impl::getImplementationName_Static();
aImplName += ::rtl::OUString::createFromAscii( "/UNO/SERVICES/com.sun.star.plugin.PluginManager" );
xKey->createKey( aImplName );
aImplName = ::rtl::OUString::createFromAscii( "/" );
aImplName += PluginModel::getImplementationName_Static();
aImplName += ::rtl::OUString::createFromAscii( "/UNO/SERVICES/com.sun.star.plugin.PluginModel" );
xKey->createKey( aImplName );
return sal_True;
}
catch( ::com::sun::star::registry::InvalidRegistryException& )
{
}
}
return sal_False;
}
void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,
void* pXUnoSMgr,

View File

@ -107,3 +107,11 @@ SHL1STDLIBS+=$(SHL1OWNLIBS)
ALLTAR : $(MISC)/pl.component
$(MISC)/pl.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
pl.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt pl.component

View File

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.extensions.PluginManager">
<service name="com.sun.star.plugin.PluginManager"/>
</implementation>
<implementation name="com.sun.star.extensions.PluginModel">
<service name="com.sun.star.plugin.PluginModel"/>
</implementation>
</component>

View File

@ -83,3 +83,11 @@ DEF1NAME= $(SHL1TARGET)
.INCLUDE : target.mk
ALLTAR : $(MISC)/preload.component
$(MISC)/preload.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
preload.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt preload.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="org.openoffice.comp.preload.OEMPreloadWizard">
<service name="org.openoffice.comp.preload.OEMPreloadWizard"/>
</implementation>
</component>

View File

@ -65,27 +65,6 @@ component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo(
void* pServiceManager,
void* pRegistryKey
)
{
if (pRegistryKey)
try
{
return ::preload::OModule::writeComponentInfos(
static_cast<XMultiServiceFactory*>(pServiceManager),
static_cast<XRegistryKey*>(pRegistryKey));
}
catch (InvalidRegistryException& )
{
OSL_ASSERT("preload::component_writeInfo: could not create a registry key (InvalidRegistryException) !");
}
return sal_False;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,

View File

@ -144,3 +144,11 @@ DEF1NAME= $(SHL1TARGET)
.INCLUDE : target.mk
ALLTAR : $(MISC)/pcr.component
$(MISC)/pcr.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
pcr.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt pcr.component

View File

@ -0,0 +1,91 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="StringRepresentation">
<service name="com.sun.star.inspection.StringRepresentation"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.ButtonNavigationHandler">
<service name="com.sun.star.form.inspection.ButtonNavigationHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.CellBindingPropertyHandler">
<service name="com.sun.star.form.inspection.CellBindingPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.EFormsPropertyHandler">
<service name="com.sun.star.form.inspection.XMLFormsPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.EditPropertyHandler">
<service name="com.sun.star.form.inspection.EditPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.EventHandler">
<service name="com.sun.star.form.inspection.EventHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.FormComponentPropertyHandler">
<service name="com.sun.star.form.inspection.FormComponentPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.FormGeometryHandler">
<service name="com.sun.star.form.inspection.FormGeometryHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.GenericPropertyHandler">
<service name="com.sun.star.inspection.GenericPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.SubmissionPropertyHandler">
<service name="com.sun.star.form.inspection.SubmissionPropertyHandler"/>
</implementation>
<implementation name="com.sun.star.comp.extensions.XSDValidationPropertyHandler">
<service name="com.sun.star.form.inspection.XSDValidationPropertyHandler"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.DefaultFormComponentInspectorModel">
<service name="com.sun.star.form.inspection.DefaultFormComponentInspectorModel"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.DefaultHelpProvider">
<service name="com.sun.star.inspection.DefaultHelpProvider"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.DialogController">
<service name="com.sun.star.awt.PropertyBrowserController"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.FormController">
<service name="com.sun.star.form.PropertyBrowserController"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.ObjectInspector">
<service name="com.sun.star.inspection.ObjectInspector"/>
</implementation>
<implementation name="org.openoffice.comp.extensions.ObjectInspectorModel">
<service name="com.sun.star.inspection.ObjectInspectorModel"/>
</implementation>
<implementation name="org.openoffice.comp.form.ui.MasterDetailLinkDialog">
<service name="com.sun.star.form.MasterDetailLinkDialog"/>
</implementation>
<implementation name="org.openoffice.comp.form.ui.OControlFontDialog">
<service name="com.sun.star.form.ControlFontDialog"/>
</implementation>
<implementation name="org.openoffice.comp.form.ui.OTabOrderDialog">
<service name="com.sun.star.form.ui.TabOrderDialog"/>
</implementation>
</component>

View File

@ -103,27 +103,6 @@ component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo(
void* pServiceManager,
void* pRegistryKey
)
{
if (pRegistryKey)
try
{
return ::pcr::PcrModule::getInstance().writeComponentInfos(
static_cast<XMultiServiceFactory*>(pServiceManager),
static_cast<XRegistryKey*>(pRegistryKey));
}
catch (InvalidRegistryException& )
{
OSL_ASSERT("pcr::component_writeInfo: could not create a registry key (InvalidRegistryException) !");
}
return sal_False;
}
//---------------------------------------------------------------------------------------
extern "C" SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(
const sal_Char* pImplementationName,

View File

@ -1,3 +1,2 @@
component_writeInfo
component_getImplementationEnvironment
component_getFactory

View File

@ -74,3 +74,11 @@ DEF1EXPORTFILE= exports.dxp
.INCLUDE : target.mk
.INCLUDE : $(PRJ)$/util$/target.pmk
ALLTAR : $(MISC)/res.component
$(MISC)/res.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
res.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt res.component

View File

@ -0,0 +1,38 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.extensions.ResourceService">
<service name="com.sun.star.resource.VclStringResourceLoader"/>
</implementation>
<implementation name="com.sun.star.comp.resource.OpenOfficeResourceLoader">
<service name="com.sun.star.resource.OfficeResourceLoader"/>
<singleton name="com.sun.star.resource.OfficeResourceLoader"/>
</implementation>
</component>

View File

@ -29,12 +29,7 @@
#include "precompiled_extensions.hxx"
#include "res_services.hxx"
/** === begin UNO includes === **/
#include <com/sun/star/registry/XRegistryKey.hpp>
/** === end UNO includes === **/
/** === begin UNO using === **/
using ::com::sun::star::registry::XRegistryKey;
using ::com::sun::star::uno::Reference;
using ::com::sun::star::uno::Sequence;
using ::com::sun::star::uno::Exception;
@ -64,43 +59,6 @@ void SAL_CALL component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
sal_Bool SAL_CALL component_writeInfo( void * /*pServiceManager*/, XRegistryKey * pRegistryKey )
{
try
{
::std::vector< ::res::ComponentInfo > aComponentInfos( ::res::getComponentInfos() );
for ( ::std::vector< ::res::ComponentInfo >::const_iterator loop = aComponentInfos.begin();
loop != aComponentInfos.end();
++loop
)
{
Reference< XRegistryKey > xNewKey =
pRegistryKey->createKey( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") )
+ loop->sImplementationName + ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES" ) ) );
for( sal_Int32 i = 0; i < loop->aSupportedServices.getLength(); ++i )
xNewKey->createKey( loop->aSupportedServices.getConstArray()[i]);
if ( loop->sSingletonName.getLength() )
{
OSL_ENSURE( loop->aSupportedServices.getLength() == 1, "singletons must support exactly one service!" );
xNewKey = pRegistryKey->createKey( ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("/") )
+ loop->sImplementationName + ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "/UNO/SINGLETONS/" ) )
+ loop->sSingletonName );
xNewKey->setStringValue( loop->aSupportedServices[ 0 ] );
}
}
return sal_True;
}
catch (Exception &)
{
// not allowed to throw an exception over the c function.
//OSL_ENSURE( sal_False, "Exception cannot register component!" );
return sal_False;
}
}
void * SAL_CALL component_getFactory(
const sal_Char * pImplName, XMultiServiceFactory * /*pServiceManager*/, void * /*pRegistryKey*/ )
{

View File

@ -1,3 +1,2 @@
component_getImplementationEnvironment
component_writeInfo
component_getFactory

View File

@ -98,3 +98,11 @@ DEF1EXPORTFILE=exports.dxp
.INCLUDE : target.mk
ALLTAR : $(MISC)/scn.component
$(MISC)/scn.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
scn.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt scn.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.scanner.ScannerManager">
<service name="com.sun.star.scanner.ScannerManager"/>
</implementation>
</component>

View File

@ -45,37 +45,6 @@ extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char*
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
// -----------------------
// - component_writeInfo -
// -----------------------
extern "C" sal_Bool SAL_CALL component_writeInfo( void* /*pServiceManager*/, void* pRegistryKey )
{
sal_Bool bRet = sal_False;
if( pRegistryKey )
{
try
{
::rtl::OUString aImplName( '/' );
aImplName += ScannerManager::getImplementationName_Static();
aImplName += ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "/UNO/SERVICES/" ) );
aImplName += ScannerManager::getImplementationName_Static();
REF( XRegistryKey ) xNewKey1( static_cast< XRegistryKey* >( pRegistryKey )->createKey( aImplName ) );
bRet = sal_True;
}
catch( InvalidRegistryException& )
{
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
}
}
return bRet;
}
// ------------------------
// - component_getFactory -
// ------------------------

View File

@ -60,36 +60,6 @@ extern "C" void SAL_CALL component_getImplementationEnvironment( const sal_Char
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
// -----------------------
// - component_writeInfo -
// -----------------------
extern "C" sal_Bool SAL_CALL component_writeInfo( void* /*pServiceManager*/, void* pRegistryKey )
{
sal_Bool bRet = sal_False;
if( pRegistryKey )
{
try
{
REF( NMSP_REGISTRY::XRegistryKey ) xNewKey1(
static_cast< NMSP_REGISTRY::XRegistryKey* >( pRegistryKey )->createKey(
B2UCONST( "/com.sun.star.comp.extensions.SVGWriter/UNO/SERVICES/com.sun.star.svg.SVGWriter" ) ) );
REF( NMSP_REGISTRY::XRegistryKey ) xNewKey2(
static_cast< NMSP_REGISTRY::XRegistryKey* >( pRegistryKey )->createKey(
B2UCONST( "/com.sun.star.comp.extensions.SVGPrinter/UNO/SERVICES/com.sun.star.svg.SVGPrinter" ) ) );
bRet = sal_True;
}
catch( NMSP_REGISTRY::InvalidRegistryException& )
{
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
}
}
return bRet;
}
// ------------------------
// - component_getFactory -
// ------------------------

View File

@ -132,3 +132,11 @@ $(SPOOLDIR)$/$(PACKAGEDIR)$/Jobs$/Jobs-onlineupdate.xcu : $(XCU_SOURCEDIR)$/Jobs
@$(COPY) $< $@
# @$(PERL) transform.pl < $< > $@
ALLTAR : $(MISC)/updchk.uno.component
$(MISC)/updchk.uno.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
updchk.uno.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt updchk.uno.component

View File

@ -388,18 +388,6 @@ component_getImplementationEnvironment( const sal_Char **aEnvTypeName, uno_Envir
//------------------------------------------------------------------------------
extern "C" sal_Bool SAL_CALL
component_writeInfo(void *pServiceManager, void *pRegistryKey)
{
return cppu::component_writeInfoHelper(
pServiceManager,
pRegistryKey,
kImplementations_entries
);
}
//------------------------------------------------------------------------------
extern "C" void *
component_getFactory(const sal_Char *pszImplementationName, void *pServiceManager, void *pRegistryKey)
{

View File

@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="vnd.sun.UpdateCheck">
<service name="com.sun.star.setup.UpdateCheck"/>
</implementation>
<implementation name="vnd.sun.UpdateCheckConfig">
<service name="com.sun.star.setup.UpdateCheckConfig"/>
</implementation>
</component>

View File

@ -62,3 +62,11 @@ DEF1NAME=$(SHL1TARGET)
.INCLUDE : target.mk
ALLTAR : $(MISC)/updatefeed.component
$(MISC)/updatefeed.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
updatefeed.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt updatefeed.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="vnd.sun.UpdateInformationProvider">
<service name="com.sun.star.deployment.UpdateInformationProvider"/>
</implementation>
</component>

View File

@ -851,18 +851,6 @@ component_getImplementationEnvironment( const sal_Char **aEnvTypeName, uno_Envir
//------------------------------------------------------------------------------
extern "C" sal_Bool SAL_CALL
component_writeInfo(void *pServiceManager, void *pRegistryKey)
{
return cppu::component_writeInfoHelper(
pServiceManager,
pRegistryKey,
kImplementations_entries
);
}
//------------------------------------------------------------------------------
extern "C" void *
component_getFactory(const sal_Char *pszImplementationName, void *pServiceManager, void *pRegistryKey)
{

View File

@ -72,3 +72,11 @@ DEF1NAME=$(SHL1TARGET)
.INCLUDE : target.mk
ALLTAR : $(MISC)/updchk.component
$(MISC)/updchk.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
updchk.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt updchk.component

View File

@ -1059,18 +1059,6 @@ component_getImplementationEnvironment( const sal_Char **aEnvTypeName, uno_Envir
//------------------------------------------------------------------------------
extern "C" sal_Bool SAL_CALL
component_writeInfo(void *pServiceManager, void *pRegistryKey)
{
return cppu::component_writeInfoHelper(
pServiceManager,
pRegistryKey,
kImplementations_entries
);
}
//------------------------------------------------------------------------------
extern "C" void *
component_getFactory(const sal_Char *pszImplementationName, void *pServiceManager, void *pRegistryKey)
{

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="vnd.sun.UpdateCheckUI">
<service name="com.sun.star.setup.UpdateCheckUI"/>
</implementation>
</component>

View File

@ -63,3 +63,11 @@ SHL1LIBS= $(SLB)$/$(TARGET).lib
# --- Targets ----------------------------------
.INCLUDE : target.mk
ALLTAR : $(MISC)/xmx.component
$(MISC)/xmx.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
xmx.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt xmx.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.io.XMLExtractor">
<service name="com.sun.star.io.XMLExtractor"/>
</implementation>
</component>

View File

@ -52,27 +52,6 @@ void SAL_CALL component_getImplementationEnvironment(
*ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//==================================================================================================
sal_Bool SAL_CALL component_writeInfo(
void * /*pServiceManager*/, void * pRegistryKey )
{
if (pRegistryKey)
{
try
{
REF( NMSP_REGISTRY::XRegistryKey ) xNewKey(
reinterpret_cast< NMSP_REGISTRY::XRegistryKey * >( pRegistryKey )->createKey(
NMSP_RTL::OUString( RTL_CONSTASCII_USTRINGPARAM("/com.sun.star.comp.io.XMLExtractor/UNO/SERVICES/com.sun.star.io.XMLExtractor") ) ) );
return sal_True;
}
catch (NMSP_REGISTRY::InvalidRegistryException &)
{
OSL_ENSURE( sal_False, "### InvalidRegistryException!" );
}
}
return sal_False;
}
//==================================================================================================
void * SAL_CALL component_getFactory(
const sal_Char * pImplName, void * pServiceManager, void * /*pRegistryKey*/ )
{

View File

@ -5,3 +5,4 @@
..\%__SRC%\bin\*.bin %_DEST%\bin%_EXT%\*.bin
..\%__SRC%\bin\*.res %_DEST%\bin%_EXT%\*.res
..\util\*.xml %_DEST%\xml%_EXT%\*.xml
..\%__SRC%\misc\frm.component %_DEST%\xml%_EXT%\frm.component

View File

@ -101,21 +101,6 @@ namespace FORMS_MODULE_NAMESPACE
static void revokeComponent(
const ::rtl::OUString& _rImplementationName);
/** write the registration information of all known components
<p>writes the registration information of all components which are currently registered into the
specified registry.<p/>
<p>Usually used from within component_writeInfo.<p/>
@param _rxServiceManager
the service manager
@param _rRootKey
the registry key under which the information will be stored
@return
sal_True if the registration of all implementations was successfull, sal_False otherwise
*/
static sal_Bool writeComponentInfos(
const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XMultiServiceFactory >& _rxServiceManager,
const ::com::sun::star::uno::Reference< ::com::sun::star::registry::XRegistryKey >& _rRootKey);
/** creates a Factory for the component with the given implementation name.
<p>Usually used from within component_getFactory.<p/>
@param _rxServiceManager

View File

@ -106,54 +106,6 @@ namespace FORMS_MODULE_NAMESPACE
}
}
//--------------------------------------------------------------------------
sal_Bool OFormsModule::writeComponentInfos(
const Reference< XMultiServiceFactory >& /*_rxServiceManager*/,
const Reference< XRegistryKey >& _rxRootKey)
{
OSL_ENSURE(_rxRootKey.is(), "OFormsModule::writeComponentInfos : invalid argument !");
if (!s_pImplementationNames)
{
OSL_ASSERT("OFormsModule::writeComponentInfos : have no class infos ! Are you sure called this method at the right time ?");
return sal_True;
}
OSL_ENSURE(s_pImplementationNames && s_pSupportedServices && s_pCreationFunctionPointers && s_pFactoryFunctionPointers,
"OFormsModule::writeComponentInfos : inconsistent state (the pointers) !");
OSL_ENSURE( (s_pImplementationNames->getLength() == s_pSupportedServices->getLength())
&& (s_pImplementationNames->getLength() == s_pCreationFunctionPointers->getLength())
&& (s_pImplementationNames->getLength() == s_pFactoryFunctionPointers->getLength()),
"OFormsModule::writeComponentInfos : inconsistent state !");
sal_Int32 nLen = s_pImplementationNames->getLength();
const ::rtl::OUString* pImplName = s_pImplementationNames->getConstArray();
const Sequence< ::rtl::OUString >* pServices = s_pSupportedServices->getConstArray();
::rtl::OUString sRootKey("/", 1, RTL_TEXTENCODING_ASCII_US);
for (sal_Int32 i=0; i<nLen; ++i, ++pImplName, ++pServices)
{
::rtl::OUString aMainKeyName(sRootKey);
aMainKeyName += *pImplName;
aMainKeyName += ::rtl::OUString::createFromAscii("/UNO/SERVICES");
try
{
Reference< XRegistryKey > xNewKey( _rxRootKey->createKey(aMainKeyName) );
const ::rtl::OUString* pService = pServices->getConstArray();
for (sal_Int32 j=0; j<pServices->getLength(); ++j, ++pService)
xNewKey->createKey(*pService);
}
catch(Exception&)
{
OSL_ASSERT("OFormsModule::writeComponentInfos : something went wrong while creating the keys !");
return sal_False;
}
}
return sal_True;
}
//--------------------------------------------------------------------------
Reference< XInterface > OFormsModule::getComponentFactory(
const ::rtl::OUString& _rImplementationName,

View File

@ -283,22 +283,6 @@ void ensureClassInfos()
}
//---------------------------------------------------------------------------------------
void registerServiceProvider(const ::rtl::OUString& _rServiceImplName, const Sequence< ::rtl::OUString >& _rServices, XRegistryKey* _pKey)
{
::rtl::OUString sMainKeyName = ::rtl::OUString::createFromAscii("/");
sMainKeyName += _rServiceImplName;
sMainKeyName += ::rtl::OUString::createFromAscii("/UNO/SERVICES");
Reference< XRegistryKey > xNewKey = _pKey->createKey(sMainKeyName);
OSL_ENSURE(xNewKey.is(), "forms::registerProvider : could not create a registry key !");
if (!xNewKey.is())
return;
const ::rtl::OUString* pSupportedServices = _rServices.getConstArray();
for (sal_Int32 i=0; i<_rServices.getLength(); ++i, ++pSupportedServices)
xNewKey->createKey(*pSupportedServices);
}
//=======================================================================================
extern "C"
{
@ -341,57 +325,6 @@ SAL_DLLPUBLIC_EXPORT void SAL_CALL component_getImplementationEnvironment(const
*_ppEnvTypeName = CPPU_CURRENT_LANGUAGE_BINDING_NAME;
}
//---------------------------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT sal_Bool SAL_CALL component_writeInfo(void* _pServiceManager, XRegistryKey* _pRegistryKey)
{
if (_pRegistryKey)
{
try
{
// ========================================================================
// the real way - use the OModule
createRegistryInfo_FORMS();
if ( !::frm::OFormsModule::writeComponentInfos(
static_cast<XMultiServiceFactory*>( _pServiceManager ),
static_cast<XRegistryKey*>( _pRegistryKey ) )
)
return sal_False;
// ========================================================================
// a lot of stuff which is implemented "manually" here in this file
// collect the class infos
ensureClassInfos();
// both our static sequences should have the same length ...
sal_Int32 nClasses = s_aClassImplementationNames.getLength();
OSL_ENSURE(s_aClassServiceNames.getLength() == nClasses,
"forms::component_writeInfo : invalid class infos !");
// loop through the sequences and register the service providers
const ::rtl::OUString* pClasses = s_aClassImplementationNames.getConstArray();
const Sequence< ::rtl::OUString >* pServices = s_aClassServiceNames.getConstArray();
for (sal_Int32 i=0; i<nClasses; ++i, ++pClasses, ++pServices)
registerServiceProvider(*pClasses, *pServices, _pRegistryKey);
s_aClassImplementationNames.realloc(0);
s_aClassServiceNames.realloc(0);
s_aFactories.realloc(0);
return sal_True;
}
catch ( InvalidRegistryException& )
{
OSL_ENSURE(sal_False, "forms::component_writeInfo : InvalidRegistryException !");
}
}
s_aClassImplementationNames.realloc(0);
s_aClassServiceNames.realloc(0);
s_aFactories.realloc(0);
return sal_False;
}
//---------------------------------------------------------------------------------------
SAL_DLLPUBLIC_EXPORT void* SAL_CALL component_getFactory(const sal_Char* _pImplName, XMultiServiceFactory* _pServiceManager, void* /*_pRegistryKey*/)
{

255
forms/util/frm.component Normal file
View File

@ -0,0 +1,255 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.comp.form.ONavigationBarControl">
<service name="com.sun.star.form.control.NavigationToolBar"/>
</implementation>
<implementation name="com.sun.star.comp.form.ONavigationBarModel">
<service name="com.sun.star.form.FormComponent"/>
<service name="com.sun.star.form.FormControlModel"/>
<service name="com.sun.star.form.component.NavigationToolBar"/>
</implementation>
<implementation name="com.sun.star.comp.form.ORichTextControl">
<service name="com.sun.star.form.control.RichTextControl"/>
</implementation>
<implementation name="com.sun.star.comp.forms.FormOperations">
<service name="com.sun.star.form.runtime.FormOperations"/>
</implementation>
<implementation name="com.sun.star.comp.forms.ODatabaseForm">
<service name="com.sun.star.form.FormComponent"/>
<service name="com.sun.star.form.FormComponents"/>
<service name="com.sun.star.form.component.DataForm"/>
<service name="com.sun.star.form.component.Form"/>
<service name="com.sun.star.form.component.HTMLForm"/>
<service name="stardiv.one.form.component.Form"/>
</implementation>
<implementation name="com.sun.star.comp.forms.OFilterControl">
<service name="com.sun.star.awt.UnoControl"/>
<service name="com.sun.star.form.control.FilterControl"/>
</implementation>
<implementation name="com.sun.star.comp.forms.OFormattedFieldWrapper_ForcedFormatted">
<service name="com.sun.star.form.binding.BindableDatabaseFormattedField"/>
<service name="com.sun.star.form.component.DatabaseFormattedField"/>
<service name="com.sun.star.form.component.FormattedField"/>
<service name="stardiv.one.form.component.FormattedField"/>
</implementation>
<implementation name="com.sun.star.comp.forms.ORichTextModel">
<service name="com.sun.star.form.FormComponent"/>
<service name="com.sun.star.form.FormControlModel"/>
<service name="com.sun.star.form.component.RichTextControl"/>
<service name="com.sun.star.style.CharacterProperties"/>
<service name="com.sun.star.style.CharacterPropertiesAsian"/>
<service name="com.sun.star.style.CharacterPropertiesComplex"/>
<service name="com.sun.star.style.ParagraphProperties"/>
<service name="com.sun.star.style.ParagraphPropertiesComplex"/>
<service name="com.sun.star.text.TextRange"/>
</implementation>
<implementation name="com.sun.star.comp.forms.OScrollBarModel">
<service name="com.sun.star.form.FormComponent"/>
<service name="com.sun.star.form.FormControlModel"/>
<service name="com.sun.star.form.binding.BindableIntegerValueRange"/>
<service name="com.sun.star.form.component.ScrollBar"/>
</implementation>
<implementation name="com.sun.star.comp.forms.OSpinButtonModel">
<service name="com.sun.star.form.FormComponent"/>
<service name="com.sun.star.form.FormControlModel"/>
<service name="com.sun.star.form.binding.BindableIntegerValueRange"/>
<service name="com.sun.star.form.component.SpinButton"/>
</implementation>
<implementation name="com.sun.star.comp.xml.xpath.XFormsExtension">
<service name="com.sun.star.xml.xpath.XPathExtension"/>
</implementation>
<implementation name="com.sun.star.form.ImageProducer">
<service name="com.sun.star.awt.ImageProducer"/>
</implementation>
<implementation name="com.sun.star.form.Model">
<service name="com.sun.star.xforms.Model"/>
</implementation>
<implementation name="com.sun.star.form.OButtonControl">
<service name="com.sun.star.form.control.CommandButton"/>
<service name="stardiv.one.form.control.CommandButton"/>
</implementation>
<implementation name="com.sun.star.form.OButtonModel">
<service name="com.sun.star.form.component.CommandButton"/>
<service name="stardiv.one.form.component.CommandButton"/>
</implementation>
<implementation name="com.sun.star.form.OCheckBoxControl">
<service name="com.sun.star.form.control.CheckBox"/>
<service name="stardiv.one.form.control.CheckBox"/>
</implementation>
<implementation name="com.sun.star.form.OCheckBoxModel">
<service name="com.sun.star.form.binding.BindableDatabaseCheckBox"/>
<service name="com.sun.star.form.component.CheckBox"/>
<service name="com.sun.star.form.component.DatabaseCheckBox"/>
<service name="stardiv.one.form.component.CheckBox"/>
</implementation>
<implementation name="com.sun.star.form.OComboBoxControl">
<service name="com.sun.star.form.control.ComboBox"/>
<service name="stardiv.one.form.control.ComboBox"/>
</implementation>
<implementation name="com.sun.star.form.OComboBoxModel">
<service name="com.sun.star.form.binding.BindableDatabaseComboBox"/>
<service name="com.sun.star.form.component.ComboBox"/>
<service name="com.sun.star.form.component.DatabaseComboBox"/>
<service name="stardiv.one.form.component.ComboBox"/>
</implementation>
<implementation name="com.sun.star.form.OCurrencyControl">
<service name="com.sun.star.form.control.CurrencyField"/>
<service name="stardiv.one.form.control.CurrencyField"/>
</implementation>
<implementation name="com.sun.star.form.OCurrencyModel">
<service name="com.sun.star.form.component.CurrencyField"/>
<service name="com.sun.star.form.component.DatabaseCurrencyField"/>
<service name="stardiv.one.form.component.CurrencyField"/>
</implementation>
<implementation name="com.sun.star.form.ODateControl">
<service name="com.sun.star.form.control.DateField"/>
<service name="stardiv.one.form.control.DateField"/>
</implementation>
<implementation name="com.sun.star.form.ODateModel">
<service name="com.sun.star.form.component.DatabaseDateField"/>
<service name="com.sun.star.form.component.DateField"/>
<service name="stardiv.one.form.component.DateField"/>
</implementation>
<implementation name="com.sun.star.form.OEditControl">
<service name="com.sun.star.form.control.TextField"/>
<service name="stardiv.one.form.control.Edit"/>
<service name="stardiv.one.form.control.TextField"/>
</implementation>
<implementation name="com.sun.star.form.OEditModel">
<service name="com.sun.star.form.binding.BindableDatabaseTextField"/>
<service name="com.sun.star.form.component.DatabaseTextField"/>
<service name="com.sun.star.form.component.TextField"/>
<service name="stardiv.one.form.component.TextField"/>
</implementation>
<implementation name="com.sun.star.form.OFileControlModel">
<service name="com.sun.star.form.component.FileControl"/>
<service name="stardiv.one.form.component.FileControl"/>
</implementation>
<implementation name="com.sun.star.form.OFixedTextModel">
<service name="com.sun.star.form.component.FixedText"/>
<service name="stardiv.one.form.component.FixedText"/>
</implementation>
<implementation name="com.sun.star.form.OFormattedControl">
<service name="com.sun.star.form.control.FormattedField"/>
<service name="stardiv.one.form.control.FormattedField"/>
</implementation>
<implementation name="com.sun.star.form.OFormattedFieldWrapper">
<service name="stardiv.one.form.component.Edit"/>
</implementation>
<implementation name="com.sun.star.form.OFormsCollection">
<service name="com.sun.star.form.Forms"/>
</implementation>
<implementation name="com.sun.star.form.OGridControlModel">
<service name="com.sun.star.form.component.GridControl"/>
<service name="stardiv.one.form.component.Grid"/>
<service name="stardiv.one.form.component.GridControl"/>
</implementation>
<implementation name="com.sun.star.form.OGroupBoxControl">
<service name="com.sun.star.form.control.GroupBox"/>
<service name="stardiv.one.form.control.GroupBox"/>
</implementation>
<implementation name="com.sun.star.form.OGroupBoxModel">
<service name="com.sun.star.form.component.GroupBox"/>
<service name="stardiv.one.form.component.GroupBox"/>
</implementation>
<implementation name="com.sun.star.form.OHiddenModel">
<service name="com.sun.star.form.component.HiddenControl"/>
<service name="stardiv.one.form.component.Hidden"/>
<service name="stardiv.one.form.component.HiddenControl"/>
</implementation>
<implementation name="com.sun.star.form.OImageButtonControl">
<service name="com.sun.star.form.control.ImageButton"/>
<service name="stardiv.one.form.control.ImageButton"/>
</implementation>
<implementation name="com.sun.star.form.OImageButtonModel">
<service name="com.sun.star.form.component.ImageButton"/>
<service name="stardiv.one.form.component.ImageButton"/>
</implementation>
<implementation name="com.sun.star.form.OImageControlControl">
<service name="com.sun.star.form.control.ImageControl"/>
<service name="stardiv.one.form.control.ImageControl"/>
</implementation>
<implementation name="com.sun.star.form.OImageControlModel">
<service name="com.sun.star.form.component.DatabaseImageControl"/>
<service name="stardiv.one.form.component.ImageControl"/>
</implementation>
<implementation name="com.sun.star.form.OListBoxControl">
<service name="com.sun.star.form.control.ListBox"/>
<service name="stardiv.one.form.control.ListBox"/>
</implementation>
<implementation name="com.sun.star.form.OListBoxModel">
<service name="com.sun.star.form.binding.BindableDatabaseListBox"/>
<service name="com.sun.star.form.component.DatabaseListBox"/>
<service name="com.sun.star.form.component.ListBox"/>
<service name="stardiv.one.form.component.ListBox"/>
</implementation>
<implementation name="com.sun.star.form.ONumericControl">
<service name="com.sun.star.form.control.NumericField"/>
<service name="stardiv.one.form.control.NumericField"/>
</implementation>
<implementation name="com.sun.star.form.ONumericModel">
<service name="com.sun.star.form.binding.BindableDatabaseNumericField"/>
<service name="com.sun.star.form.component.DatabaseNumericField"/>
<service name="com.sun.star.form.component.NumericField"/>
<service name="stardiv.one.form.component.NumericField"/>
</implementation>
<implementation name="com.sun.star.form.OPatternControl">
<service name="com.sun.star.form.control.PatternField"/>
<service name="stardiv.one.form.control.PatternField"/>
</implementation>
<implementation name="com.sun.star.form.OPatternModel">
<service name="com.sun.star.form.component.DatabasePatternField"/>
<service name="com.sun.star.form.component.PatternField"/>
<service name="stardiv.one.form.component.PatternField"/>
</implementation>
<implementation name="com.sun.star.form.ORadioButtonControl">
<service name="com.sun.star.form.control.RadioButton"/>
<service name="stardiv.one.form.control.RadioButton"/>
</implementation>
<implementation name="com.sun.star.form.ORadioButtonModel">
<service name="com.sun.star.form.binding.BindableDatabaseRadioButton"/>
<service name="com.sun.star.form.component.DatabaseRadioButton"/>
<service name="com.sun.star.form.component.RadioButton"/>
<service name="stardiv.one.form.component.RadioButton"/>
</implementation>
<implementation name="com.sun.star.form.OTimeControl">
<service name="com.sun.star.form.control.TimeField"/>
<service name="stardiv.one.form.control.TimeField"/>
</implementation>
<implementation name="com.sun.star.form.OTimeModel">
<service name="com.sun.star.form.component.DatabaseTimeField"/>
<service name="com.sun.star.form.component.TimeField"/>
<service name="stardiv.one.form.component.TimeField"/>
</implementation>
<implementation name="com.sun.star.form.XForms">
<service name="com.sun.star.xforms.XForms"/>
</implementation>
</component>

View File

@ -1,3 +1,2 @@
component_writeInfo
component_getImplementationEnvironment
component_getFactory

View File

@ -112,3 +112,11 @@ $(MISC)$/$(SHL1TARGET).flt: makefile.mk
@echo NavigationToolBar >>$@
@echo ONavigationBar >>$@
ALLTAR : $(MISC)/frm.component
$(MISC)/frm.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
frm.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt frm.component

View File

@ -76,6 +76,7 @@ public class InstallData
static private boolean useRtl = false;
static private boolean installedProductMinorSet = false;
static private boolean isDebianSystem = false;
static private boolean useForceDebian = false; /* --force-debian */
static private boolean debianInvestigated = false;
static private String installType; /* custom or typical installation */
static private String osType; /* Linux, SunOS, ... */
@ -667,6 +668,14 @@ public class InstallData
isDebianSystem = value;
}
public boolean useForceDebian() {
return useForceDebian;
}
public void setUseForceDebian(boolean value) {
useForceDebian = value;
}
public boolean databaseQueried() {
return databaseQueried;
}

View File

@ -202,12 +202,13 @@ public class LinuxInstaller extends Installer {
}
if ( data.isDebianSystem() ) {
forceDebianString = "--force-debian";
nodepsString = "--nodeps";
if ( data.useForceDebian() ) {
forceDebianString = "--force-debian";
}
}
String rpmCommand = "";
String[] rpmCommandArray;
String databasePath = null;
String databaseString = "";
boolean useLocalDatabase = false;
@ -225,130 +226,57 @@ public class LinuxInstaller extends Installer {
useLocalDatabase = true;
}
if (useForce) {
if (useLocalDatabase) {
if ( relocations != null ) {
rpmCommand = "rpm --upgrade --ignoresize --force " + forceDebianString + " " + nodepsString + " -vh " +
"--relocate " + relocations + " " + databaseString +
" " + databasePath + " " + packageName;
rpmCommandArray = new String[12];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = "--force";
rpmCommandArray[4] = forceDebianString;
rpmCommandArray[5] = nodepsString;
rpmCommandArray[6] = "-vh";
rpmCommandArray[7] = "--relocate";
rpmCommandArray[8] = relocations;
rpmCommandArray[9] = databaseString;
rpmCommandArray[10] = databasePath;
rpmCommandArray[11] = packageName;
} else {
rpmCommand = "rpm --upgrade --ignoresize --force " + forceDebianString + " " + nodepsString + " -vh " +
databaseString + " " + databasePath + " " + packageName;
rpmCommandArray = new String[10];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = "--force";
rpmCommandArray[4] = forceDebianString;
rpmCommandArray[5] = nodepsString;
rpmCommandArray[6] = "-vh";
rpmCommandArray[7] = databaseString;
rpmCommandArray[8] = databasePath;
rpmCommandArray[9] = packageName;
}
} else {
if ( relocations != null )
{
rpmCommand = "rpm --upgrade --ignoresize --force " + forceDebianString + " " + nodepsString + " -vh " +
"--relocate " + relocations + " " + packageName;
rpmCommandArray = new String[10];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = "--force";
rpmCommandArray[4] = forceDebianString;
rpmCommandArray[5] = nodepsString;
rpmCommandArray[6] = "-vh";
rpmCommandArray[7] = "--relocate";
rpmCommandArray[8] = relocations;
rpmCommandArray[9] = packageName;
} else {
rpmCommand = "rpm --upgrade --ignoresize --force " + forceDebianString + " " + nodepsString + " -vh " + packageName;
rpmCommandArray = new String[8];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = "--force";
rpmCommandArray[4] = forceDebianString;
rpmCommandArray[5] = nodepsString;
rpmCommandArray[6] = "-vh";
rpmCommandArray[7] = packageName;
}
}
} else {
if (useLocalDatabase) {
if ( relocations != null ) {
rpmCommand = "rpm --upgrade --ignoresize " + forceDebianString + " " + nodepsString + " -vh " +
"--relocate " + relocations + " " + databaseString +
" " + databasePath + " " + packageName;
rpmCommandArray = new String[11];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = forceDebianString;
rpmCommandArray[4] = nodepsString;
rpmCommandArray[5] = "-vh";
rpmCommandArray[6] = "--relocate";
rpmCommandArray[7] = relocations;
rpmCommandArray[8] = databaseString;
rpmCommandArray[9] = databasePath;
rpmCommandArray[10] = packageName;
} else {
rpmCommand = "rpm --upgrade --ignoresize " + forceDebianString + " " + nodepsString + " -vh " +
databaseString + " " + databasePath + " " + packageName;
rpmCommandArray = new String[9];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = forceDebianString;
rpmCommandArray[4] = nodepsString;
rpmCommandArray[5] = "-vh";
rpmCommandArray[6] = databaseString;
rpmCommandArray[7] = databasePath;
rpmCommandArray[8] = packageName;
}
} else {
if ( relocations != null )
{
rpmCommand = "rpm --upgrade --ignoresize " + forceDebianString + " " + nodepsString + " -vh " +
"--relocate " + relocations + " " + packageName;
rpmCommandArray = new String[9];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = forceDebianString;
rpmCommandArray[4] = nodepsString;
rpmCommandArray[5] = "-vh";
rpmCommandArray[6] = "--relocate";
rpmCommandArray[7] = relocations;
rpmCommandArray[8] = packageName;
} else {
rpmCommand = "rpm --upgrade --ignoresize " + forceDebianString + " " + nodepsString + " -vh " + packageName;
rpmCommandArray = new String[7];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "--upgrade";
rpmCommandArray[2] = "--ignoresize";
rpmCommandArray[3] = forceDebianString;
rpmCommandArray[4] = nodepsString;
rpmCommandArray[5] = "-vh";
rpmCommandArray[6] = packageName;
}
}
// Defining a Vector that contains the full rpm command. Then the string array can be
// created dynamically. Otherwise there would be too many different scenarios.
Vector rpmVector = new Vector();
rpmVector.add("rpm");
rpmVector.add("--upgrade");
rpmVector.add("--ignoresize");
if ( useForce ) {
rpmVector.add("--force");
}
if ( ! forceDebianString.equals("") ) {
rpmVector.add(forceDebianString);
}
if ( ! nodepsString.equals("") ) {
rpmVector.add(nodepsString);
}
rpmVector.add("-vh");
if ( relocations != null ) {
rpmVector.add("--relocate");
rpmVector.add(relocations);
}
if ( useLocalDatabase ) {
rpmVector.add(databaseString);
rpmVector.add(databasePath);
}
rpmVector.add(packageName);
// Creating String and StringArray for rpm command
int capacity = rpmVector.size();
String rpmCommand = "";
String[] rpmCommandArray = new String[capacity];
for (int i = 0; i < rpmVector.size(); i++) {
rpmCommandArray[i] = (String)rpmVector.get(i);
rpmCommand = rpmCommand + " " + (String)rpmVector.get(i);
}
rpmCommand = rpmCommand.trim();
// Staring rpm process
Vector returnVector = new Vector();
Vector returnErrorVector = new Vector();
// int returnValue = SystemManager.executeProcessReturnVector(rpmCommand, returnVector, returnErrorVector);
@ -407,8 +335,6 @@ public class LinuxInstaller extends Installer {
String databasePath = data.getDatabasePath();
String databaseString = "";
boolean useLocalDatabase = false;
String rpmCommand;
String[] rpmCommandArray;
if (( databasePath != null ) && (! databasePath.equalsIgnoreCase("null"))) {
databaseString = "--dbpath";
@ -427,52 +353,53 @@ public class LinuxInstaller extends Installer {
}
if ( data.isDebianSystem() ) {
forceDebianString = "--force-debian";
nodepsString = "--nodeps";
}
// Code duplication for isDebianSystem is necessary, because there is no valid position
// for forceDebianString, if it is empty. This is no problem in installPackage.
if ( data.isDebianSystem() ) {
if (useLocalDatabase) {
rpmCommand = "rpm " + forceDebianString + " " + nodepsString + " -ev" + " " + databaseString + " " + databasePath + " " + packageName;
rpmCommandArray = new String[7];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = forceDebianString;
rpmCommandArray[2] = nodepsString;
rpmCommandArray[3] = "-ev";
rpmCommandArray[4] = databaseString;
rpmCommandArray[5] = databasePath;
rpmCommandArray[6] = packageName;
} else {
rpmCommand = "rpm " + forceDebianString + " " + nodepsString + " -ev" + " " + packageName;
rpmCommandArray = new String[5];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = forceDebianString;
rpmCommandArray[2] = nodepsString;
rpmCommandArray[3] = "-ev";
rpmCommandArray[4] = packageName;
}
} else {
if (useLocalDatabase) {
rpmCommand = "rpm -ev" + " " + databaseString + " " + databasePath + " " + packageName;
rpmCommandArray = new String[5];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "-ev";
rpmCommandArray[2] = databaseString;
rpmCommandArray[3] = databasePath;
rpmCommandArray[4] = packageName;
} else {
rpmCommand = "rpm -ev" + " " + packageName;
rpmCommandArray = new String[3];
rpmCommandArray[0] = "rpm";
rpmCommandArray[1] = "-ev";
rpmCommandArray[2] = packageName;
if ( data.useForceDebian() ) {
forceDebianString = "--force-debian";
}
}
// Defining a Vector that contains the full rpm command. Then the string array can be
// created dynamically. Otherwise there would be too many different scenarios.
Vector rpmVector = new Vector();
rpmVector.add("rpm");
if ( ! forceDebianString.equals("") ) {
rpmVector.add(forceDebianString);
}
if ( ! nodepsString.equals("") ) {
rpmVector.add(nodepsString);
}
rpmVector.add("-ev");
if ( useLocalDatabase ) {
rpmVector.add(databaseString);
rpmVector.add(databasePath);
}
rpmVector.add(packageName);
// Creating String and StringArray for rpm command
int capacity = rpmVector.size();
String rpmCommand = "";
String[] rpmCommandArray = new String[capacity];
for (int i = 0; i < rpmVector.size(); i++) {
rpmCommandArray[i] = (String)rpmVector.get(i);
rpmCommand = rpmCommand + " " + (String)rpmVector.get(i);
}
rpmCommand = rpmCommand.trim();
// Starting rpm process
Vector returnVector = new Vector();
Vector returnErrorVector = new Vector();
int returnValue = ExecuteProcess.executeProcessReturnVector(rpmCommandArray, returnVector, returnErrorVector);

View File

@ -383,21 +383,33 @@ import java.util.Vector;public class LinuxHelper {
public void investigateDebian(InstallData data) {
// String rpmQuery = "rpm --help;
String[] rpmQueryArray = new String[2];
rpmQueryArray[0] = "rpm";
rpmQueryArray[1] = "--help";
// First check: Is this a Debian system?
Vector returnVector = new Vector();
Vector returnErrorVector = new Vector();
int returnValue = ExecuteProcess.executeProcessReturnVector(rpmQueryArray, returnVector, returnErrorVector);
String dpkgFile = "/usr/bin/dpkg";
// Checking if the return vector contains the string "force-debian"
if ( new File(dpkgFile).exists() ) {
for (int i = 0; i < returnVector.size(); i++) {
String line = (String) returnVector.get(i);
if ( line.indexOf("force-debian") > -1 ) {
data.setIsDebianSystem(true);
data.setIsDebianSystem(true);
// Second check: If this is a Debian system, is "--force-debian" required? Older
// versions do not support "--force-debian".
// String rpmQuery = "rpm --help;
String[] rpmQueryArray = new String[2];
rpmQueryArray[0] = "rpm";
rpmQueryArray[1] = "--help";
Vector returnVector = new Vector();
Vector returnErrorVector = new Vector();
int returnValue = ExecuteProcess.executeProcessReturnVector(rpmQueryArray, returnVector, returnErrorVector);
// Checking if the return vector contains the string "force-debian"
for (int i = 0; i < returnVector.size(); i++) {
String line = (String) returnVector.get(i);
if ( line.indexOf("force-debian") > -1 ) {
data.setUseForceDebian(true);
}
}
}
}

View File

@ -46,3 +46,8 @@ mkdir: %_DEST%\xml%_EXT%\registry\data\org\openoffice
mkdir: %_DEST%\xml%_EXT%\registry\data\org\openoffice\Office
..\config\*.xcu %_DEST%\xml%_EXT%\registry\data\org\openoffice\Office\*.xcu
..\%__SRC%\misc\MacOSXSpell.component %_DEST%\xml%_EXT%\MacOSXSpell.component
..\%__SRC%\misc\guesslang.component %_DEST%\xml%_EXT%\guesslang.component
..\%__SRC%\misc\hyphen.component %_DEST%\xml%_EXT%\hyphen.component
..\%__SRC%\misc\lnth.component %_DEST%\xml%_EXT%\lnth.component
..\%__SRC%\misc\spell.component %_DEST%\xml%_EXT%\spell.component

View File

@ -1,3 +1,2 @@
component_getFactory
component_getImplementationEnvironment
component_writeInfo

View File

@ -42,9 +42,6 @@ using namespace com::sun::star::registry;
// declaration of external RegEntry-functions defined by the service objects
//
extern sal_Bool SAL_CALL Hyphenator_writeInfo(
void * /*pServiceManager*/, XRegistryKey * pRegistryKey );
extern void * SAL_CALL Hyphenator_getFactory(
const sal_Char * pImplName,
XMultiServiceFactory * pServiceManager,
@ -57,12 +54,6 @@ extern void * SAL_CALL Hyphenator_getFactory(
extern "C"
{
sal_Bool SAL_CALL component_writeInfo(
void * pServiceManager, XRegistryKey * pRegistryKey )
{
return Hyphenator_writeInfo( pServiceManager, pRegistryKey );
}
void SAL_CALL component_getImplementationEnvironment(
const sal_Char ** ppEnvTypeName, uno_Environment ** /*ppEnv*/ )
{

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="org.openoffice.lingu.LibHnjHyphenator">
<service name="com.sun.star.linguistic2.Hyphenator"/>
</implementation>
</component>

View File

@ -65,7 +65,7 @@ struct HDInfo {
HyphenDict * aPtr;
OUString aName;
Locale aLoc;
rtl_TextEncoding aEnc;
rtl_TextEncoding eEnc;
CharClass * apCC;
};
@ -83,12 +83,12 @@ class Hyphenator :
>
{
Sequence< Locale > aSuppLocales;
HDInfo * aDicts;
sal_Int32 numdict;
HDInfo * aDicts;
sal_Int32 numdict;
::cppu::OInterfaceContainerHelper aEvtListeners;
Reference< XPropertyChangeListener > xPropHelper;
Reference< XMultiServiceFactory > rSMgr;
Reference< XMultiServiceFactory > rSMgr;
linguistic::PropertyHelper_Hyphen * pPropHelper;
BOOL bDisposing;
@ -108,87 +108,37 @@ public:
virtual ~Hyphenator();
// XSupportedLocales (for XHyphenator)
virtual Sequence< Locale > SAL_CALL getLocales()
throw(RuntimeException);
virtual sal_Bool SAL_CALL hasLocale( const Locale& rLocale )
throw(RuntimeException);
virtual Sequence< Locale > SAL_CALL getLocales() throw(RuntimeException);
virtual sal_Bool SAL_CALL hasLocale( const Locale& rLocale ) throw(RuntimeException);
// XHyphenator
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenatedWord > SAL_CALL
hyphenate( const ::rtl::OUString& aWord,
const ::com::sun::star::lang::Locale& aLocale,
sal_Int16 nMaxLeading,
const ::com::sun::star::beans::PropertyValues& aProperties )
throw(::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenatedWord > SAL_CALL
queryAlternativeSpelling( const ::rtl::OUString& aWord,
const ::com::sun::star::lang::Locale& aLocale,
sal_Int16 nIndex,
const ::com::sun::star::beans::PropertyValues& aProperties )
throw(::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XPossibleHyphens > SAL_CALL
createPossibleHyphens( const ::rtl::OUString& aWord,
const ::com::sun::star::lang::Locale& aLocale,
const ::com::sun::star::beans::PropertyValues& aProperties )
throw(::com::sun::star::lang::IllegalArgumentException,
::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenatedWord > SAL_CALL hyphenate( const ::rtl::OUString& aWord, const ::com::sun::star::lang::Locale& aLocale, sal_Int16 nMaxLeading, const ::com::sun::star::beans::PropertyValues& aProperties ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XHyphenatedWord > SAL_CALL queryAlternativeSpelling( const ::rtl::OUString& aWord, const ::com::sun::star::lang::Locale& aLocale, sal_Int16 nIndex, const ::com::sun::star::beans::PropertyValues& aProperties ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
virtual ::com::sun::star::uno::Reference< ::com::sun::star::linguistic2::XPossibleHyphens > SAL_CALL createPossibleHyphens( const ::rtl::OUString& aWord, const ::com::sun::star::lang::Locale& aLocale, const ::com::sun::star::beans::PropertyValues& aProperties ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException);
// XLinguServiceEventBroadcaster
virtual sal_Bool SAL_CALL
addLinguServiceEventListener(
const Reference< XLinguServiceEventListener >& rxLstnr )
throw(RuntimeException);
virtual sal_Bool SAL_CALL
removeLinguServiceEventListener(
const Reference< XLinguServiceEventListener >& rxLstnr )
throw(RuntimeException);
virtual sal_Bool SAL_CALL addLinguServiceEventListener( const Reference< XLinguServiceEventListener >& rxLstnr ) throw(RuntimeException);
virtual sal_Bool SAL_CALL removeLinguServiceEventListener( const Reference< XLinguServiceEventListener >& rxLstnr ) throw(RuntimeException);
// XServiceDisplayName
virtual OUString SAL_CALL
getServiceDisplayName( const Locale& rLocale )
throw(RuntimeException);
virtual OUString SAL_CALL getServiceDisplayName( const Locale& rLocale ) throw(RuntimeException);
// XInitialization
virtual void SAL_CALL
initialize( const Sequence< Any >& rArguments )
throw(Exception, RuntimeException);
virtual void SAL_CALL initialize( const Sequence< Any >& rArguments ) throw(Exception, RuntimeException);
// XComponent
virtual void SAL_CALL
dispose()
throw(RuntimeException);
virtual void SAL_CALL
addEventListener( const Reference< XEventListener >& rxListener )
throw(RuntimeException);
virtual void SAL_CALL
removeEventListener( const Reference< XEventListener >& rxListener )
throw(RuntimeException);
////////////////////////////////////////////////////////////
// Service specific part
//
virtual void SAL_CALL dispose() throw(RuntimeException);
virtual void SAL_CALL addEventListener( const Reference< XEventListener >& rxListener ) throw(RuntimeException);
virtual void SAL_CALL removeEventListener( const Reference< XEventListener >& rxListener ) throw(RuntimeException);
// XServiceInfo
virtual OUString SAL_CALL
getImplementationName()
throw(RuntimeException);
virtual sal_Bool SAL_CALL
supportsService( const OUString& rServiceName )
throw(RuntimeException);
virtual Sequence< OUString > SAL_CALL
getSupportedServiceNames()
throw(RuntimeException);
virtual OUString SAL_CALL getImplementationName() throw(RuntimeException);
virtual sal_Bool SAL_CALL supportsService( const OUString& rServiceName ) throw(RuntimeException);
virtual Sequence< OUString > SAL_CALL getSupportedServiceNames() throw(RuntimeException);
static inline OUString
getImplementationName_Static() throw();
static Sequence< OUString >
getSupportedServiceNames_Static() throw();
static inline OUString getImplementationName_Static() throw();
static Sequence< OUString > getSupportedServiceNames_Static() throw();
private:

View File

@ -91,3 +91,11 @@ DEF1EXPORTFILE= exports.dxp
.INCLUDE : target.mk
ALLTAR : $(MISC)/hyphen.component
$(MISC)/hyphen.component .ERRREMOVE : $(SOLARENV)/bin/createcomponent.xslt \
hyphen.component
$(XSLTPROC) --nonet --stringparam uri \
'$(COMPONENTPREFIX_BASIS_NATIVE)$(SHL1TARGETN:f)' -o $@ \
$(SOLARENV)/bin/createcomponent.xslt hyphen.component

View File

@ -0,0 +1,34 @@
<?xml version="1.0" encoding="UTF-8"?>
<!--**********************************************************************
*
* 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.
*
**********************************************************************-->
<component loader="com.sun.star.loader.SharedLibrary"
xmlns="http://openoffice.org/2010/uno-components">
<implementation name="com.sun.star.lingu2.LanguageGuessing">
<service name="com.sun.star.linguistic2.LanguageGuessing"/>
</implementation>
</component>

Some files were not shown because too many files have changed in this diff Show More