LCOV - code coverage report
Current view: top level - libreoffice/sw/source/core/access - accgraphic.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 18 0.0 %
Date: 2012-12-27 Functions: 0 7 0.0 %
Legend: Lines: hit not hit

          Line data    Source code
       1             : /* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
       2             : /*
       3             :  * This file is part of the LibreOffice project.
       4             :  *
       5             :  * This Source Code Form is subject to the terms of the Mozilla Public
       6             :  * License, v. 2.0. If a copy of the MPL was not distributed with this
       7             :  * file, You can obtain one at http://mozilla.org/MPL/2.0/.
       8             :  *
       9             :  * This file incorporates work covered by the following license notice:
      10             :  *
      11             :  *   Licensed to the Apache Software Foundation (ASF) under one or more
      12             :  *   contributor license agreements. See the NOTICE file distributed
      13             :  *   with this work for additional information regarding copyright
      14             :  *   ownership. The ASF licenses this file to you under the Apache
      15             :  *   License, Version 2.0 (the "License"); you may not use this file
      16             :  *   except in compliance with the License. You may obtain a copy of
      17             :  *   the License at http://www.apache.org/licenses/LICENSE-2.0 .
      18             :  */
      19             : 
      20             : #include <vcl/svapp.hxx>
      21             : #include <com/sun/star/accessibility/AccessibleRole.hpp>
      22             : #include <com/sun/star/uno/RuntimeException.hpp>
      23             : #include <comphelper/servicehelper.hxx>
      24             : #include <flyfrm.hxx>
      25             : #include "accgraphic.hxx"
      26             : 
      27             : using namespace ::com::sun::star;
      28             : using namespace ::com::sun::star::lang;
      29             : using namespace ::com::sun::star::uno;
      30             : using namespace ::com::sun::star::accessibility;
      31             : using ::rtl::OUString;
      32             : 
      33             : const sal_Char sServiceName[] = "com.sun.star.text.AccessibleTextGraphicObject";
      34             : const sal_Char sImplementationName[] = "com.sun.star.comp.Writer.SwAccessibleGraphic";
      35             : 
      36           0 : SwAccessibleGraphic::SwAccessibleGraphic(
      37             :         SwAccessibleMap* pInitMap,
      38             :         const SwFlyFrm* pFlyFrm  ) :
      39           0 :     SwAccessibleNoTextFrame( pInitMap, AccessibleRole::GRAPHIC, pFlyFrm )
      40             : {
      41           0 : }
      42             : 
      43           0 : SwAccessibleGraphic::~SwAccessibleGraphic()
      44             : {
      45           0 : }
      46             : 
      47           0 : OUString SAL_CALL SwAccessibleGraphic::getImplementationName()
      48             :         throw( RuntimeException )
      49             : {
      50           0 :     return OUString(RTL_CONSTASCII_USTRINGPARAM(sImplementationName));
      51             : }
      52             : 
      53           0 : sal_Bool SAL_CALL SwAccessibleGraphic::supportsService(
      54             :         const ::rtl::OUString& sTestServiceName)
      55             :     throw (uno::RuntimeException)
      56             : {
      57             :     return sTestServiceName.equalsAsciiL( sServiceName,
      58           0 :                                           sizeof(sServiceName)-1 ) ||
      59             :            sTestServiceName.equalsAsciiL( sAccessibleServiceName,
      60           0 :                                              sizeof(sAccessibleServiceName)-1 );
      61             : }
      62             : 
      63           0 : Sequence< OUString > SAL_CALL SwAccessibleGraphic::getSupportedServiceNames()
      64             :         throw( uno::RuntimeException )
      65             : {
      66           0 :     Sequence< OUString > aRet(2);
      67           0 :     OUString* pArray = aRet.getArray();
      68           0 :     pArray[0] = OUString( RTL_CONSTASCII_USTRINGPARAM(sServiceName) );
      69           0 :     pArray[1] = OUString( RTL_CONSTASCII_USTRINGPARAM(sAccessibleServiceName) );
      70           0 :     return aRet;
      71             : }
      72             : 
      73             : namespace
      74             : {
      75             :     class theSwAccessibleGraphicImplementationId : public rtl::Static< UnoTunnelIdInit, theSwAccessibleGraphicImplementationId > {};
      76             : }
      77             : 
      78           0 : Sequence< sal_Int8 > SAL_CALL SwAccessibleGraphic::getImplementationId()
      79             :         throw(RuntimeException)
      80             : {
      81           0 :     return theSwAccessibleGraphicImplementationId::get().getSeq();
      82             : }
      83             : 
      84             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10