LCOV - code coverage report
Current view: top level - oox/source/shape - LockedCanvasContext.cxx (source / functions) Hit Total Coverage
Test: commit e02a6cb2c3e2b23b203b422e4e0680877f232636 Lines: 0 23 0.0 %
Date: 2014-04-14 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             : 
      10             : #include "LockedCanvasContext.hxx"
      11             : #include <oox/drawingml/shapegroupcontext.hxx>
      12             : 
      13             : using namespace com::sun::star;
      14             : 
      15             : namespace oox
      16             : {
      17             : namespace shape
      18             : {
      19             : 
      20           0 : LockedCanvasContext::LockedCanvasContext(ContextHandler2Helper& rParent)
      21           0 :     : ContextHandler2(rParent)
      22             : {
      23           0 : }
      24             : 
      25           0 : LockedCanvasContext::~LockedCanvasContext()
      26             : {
      27           0 : }
      28             : 
      29           0 : oox::drawingml::ShapePtr LockedCanvasContext::getShape()
      30             : {
      31           0 :     return mpShape;
      32             : }
      33             : 
      34           0 : ::oox::core::ContextHandlerRef LockedCanvasContext::onCreateContext(sal_Int32 aElementToken, const ::oox::AttributeList& /*rAttribs*/)
      35             : {
      36           0 :     switch (getBaseToken(aElementToken))
      37             :     {
      38             :     case XML_lockedCanvas:
      39           0 :         break;
      40             :     case XML_nvGrpSpPr:
      41           0 :         break;
      42             :     case XML_grpSpPr:
      43           0 :         break;
      44             :     case XML_sp:
      45             :     {
      46           0 :         oox::drawingml::ShapePtr pMasterShape;
      47           0 :         mpShape.reset(new oox::drawingml::Shape("com.sun.star.drawing.CustomShape"));
      48           0 :         mpShape->setLockedCanvas(true);
      49           0 :         return new oox::drawingml::ShapeContext(*this, pMasterShape, mpShape);
      50             :     }
      51             :     case XML_grpSp:
      52             :     {
      53           0 :         oox::drawingml::ShapePtr pMasterShape;
      54           0 :         mpShape.reset(new oox::drawingml::Shape("com.sun.star.drawing.GroupShape"));
      55           0 :         mpShape->setLockedCanvas(true);
      56           0 :         return new oox::drawingml::ShapeGroupContext(*this, pMasterShape, mpShape);
      57             :     }
      58             :     default:
      59             :         SAL_WARN("oox", "LockedCanvasContext::createFastChildContext: unhandled element:" << getBaseToken(aElementToken));
      60           0 :         break;
      61             :     }
      62           0 :     return 0;
      63             : }
      64             : 
      65             : }
      66           0 : }
      67             : 
      68             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10