diff options
Diffstat (limited to 'sw/source/core/access/accembedded.cxx')
-rw-r--r-- | sw/source/core/access/accembedded.cxx | 64 |
1 files changed, 64 insertions, 0 deletions
diff --git a/sw/source/core/access/accembedded.cxx b/sw/source/core/access/accembedded.cxx index a3efadcd726a..48a123f1bcf7 100644 --- a/sw/source/core/access/accembedded.cxx +++ b/sw/source/core/access/accembedded.cxx @@ -31,6 +31,14 @@ #include <rtl/uuid.h> #include <flyfrm.hxx> #include "accembedded.hxx" +//IAccessibility2 Implementation 2009----- +#include "cntfrm.hxx" +#include "ndole.hxx" +#include <doc.hxx> +#include <docsh.hxx> +#include <../../ui/inc/wrtsh.hxx> +#include <../../ui/inc/view.hxx> +//-----IAccessibility2 Implementation 2009 using namespace ::com::sun::star; using namespace ::com::sun::star::lang; @@ -51,6 +59,34 @@ SwAccessibleEmbeddedObject::~SwAccessibleEmbeddedObject() { } +//IAccessibility2 Implementation 2009----- +//===== XInterface ========================================================== +com::sun::star::uno::Any SAL_CALL + SwAccessibleEmbeddedObject::queryInterface (const com::sun::star::uno::Type & rType) + throw (::com::sun::star::uno::RuntimeException) +{ + ::com::sun::star::uno::Any aReturn = SwAccessibleNoTextFrame::queryInterface (rType); + if ( ! aReturn.hasValue()) + aReturn = ::cppu::queryInterface (rType, + static_cast< ::com::sun::star::accessibility::XAccessibleExtendedAttributes* >(this) ); + return aReturn; +} + +void SAL_CALL + SwAccessibleEmbeddedObject::acquire (void) + throw () +{ + SwAccessibleNoTextFrame::acquire (); +} + +void SAL_CALL + SwAccessibleEmbeddedObject::release (void) + throw () +{ + SwAccessibleNoTextFrame::release (); +} +//-----IAccessibility2 Implementation 2009 + OUString SAL_CALL SwAccessibleEmbeddedObject::getImplementationName() throw( uno::RuntimeException ) { @@ -91,3 +127,31 @@ uno::Sequence< sal_Int8 > SAL_CALL SwAccessibleEmbeddedObject::getImplementation } return aId; } +//IAccessibility2 Implementation 2009----- +//===== XAccessibleExtendedAttributes ======================================================== +::com::sun::star::uno::Any SAL_CALL SwAccessibleEmbeddedObject::getExtendedAttributes() + throw (::com::sun::star::lang::IndexOutOfBoundsException, ::com::sun::star::uno::RuntimeException) +{ + ::com::sun::star::uno::Any strRet; + ::rtl::OUString style; + SwFlyFrm* pFFrm = getFlyFrm(); + + if( pFFrm ) + { + style = ::rtl::OUString::createFromAscii("style:"); + SwCntntFrm* pCFrm; + pCFrm = pFFrm->ContainsCntnt(); + if( pCFrm ) + { + SwCntntNode* pCNode = pCFrm->GetNode(); + if( pCNode ) + { + style += ((SwOLENode*)pCNode)->GetOLEObj().GetStyleString(); + } + } + style += ::rtl::OUString::createFromAscii(";"); + } + strRet <<= style; + return strRet; +} +//-----IAccessibility2 Implementation 2009 |