diff options
author | Vladimir Glazounov <vg@openoffice.org> | 2007-05-22 16:19:55 +0000 |
---|---|---|
committer | Vladimir Glazounov <vg@openoffice.org> | 2007-05-22 16:19:55 +0000 |
commit | bdf882fbdda2edfaa154ae1d775bcdaab78d37eb (patch) | |
tree | e9939455fc90f9f3a274b5ef211b484f16fc536f /chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx | |
parent | 1ad75aebdc12719392caf0633baa8745aacda73c (diff) |
INTEGRATION: CWS chart2mst3 (1.1.2); FILE ADDED
2006/02/17 20:57:44 iha 1.1.2.4: enlarge validity of api wrapper objects to lifetime of new chartmodel
2005/10/11 09:19:55 bm 1.1.2.3: license header change
2005/07/13 16:07:44 iha 1.1.2.2: disable mapping from name to value for gradients etc. - use nane to name instead
2005/06/15 17:58:46 iha 1.1.2.1: support Up/DownBar in old API
Diffstat (limited to 'chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx')
-rw-r--r-- | chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx | 173 |
1 files changed, 173 insertions, 0 deletions
diff --git a/chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx b/chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx new file mode 100644 index 000000000000..d613f3d4f30f --- /dev/null +++ b/chart2/source/controller/chartapiwrapper/UpDownBarWrapper.hxx @@ -0,0 +1,173 @@ +/************************************************************************* + * + * OpenOffice.org - a multi-platform office productivity suite + * + * $RCSfile: UpDownBarWrapper.hxx,v $ + * + * $Revision: 1.2 $ + * + * last change: $Author: vg $ $Date: 2007-05-22 17:19:55 $ + * + * The Contents of this file are made available subject to + * the terms of GNU Lesser General Public License Version 2.1. + * + * + * GNU Lesser General Public License Version 2.1 + * ============================================= + * Copyright 2005 by Sun Microsystems, Inc. + * 901 San Antonio Road, Palo Alto, CA 94303, USA + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Lesser General Public + * License version 2.1, as published by the Free Software Foundation. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Lesser General Public License for more details. + * + * You should have received a copy of the GNU Lesser General Public + * License along with this library; if not, write to the Free Software + * Foundation, Inc., 59 Temple Place, Suite 330, Boston, + * MA 02111-1307 USA + * + ************************************************************************/ +#ifndef CHART_UPDOWNBARWRAPPER_HXX +#define CHART_UPDOWNBARWRAPPER_HXX + +#include "ServiceMacros.hxx" +#include "MutexContainer.hxx" +// #include "WrappedNamedProperty.hxx" + +#ifndef _CPPUHELPER_INTERFACECONTAINER_HXX_ +#include <cppuhelper/interfacecontainer.hxx> +#endif + + +#ifndef _COM_SUN_STAR_CHART2_XDIAGRAM_HPP_ +#include <com/sun/star/chart2/XDiagram.hpp> +#endif + +// header for class OPropertyArrayHelper +#ifndef _CPPUHELPER_PROPSHLP_HXX +#include <cppuhelper/propshlp.hxx> +#endif +#ifndef _CPPUHELPER_IMPLBASE6_HXX_ +#include <cppuhelper/implbase6.hxx> +#endif + +#ifndef _COM_SUN_STAR_BEANS_XMULTIPROPERTYSET_HPP_ +#include <com/sun/star/beans/XMultiPropertySet.hpp> +#endif +#ifndef _COM_SUN_STAR_BEANS_XMULTIPROPERTYSTATES_HPP_ +#include <com/sun/star/beans/XMultiPropertyStates.hpp> +#endif +#ifndef _COM_SUN_STAR_BEANS_XPROPERTYSTATE_HPP_ +#include <com/sun/star/beans/XPropertyState.hpp> +#endif +#ifndef _COM_SUN_STAR_LANG_XCOMPONENT_HPP_ +#include <com/sun/star/lang/XComponent.hpp> +#endif +#ifndef _COM_SUN_STAR_LANG_XSERVICEINFO_HPP_ +#include <com/sun/star/lang/XServiceInfo.hpp> +#endif +#ifndef _COM_SUN_STAR_UNO_XCOMPONENTCONTEXT_HPP_ +#include <com/sun/star/uno/XComponentContext.hpp> +#endif + +#include <boost/shared_ptr.hpp> + +namespace chart +{ + +namespace wrapper +{ + +class Chart2ModelContact; + +class UpDownBarWrapper : public MutexContainer + , public ::cppu::WeakImplHelper6 + < ::com::sun::star::lang::XComponent + , ::com::sun::star::lang::XServiceInfo + , ::com::sun::star::beans::XPropertySet + , ::com::sun::star::beans::XMultiPropertySet + , ::com::sun::star::beans::XPropertyState + , ::com::sun::star::beans::XMultiPropertyStates + // , ::com::sun::star::uno::XWeak // implemented by WeakImplHelper(optional interface) + // , ::com::sun::star::uno::XInterface // implemented by WeakImplHelper + // , ::com::sun::star::lang::XTypeProvider // implemented by WeakImplHelper + > +{ +public: + UpDownBarWrapper( bool bUp, ::boost::shared_ptr< Chart2ModelContact > spChart2ModelContact ); + virtual ~UpDownBarWrapper(); + + /// XServiceInfo declarations + APPHELPER_XSERVICEINFO_DECL() + + // ____ XComponent ____ + virtual void SAL_CALL dispose() + throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL addEventListener( const ::com::sun::star::uno::Reference< + ::com::sun::star::lang::XEventListener >& xListener ) + throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL removeEventListener( const ::com::sun::star::uno::Reference< + ::com::sun::star::lang::XEventListener >& aListener ) + throw (::com::sun::star::uno::RuntimeException); + + //XPropertySet + virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo( ) throw (::com::sun::star::uno::RuntimeException); + + virtual void SAL_CALL setPropertyValue( const ::rtl::OUString& aPropertyName, const ::com::sun::star::uno::Any& aValue ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue( const ::rtl::OUString& PropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + + virtual void SAL_CALL addPropertyChangeListener( const ::rtl::OUString& aPropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& xListener ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL removePropertyChangeListener( const ::rtl::OUString& aPropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertyChangeListener >& aListener ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL addVetoableChangeListener( const ::rtl::OUString& PropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL removeVetoableChangeListener( const ::rtl::OUString& PropertyName, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XVetoableChangeListener >& aListener ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + + //XMultiPropertySet + //getPropertySetInfo() already declared in XPropertySet + virtual void SAL_CALL setPropertyValues( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, const ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any >& aValues ) throw (::com::sun::star::beans::PropertyVetoException, ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > SAL_CALL getPropertyValues( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL addPropertiesChangeListener( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL removePropertiesChangeListener( const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL firePropertiesChangeEvent( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames, const ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertiesChangeListener >& xListener ) throw (::com::sun::star::uno::RuntimeException); + + //XPropertyState + virtual ::com::sun::star::beans::PropertyState SAL_CALL getPropertyState( const ::rtl::OUString& PropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException); + virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyState > SAL_CALL getPropertyStates( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL setPropertyToDefault( const ::rtl::OUString& PropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException); + virtual ::com::sun::star::uno::Any SAL_CALL getPropertyDefault( const ::rtl::OUString& aPropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + + //XMultiPropertyStates + //getPropertyStates() already declared in XPropertyState + virtual void SAL_CALL setAllPropertiesToDefault( ) throw (::com::sun::star::uno::RuntimeException); + virtual void SAL_CALL setPropertiesToDefault( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException); + virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Any > SAL_CALL getPropertyDefaults( const ::com::sun::star::uno::Sequence< ::rtl::OUString >& aPropertyNames ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException); + +private: //methods + ::cppu::IPropertyArrayHelper& getInfoHelper(); + +private: //member + ::boost::shared_ptr< Chart2ModelContact > m_spChart2ModelContact; + ::cppu::OInterfaceContainerHelper m_aEventListenerContainer; + + rtl::OUString m_aPropertySetName; + ::com::sun::star::uno::Reference< + ::com::sun::star::beans::XPropertySetInfo > + m_xInfo;//outer PropertySetInfo + ::boost::shared_ptr< ::cppu::OPropertyArrayHelper > m_pPropertyArrayHelper; + +// WrappedFillGradientNameProperty m_aWrappedFillGradientNameProperty; +// WrappedFillHatchNameProperty m_aWrappedFillHatchNameProperty; +// WrappedFillBitmapNameProperty m_aWrappedFillBitmapNameProperty; +// WrappedFillTransparenceGradientNameProperty m_aWrappedFillTransparenceGradientNameProperty; +// WrappedLineDashNameProperty m_aWrappedLineDashNameProperty; +}; + +} // namespace wrapper +} // namespace chart + +// CHART_UPDOWNBARWRAPPER_HXX +#endif |