diff options
author | Norbert Thiebaud <nthiebaud@gmail.com> | 2010-10-09 21:10:35 -0500 |
---|---|---|
committer | Norbert Thiebaud <nthiebaud@gmail.com> | 2010-10-09 21:10:35 -0500 |
commit | da8101702661c03364a747f5e5a6c026c00d8c21 (patch) | |
tree | 1eb61c65a393bade54b169c7a07e7670d69b33f4 | |
parent | 7b8d6eb623cb41413c126cb42c066c572800b268 (diff) |
missing include for SAL_N_ELEMENTS
-rw-r--r-- | sc/source/core/data/cell2.cxx | 2 | ||||
-rw-r--r-- | sc/source/core/data/dpobject.cxx | 1 | ||||
-rw-r--r-- | sc/source/core/tool/compiler.cxx | 1 | ||||
-rw-r--r-- | sc/source/core/tool/interpr2.cxx | 15 | ||||
-rw-r--r-- | sc/source/core/tool/odffmap.cxx | 1 | ||||
-rw-r--r-- | sc/source/filter/qpro/qproform.cxx | 1 | ||||
-rw-r--r-- | sc/source/filter/xml/xmlimprt.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/miscdlgs/protectiondlg.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/unoobj/scdetect.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/unoobj/servuno.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/unoobj/tokenuno.cxx | 2 | ||||
-rw-r--r-- | sc/source/ui/vba/vbaborders.cxx | 1 | ||||
-rw-r--r-- | sc/source/ui/vba/vbadialog.cxx | 12 | ||||
-rw-r--r-- | sc/source/ui/vba/vbaglobals.cxx | 60 | ||||
-rw-r--r-- | sc/source/ui/vba/vbapalette.cxx | 10 |
15 files changed, 65 insertions, 46 deletions
diff --git a/sc/source/core/data/cell2.cxx b/sc/source/core/data/cell2.cxx index d2a5e1291..efa900e19 100644 --- a/sc/source/core/data/cell2.cxx +++ b/sc/source/core/data/cell2.cxx @@ -35,7 +35,7 @@ #include <deque> #include <boost/bind.hpp> - +#include <sal/macros.h> #include <vcl/mapmod.hxx> #include <editeng/editobj.hxx> #include <editeng/editstat.hxx> diff --git a/sc/source/core/data/dpobject.cxx b/sc/source/core/data/dpobject.cxx index 839b58d4d..b2f28ff0c 100644 --- a/sc/source/core/data/dpobject.cxx +++ b/sc/source/core/data/dpobject.cxx @@ -74,6 +74,7 @@ #include <com/sun/star/sheet/XDrillDownDataSupplier.hpp> #include <comphelper/processfactory.hxx> +#include <sal/macros.h> #include <tools/debug.hxx> #include <tools/diagnose_ex.h> #include <svl/zforlist.hxx> // IsNumberFormat diff --git a/sc/source/core/tool/compiler.cxx b/sc/source/core/tool/compiler.cxx index e55a94b02..34bf83594 100644 --- a/sc/source/core/tool/compiler.cxx +++ b/sc/source/core/tool/compiler.cxx @@ -35,6 +35,7 @@ #include <basic/sbmeth.hxx> #include <basic/sbstar.hxx> #include <svl/zforlist.hxx> +#include <sal/macros.h> #include <tools/rcid.h> #include <tools/rc.hxx> #include <tools/solar.h> diff --git a/sc/source/core/tool/interpr2.cxx b/sc/source/core/tool/interpr2.cxx index e7f5bffa0..f65ccc413 100644 --- a/sc/source/core/tool/interpr2.cxx +++ b/sc/source/core/tool/interpr2.cxx @@ -1,7 +1,7 @@ /************************************************************************* * * 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 @@ -36,6 +36,7 @@ #include <svl/stritem.hxx> #include <svl/zforlist.hxx> #include <rtl/logfile.hxx> +#include <sal/macros.h> #include "interpre.hxx" #include "attrib.hxx" @@ -71,7 +72,7 @@ double ScInterpreter::GetDateSerial( INT16 nYear, INT16 nMonth, INT16 nDay, bool RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "sc", "er", "ScInterpreter::GetDateSerial" ); if ( nYear < 100 && !bStrict ) nYear = pFormatter->ExpandTwoDigitYear( nYear ); - // Do not use a default Date ctor here because it asks system time with a + // Do not use a default Date ctor here because it asks system time with a // performance penalty. INT16 nY, nM, nD; if (bStrict) @@ -1806,7 +1807,7 @@ void ScInterpreter::ScIntersect() RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "sc", "er", "ScInterpreter::ScIntersect" ); formula::FormulaTokenRef p2nd = PopToken(); formula::FormulaTokenRef p1st = PopToken(); - + if (nGlobalError || !p2nd || !p1st) { PushIllegalArgument(); @@ -1954,7 +1955,7 @@ void ScInterpreter::ScRangeFunc() RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "sc", "er", "ScInterpreter::ScRangeFunc" ); formula::FormulaTokenRef x2 = PopToken(); formula::FormulaTokenRef x1 = PopToken(); - + if (nGlobalError || !x2 || !x1) { PushIllegalArgument(); @@ -1973,7 +1974,7 @@ void ScInterpreter::ScUnionFunc() RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "sc", "er", "ScInterpreter::ScUnionFunc" ); formula::FormulaTokenRef p2nd = PopToken(); formula::FormulaTokenRef p1st = PopToken(); - + if (nGlobalError || !p2nd || !p1st) { PushIllegalArgument(); @@ -1992,7 +1993,7 @@ void ScInterpreter::ScUnionFunc() ScToken* x1 = static_cast<ScToken*>(p1st.get()); ScToken* x2 = static_cast<ScToken*>(p2nd.get()); - + ScTokenRef xRes; // Append to an existing RefList if there is one. if (sv1 == svRefList) @@ -2977,7 +2978,7 @@ void ScInterpreter::ScGetPivotData() //! should allow numeric constraint values aFilters[i].mbValIsStr = TRUE; aFilters[i].maValStr = GetString(); - + aFilters[i].maFieldName = GetString(); } } diff --git a/sc/source/core/tool/odffmap.cxx b/sc/source/core/tool/odffmap.cxx index 5c06aa5b2..e27e1e769 100644 --- a/sc/source/core/tool/odffmap.cxx +++ b/sc/source/core/tool/odffmap.cxx @@ -29,6 +29,7 @@ #include "precompiled_sc.hxx" #include "compiler.hxx" +#include <sal/macros.h> // ODFF, English, Programmatical, ODF_11 ScCompiler::AddInMap ScCompiler::maAddInMap[] = diff --git a/sc/source/filter/qpro/qproform.cxx b/sc/source/filter/qpro/qproform.cxx index f1cccab6c..8db1e59c3 100644 --- a/sc/source/filter/qpro/qproform.cxx +++ b/sc/source/filter/qpro/qproform.cxx @@ -29,6 +29,7 @@ #include "precompiled_sc.hxx" #include <sal/config.h> +#include <sal/macros.h> #include "qpro.hxx" #include "qproform.hxx" diff --git a/sc/source/filter/xml/xmlimprt.cxx b/sc/source/filter/xml/xmlimprt.cxx index 003ff2302..a6ffdb227 100644 --- a/sc/source/filter/xml/xmlimprt.cxx +++ b/sc/source/filter/xml/xmlimprt.cxx @@ -31,6 +31,7 @@ // INCLUDE --------------------------------------------------------------- #include <svl/zforlist.hxx> +#include <sal/macros.h> #include <xmloff/nmspmap.hxx> #include <xmloff/xmlnmspe.hxx> diff --git a/sc/source/ui/miscdlgs/protectiondlg.cxx b/sc/source/ui/miscdlgs/protectiondlg.cxx index 9edb9f0a4..4308d9abe 100644 --- a/sc/source/ui/miscdlgs/protectiondlg.cxx +++ b/sc/source/ui/miscdlgs/protectiondlg.cxx @@ -33,6 +33,7 @@ #include "scresid.hxx" #include "tabprotection.hxx" +#include <sal/macros.h> #include <vcl/msgbox.hxx> diff --git a/sc/source/ui/unoobj/scdetect.cxx b/sc/source/ui/unoobj/scdetect.cxx index ac8755237..ce1111010 100644 --- a/sc/source/ui/unoobj/scdetect.cxx +++ b/sc/source/ui/unoobj/scdetect.cxx @@ -30,6 +30,8 @@ #include "scdetect.hxx" +#include <sal/macros.h> + #include <framework/interaction.hxx> #include <com/sun/star/lang/XMultiServiceFactory.hpp> #include <com/sun/star/beans/PropertyValue.hpp> diff --git a/sc/source/ui/unoobj/servuno.cxx b/sc/source/ui/unoobj/servuno.cxx index a30c270e8..d4eef0c77 100644 --- a/sc/source/ui/unoobj/servuno.cxx +++ b/sc/source/ui/unoobj/servuno.cxx @@ -31,6 +31,7 @@ #include <tools/debug.hxx> +#include <sal/macros.h> #include <svtools/unoimap.hxx> #include <svx/unofill.hxx> #include <editeng/unonrule.hxx> diff --git a/sc/source/ui/unoobj/tokenuno.cxx b/sc/source/ui/unoobj/tokenuno.cxx index 350c74471..e67f217ab 100644 --- a/sc/source/ui/unoobj/tokenuno.cxx +++ b/sc/source/ui/unoobj/tokenuno.cxx @@ -30,6 +30,8 @@ #include "tokenuno.hxx" +#include <sal/macros.h> + #include <com/sun/star/sheet/ComplexReference.hpp> #include <com/sun/star/sheet/ExternalReference.hpp> #include <com/sun/star/sheet/ReferenceFlags.hpp> diff --git a/sc/source/ui/vba/vbaborders.cxx b/sc/source/ui/vba/vbaborders.cxx index 3da3f2bb0..47430c122 100644 --- a/sc/source/ui/vba/vbaborders.cxx +++ b/sc/source/ui/vba/vbaborders.cxx @@ -26,6 +26,7 @@ ************************************************************************/ #include "vbaborders.hxx" +#include <sal/macros.h> #include <cppuhelper/implbase3.hxx> #include <ooo/vba/excel/XlBordersIndex.hpp> #include <ooo/vba/excel/XlBorderWeight.hpp> diff --git a/sc/source/ui/vba/vbadialog.cxx b/sc/source/ui/vba/vbadialog.cxx index 6fe0a3edb..88a4c4ae6 100644 --- a/sc/source/ui/vba/vbadialog.cxx +++ b/sc/source/ui/vba/vbadialog.cxx @@ -1,7 +1,7 @@ /************************************************************************* * * 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 @@ -26,6 +26,8 @@ ************************************************************************/ #include "vbadialog.hxx" +#include <sal/macros.h> + using namespace ::ooo::vba; using namespace ::com::sun::star; @@ -55,12 +57,12 @@ static const rtl::OUString aStringList[]= rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:DefineLabelRange" ) ), rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:DataFilterAutoFilter" ) ), rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:DataFilterSpecialFilter" ) ), - rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:AutoFormat" ) ) + rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( ".uno:AutoFormat" ) ) }; const sal_Int32 nDialogSize = SAL_N_ELEMENTS( aStringList ) ; -rtl::OUString +rtl::OUString ScVbaDialog::mapIndexToName( sal_Int32 nIndex ) { if( nIndex < nDialogSize ) @@ -68,14 +70,14 @@ ScVbaDialog::mapIndexToName( sal_Int32 nIndex ) return rtl::OUString(); } -rtl::OUString& +rtl::OUString& ScVbaDialog::getServiceImplName() { static rtl::OUString sImplName( RTL_CONSTASCII_USTRINGPARAM("ScVbaDialog") ); return sImplName; } -uno::Sequence< rtl::OUString > +uno::Sequence< rtl::OUString > ScVbaDialog::getServiceNames() { static uno::Sequence< rtl::OUString > aServiceNames; diff --git a/sc/source/ui/vba/vbaglobals.cxx b/sc/source/ui/vba/vbaglobals.cxx index 8c7e3d321..cac7a53a3 100644 --- a/sc/source/ui/vba/vbaglobals.cxx +++ b/sc/source/ui/vba/vbaglobals.cxx @@ -1,7 +1,7 @@ /************************************************************************* * * 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 @@ -27,6 +27,8 @@ #include <vbahelper/helperdecl.hxx> #include "vbaglobals.hxx" +#include <sal/macros.h> + #include <comphelper/unwrapargs.hxx> #include <com/sun/star/lang/XMultiComponentFactory.hpp> @@ -58,7 +60,7 @@ ScVbaGlobals::ScVbaGlobals( uno::Sequence< uno::Any > const& aArgs, uno::Referen aInitArgs[ 0 ].Value = uno::makeAny( getApplication() ); aInitArgs[ 1 ].Name = sDocCtxName; aInitArgs[ 1 ].Value = uno::makeAny( getXSomethingFromArgs< frame::XModel >( aArgs, 0 ) ); - + init( aInitArgs ); } @@ -73,29 +75,29 @@ ScVbaGlobals::~ScVbaGlobals() uno::Reference<excel::XApplication > ScVbaGlobals::getApplication() throw (uno::RuntimeException) { -// OSL_TRACE("In ScVbaGlobals::getApplication"); +// OSL_TRACE("In ScVbaGlobals::getApplication"); if ( !mxApplication.is() ) mxApplication.set( new ScVbaApplication( mxContext) ); - return mxApplication; + return mxApplication; } uno::Reference<excel::XApplication > SAL_CALL ScVbaGlobals::getExcel() throw (uno::RuntimeException) { - return getApplication(); + return getApplication(); } -uno::Reference< excel::XWorkbook > SAL_CALL +uno::Reference< excel::XWorkbook > SAL_CALL ScVbaGlobals::getActiveWorkbook() throw (uno::RuntimeException) { -// OSL_TRACE("In ScVbaGlobals::getActiveWorkbook"); +// OSL_TRACE("In ScVbaGlobals::getActiveWorkbook"); uno::Reference< excel::XWorkbook > xWorkbook( getApplication()->getActiveWorkbook(), uno::UNO_QUERY); if ( xWorkbook.is() ) { - return xWorkbook; + return xWorkbook; } // FIXME check if this is correct/desired behavior throw uno::RuntimeException( rtl::OUString::createFromAscii( @@ -103,19 +105,19 @@ ScVbaGlobals::getActiveWorkbook() throw (uno::RuntimeException) } -uno::Reference< excel::XWindow > SAL_CALL +uno::Reference< excel::XWindow > SAL_CALL ScVbaGlobals::getActiveWindow() throw (uno::RuntimeException) { return getApplication()->getActiveWindow(); } -uno::Reference< excel::XWorksheet > SAL_CALL +uno::Reference< excel::XWorksheet > SAL_CALL ScVbaGlobals::getActiveSheet() throw (uno::RuntimeException) { return getApplication()->getActiveSheet(); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::WorkBooks( const uno::Any& aIndex ) throw (uno::RuntimeException) { return uno::Any( getApplication()->Workbooks(aIndex) ); @@ -132,7 +134,7 @@ ScVbaGlobals::Sheets( const uno::Any& aIndex ) throw (uno::RuntimeException) return WorkSheets( aIndex ); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::Range( const uno::Any& Cell1, const uno::Any& Cell2 ) throw (uno::RuntimeException) { return getApplication()->Range( Cell1, Cell2 ); @@ -144,87 +146,87 @@ ScVbaGlobals::Names( const css::uno::Any& aIndex ) throw ( uno::RuntimeException return getApplication()->Names( aIndex ); } -uno::Reference< excel::XRange > SAL_CALL +uno::Reference< excel::XRange > SAL_CALL ScVbaGlobals::getActiveCell() throw (uno::RuntimeException) { return getApplication()->getActiveCell(); } -uno::Reference< XAssistant > SAL_CALL +uno::Reference< XAssistant > SAL_CALL ScVbaGlobals::getAssistant() throw (uno::RuntimeException) { return getApplication()->getAssistant(); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::getSelection() throw (uno::RuntimeException) { return getApplication()->getSelection(); } -uno::Reference< excel::XWorkbook > SAL_CALL +uno::Reference< excel::XWorkbook > SAL_CALL ScVbaGlobals::getThisWorkbook() throw (uno::RuntimeException) { return getApplication()->getThisWorkbook(); } -void SAL_CALL +void SAL_CALL ScVbaGlobals::Calculate() throw (::com::sun::star::script::BasicErrorException, ::com::sun::star::uno::RuntimeException) { return getApplication()->Calculate(); } -uno::Reference< excel::XRange > SAL_CALL +uno::Reference< excel::XRange > SAL_CALL ScVbaGlobals::Cells( const uno::Any& RowIndex, const uno::Any& ColumnIndex ) throw (uno::RuntimeException) { return getApplication()->getActiveSheet()->Cells( RowIndex, ColumnIndex ); } -uno::Reference< excel::XRange > SAL_CALL +uno::Reference< excel::XRange > SAL_CALL ScVbaGlobals::Columns( const uno::Any& aIndex ) throw (uno::RuntimeException) { return getApplication()->getActiveSheet()->Columns( aIndex ); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::CommandBars( const uno::Any& aIndex ) throw (uno::RuntimeException) { uno::Reference< XApplicationBase > xBase( getApplication(), uno::UNO_QUERY_THROW ); return xBase->CommandBars( aIndex ); } -css::uno::Reference< ov::excel::XRange > SAL_CALL +css::uno::Reference< ov::excel::XRange > SAL_CALL ScVbaGlobals::Union( const css::uno::Reference< ov::excel::XRange >& Arg1, const css::uno::Reference< ov::excel::XRange >& Arg2, const css::uno::Any& Arg3, const css::uno::Any& Arg4, const css::uno::Any& Arg5, const css::uno::Any& Arg6, const css::uno::Any& Arg7, const css::uno::Any& Arg8, const css::uno::Any& Arg9, const css::uno::Any& Arg10, const css::uno::Any& Arg11, const css::uno::Any& Arg12, const css::uno::Any& Arg13, const css::uno::Any& Arg14, const css::uno::Any& Arg15, const css::uno::Any& Arg16, const css::uno::Any& Arg17, const css::uno::Any& Arg18, const css::uno::Any& Arg19, const css::uno::Any& Arg20, const css::uno::Any& Arg21, const css::uno::Any& Arg22, const css::uno::Any& Arg23, const css::uno::Any& Arg24, const css::uno::Any& Arg25, const css::uno::Any& Arg26, const css::uno::Any& Arg27, const css::uno::Any& Arg28, const css::uno::Any& Arg29, const css::uno::Any& Arg30 ) throw (css::script::BasicErrorException, css::uno::RuntimeException) { return getApplication()->Union( Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20, Arg21, Arg22, Arg23, Arg24, Arg25, Arg26, Arg27, Arg28, Arg29, Arg30 ); } -css::uno::Reference< ov::excel::XRange > SAL_CALL +css::uno::Reference< ov::excel::XRange > SAL_CALL ScVbaGlobals::Intersect( const css::uno::Reference< ov::excel::XRange >& Arg1, const css::uno::Reference< ov::excel::XRange >& Arg2, const css::uno::Any& Arg3, const css::uno::Any& Arg4, const css::uno::Any& Arg5, const css::uno::Any& Arg6, const css::uno::Any& Arg7, const css::uno::Any& Arg8, const css::uno::Any& Arg9, const css::uno::Any& Arg10, const css::uno::Any& Arg11, const css::uno::Any& Arg12, const css::uno::Any& Arg13, const css::uno::Any& Arg14, const css::uno::Any& Arg15, const css::uno::Any& Arg16, const css::uno::Any& Arg17, const css::uno::Any& Arg18, const css::uno::Any& Arg19, const css::uno::Any& Arg20, const css::uno::Any& Arg21, const css::uno::Any& Arg22, const css::uno::Any& Arg23, const css::uno::Any& Arg24, const css::uno::Any& Arg25, const css::uno::Any& Arg26, const css::uno::Any& Arg27, const css::uno::Any& Arg28, const css::uno::Any& Arg29, const css::uno::Any& Arg30 ) throw (css::script::BasicErrorException, css::uno::RuntimeException) { return getApplication()->Intersect( Arg1, Arg2, Arg3, Arg4, Arg5, Arg6, Arg7, Arg8, Arg9, Arg10, Arg11, Arg12, Arg13, Arg14, Arg15, Arg16, Arg17, Arg18, Arg19, Arg20, Arg21, Arg22, Arg23, Arg24, Arg25, Arg26, Arg27, Arg28, Arg29, Arg30 ); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::Evaluate( const ::rtl::OUString& Name ) throw (uno::RuntimeException) { return getApplication()->Evaluate( Name ); } -css::uno::Any SAL_CALL +css::uno::Any SAL_CALL ScVbaGlobals::WorksheetFunction( ) throw (css::uno::RuntimeException) { return getApplication()->WorksheetFunction(); } -uno::Any SAL_CALL +uno::Any SAL_CALL ScVbaGlobals::Windows( const uno::Any& aIndex ) throw (uno::RuntimeException) { return getApplication()->Windows( aIndex ); } -uno::Reference< excel::XRange > SAL_CALL +uno::Reference< excel::XRange > SAL_CALL ScVbaGlobals::Rows( const uno::Any& aIndex ) throw (uno::RuntimeException) { return getApplication()->getActiveSheet()->Rows( aIndex ); - + } @@ -246,14 +248,14 @@ ScVbaGlobals::getDebug() throw (uno::RuntimeException) return uno::Any(); } -uno::Sequence< ::rtl::OUString > SAL_CALL +uno::Sequence< ::rtl::OUString > SAL_CALL ScVbaGlobals::getAvailableServiceNames( ) throw (uno::RuntimeException) { static bool bInit = false; static uno::Sequence< rtl::OUString > serviceNames( ScVbaGlobals_BASE::getAvailableServiceNames() ); if ( !bInit ) { - rtl::OUString names[] = { + rtl::OUString names[] = { ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "ooo.vba.excel.Range" ) ), ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "ooo.vba.excel.Workbook" ) ), ::rtl::OUString( RTL_CONSTASCII_USTRINGPARAM ( "ooo.vba.excel.Window" ) ), diff --git a/sc/source/ui/vba/vbapalette.cxx b/sc/source/ui/vba/vbapalette.cxx index 441d60558..d49ea47b5 100644 --- a/sc/source/ui/vba/vbapalette.cxx +++ b/sc/source/ui/vba/vbapalette.cxx @@ -1,7 +1,7 @@ /************************************************************************* * * 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 @@ -24,8 +24,10 @@ * for a copy of the LGPLv3 License. * ************************************************************************/ - + #include "vbapalette.hxx" + +#include <sal/macros.h> #include <cppuhelper/implbase1.hxx> #include <com/sun/star/beans/XPropertySet.hpp> #include <com/sun/star/container/XIndexAccess.hpp> @@ -100,12 +102,12 @@ ScVbaPalette::getPalette() const { uno::Reference< container::XIndexAccess > xIndex; uno::Reference< beans::XPropertySet > xProps; - if ( m_pShell ) + if ( m_pShell ) xProps.set( m_pShell->GetModel(), uno::UNO_QUERY_THROW ); else throw uno::RuntimeException( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM( "Can't extract palette, no doc shell" ) ), uno::Reference< uno::XInterface >() ); xIndex.set( xProps->getPropertyValue( rtl::OUString( RTL_CONSTASCII_USTRINGPARAM("ColorPalette") ) ), uno::UNO_QUERY ); if ( !xIndex.is() ) return new DefaultPalette(); - return xIndex; + return xIndex; } |