Trying to keep up with the changes a little better by sending smaller
files. Hope I didn't mess up this diff as I'm new to git, and I had
to stash to pull in some upstream changes. Please review!
This is my first attempt at the sc/source/core/tool directory.
Hopefully the diff is attached below properly, but if not it should be
available at the following url for a few days:
http://dl.dropbox.com/u/18377756/topround_20110115_diff.txt
On another note, is there an automated test suite? If so, I'd love to
know how to kick it off after I make changes.
Regards,
PS: hopefully my name shows up in the email address now, but Topround is fine :)
diff --git a/sc/source/core/tool/addincol.cxx b/sc/source/core/tool/addincol.cxx
old mode 100644
new mode 100755
index 2bc3760..73959cd
--- a/sc/source/core/tool/addincol.cxx
+++ b/sc/source/core/tool/addincol.cxx
@@ -318,37 +318,33 @@ void ScUnoAddInCollection::Initialize()
while ( xEnum-hasMoreElements() )
{
uno::Any aAddInAny = xEnum-nextElement();
-//? if ( aAddInAny.getReflection()-getTypeClass() ==
uno::TypeClass_INTERFACE )
-{
-uno::Referenceuno::XInterface xIntFac;
-aAddInAny = xIntFac;
-if ( xIntFac.is() )
-{
-// #i59984# try XSingleComponentFactory in addition to
(old) XSingleServiceFactory,
-// passing the context to the component
-
-uno::Referenceuno::XInterface xInterface;
-uno::Referenceuno::XComponentContext xCtx =
getContext(xManager);
-uno::Referencelang::XSingleComponentFactory xCFac(
xIntFac, uno::UNO_QUERY );
-if (xCtx.is() xCFac.is())
-{
-xInterface =
xCFac-createInstanceWithContext(xCtx);
-if (xInterface.is())
-ReadFromAddIn( xInterface );
-}
-
-if (!xInterface.is())
-{
-uno::Referencelang::XSingleServiceFactory xFac(
xIntFac, uno::UNO_QUERY );
-if ( xFac.is() )
-{
-xInterface = xFac-createInstance();
-if (xInterface.is())
-ReadFromAddIn( xInterface );
-}
-}
-}
-}
+ uno::Referenceuno::XInterface xIntFac;
+ aAddInAny = xIntFac;
+ if ( xIntFac.is() )
+ {
+ // #i59984# try XSingleComponentFactory
in addition to (old) XSingleServiceFactory,
+ // passing the context to the component
+ uno::Referenceuno::XInterface
xInterface;
+ uno::Referenceuno::XComponentContext
xCtx = getContext(xManager);
+
uno::Referencelang::XSingleComponentFactory xCFac( xIntFac, uno::UNO_QUERY );
+ if (xCtx.is() xCFac.is())
+ {
+ xInterface =
xCFac-createInstanceWithContext(xCtx);
+ if (xInterface.is())
+ ReadFromAddIn(
xInterface );
+ }
+
+ if (!xInterface.is())
+ {
+
uno::Referencelang::XSingleServiceFactory xFac( xIntFac, uno::UNO_QUERY );
+ if ( xFac.is() )
+ {
+ xInterface =
xFac-createInstance();
+ if (xInterface.is())
+ ReadFromAddIn(
xInterface );
+ }
+ }
+ }
}
}
}
@@ -715,9 +711,6 @@ BOOL lcl_ValidReturnType( const
uno::Referencereflection::XIdlClass xClass )
switch (xClass-getTypeClass())
{
-// case uno::TypeClass_VOID:
-// ???
-
case uno::TypeClass_ANY:// variable type
case uno::TypeClass_ENUM: //! ???
case uno::TypeClass_BOOLEAN:
diff --git a/sc/source/core/tool/addinlis.cxx b/sc/source/core/tool/addinlis.cxx
old mode 100644
new mode 100755
index