summaryrefslogtreecommitdiff
path: root/chart2/source
diff options
context:
space:
mode:
authorOlivier Hallot <olivier.hallot@alta.org.br>2012-10-06 23:04:07 -0300
committerMuthu Subramanian <sumuthu@suse.com>2012-10-08 21:41:41 +0530
commit33bea955ca93e218ae19961e1fd9800b8a0590d4 (patch)
tree93a10618656800458c3404694b6f29bf290cd963 /chart2/source
parentd812cee7cb3ac7069d4cfbabc567312a325f6f69 (diff)
OUString cleanup in Chart2
Include C2U macro and rtl prefix Change-Id: I01c3224bc21a7f8a03a8562191fbc161032f2a1d
Diffstat (limited to 'chart2/source')
-rw-r--r--chart2/source/controller/dialogs/res_ErrorBar.cxx10
-rw-r--r--chart2/source/controller/dialogs/res_LegendPosition.cxx12
-rw-r--r--chart2/source/controller/dialogs/res_TextSeparator.cxx18
-rw-r--r--chart2/source/controller/dialogs/res_TextSeparator.hxx6
-rw-r--r--chart2/source/controller/dialogs/tp_3D_SceneAppearance.cxx4
-rw-r--r--chart2/source/controller/dialogs/tp_3D_SceneGeometry.cxx10
-rw-r--r--chart2/source/controller/dialogs/tp_ChartType.cxx6
-rw-r--r--chart2/source/controller/dialogs/tp_DataSource.cxx20
8 files changed, 43 insertions, 43 deletions
diff --git a/chart2/source/controller/dialogs/res_ErrorBar.cxx b/chart2/source/controller/dialogs/res_ErrorBar.cxx
index ba613209d71c..377c7dd282af 100644
--- a/chart2/source/controller/dialogs/res_ErrorBar.cxx
+++ b/chart2/source/controller/dialogs/res_ErrorBar.cxx
@@ -191,7 +191,7 @@ void ErrorBarResources::SetChartDocumentForRangeChoosing(
{
try
{
- xProps->getPropertyValue( C2U( "DisableDataTableDialog" ) ) >>= m_bDisableDataTableDialog;
+ xProps->getPropertyValue( "DisableDataTableDialog" ) >>= m_bDisableDataTableDialog;
}
catch( const uno::Exception& e )
{
@@ -455,7 +455,7 @@ IMPL_LINK( ErrorBarResources, ChooseRange, RangeSelectionButton *, pButton )
return 0;
OSL_ASSERT( m_pCurrentRangeChoosingField == 0 );
- ::rtl::OUString aUIString;
+ OUString aUIString;
if( pButton == &m_aIbRangePositive )
{
m_pCurrentRangeChoosingField = &m_aEdRangePositive;
@@ -697,14 +697,14 @@ void ErrorBarResources::FillValueSets()
}
void ErrorBarResources::listeningFinished(
- const ::rtl::OUString & rNewRange )
+ const OUString & rNewRange )
{
OSL_ASSERT( m_apRangeSelectionHelper.get());
if( ! m_apRangeSelectionHelper.get())
return;
// rNewRange becomes invalid after removing the listener
- ::rtl::OUString aRange( rNewRange );
+ OUString aRange( rNewRange );
// stop listening
m_apRangeSelectionHelper->stopRangeListening();
@@ -740,7 +740,7 @@ void ErrorBarResources::disposingRangeSelection()
bool ErrorBarResources::isRangeFieldContentValid( Edit & rEdit )
{
- ::rtl::OUString aRange( rEdit.GetText());
+ OUString aRange( rEdit.GetText());
bool bIsValid = ( aRange.isEmpty() ) ||
( m_apRangeSelectionHelper.get() &&
m_apRangeSelectionHelper->verifyCellRange( aRange ));
diff --git a/chart2/source/controller/dialogs/res_LegendPosition.cxx b/chart2/source/controller/dialogs/res_LegendPosition.cxx
index c08bdd761eb1..0760a8bf01c5 100644
--- a/chart2/source/controller/dialogs/res_LegendPosition.cxx
+++ b/chart2/source/controller/dialogs/res_LegendPosition.cxx
@@ -95,13 +95,13 @@ void LegendPositionResources::writeToResources( const uno::Reference< frame::XMo
{
//show
sal_Bool bShowLegend = sal_False;
- xProp->getPropertyValue( C2U("Show") ) >>= bShowLegend;
+ xProp->getPropertyValue( "Show" ) >>= bShowLegend;
m_aCbxShow.Check( bShowLegend );
PositionEnableHdl(0);
//position
chart2::LegendPosition ePos;
- xProp->getPropertyValue( C2U( "AnchorPosition" )) >>= ePos;
+ xProp->getPropertyValue( "AnchorPosition" ) >>= ePos;
switch( ePos )
{
case chart2::LegendPosition_LINE_START:
@@ -139,7 +139,7 @@ void LegendPositionResources::writeToModel( const ::com::sun::star::uno::Referen
if( xProp.is() )
{
//show
- xProp->setPropertyValue( C2U("Show"), uno::makeAny( bShowLegend ));
+ xProp->setPropertyValue( "Show" , uno::makeAny( bShowLegend ));
//position
chart2::LegendPosition eNewPos;
@@ -162,9 +162,9 @@ void LegendPositionResources::writeToModel( const ::com::sun::star::uno::Referen
eExp = ::com::sun::star::chart::ChartLegendExpansion_WIDE;
}
- xProp->setPropertyValue( C2U( "AnchorPosition" ), uno::makeAny( eNewPos ));
- xProp->setPropertyValue( C2U( "Expansion" ), uno::makeAny( eExp ));
- xProp->setPropertyValue( C2U( "RelativePosition" ), uno::Any());
+ xProp->setPropertyValue( "AnchorPosition" , uno::makeAny( eNewPos ));
+ xProp->setPropertyValue( "Expansion" , uno::makeAny( eExp ));
+ xProp->setPropertyValue( "RelativePosition" , uno::Any());
}
}
catch( const uno::Exception & ex )
diff --git a/chart2/source/controller/dialogs/res_TextSeparator.cxx b/chart2/source/controller/dialogs/res_TextSeparator.cxx
index 5ebc89b76b40..9b7fc8ce3a65 100644
--- a/chart2/source/controller/dialogs/res_TextSeparator.cxx
+++ b/chart2/source/controller/dialogs/res_TextSeparator.cxx
@@ -43,10 +43,10 @@ TextSeparatorResources::TextSeparatorResources( Window* pWindow )
m_aLB_Separator.SetDropDownLineCount(m_aLB_Separator.GetEntryCount());
m_aLB_Separator.SetSizePixel( m_aLB_Separator.CalcMinimumSize() );
- m_aEntryMap[ C2U( " " ) ] = 0;
- m_aEntryMap[ C2U( ", " ) ] = 1;
- m_aEntryMap[ C2U( "; " ) ] = 2;
- m_aEntryMap[ C2U( "\n" ) ] = 3;
+ m_aEntryMap[ " " ] = 0;
+ m_aEntryMap[ ", " ] = 1;
+ m_aEntryMap[ "; " ] = 2;
+ m_aEntryMap[ "\n" ] = 3;
m_aLB_Separator.SetAccessibleName(m_aFT_Separator.GetText());
m_aLB_Separator.SetAccessibleRelationLabeledBy(&m_aFT_Separator);
@@ -113,9 +113,9 @@ Size TextSeparatorResources::GetCurrentListBoxSize() const
return m_aLB_Separator.GetSizePixel();
}
-void TextSeparatorResources::SetValue( const rtl::OUString& rSeparator )
+void TextSeparatorResources::SetValue( const OUString& rSeparator )
{
- ::std::map< ::rtl::OUString, sal_uInt16 >::iterator aIter( m_aEntryMap.find(rSeparator) );
+ ::std::map< OUString , sal_uInt16 >::iterator aIter( m_aEntryMap.find(rSeparator) );
if( aIter == m_aEntryMap.end() )
m_aLB_Separator.SelectEntryPos( m_nDefaultPos );
else
@@ -127,17 +127,17 @@ void TextSeparatorResources::SetDefault()
m_aLB_Separator.SelectEntryPos( m_nDefaultPos );
}
-rtl::OUString TextSeparatorResources::GetValue() const
+ OUString TextSeparatorResources::GetValue() const
{
sal_uInt16 nPos = m_aLB_Separator.GetSelectEntryPos();
- ::std::map< ::rtl::OUString, sal_uInt16 >::const_iterator aIter( m_aEntryMap.begin() );
+ ::std::map< OUString , sal_uInt16 >::const_iterator aIter( m_aEntryMap.begin() );
while( aIter != m_aEntryMap.end() )
{
if(aIter->second==nPos )
return aIter->first;
++aIter;
}
- return C2U( " " );
+ return OUString( " " );
}
//.............................................................................
diff --git a/chart2/source/controller/dialogs/res_TextSeparator.hxx b/chart2/source/controller/dialogs/res_TextSeparator.hxx
index 9d6121c07ef8..9f89dcca7927 100644
--- a/chart2/source/controller/dialogs/res_TextSeparator.hxx
+++ b/chart2/source/controller/dialogs/res_TextSeparator.hxx
@@ -47,15 +47,15 @@ public:
Point GetCurrentListBoxPosition() const;
Size GetCurrentListBoxSize() const;
- ::rtl::OUString GetValue() const;
- void SetValue( const ::rtl::OUString& rSeparator );
+ OUString GetValue() const;
+ void SetValue( const OUString& rSeparator );
void SetDefault();
private:
FixedText m_aFT_Separator;
ListBox m_aLB_Separator;
- ::std::map< ::rtl::OUString, sal_uInt16 > m_aEntryMap;
+ ::std::map< OUString, sal_uInt16 > m_aEntryMap;
const sal_uInt16 m_nDefaultPos;
};
diff --git a/chart2/source/controller/dialogs/tp_3D_SceneAppearance.cxx b/chart2/source/controller/dialogs/tp_3D_SceneAppearance.cxx
index 0e05e503f63c..4c3fd3c31c22 100644
--- a/chart2/source/controller/dialogs/tp_3D_SceneAppearance.cxx
+++ b/chart2/source/controller/dialogs/tp_3D_SceneAppearance.cxx
@@ -55,7 +55,7 @@ lcl_ModelProperties lcl_getPropertiesFromModel( uno::Reference< frame::XModel >
{
uno::Reference< chart2::XDiagram > xDiagram( ::chart::ChartModelHelper::findDiagram( xModel ) );
uno::Reference< beans::XPropertySet > xDiaProp( xDiagram, uno::UNO_QUERY_THROW );
- xDiaProp->getPropertyValue( C2U("D3DSceneShadeMode")) >>= aProps.m_aShadeMode;
+ xDiaProp->getPropertyValue( "D3DSceneShadeMode" ) >>= aProps.m_aShadeMode;
::chart::ThreeDHelper::getRoundedEdgesAndObjectLines( xDiagram, aProps.m_nRoundedEdges, aProps.m_nObjectLines );
aProps.m_eScheme = ::chart::ThreeDHelper::detectScheme( xDiagram );
}
@@ -72,7 +72,7 @@ void lcl_setShadeModeAtModel( uno::Reference< frame::XModel > & xModel, drawing:
{
uno::Reference< beans::XPropertySet > xDiaProp(
::chart::ChartModelHelper::findDiagram( xModel ), uno::UNO_QUERY_THROW );
- xDiaProp->setPropertyValue( C2U("D3DSceneShadeMode"), uno::makeAny( aShadeMode ));
+ xDiaProp->setPropertyValue( "D3DSceneShadeMode" , uno::makeAny( aShadeMode ));
}
catch( const uno::Exception & ex )
{
diff --git a/chart2/source/controller/dialogs/tp_3D_SceneGeometry.cxx b/chart2/source/controller/dialogs/tp_3D_SceneGeometry.cxx
index bcd4c1bf34be..0fe8ac881125 100644
--- a/chart2/source/controller/dialogs/tp_3D_SceneGeometry.cxx
+++ b/chart2/source/controller/dialogs/tp_3D_SceneGeometry.cxx
@@ -122,12 +122,12 @@ ThreeD_SceneGeometry_TabPage::ThreeD_SceneGeometry_TabPage( Window* pWindow
m_aMFZRotation.SetModifyHdl( aAngleEditedLink );
drawing::ProjectionMode aProjectionMode = drawing::ProjectionMode_PERSPECTIVE;
- m_xSceneProperties->getPropertyValue( C2U("D3DScenePerspective")) >>= aProjectionMode;
+ m_xSceneProperties->getPropertyValue( "D3DScenePerspective" ) >>= aProjectionMode;
m_aCbxPerspective.Check( aProjectionMode == drawing::ProjectionMode_PERSPECTIVE );
m_aCbxPerspective.SetToggleHdl( LINK( this, ThreeD_SceneGeometry_TabPage, PerspectiveToggled ));
sal_Int32 nPerspectivePercentage = 20;
- m_xSceneProperties->getPropertyValue( C2U("Perspective")) >>= nPerspectivePercentage;
+ m_xSceneProperties->getPropertyValue( "Perspective" ) >>= nPerspectivePercentage;
m_aMFPerspective.SetValue( nPerspectivePercentage );
m_aMFPerspective.EnableUpdateData( nTimeout );
@@ -143,7 +143,7 @@ ThreeD_SceneGeometry_TabPage::ThreeD_SceneGeometry_TabPage( Window* pWindow
if( ChartTypeHelper::isSupportingRightAngledAxes(
DiagramHelper::getChartTypeByIndex( xDiagram, 0 ) ) )
{
- m_xSceneProperties->getPropertyValue( C2U("RightAngledAxes")) >>= bRightAngledAxes;
+ m_xSceneProperties->getPropertyValue( "RightAngledAxes" ) >>= bRightAngledAxes;
m_aCbxRightAngledAxes.SetToggleHdl( LINK( this, ThreeD_SceneGeometry_TabPage, RightAngledAxesToggled ));
m_aCbxRightAngledAxes.Check( bRightAngledAxes );
}
@@ -216,8 +216,8 @@ void ThreeD_SceneGeometry_TabPage::applyPerspectiveToModel()
try
{
- m_xSceneProperties->setPropertyValue( C2U("D3DScenePerspective"), uno::makeAny( aMode ));
- m_xSceneProperties->setPropertyValue( C2U("Perspective"), uno::makeAny( (sal_Int32)m_aMFPerspective.GetValue() ));
+ m_xSceneProperties->setPropertyValue( "D3DScenePerspective" , uno::makeAny( aMode ));
+ m_xSceneProperties->setPropertyValue( "Perspective" , uno::makeAny( (sal_Int32)m_aMFPerspective.GetValue() ));
}
catch( const uno::Exception & ex )
{
diff --git a/chart2/source/controller/dialogs/tp_ChartType.cxx b/chart2/source/controller/dialogs/tp_ChartType.cxx
index 6884e67bb58c..7ab0e5444a7b 100644
--- a/chart2/source/controller/dialogs/tp_ChartType.cxx
+++ b/chart2/source/controller/dialogs/tp_ChartType.cxx
@@ -59,7 +59,7 @@ namespace
try
{
uno::Reference< beans::XPropertySet > xDiaProp( xChartDoc->getFirstDiagram(), uno::UNO_QUERY_THROW );
- xDiaProp->getPropertyValue( C2U( "SortByXValues" ) ) >>= bRet;
+ xDiaProp->getPropertyValue( "SortByXValues" ) >>= bRet;
}
catch( const uno::Exception & ex )
{
@@ -840,7 +840,7 @@ ChartTypeTabPage::ChartTypeTabPage( Window* pParent
{
try
{
- xProps->getPropertyValue( C2U( "DisableComplexChartTypes" ) ) >>= bDisableComplexChartTypes;
+ xProps->getPropertyValue( "DisableComplexChartTypes" ) >>= bDisableComplexChartTypes;
}
catch( const uno::Exception& e )
{
@@ -1089,7 +1089,7 @@ void ChartTypeTabPage::initializePage()
uno::Reference< XDiagram > xDiagram( ChartModelHelper::findDiagram( xModel ) );
DiagramHelper::tTemplateWithServiceName aTemplate =
DiagramHelper::getTemplateForDiagram( xDiagram, xTemplateManager );
- ::rtl::OUString aServiceName( aTemplate.second );
+ OUString aServiceName( aTemplate.second );
bool bFound = false;
diff --git a/chart2/source/controller/dialogs/tp_DataSource.cxx b/chart2/source/controller/dialogs/tp_DataSource.cxx
index e0fb150eda8e..080ad76c8f24 100644
--- a/chart2/source/controller/dialogs/tp_DataSource.cxx
+++ b/chart2/source/controller/dialogs/tp_DataSource.cxx
@@ -58,7 +58,7 @@ using ::rtl::OUStringBuffer;
namespace
{
-const OUString lcl_aLabelRole( RTL_CONSTASCII_USTRINGPARAM( "label" ));
+const OUString lcl_aLabelRole( "label" );
String lcl_GetRoleLBEntry(
const OUString & rRole, const OUString & rRange )
@@ -124,7 +124,7 @@ OUString lcl_GetSelectedRolesRange( const SvTabListBox & rRoleListBox )
OUString lcl_GetSequenceNameForLabel( ::chart::SeriesEntry * pEntry )
{
- OUString aResult( RTL_CONSTASCII_USTRINGPARAM("values-y"));
+ OUString aResult( "values-y" );
if( pEntry &&
pEntry->m_xChartType.is())
{
@@ -477,7 +477,7 @@ void DataSourceTabPage::fillSeriesListBox()
OUString aResString( String( ::chart::SchResId( STR_DATA_UNNAMED_SERIES_WITH_INDEX )));
// replace index of unnamed series
- const OUString aReplacementStr( RTL_CONSTASCII_USTRINGPARAM( "%NUMBER" ));
+ const OUString aReplacementStr( "%NUMBER" );
sal_Int32 nIndex = aResString.indexOf( aReplacementStr );
if( nIndex != -1 )
aLabel = String( aResString.replaceAt(
@@ -609,7 +609,7 @@ IMPL_LINK_NOARG(DataSourceTabPage, RoleSelectionChangedHdl)
OUString aSelectedRange = lcl_GetSelectedRolesRange( m_aLB_ROLE );
// replace role in fixed text label
- const OUString aReplacementStr( RTL_CONSTASCII_USTRINGPARAM( "%VALUETYPE" ));
+ const OUString aReplacementStr( "%VALUETYPE" );
sal_Int32 nIndex = m_aFixedTextRange.indexOf( aReplacementStr );
if( nIndex != -1 )
{
@@ -644,7 +644,7 @@ IMPL_LINK_NOARG(DataSourceTabPage, MainRangeButtonClickedHdl)
OUString aUIStr( aStr );
// replace role
- OUString aReplacement( RTL_CONSTASCII_USTRINGPARAM( "%VALUETYPE" ));
+ OUString aReplacement( "%VALUETYPE" );
sal_Int32 nIndex = aUIStr.indexOf( aReplacement );
if( nIndex != -1 )
{
@@ -652,7 +652,7 @@ IMPL_LINK_NOARG(DataSourceTabPage, MainRangeButtonClickedHdl)
lcl_GetSelectedRole( m_aLB_ROLE, true ));
}
// replace series name
- aReplacement = C2U( "%SERIESNAME" );
+ aReplacement = "%SERIESNAME";
nIndex = aUIStr.indexOf( aReplacement );
if( nIndex != -1 )
{
@@ -936,7 +936,7 @@ bool DataSourceTabPage::updateModelFromControl( Edit * pField )
OUString aSelectedRole = lcl_GetSelectedRole( m_aLB_ROLE );
OUString aRange( m_aEDT_RANGE.GetText());
OUString aSequenceRole( aSelectedRole );
- bool bIsLabel = aSequenceRole.equals( lcl_aLabelRole );
+ bool bIsLabel = (aSequenceRole == lcl_aLabelRole );
OUString aSequenceNameForLabel( lcl_GetSequenceNameForLabel( pSeriesEntry ));
if( bIsLabel )
@@ -982,7 +982,7 @@ bool DataSourceTabPage::updateModelFromControl( Edit * pField )
// "$Sheet1.$A$1"
aRange = xNewSeq->getSourceRangeRepresentation();
Reference< beans::XPropertySet > xProp( xNewSeq, uno::UNO_QUERY_THROW );
- xProp->setPropertyValue( C2U("Role"), uno::makeAny( lcl_aLabelRole ));
+ xProp->setPropertyValue( "Role" , uno::makeAny( lcl_aLabelRole ));
xLabeledSeq->setLabel( xNewSeq );
}
}
@@ -1014,10 +1014,10 @@ bool DataSourceTabPage::updateModelFromControl( Edit * pField )
aRange = xNewSeq->getSourceRangeRepresentation();
Reference< beans::XPropertySet > xProp( xNewSeq, uno::UNO_QUERY_THROW );
- xProp->setPropertyValue( C2U("Role"), uno::makeAny( aSelectedRole ));
+ xProp->setPropertyValue( "Role" , uno::makeAny( aSelectedRole ));
if( !xLabeledSeq.is())
{
- if( aSelectedRole.equals( aSequenceNameForLabel ))
+ if( aSelectedRole == aSequenceNameForLabel )
xLabeledSeq.set( lcl_findLSequenceWithOnlyLabel( xSource ));
if( ! xLabeledSeq.is())
{