/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ /* * This file is part of the LibreOffice project. * * This Source Code Form is subject to the terms of the Mozilla Public * License, v. 2.0. If a copy of the MPL was not distributed with this * file, You can obtain one at http://mozilla.org/MPL/2.0/. * * This file incorporates work covered by the following license notice: * * Licensed to the Apache Software Foundation (ASF) under one or more * contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright * ownership. The ASF licenses this file to you under the Apache * License, Version 2.0 (the "License"); you may not use this file * except in compliance with the License. You may obtain a copy of * the License at http://www.apache.org/licenses/LICENSE-2.0 . */ #ifndef INCLUDED_SC_INC_SHAPEUNO_HXX #define INCLUDED_SC_INC_SHAPEUNO_HXX #include #include #include #include #include #include #include #include #include #include namespace com { namespace sun { namespace star { namespace uno { class XAggregation; } namespace drawing { class XShape; } }}} class SdrObject; struct SvEventDescription; class ShapeUnoEventAccessImpl; class ScMacroInfo; // object which aggregates all svx shape objects, // to add own properties typedef ::cppu::WeakImplHelper5 < ::com::sun::star::beans::XPropertySet , ::com::sun::star::beans::XPropertyState , ::com::sun::star::text::XTextContent , ::com::sun::star::document::XEventsSupplier , ::com::sun::star::lang::XServiceInfo > ScShapeObj_Base; typedef ::cppu::ImplHelper1 < ::com::sun::star::text::XText > ScShapeObj_TextBase; typedef ::cppu::ImplHelper1 < ::com::sun::star::container::XChild > ScShapeObj_ChildBase; class ScShapeObj :public ScShapeObj_Base ,public ScShapeObj_TextBase ,public ScShapeObj_ChildBase { private: friend ScMacroInfo* ScShapeObj_getShapeHyperMacroInfo( ScShapeObj* pShape, bool bCreate ); ::com::sun::star::uno::Reference< ::com::sun::star::uno::XAggregation > mxShapeAgg; // cached pointers to avoid repeated queryAggregation calls: ::com::sun::star::beans::XPropertySet* pShapePropertySet; ::com::sun::star::beans::XPropertyState* pShapePropertyState; ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > mxPropSetInfo; bool bIsTextShape; bool bIsNoteCaption; bool bInitializedNotifier; SdrObject* GetSdrObject() const throw(); void GetShapePropertySet(); void GetShapePropertyState(); friend class ShapeUnoEventAccessImpl; public: static const SvEventDescription* GetSupportedMacroItems(); // ctor modifies xShape parameter ScShapeObj( ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XShape > & xShape ); virtual ~ScShapeObj(); // XInterface virtual ::com::sun::star::uno::Any SAL_CALL queryInterface( const ::com::sun::star::uno::Type & rType ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL acquire() throw() SAL_OVERRIDE; virtual void SAL_CALL release() throw() SAL_OVERRIDE; // XPropertySet virtual ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySetInfo > SAL_CALL getPropertySetInfo() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL setPropertyValue( const 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, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Any SAL_CALL getPropertyValue( const OUString& PropertyName ) throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL addPropertyChangeListener( const 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, std::exception) SAL_OVERRIDE; virtual void SAL_CALL removePropertyChangeListener( const 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, std::exception) SAL_OVERRIDE; virtual void SAL_CALL addVetoableChangeListener( const 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, std::exception) SAL_OVERRIDE; virtual void SAL_CALL removeVetoableChangeListener( const 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, std::exception) SAL_OVERRIDE; // XPropertyState virtual ::com::sun::star::beans::PropertyState SAL_CALL getPropertyState( const OUString& PropertyName ) throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyState > SAL_CALL getPropertyStates( const ::com::sun::star::uno::Sequence< OUString >& aPropertyName ) throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL setPropertyToDefault( const OUString& PropertyName ) throw (::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Any SAL_CALL getPropertyDefault( const OUString& aPropertyName ) throw(::com::sun::star::beans::UnknownPropertyException, ::com::sun::star::lang::WrappedTargetException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XTextContent virtual void SAL_CALL attach(const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > & xTextRange) throw( ::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > SAL_CALL getAnchor() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XComponent virtual void SAL_CALL dispose(void) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; virtual void SAL_CALL addEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & aListener) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; virtual void SAL_CALL removeEventListener(const ::com::sun::star::uno::Reference< ::com::sun::star::lang::XEventListener > & aListener) throw( ::com::sun::star::uno::RuntimeException, std::exception ) SAL_OVERRIDE; // XText virtual void SAL_CALL insertTextContent( const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange >& xRange, const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent >& xContent, sal_Bool bAbsorb ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL removeTextContent( const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextContent >& xContent ) throw(::com::sun::star::container::NoSuchElementException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XSimpleText virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > SAL_CALL createTextCursor() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextCursor > SAL_CALL createTextCursorByRange( const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange >& aTextPosition ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL insertString( const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange >& xRange, const OUString& aString, sal_Bool bAbsorb ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL insertControlCharacter( const ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange >& xRange, sal_Int16 nControlCharacter, sal_Bool bAbsorb ) throw(::com::sun::star::lang::IllegalArgumentException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XTextRange virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XText > SAL_CALL getText() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > SAL_CALL getStart() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Reference< ::com::sun::star::text::XTextRange > SAL_CALL getEnd() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual OUString SAL_CALL getString() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL setString( const OUString& aString ) throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XChild virtual ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface > SAL_CALL getParent() throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual void SAL_CALL setParent( const ::com::sun::star::uno::Reference< ::com::sun::star::uno::XInterface >& xParent ) throw (::com::sun::star::lang::NoSupportException, ::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XTypeProvider virtual ::com::sun::star::uno::Sequence< ::com::sun::star::uno::Type > SAL_CALL getTypes() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Sequence< sal_Int8 > SAL_CALL getImplementationId() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XEventsSupplier virtual ::com::sun::star::uno::Reference< ::com::sun::star::container::XNameReplace > SAL_CALL getEvents() throw(::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; // XServiceInfo virtual OUString SAL_CALL getImplementationName( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE ; virtual sal_Bool SAL_CALL supportsService( const OUString& ServiceName ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; virtual ::com::sun::star::uno::Sequence< OUString > SAL_CALL getSupportedServiceNames( ) throw (::com::sun::star::uno::RuntimeException, std::exception) SAL_OVERRIDE; }; #endif /* vim:set shiftwidth=4 softtabstop=4 expandtab: */ value='feature/droid_calimpress4'>feature/droid_calimpress4 main, development code repositoryroot
summaryrefslogtreecommitdiff
AgeCommit message (Expand)AuthorFilesLines
2016-03-11tdf#91794 remove OSL_DEBUG_LEVEL > 1 conditionalsRohan Kumar1-21/+3
2016-02-09Remove excess newlinesChris Sherlock1-6/+0
2015-11-10loplugin:nullptr (automatic rewrite)Stephan Bergmann1-4/+4
2015-11-09new loplugin: oncevarNoel Grandin1-4/+2
2015-11-06loplugin:stringconstant: elide explicit ctor usage (automatic rewrite)Stephan Bergmann1-3/+3
2015-10-30use uno::Reference::set method instead of assignmentNoel Grandin1-1/+1
2015-10-12Replace "SAL_OVERRIDE" with "override" in LIBO_INTERNAL_ONLY codeStephan Bergmann1-2/+2
2015-07-17tdf#88206 replace cppu::WeakImplHelper* etc.Takeshi Abe1-3/+3
2015-05-29loplugin:loopvartoosmallNoel Grandin1-1/+1
2015-03-29Clean up template-parameter-dependent C-style castsStephan Bergmann1-1/+1
2014-12-12cpputools: Use appropriate OUString functions on string constantsStephan Bergmann1-6/+2
2014-11-05markup with event type not checker typeCaolán McNamara1-1/+1
2014-10-28coverity#982593 experiment with silencing Infinite loopCaolán McNamara1-0/+1
2014-05-29remove more unnecesary OUString constructor useNoel Grandin1-2/+2
2014-05-27remove unnecessary use of OUString constructor when throwingNoel Grandin1-2/+2
2014-05-23remove boilerplate in UNO Exception constructor callsNoel Grandin1-1/+1
2014-05-23add default value for Context param in uno::Exception constructorsNoel Grandin1-26/+14
2014-05-08various: sal_Bool->boolNoel Grandin2-21/+21
2014-03-26First batch of adding SAL_OVERRRIDE to overriding function declarationsStephan Bergmann1-2/+2
2014-02-26cppuhelper: retrofit std::exception into overriding exception specsStephan Bergmann1-4/+4
2013-11-22remove unnecessary use of OUString constructor in equalsIgnoreAsciiCaseNoel Grandin1-1/+1
2013-11-11convert OUString compareToAscii == 0 to equalsAsciiNoel Grandin1-6/+6
2013-10-31Convert indexOf->startsWith and lastIndexOf->endsWithNoel Grandin1-2/+2
2013-10-23remove RTL_CONSTASCII_(U)STRINGPARAMChr. Rossmanith1-41/+24
2013-10-01Remove odd "bootstrapping" of acceptor/connector/binaryurp componentsStephan Bergmann1-43/+0
2013-06-29remove OUString wrap for string literalsThomas Arnhold1-3/+3
2013-06-15gbuild: allow to use RepositoryFixes also for executablesMatúš Kukan2-21/+0
2013-06-10fdo#46808, Use service constructor for connection::AcceptorNoel Grandin1-5/+2
2013-05-06fdo#62475 - remove ASCII artPhilipp Riemer1-36/+9
2013-05-06cleanup whitespaces due to RTL_CONSTASCII_USTRINGPARAM removalPhilipp Riemer1-5/+2
2013-05-06remove usage of RTL_CONSTASCII_USTRINGPARAMLuboš Luňák1-4/+4
2013-04-30Move to MPLv2 license headers, with ESC decision and author's permission.Michael Meeks3-63/+12
2013-04-22Move to MPLv2 license headers, with ESC decision and author's permission.Michael Meeks1-22/+4
2013-04-07mass removal of rtl:: prefixes for O(U)String*Luboš Luňák1-4/+0
2013-03-19removal of RTL_CONSTASCII_USTRINGPARAM for quoted OUStrings declarationsThomas Arnhold1-3/