Kaydet (Commit) 2f14dc87 authored tarafından Kohei Yoshida's avatar Kohei Yoshida

Use names from unonames.hxx to be consistent.

And removed duplicated defines.
üst ee96213c
...@@ -77,28 +77,6 @@ ...@@ -77,28 +77,6 @@
#define __MAX_NUM_LEN 64 #define __MAX_NUM_LEN 64
#define __DECIMALPLACE 18 #define __DECIMALPLACE 18
#define DP_PROP_COLUMNGRAND "ColumnGrand"
#define DP_PROP_FUNCTION "Function"
#define DP_PROP_IGNOREEMPTY "IgnoreEmptyRows"
#define DP_PROP_ISDATALAYOUT "IsDataLayoutDimension"
#define DP_PROP_ISVISIBLE "IsVisible"
#define DP_PROP_ORIENTATION "Orientation"
#define DP_PROP_REPEATIFEMPTY "RepeatIfEmpty"
#define DP_PROP_ROWGRAND "RowGrand"
#define DP_PROP_SHOWDETAILS "ShowDetails"
#define DP_PROP_SHOWEMPTY "ShowEmpty"
#define DP_PROP_SUBTOTALS "SubTotals"
#define DP_PROP_USEDHIERARCHY "UsedHierarchy"
#define DP_PROP_FILTER "Filter"
#define DP_PROP_POSITION "Position"
#define DP_PROP_ORIGINAL "Original"
class ScTypedStrData;
class ScDPObject;
class ScDPInfoWnd;
class ScDocShell;
class ScTabViewShell;
class SC_DLLPUBLIC ScDPItemData class SC_DLLPUBLIC ScDPItemData
{ {
public: public:
......
...@@ -41,6 +41,7 @@ ...@@ -41,6 +41,7 @@
#include <boost/ptr_container/ptr_vector.hpp> #include <boost/ptr_container/ptr_vector.hpp>
struct ScQueryParam; struct ScQueryParam;
class ScDPObject;
/** /**
* This class represents the cached data part of the datapilot cache table * This class represents the cached data part of the datapilot cache table
......
...@@ -565,18 +565,18 @@ ...@@ -565,18 +565,18 @@
#define SC_UNO_DP_COLGRAND "ColumnGrand" #define SC_UNO_DP_COLGRAND "ColumnGrand"
#define SC_UNO_DP_ROWGRAND "RowGrand" #define SC_UNO_DP_ROWGRAND "RowGrand"
#define SC_UNO_DP_ORIGINAL "Original" #define SC_UNO_DP_ORIGINAL "Original"
#define SC_UNO_DP_ISDATALA "IsDataLayoutDimension" #define SC_UNO_DP_ISDATALAYOUT "IsDataLayoutDimension"
#define SC_UNO_DP_ORIENTAT "Orientation" #define SC_UNO_DP_ORIENTATION "Orientation"
#define SC_UNO_DP_POSITION "Position" #define SC_UNO_DP_POSITION "Position"
#define SC_UNO_DP_FUNCTION "Function" #define SC_UNO_DP_FUNCTION "Function"
#define SC_UNO_DP_USEDHIER "UsedHierarchy" #define SC_UNO_DP_USEDHIERARCHY "UsedHierarchy"
#define SC_UNO_DP_FILTER "Filter" #define SC_UNO_DP_FILTER "Filter"
#define SC_UNO_DP_SUBTOTAL "SubTotals" #define SC_UNO_DP_SUBTOTAL "SubTotals"
#define SC_UNO_DP_SHOWEMPT "ShowEmpty" #define SC_UNO_DP_SHOWEMPTY "ShowEmpty"
#define SC_UNO_DP_ISVISIBL "IsVisible" #define SC_UNO_DP_ISVISIBLE "IsVisible"
#define SC_UNO_DP_SHOWDETA "ShowDetails" #define SC_UNO_DP_SHOWDETAILS "ShowDetails"
#define SC_UNO_DP_IGNOREEM "IgnoreEmptyRows" #define SC_UNO_DP_IGNOREEMPTY "IgnoreEmptyRows"
#define SC_UNO_DP_REPEATIF "RepeatIfEmpty" #define SC_UNO_DP_REPEATEMPTY "RepeatIfEmpty"
#define SC_UNO_DP_DATADESC "DataDescription" #define SC_UNO_DP_DATADESC "DataDescription"
#define SC_UNO_DP_NUMBERFO SC_UNONAME_NUMFMT #define SC_UNO_DP_NUMBERFO SC_UNONAME_NUMFMT
#define SC_UNO_DP_ROWFIELDCOUNT "RowFieldCount" #define SC_UNO_DP_ROWFIELDCOUNT "RowFieldCount"
...@@ -594,12 +594,12 @@ ...@@ -594,12 +594,12 @@
#define SC_UNO_DP_LAYOUT "Layout" #define SC_UNO_DP_LAYOUT "Layout"
// data pilot descriptor // data pilot descriptor
#define SC_UNO_DP_IGNEMPROWS "IgnoreEmptyRows" #define SC_UNO_DP_IGNORE_EMPTYROWS "IgnoreEmptyRows"
#define SC_UNO_DP_RPTEMPTY "RepeatIfEmpty" #define SC_UNO_DP_REPEATEMPTY "RepeatIfEmpty"
#define SC_UNO_DP_DRILLDOWN "DrillDownOnDoubleClick" #define SC_UNO_DP_DRILLDOWN "DrillDownOnDoubleClick"
#define SC_UNO_DP_SHOWFILT "ShowFilterButton" #define SC_UNO_DP_SHOWFILTER "ShowFilterButton"
#define SC_UNO_DP_IMPORTDESC "ImportDescriptor" #define SC_UNO_DP_IMPORTDESC "ImportDescriptor"
#define SC_UNO_DP_SOURCESERV "SourceServiceName" #define SC_UNO_DP_SOURCESERVICE "SourceServiceName"
#define SC_UNO_DP_SERVICEARG "ServiceArguments" #define SC_UNO_DP_SERVICEARG "ServiceArguments"
// properties in data pilot descriptor ServiceArguments // properties in data pilot descriptor ServiceArguments
......
...@@ -372,7 +372,7 @@ void lcl_FillNumberFormats( sal_uInt32*& rFormats, long& rCount, ...@@ -372,7 +372,7 @@ void lcl_FillNumberFormats( sal_uInt32*& rFormats, long& rCount,
{ {
sheet::DataPilotFieldOrientation eDimOrient = sheet::DataPilotFieldOrientation eDimOrient =
(sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty( (sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty(
xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)),
sheet::DataPilotFieldOrientation_HIDDEN ); sheet::DataPilotFieldOrientation_HIDDEN );
if ( eDimOrient == sheet::DataPilotFieldOrientation_DATA ) if ( eDimOrient == sheet::DataPilotFieldOrientation_DATA )
{ {
...@@ -439,7 +439,7 @@ sal_uInt32 lcl_GetFirstNumberFormat( const uno::Reference<container::XIndexAcces ...@@ -439,7 +439,7 @@ sal_uInt32 lcl_GetFirstNumberFormat( const uno::Reference<container::XIndexAcces
{ {
sheet::DataPilotFieldOrientation eDimOrient = sheet::DataPilotFieldOrientation eDimOrient =
(sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty( (sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty(
xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)),
sheet::DataPilotFieldOrientation_HIDDEN ); sheet::DataPilotFieldOrientation_HIDDEN );
if ( eDimOrient == sheet::DataPilotFieldOrientation_DATA ) if ( eDimOrient == sheet::DataPilotFieldOrientation_DATA )
{ {
...@@ -487,7 +487,7 @@ uno::Sequence<sheet::MemberResult> lcl_GetSelectedPageAsResult( const uno::Refer ...@@ -487,7 +487,7 @@ uno::Sequence<sheet::MemberResult> lcl_GetSelectedPageAsResult( const uno::Refer
{ {
//! merge with ScDPDimension::setPropertyValue? //! merge with ScDPDimension::setPropertyValue?
uno::Any aValue = xDimProp->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_FILTER)) ); uno::Any aValue = xDimProp->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_FILTER)) );
uno::Sequence<sheet::TableFilterField> aSeq; uno::Sequence<sheet::TableFilterField> aSeq;
if (aValue >>= aSeq) if (aValue >>= aSeq)
...@@ -561,13 +561,13 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS ...@@ -561,13 +561,13 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS
{ {
sheet::DataPilotFieldOrientation eDimOrient = sheet::DataPilotFieldOrientation eDimOrient =
(sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty( (sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty(
xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)),
sheet::DataPilotFieldOrientation_HIDDEN ); sheet::DataPilotFieldOrientation_HIDDEN );
long nDimPos = ScUnoHelpFunctions::GetLongProperty( xDimProp, long nDimPos = ScUnoHelpFunctions::GetLongProperty( xDimProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_POSITION)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_POSITION)) );
sal_Bool bIsDataLayout = ScUnoHelpFunctions::GetBoolProperty( sal_Bool bIsDataLayout = ScUnoHelpFunctions::GetBoolProperty(
xDimProp, xDimProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ISDATALAYOUT)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISDATALAYOUT)) );
bool bHasHiddenMember = ScUnoHelpFunctions::GetBoolProperty( bool bHasHiddenMember = ScUnoHelpFunctions::GetBoolProperty(
xDimProp, OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_HAS_HIDDEN_MEMBER))); xDimProp, OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_HAS_HIDDEN_MEMBER)));
...@@ -577,7 +577,7 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS ...@@ -577,7 +577,7 @@ ScDPOutput::ScDPOutput( ScDocument* pD, const uno::Reference<sheet::XDimensionsS
new ScNameToIndexAccess( xDimSupp->getHierarchies() ); new ScNameToIndexAccess( xDimSupp->getHierarchies() );
long nHierarchy = ScUnoHelpFunctions::GetLongProperty( long nHierarchy = ScUnoHelpFunctions::GetLongProperty(
xDimProp, xDimProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_USEDHIERARCHY)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_USEDHIERARCHY)) );
if ( nHierarchy >= xHiers->getCount() ) if ( nHierarchy >= xHiers->getCount() )
nHierarchy = 0; nHierarchy = 0;
...@@ -1221,12 +1221,12 @@ void lcl_GetTableVars( sal_Int32& rGrandTotalCols, sal_Int32& rGrandTotalRows, s ...@@ -1221,12 +1221,12 @@ void lcl_GetTableVars( sal_Int32& rGrandTotalCols, sal_Int32& rGrandTotalRows, s
uno::Reference<beans::XPropertySet> xSrcProp( xSource, uno::UNO_QUERY ); uno::Reference<beans::XPropertySet> xSrcProp( xSource, uno::UNO_QUERY );
sal_Bool bColGrand = ScUnoHelpFunctions::GetBoolProperty( xSrcProp, sal_Bool bColGrand = ScUnoHelpFunctions::GetBoolProperty( xSrcProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_COLUMNGRAND)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_COLGRAND)) );
if ( bColGrand ) if ( bColGrand )
rGrandTotalCols = 1; // default if data layout not in columns rGrandTotalCols = 1; // default if data layout not in columns
sal_Bool bRowGrand = ScUnoHelpFunctions::GetBoolProperty( xSrcProp, sal_Bool bRowGrand = ScUnoHelpFunctions::GetBoolProperty( xSrcProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ROWGRAND)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ROWGRAND)) );
if ( bRowGrand ) if ( bRowGrand )
rGrandTotalRows = 1; // default if data layout not in rows rGrandTotalRows = 1; // default if data layout not in rows
...@@ -1247,10 +1247,10 @@ void lcl_GetTableVars( sal_Int32& rGrandTotalCols, sal_Int32& rGrandTotalRows, s ...@@ -1247,10 +1247,10 @@ void lcl_GetTableVars( sal_Int32& rGrandTotalCols, sal_Int32& rGrandTotalRows, s
{ {
sheet::DataPilotFieldOrientation eDimOrient = sheet::DataPilotFieldOrientation eDimOrient =
(sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty( (sheet::DataPilotFieldOrientation) ScUnoHelpFunctions::GetEnumProperty(
xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)),
sheet::DataPilotFieldOrientation_HIDDEN ); sheet::DataPilotFieldOrientation_HIDDEN );
if ( ScUnoHelpFunctions::GetBoolProperty( xDimProp, if ( ScUnoHelpFunctions::GetBoolProperty( xDimProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ISDATALAYOUT)) ) ) rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISDATALAYOUT)) ) )
{ {
rDataLayoutIndex = nDim; rDataLayoutIndex = nDim;
rDataOrient = eDimOrient; rDataOrient = eDimOrient;
...@@ -1570,7 +1570,7 @@ uno::Sequence<sheet::GeneralFunction> lcl_GetSubTotals( ...@@ -1570,7 +1570,7 @@ uno::Sequence<sheet::GeneralFunction> lcl_GetSubTotals(
{ {
try try
{ {
uno::Any aValue = xLevelProp->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_SUBTOTALS)) ); uno::Any aValue = xLevelProp->getPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_SUBTOTAL)) );
aValue >>= aSubTotals; aValue >>= aSubTotals;
} }
catch(uno::Exception&) catch(uno::Exception&)
...@@ -1826,7 +1826,7 @@ void ScDPOutput::GetDataDimensionNames( String& rSourceName, String& rGivenName, ...@@ -1826,7 +1826,7 @@ void ScDPOutput::GetDataDimensionNames( String& rSourceName, String& rGivenName,
//! Should use a stored name when available //! Should use a stored name when available
sheet::GeneralFunction eFunc = (sheet::GeneralFunction)ScUnoHelpFunctions::GetEnumProperty( sheet::GeneralFunction eFunc = (sheet::GeneralFunction)ScUnoHelpFunctions::GetEnumProperty(
xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_FUNCTION)), xDimProp, rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_FUNCTION)),
sheet::GeneralFunction_NONE ); sheet::GeneralFunction_NONE );
rGivenName = lcl_GetDataFieldName( rSourceName, eFunc ); rGivenName = lcl_GetDataFieldName( rSourceName, eFunc );
} }
......
...@@ -166,17 +166,17 @@ void ScDPSaveMember::WriteToSource( const uno::Reference<uno::XInterface>& xMemb ...@@ -166,17 +166,17 @@ void ScDPSaveMember::WriteToSource( const uno::Reference<uno::XInterface>& xMemb
if ( nVisibleMode != SC_DPSAVEMODE_DONTKNOW ) if ( nVisibleMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xMembProp, lcl_SetBoolProperty( xMembProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ISVISIBLE)), (bool)nVisibleMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISVISIBLE)), (bool)nVisibleMode );
if ( nShowDetailsMode != SC_DPSAVEMODE_DONTKNOW ) if ( nShowDetailsMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xMembProp, lcl_SetBoolProperty( xMembProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_SHOWDETAILS)), (bool)nShowDetailsMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_SHOWDETAILS)), (bool)nShowDetailsMode );
if (mpLayoutName.get()) if (mpLayoutName.get())
ScUnoHelpFunctions::SetOptionalPropertyValue(xMembProp, SC_UNO_DP_LAYOUTNAME, *mpLayoutName); ScUnoHelpFunctions::SetOptionalPropertyValue(xMembProp, SC_UNO_DP_LAYOUTNAME, *mpLayoutName);
if ( nPosition >= 0 ) if ( nPosition >= 0 )
ScUnoHelpFunctions::SetOptionalPropertyValue(xMembProp, DP_PROP_POSITION, nPosition); ScUnoHelpFunctions::SetOptionalPropertyValue(xMembProp, SC_UNO_DP_POSITION, nPosition);
} }
} }
...@@ -555,16 +555,16 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD ...@@ -555,16 +555,16 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD
sheet::DataPilotFieldOrientation eOrient = (sheet::DataPilotFieldOrientation)nOrientation; sheet::DataPilotFieldOrientation eOrient = (sheet::DataPilotFieldOrientation)nOrientation;
aAny <<= eOrient; aAny <<= eOrient;
xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), aAny ); xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)), aAny );
sheet::GeneralFunction eFunc = (sheet::GeneralFunction)nFunction; sheet::GeneralFunction eFunc = (sheet::GeneralFunction)nFunction;
aAny <<= eFunc; aAny <<= eFunc;
xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_FUNCTION)), aAny ); xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_FUNCTION)), aAny );
if ( nUsedHierarchy >= 0 ) if ( nUsedHierarchy >= 0 )
{ {
aAny <<= (sal_Int32)nUsedHierarchy; aAny <<= (sal_Int32)nUsedHierarchy;
xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_USEDHIERARCHY)), aAny ); xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_USEDHIERARCHY)), aAny );
} }
if ( pReferenceValue ) if ( pReferenceValue )
...@@ -584,7 +584,7 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD ...@@ -584,7 +584,7 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD
} }
// else keep empty sequence // else keep empty sequence
ScUnoHelpFunctions::SetOptionalPropertyValue(xDimProp, DP_PROP_FILTER, aFilter); ScUnoHelpFunctions::SetOptionalPropertyValue(xDimProp, SC_UNO_DP_FILTER, aFilter);
if (mpLayoutName.get()) if (mpLayoutName.get())
ScUnoHelpFunctions::SetOptionalPropertyValue(xDimProp, SC_UNO_DP_LAYOUTNAME, *mpLayoutName); ScUnoHelpFunctions::SetOptionalPropertyValue(xDimProp, SC_UNO_DP_LAYOUTNAME, *mpLayoutName);
...@@ -643,11 +643,11 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD ...@@ -643,11 +643,11 @@ void ScDPSaveDimension::WriteToSource( const uno::Reference<uno::XInterface>& xD
for (long i=0; i<nSubTotalCount; i++) for (long i=0; i<nSubTotalCount; i++)
pArray[i] = (sheet::GeneralFunction)pSubTotalFuncs[i]; pArray[i] = (sheet::GeneralFunction)pSubTotalFuncs[i];
aAny <<= aSeq; aAny <<= aSeq;
xLevProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_SUBTOTALS)), aAny ); xLevProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_SUBTOTAL)), aAny );
} }
if ( nShowEmptyMode != SC_DPSAVEMODE_DONTKNOW ) if ( nShowEmptyMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xLevProp, lcl_SetBoolProperty( xLevProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_SHOWEMPTY)), (bool)nShowEmptyMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_SHOWEMPTY)), (bool)nShowEmptyMode );
if ( pSortInfo ) if ( pSortInfo )
ScUnoHelpFunctions::SetOptionalPropertyValue(xLevProp, SC_UNO_DP_SORTING, *pSortInfo); ScUnoHelpFunctions::SetOptionalPropertyValue(xLevProp, SC_UNO_DP_SORTING, *pSortInfo);
...@@ -1029,7 +1029,7 @@ void lcl_ResetOrient( const uno::Reference<sheet::XDimensionsSupplier>& xSource ...@@ -1029,7 +1029,7 @@ void lcl_ResetOrient( const uno::Reference<sheet::XDimensionsSupplier>& xSource
{ {
uno::Any aAny; uno::Any aAny;
aAny <<= eOrient; aAny <<= eOrient;
xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ORIENTATION)), aAny ); xDimProp->setPropertyValue( rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION)), aAny );
} }
} }
} }
...@@ -1052,10 +1052,10 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie ...@@ -1052,10 +1052,10 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie
{ {
if ( nIgnoreEmptyMode != SC_DPSAVEMODE_DONTKNOW ) if ( nIgnoreEmptyMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xSourceProp, lcl_SetBoolProperty( xSourceProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_IGNOREEMPTY)), (bool)nIgnoreEmptyMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_IGNOREEMPTY)), (bool)nIgnoreEmptyMode );
if ( nRepeatEmptyMode != SC_DPSAVEMODE_DONTKNOW ) if ( nRepeatEmptyMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xSourceProp, lcl_SetBoolProperty( xSourceProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_REPEATIFEMPTY)), (bool)nRepeatEmptyMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_REPEATEMPTY)), (bool)nRepeatEmptyMode );
} }
catch(uno::Exception&) catch(uno::Exception&)
{ {
...@@ -1101,7 +1101,7 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie ...@@ -1101,7 +1101,7 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie
if ( xDimProp.is() ) if ( xDimProp.is() )
{ {
bFound = ScUnoHelpFunctions::GetBoolProperty( xDimProp, bFound = ScUnoHelpFunctions::GetBoolProperty( xDimProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ISDATALAYOUT)) ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISDATALAYOUT)) );
//! error checking -- is "IsDataLayoutDimension" property required?? //! error checking -- is "IsDataLayoutDimension" property required??
} }
} }
...@@ -1146,10 +1146,10 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie ...@@ -1146,10 +1146,10 @@ void ScDPSaveData::WriteToSource( const uno::Reference<sheet::XDimensionsSupplie
{ {
if ( nColumnGrandMode != SC_DPSAVEMODE_DONTKNOW ) if ( nColumnGrandMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xSourceProp, lcl_SetBoolProperty( xSourceProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_COLUMNGRAND)), (bool)nColumnGrandMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_COLGRAND)), (bool)nColumnGrandMode );
if ( nRowGrandMode != SC_DPSAVEMODE_DONTKNOW ) if ( nRowGrandMode != SC_DPSAVEMODE_DONTKNOW )
lcl_SetBoolProperty( xSourceProp, lcl_SetBoolProperty( xSourceProp,
rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(DP_PROP_ROWGRAND)), (bool)nRowGrandMode ); rtl::OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ROWGRAND)), (bool)nRowGrandMode );
} }
} }
catch(uno::Exception&) catch(uno::Exception&)
......
...@@ -1142,8 +1142,8 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPSource::getPropertySetInfo( ...@@ -1142,8 +1142,8 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPSource::getPropertySetInfo(
{ {
{MAP_CHAR_LEN(SC_UNO_DP_COLGRAND), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_COLGRAND), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_DATADESC), 0, &getCppuType((rtl::OUString*)0), beans::PropertyAttribute::READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_DATADESC), 0, &getCppuType((rtl::OUString*)0), beans::PropertyAttribute::READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_IGNOREEM), 0, &getBooleanCppuType(), 0, 0 }, // for sheet data only {MAP_CHAR_LEN(SC_UNO_DP_IGNOREEMPTY), 0, &getBooleanCppuType(), 0, 0 }, // for sheet data only
{MAP_CHAR_LEN(SC_UNO_DP_REPEATIF), 0, &getBooleanCppuType(), 0, 0 }, // for sheet data only {MAP_CHAR_LEN(SC_UNO_DP_REPEATEMPTY), 0, &getBooleanCppuType(), 0, 0 }, // for sheet data only
{MAP_CHAR_LEN(SC_UNO_DP_ROWGRAND), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ROWGRAND), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_ROWFIELDCOUNT), 0, &getCppuType(static_cast<sal_Int32*>(0)), READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ROWFIELDCOUNT), 0, &getCppuType(static_cast<sal_Int32*>(0)), READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_COLUMNFIELDCOUNT), 0, &getCppuType(static_cast<sal_Int32*>(0)), READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_COLUMNFIELDCOUNT), 0, &getCppuType(static_cast<sal_Int32*>(0)), READONLY, 0 },
...@@ -1166,9 +1166,9 @@ void SAL_CALL ScDPSource::setPropertyValue( const rtl::OUString& aPropertyName, ...@@ -1166,9 +1166,9 @@ void SAL_CALL ScDPSource::setPropertyValue( const rtl::OUString& aPropertyName,
setColumnGrand( lcl_GetBoolFromAny( aValue ) ); setColumnGrand( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_ROWGRAND ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_ROWGRAND ) )
setRowGrand( lcl_GetBoolFromAny( aValue ) ); setRowGrand( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_IGNOREEM ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_IGNOREEMPTY ) )
setIgnoreEmptyRows( lcl_GetBoolFromAny( aValue ) ); setIgnoreEmptyRows( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_REPEATIF ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_REPEATEMPTY ) )
setRepeatIfEmpty( lcl_GetBoolFromAny( aValue ) ); setRepeatIfEmpty( lcl_GetBoolFromAny( aValue ) );
else if (aNameStr.EqualsAscii(SC_UNO_DP_GRANDTOTAL_NAME)) else if (aNameStr.EqualsAscii(SC_UNO_DP_GRANDTOTAL_NAME))
{ {
...@@ -1193,9 +1193,9 @@ uno::Any SAL_CALL ScDPSource::getPropertyValue( const rtl::OUString& aPropertyNa ...@@ -1193,9 +1193,9 @@ uno::Any SAL_CALL ScDPSource::getPropertyValue( const rtl::OUString& aPropertyNa
lcl_SetBoolInAny( aRet, getColumnGrand() ); lcl_SetBoolInAny( aRet, getColumnGrand() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_ROWGRAND ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_ROWGRAND ) )
lcl_SetBoolInAny( aRet, getRowGrand() ); lcl_SetBoolInAny( aRet, getRowGrand() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_IGNOREEM ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_IGNOREEMPTY ) )
lcl_SetBoolInAny( aRet, getIgnoreEmptyRows() ); lcl_SetBoolInAny( aRet, getIgnoreEmptyRows() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_REPEATIF ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_REPEATEMPTY ) )
lcl_SetBoolInAny( aRet, getRepeatIfEmpty() ); lcl_SetBoolInAny( aRet, getRepeatIfEmpty() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_DATADESC ) ) // read-only else if ( aNameStr.EqualsAscii( SC_UNO_DP_DATADESC ) ) // read-only
aRet <<= rtl::OUString( getDataDescription() ); aRet <<= rtl::OUString( getDataDescription() );
...@@ -1541,13 +1541,13 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPDimension::getPropertySetIn ...@@ -1541,13 +1541,13 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPDimension::getPropertySetIn
{MAP_CHAR_LEN(SC_UNO_DP_FILTER), 0, &getCppuType((uno::Sequence<sheet::TableFilterField>*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_FILTER), 0, &getCppuType((uno::Sequence<sheet::TableFilterField>*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_FLAGS), 0, &getCppuType((sal_Int32*)0), beans::PropertyAttribute::READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_FLAGS), 0, &getCppuType((sal_Int32*)0), beans::PropertyAttribute::READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_FUNCTION), 0, &getCppuType((sheet::GeneralFunction*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_FUNCTION), 0, &getCppuType((sheet::GeneralFunction*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_ISDATALA), 0, &getBooleanCppuType(), beans::PropertyAttribute::READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ISDATALAYOUT), 0, &getBooleanCppuType(), beans::PropertyAttribute::READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_NUMBERFO), 0, &getCppuType((sal_Int32*)0), beans::PropertyAttribute::READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_NUMBERFO), 0, &getCppuType((sal_Int32*)0), beans::PropertyAttribute::READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_ORIENTAT), 0, &getCppuType((sheet::DataPilotFieldOrientation*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ORIENTATION), 0, &getCppuType((sheet::DataPilotFieldOrientation*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_ORIGINAL), 0, &getCppuType((uno::Reference<container::XNamed>*)0), beans::PropertyAttribute::READONLY, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ORIGINAL), 0, &getCppuType((uno::Reference<container::XNamed>*)0), beans::PropertyAttribute::READONLY, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_POSITION), 0, &getCppuType((sal_Int32*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_POSITION), 0, &getCppuType((sal_Int32*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_REFVALUE), 0, &getCppuType((sheet::DataPilotFieldReference*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_REFVALUE), 0, &getCppuType((sheet::DataPilotFieldReference*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_USEDHIER), 0, &getCppuType((sal_Int32*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_USEDHIERARCHY), 0, &getCppuType((sal_Int32*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_LAYOUTNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_LAYOUTNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_FIELD_SUBTOTALNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_FIELD_SUBTOTALNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_HAS_HIDDEN_MEMBER), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_HAS_HIDDEN_MEMBER), 0, &getBooleanCppuType(), 0, 0 },
...@@ -1570,13 +1570,13 @@ void SAL_CALL ScDPDimension::setPropertyValue( const rtl::OUString& aPropertyNam ...@@ -1570,13 +1570,13 @@ void SAL_CALL ScDPDimension::setPropertyValue( const rtl::OUString& aPropertyNam
if (aValue >>= nInt) if (aValue >>= nInt)
setPosition( nInt ); setPosition( nInt );
} }
else if ( aNameStr.EqualsAscii( SC_UNO_DP_USEDHIER ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_USEDHIERARCHY ) )
{ {
sal_Int32 nInt = 0; sal_Int32 nInt = 0;
if (aValue >>= nInt) if (aValue >>= nInt)
setUsedHierarchy( nInt ); setUsedHierarchy( nInt );
} }
else if ( aNameStr.EqualsAscii( SC_UNO_DP_ORIENTAT ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_ORIENTATION ) )
{ {
sheet::DataPilotFieldOrientation eEnum; sheet::DataPilotFieldOrientation eEnum;
if (aValue >>= eEnum) if (aValue >>= eEnum)
...@@ -1650,9 +1650,9 @@ uno::Any SAL_CALL ScDPDimension::getPropertyValue( const rtl::OUString& aPropert ...@@ -1650,9 +1650,9 @@ uno::Any SAL_CALL ScDPDimension::getPropertyValue( const rtl::OUString& aPropert
String aNameStr = aPropertyName; String aNameStr = aPropertyName;
if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) ) if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) )
aRet <<= (sal_Int32) getPosition(); aRet <<= (sal_Int32) getPosition();
else if ( aNameStr.EqualsAscii( SC_UNO_DP_USEDHIER ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_USEDHIERARCHY ) )
aRet <<= (sal_Int32) getUsedHierarchy(); aRet <<= (sal_Int32) getUsedHierarchy();
else if ( aNameStr.EqualsAscii( SC_UNO_DP_ORIENTAT ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_ORIENTATION ) )
{ {
sheet::DataPilotFieldOrientation eVal = (sheet::DataPilotFieldOrientation)getOrientation(); sheet::DataPilotFieldOrientation eVal = (sheet::DataPilotFieldOrientation)getOrientation();
aRet <<= eVal; aRet <<= eVal;
...@@ -1664,7 +1664,7 @@ uno::Any SAL_CALL ScDPDimension::getPropertyValue( const rtl::OUString& aPropert ...@@ -1664,7 +1664,7 @@ uno::Any SAL_CALL ScDPDimension::getPropertyValue( const rtl::OUString& aPropert
} }
else if ( aNameStr.EqualsAscii( SC_UNO_DP_REFVALUE ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_REFVALUE ) )
aRet <<= aReferenceValue; aRet <<= aReferenceValue;
else if ( aNameStr.EqualsAscii( SC_UNO_DP_ISDATALA ) ) // read-only properties else if ( aNameStr.EqualsAscii( SC_UNO_DP_ISDATALAYOUT ) ) // read-only properties
lcl_SetBoolInAny( aRet, getIsDataLayoutDimension() ); lcl_SetBoolInAny( aRet, getIsDataLayoutDimension() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_NUMBERFO ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_NUMBERFO ) )
{ {
...@@ -2266,7 +2266,7 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPLevel::getPropertySetInfo() ...@@ -2266,7 +2266,7 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPLevel::getPropertySetInfo()
//! change type of AutoShow/Layout/Sorting to API struct when available //! change type of AutoShow/Layout/Sorting to API struct when available
{MAP_CHAR_LEN(SC_UNO_DP_AUTOSHOW), 0, &getCppuType((sheet::DataPilotFieldAutoShowInfo*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_AUTOSHOW), 0, &getCppuType((sheet::DataPilotFieldAutoShowInfo*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_LAYOUT), 0, &getCppuType((sheet::DataPilotFieldLayoutInfo*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_LAYOUT), 0, &getCppuType((sheet::DataPilotFieldLayoutInfo*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SHOWEMPT), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SHOWEMPTY), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SORTING), 0, &getCppuType((sheet::DataPilotFieldSortInfo*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SORTING), 0, &getCppuType((sheet::DataPilotFieldSortInfo*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SUBTOTAL), 0, &getCppuType((uno::Sequence<sheet::GeneralFunction>*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SUBTOTAL), 0, &getCppuType((uno::Sequence<sheet::GeneralFunction>*)0), 0, 0 },
{0,0,0,0,0,0} {0,0,0,0,0,0}
...@@ -2282,7 +2282,7 @@ void SAL_CALL ScDPLevel::setPropertyValue( const rtl::OUString& aPropertyName, c ...@@ -2282,7 +2282,7 @@ void SAL_CALL ScDPLevel::setPropertyValue( const rtl::OUString& aPropertyName, c
uno::RuntimeException) uno::RuntimeException)
{ {
String aNameStr = aPropertyName; String aNameStr = aPropertyName;
if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWEMPT ) ) if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWEMPTY ) )
setShowEmpty( lcl_GetBoolFromAny( aValue ) ); setShowEmpty( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_SUBTOTAL ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_SUBTOTAL ) )
{ {
...@@ -2308,7 +2308,7 @@ uno::Any SAL_CALL ScDPLevel::getPropertyValue( const rtl::OUString& aPropertyNam ...@@ -2308,7 +2308,7 @@ uno::Any SAL_CALL ScDPLevel::getPropertyValue( const rtl::OUString& aPropertyNam
{ {
uno::Any aRet; uno::Any aRet;
String aNameStr = aPropertyName; String aNameStr = aPropertyName;
if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWEMPT ) ) if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWEMPTY ) )
lcl_SetBoolInAny( aRet, getShowEmpty() ); lcl_SetBoolInAny( aRet, getShowEmpty() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_SUBTOTAL ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_SUBTOTAL ) )
{ {
...@@ -2745,9 +2745,9 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPMember::getPropertySetInfo( ...@@ -2745,9 +2745,9 @@ uno::Reference<beans::XPropertySetInfo> SAL_CALL ScDPMember::getPropertySetInfo(
static SfxItemPropertyMapEntry aDPMemberMap_Impl[] = static SfxItemPropertyMapEntry aDPMemberMap_Impl[] =
{ {
{MAP_CHAR_LEN(SC_UNO_DP_ISVISIBL), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ISVISIBLE), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_POSITION), 0, &getCppuType((sal_Int32*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_POSITION), 0, &getCppuType((sal_Int32*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SHOWDETA), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SHOWDETAILS), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_LAYOUTNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_LAYOUTNAME), 0, &getCppuType(static_cast<rtl::OUString*>(0)), 0, 0 },
{0,0,0,0,0,0} {0,0,0,0,0,0}
}; };
...@@ -2762,9 +2762,9 @@ void SAL_CALL ScDPMember::setPropertyValue( const rtl::OUString& aPropertyName, ...@@ -2762,9 +2762,9 @@ void SAL_CALL ScDPMember::setPropertyValue( const rtl::OUString& aPropertyName,
uno::RuntimeException) uno::RuntimeException)
{ {
String aNameStr = aPropertyName; String aNameStr = aPropertyName;
if ( aNameStr.EqualsAscii( SC_UNO_DP_ISVISIBL ) ) if ( aNameStr.EqualsAscii( SC_UNO_DP_ISVISIBLE ) )
setIsVisible( lcl_GetBoolFromAny( aValue ) ); setIsVisible( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWDETA ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWDETAILS ) )
setShowDetails( lcl_GetBoolFromAny( aValue ) ); setShowDetails( lcl_GetBoolFromAny( aValue ) );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) )
{ {
...@@ -2790,9 +2790,9 @@ uno::Any SAL_CALL ScDPMember::getPropertyValue( const rtl::OUString& aPropertyNa ...@@ -2790,9 +2790,9 @@ uno::Any SAL_CALL ScDPMember::getPropertyValue( const rtl::OUString& aPropertyNa
{ {
uno::Any aRet; uno::Any aRet;
String aNameStr = aPropertyName; String aNameStr = aPropertyName;
if ( aNameStr.EqualsAscii( SC_UNO_DP_ISVISIBL ) ) if ( aNameStr.EqualsAscii( SC_UNO_DP_ISVISIBLE ) )
lcl_SetBoolInAny( aRet, getIsVisible() ); lcl_SetBoolInAny( aRet, getIsVisible() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWDETA ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_SHOWDETAILS ) )
lcl_SetBoolInAny( aRet, getShowDetails() ); lcl_SetBoolInAny( aRet, getShowDetails() );
else if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) ) else if ( aNameStr.EqualsAscii( SC_UNO_DP_POSITION ) )
aRet <<= (sal_Int32) getPosition(); aRet <<= (sal_Int32) getPosition();
......
...@@ -108,13 +108,13 @@ const SfxItemPropertyMapEntry* lcl_GetDataPilotDescriptorBaseMap() ...@@ -108,13 +108,13 @@ const SfxItemPropertyMapEntry* lcl_GetDataPilotDescriptorBaseMap()
{MAP_CHAR_LEN(SC_UNO_DP_COLGRAND), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_COLGRAND), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_DRILLDOWN), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_DRILLDOWN), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_GRANDTOTAL_NAME),0,&getCppuType((rtl::OUString*)0), beans::PropertyAttribute::MAYBEVOID, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_GRANDTOTAL_NAME),0,&getCppuType((rtl::OUString*)0), beans::PropertyAttribute::MAYBEVOID, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_IGNEMPROWS), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_IGNORE_EMPTYROWS), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_IMPORTDESC), 0, &getCppuType((uno::Sequence<beans::PropertyValue>*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_IMPORTDESC), 0, &getCppuType((uno::Sequence<beans::PropertyValue>*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_RPTEMPTY), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_REPEATEMPTY), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_ROWGRAND), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_ROWGRAND), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SERVICEARG), 0, &getCppuType((uno::Sequence<beans::PropertyValue>*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SERVICEARG), 0, &getCppuType((uno::Sequence<beans::PropertyValue>*)0), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SHOWFILT), 0, &getBooleanCppuType(), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SHOWFILTER), 0, &getBooleanCppuType(), 0, 0 },
{MAP_CHAR_LEN(SC_UNO_DP_SOURCESERV), 0, &getCppuType((rtl::OUString*)0), 0, 0 }, {MAP_CHAR_LEN(SC_UNO_DP_SOURCESERVICE), 0, &getCppuType((rtl::OUString*)0), 0, 0 },
{0,0,0,0,0,0} {0,0,0,0,0,0}
}; };
return aDataPilotDescriptorBaseMap_Impl; return aDataPilotDescriptorBaseMap_Impl;
...@@ -796,11 +796,11 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp ...@@ -796,11 +796,11 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp
{ {
aNewData.SetColumnGrand(::cppu::any2bool( aValue )); aNewData.SetColumnGrand(::cppu::any2bool( aValue ));
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_IGNEMPROWS ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_IGNORE_EMPTYROWS ) )
{ {
aNewData.SetIgnoreEmptyRows(::cppu::any2bool( aValue )); aNewData.SetIgnoreEmptyRows(::cppu::any2bool( aValue ));
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_RPTEMPTY ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_REPEATEMPTY ) )
{ {
aNewData.SetRepeatIfEmpty(::cppu::any2bool( aValue )); aNewData.SetRepeatIfEmpty(::cppu::any2bool( aValue ));
} }
...@@ -808,7 +808,7 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp ...@@ -808,7 +808,7 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp
{ {
aNewData.SetRowGrand(::cppu::any2bool( aValue )); aNewData.SetRowGrand(::cppu::any2bool( aValue ));
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_SHOWFILT ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_SHOWFILTER ) )
{ {
aNewData.SetFilterButton(::cppu::any2bool( aValue )); aNewData.SetFilterButton(::cppu::any2bool( aValue ));
} }
...@@ -854,7 +854,7 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp ...@@ -854,7 +854,7 @@ void SAL_CALL ScDataPilotDescriptorBase::setPropertyValue( const OUString& aProp
pDPObject->SetImportDesc( aImportDesc ); pDPObject->SetImportDesc( aImportDesc );
} }
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_SOURCESERV ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_SOURCESERVICE ) )
{ {
rtl::OUString aStrVal; rtl::OUString aStrVal;
if ( aValue >>= aStrVal ) if ( aValue >>= aStrVal )
...@@ -945,11 +945,11 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope ...@@ -945,11 +945,11 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope
{ {
aRet = ::cppu::bool2any( aNewData.GetColumnGrand() ); aRet = ::cppu::bool2any( aNewData.GetColumnGrand() );
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_IGNEMPROWS ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_IGNORE_EMPTYROWS ) )
{ {
aRet = ::cppu::bool2any( aNewData.GetIgnoreEmptyRows() ); aRet = ::cppu::bool2any( aNewData.GetIgnoreEmptyRows() );
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_RPTEMPTY ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_REPEATEMPTY ) )
{ {
aRet = ::cppu::bool2any( aNewData.GetRepeatIfEmpty() ); aRet = ::cppu::bool2any( aNewData.GetRepeatIfEmpty() );
} }
...@@ -957,7 +957,7 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope ...@@ -957,7 +957,7 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope
{ {
aRet = ::cppu::bool2any( aNewData.GetRowGrand() ); aRet = ::cppu::bool2any( aNewData.GetRowGrand() );
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_SHOWFILT ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_SHOWFILTER ) )
{ {
aRet = ::cppu::bool2any( aNewData.GetFilterButton() ); aRet = ::cppu::bool2any( aNewData.GetFilterButton() );
} }
...@@ -996,7 +996,7 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope ...@@ -996,7 +996,7 @@ Any SAL_CALL ScDataPilotDescriptorBase::getPropertyValue( const OUString& aPrope
aRet <<= aEmpty; aRet <<= aEmpty;
} }
} }
else if ( aNameString.EqualsAscii( SC_UNO_DP_SOURCESERV ) ) else if ( aNameString.EqualsAscii( SC_UNO_DP_SOURCESERVICE ) )
{ {
rtl::OUString aServiceName; rtl::OUString aServiceName;
const ScDPServiceDesc* pServiceDesc = pDPObject->GetDPServiceDesc(); const ScDPServiceDesc* pServiceDesc = pDPObject->GetDPServiceDesc();
...@@ -1606,7 +1606,7 @@ sal_Int32 lcl_GetFieldCount( const Reference<XDimensionsSupplier>& rSource, cons ...@@ -1606,7 +1606,7 @@ sal_Int32 lcl_GetFieldCount( const Reference<XDimensionsSupplier>& rSource, cons
for (sal_Int32 i = 0; i < nIntCount; ++i) for (sal_Int32 i = 0; i < nIntCount; ++i)
{ {
xDim.set(xIntDims->getByIndex(i), UNO_QUERY); xDim.set(xIntDims->getByIndex(i), UNO_QUERY);
if (xDim.is() && (xDim->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTAT))) == rOrient)) if (xDim.is() && (xDim->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION))) == rOrient))
++nRet; ++nRet;
} }
} }
...@@ -1646,7 +1646,7 @@ sal_Bool lcl_GetFieldDataByIndex( const Reference<XDimensionsSupplier>& rSource, ...@@ -1646,7 +1646,7 @@ sal_Bool lcl_GetFieldDataByIndex( const Reference<XDimensionsSupplier>& rSource,
while (i < nIntCount && !bOk) while (i < nIntCount && !bOk)
{ {
xDim.set(xIntDims->getByIndex(i), UNO_QUERY); xDim.set(xIntDims->getByIndex(i), UNO_QUERY);
if (xDim.is() && (xDim->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTAT))) == rOrient)) if (xDim.is() && (xDim->getPropertyValue(OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ORIENTATION))) == rOrient))
{ {
if (nPos == nIndex) if (nPos == nIndex)
{ {
...@@ -1688,7 +1688,7 @@ sal_Bool lcl_GetFieldDataByIndex( const Reference<XDimensionsSupplier>& rSource, ...@@ -1688,7 +1688,7 @@ sal_Bool lcl_GetFieldDataByIndex( const Reference<XDimensionsSupplier>& rSource,
OUString sOriginalName( lcl_GetOriginalName( xDimName ) ); OUString sOriginalName( lcl_GetOriginalName( xDimName ) );
rFieldId.maFieldName = sOriginalName; rFieldId.maFieldName = sOriginalName;
rFieldId.mbDataLayout = ScUnoHelpFunctions::GetBoolProperty( xDim, rFieldId.mbDataLayout = ScUnoHelpFunctions::GetBoolProperty( xDim,
OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISDATALA)) ); OUString(RTL_CONSTASCII_USTRINGPARAM(SC_UNO_DP_ISDATALAYOUT)) );
sal_Int32 nRepeat = 0; sal_Int32 nRepeat = 0;
if ( rOrient.hasValue() && lcl_IsDuplicated( xDim ) ) if ( rOrient.hasValue() && lcl_IsDuplicated( xDim ) )
...@@ -3505,7 +3505,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName ...@@ -3505,7 +3505,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName
{ {
Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY ); Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY );
if( xMemberProps.is() ) if( xMemberProps.is() )
aRet = xMemberProps->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( SC_UNO_DP_SHOWDETA ) ) ); aRet = xMemberProps->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( SC_UNO_DP_SHOWDETAILS ) ) );
else else
aRet <<= true; aRet <<= true;
} }
...@@ -3520,7 +3520,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName ...@@ -3520,7 +3520,7 @@ Any SAL_CALL ScDataPilotItemObj::getPropertyValue( const OUString& aPropertyName
{ {
Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY ); Reference< XPropertySet > xMemberProps( xMember, UNO_QUERY );
if( xMemberProps.is() ) if( xMemberProps.is() )
aRet <<= !cppu::any2bool( xMemberProps->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( SC_UNO_DP_ISVISIBL ) ) ) ); aRet <<= !cppu::any2bool( xMemberProps->getPropertyValue( OUString( RTL_CONSTASCII_USTRINGPARAM( SC_UNO_DP_ISVISIBLE ) ) ) );
else else
aRet <<= false; aRet <<= false;
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment