LCOV - code coverage report
Current view: top level - drawinglayer/source/primitive3d - polypolygonprimitive3d.cxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 4 13 30.8 %
Date: 2015-06-13 12:38:46 Functions: 2 4 50.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 <drawinglayer/primitive3d/polypolygonprimitive3d.hxx>
      21             : #include <basegfx/polygon/b3dpolypolygontools.hxx>
      22             : #include <basegfx/tools/canvastools.hxx>
      23             : #include <drawinglayer/primitive3d/drawinglayer_primitivetypes3d.hxx>
      24             : 
      25             : 
      26             : 
      27             : using namespace com::sun::star;
      28             : 
      29             : 
      30             : 
      31             : namespace drawinglayer
      32             : {
      33             :     namespace primitive3d
      34             :     {
      35       27969 :         PolyPolygonMaterialPrimitive3D::PolyPolygonMaterialPrimitive3D(
      36             :             const basegfx::B3DPolyPolygon& rPolyPolygon,
      37             :             const attribute::MaterialAttribute3D& rMaterial,
      38             :             bool bDoubleSided)
      39             :         :   BasePrimitive3D(),
      40             :             maPolyPolygon(rPolyPolygon),
      41             :             maMaterial(rMaterial),
      42       27969 :             mbDoubleSided(bDoubleSided)
      43             :         {
      44       27969 :         }
      45             : 
      46           0 :         bool PolyPolygonMaterialPrimitive3D::operator==(const BasePrimitive3D& rPrimitive) const
      47             :         {
      48           0 :             if(BasePrimitive3D::operator==(rPrimitive))
      49             :             {
      50           0 :                 const PolyPolygonMaterialPrimitive3D& rCompare = static_cast<const PolyPolygonMaterialPrimitive3D&>(rPrimitive);
      51             : 
      52           0 :                 return (getB3DPolyPolygon() == rCompare.getB3DPolyPolygon()
      53           0 :                     && getMaterial() == rCompare.getMaterial()
      54           0 :                     && getDoubleSided() == rCompare.getDoubleSided());
      55             :             }
      56             : 
      57           0 :             return false;
      58             :         }
      59             : 
      60           0 :         basegfx::B3DRange PolyPolygonMaterialPrimitive3D::getB3DRange(const geometry::ViewInformation3D& /*rViewInformation*/) const
      61             :         {
      62           0 :             return basegfx::tools::getRange(getB3DPolyPolygon());
      63             :         }
      64             : 
      65             :         // provide unique ID
      66       74908 :         ImplPrimitive3DIDBlock(PolyPolygonMaterialPrimitive3D, PRIMITIVE3D_ID_POLYPOLYGONMATERIALPRIMITIVE3D)
      67             : 
      68             :     } // end of namespace primitive3d
      69             : } // end of namespace drawinglayer
      70             : 
      71             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11