diff options
author | Jens-Heiner Rechtien <hr@openoffice.org> | 2010-01-28 19:19:29 +0000 |
---|---|---|
committer | Jens-Heiner Rechtien <hr@openoffice.org> | 2010-01-28 19:19:29 +0000 |
commit | ddea1bbc63a2a08b8c546f8cb1bf833671342f11 (patch) | |
tree | 933284d64adaa7ccbb5107d36bb0ff654a6e09a4 /chart2/source | |
parent | 9794e714928d3d8336817545d5a1355645ccf7e8 (diff) | |
parent | a02a44429145de0a67f3b75656f10b146490feec (diff) |
koheidatapilot03: merge with DEV300_m63
Diffstat (limited to 'chart2/source')
3 files changed, 20 insertions, 3 deletions
diff --git a/chart2/source/controller/chartapiwrapper/TitleWrapper.cxx b/chart2/source/controller/chartapiwrapper/TitleWrapper.cxx index e0e9511cf71d..a84dbc0cfc4d 100644 --- a/chart2/source/controller/chartapiwrapper/TitleWrapper.cxx +++ b/chart2/source/controller/chartapiwrapper/TitleWrapper.cxx @@ -505,7 +505,7 @@ const std::vector< WrappedProperty* > TitleWrapper::createWrappedProperties() ::std::vector< ::chart::WrappedProperty* > aWrappedProperties; aWrappedProperties.push_back( new WrappedTitleStringProperty( m_spChart2ModelContact->m_xContext ) ); - aWrappedProperties.push_back( new WrappedTextRotationProperty() ); + aWrappedProperties.push_back( new WrappedTextRotationProperty( m_eTitleType==TitleHelper::Y_AXIS_TITLE || m_eTitleType==TitleHelper::X_AXIS_TITLE ) ); aWrappedProperties.push_back( new WrappedStackedTextProperty() ); WrappedCharacterHeightProperty::addWrappedProperties( aWrappedProperties, this ); WrappedAutomaticPositionProperties::addWrappedProperties( aWrappedProperties ); diff --git a/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.cxx b/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.cxx index bd505d6edac5..07532a4ecf22 100644 --- a/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.cxx +++ b/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.cxx @@ -33,7 +33,9 @@ #include "WrappedTextRotationProperty.hxx" #include "macros.hxx" +#include <com/sun/star/beans/XPropertyState.hpp> +using namespace ::com::sun::star; using ::com::sun::star::uno::Any; using ::rtl::OUString; @@ -43,13 +45,23 @@ namespace chart { //............................................................................. -WrappedTextRotationProperty::WrappedTextRotationProperty() +WrappedTextRotationProperty::WrappedTextRotationProperty( bool bDirectState ) : ::chart::WrappedProperty( C2U( "TextRotation" ), C2U( "TextRotation" ) ) + , m_bDirectState( bDirectState ) { } WrappedTextRotationProperty::~WrappedTextRotationProperty() { } + +beans::PropertyState WrappedTextRotationProperty::getPropertyState( const uno::Reference< beans::XPropertyState >& xInnerPropertyState ) const + throw (beans::UnknownPropertyException, uno::RuntimeException) +{ + if( m_bDirectState ) + return beans::PropertyState_DIRECT_VALUE; + return WrappedProperty::getPropertyState( xInnerPropertyState ); +} + Any WrappedTextRotationProperty::convertInnerToOuterValue( const Any& rInnerValue ) const { Any aRet; diff --git a/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.hxx b/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.hxx index 38a516bbc1b9..54fbf38e53d7 100644 --- a/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.hxx +++ b/chart2/source/controller/chartapiwrapper/WrappedTextRotationProperty.hxx @@ -40,12 +40,17 @@ namespace chart class WrappedTextRotationProperty : public WrappedProperty { public: - WrappedTextRotationProperty(); + WrappedTextRotationProperty( bool bDirectState=false ); virtual ~WrappedTextRotationProperty(); + virtual ::com::sun::star::beans::PropertyState getPropertyState( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyState >& xInnerPropertyState ) const + throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException); + protected: virtual ::com::sun::star::uno::Any convertInnerToOuterValue( const ::com::sun::star::uno::Any& rInnerValue ) const; virtual ::com::sun::star::uno::Any convertOuterToInnerValue( const ::com::sun::star::uno::Any& rOuterValue ) const; + + bool m_bDirectState; }; //............................................................................. |