LCOV - code coverage report
Current view: top level - svx/source/sdr/properties - connectorproperties.cxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 18 23 78.3 %
Date: 2015-06-13 12:38:46 Functions: 8 10 80.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 <sdr/properties/connectorproperties.hxx>
      21             : #include <svl/itemset.hxx>
      22             : #include <svl/style.hxx>
      23             : #include <svx/svddef.hxx>
      24             : #include <editeng/eeitem.hxx>
      25             : #include <svx/svdoedge.hxx>
      26             : 
      27             : 
      28             : 
      29             : namespace sdr
      30             : {
      31             :     namespace properties
      32             :     {
      33             :         // create a new itemset
      34          33 :         SfxItemSet* ConnectorProperties::CreateObjectSpecificItemSet(SfxItemPool& rPool)
      35             :         {
      36             :             return new SfxItemSet(rPool,
      37             : 
      38             :                 // range from SdrAttrObj
      39             :                 SDRATTR_START, SDRATTR_SHADOW_LAST,
      40             :                 SDRATTR_MISC_FIRST, SDRATTR_MISC_LAST,
      41             :                 SDRATTR_TEXTDIRECTION, SDRATTR_TEXTDIRECTION,
      42             : 
      43             :                 // range from SdrEdgeObj
      44             :                 SDRATTR_EDGE_FIRST, SDRATTR_EDGE_LAST,
      45             : 
      46             :                 // range from SdrTextObj
      47             :                 EE_ITEMS_START, EE_ITEMS_END,
      48             : 
      49             :                 // end
      50          33 :                 0, 0);
      51             :         }
      52             : 
      53          33 :         ConnectorProperties::ConnectorProperties(SdrObject& rObj)
      54          33 :         :   TextProperties(rObj)
      55             :         {
      56          33 :         }
      57             : 
      58           0 :         ConnectorProperties::ConnectorProperties(const ConnectorProperties& rProps, SdrObject& rObj)
      59           0 :         :   TextProperties(rProps, rObj)
      60             :         {
      61           0 :         }
      62             : 
      63          66 :         ConnectorProperties::~ConnectorProperties()
      64             :         {
      65          66 :         }
      66             : 
      67           0 :         BaseProperties& ConnectorProperties::Clone(SdrObject& rObj) const
      68             :         {
      69           0 :             return *(new ConnectorProperties(*this, rObj));
      70             :         }
      71             : 
      72          78 :         void ConnectorProperties::ItemSetChanged(const SfxItemSet& rSet)
      73             :         {
      74          78 :             SdrEdgeObj& rObj = static_cast<SdrEdgeObj&>(GetSdrObject());
      75             : 
      76             :             // call parent
      77          78 :             TextProperties::ItemSetChanged(rSet);
      78             : 
      79             :             // local changes
      80          78 :             rObj.ImpSetAttrToEdgeInfo();
      81          78 :         }
      82             : 
      83          35 :         void ConnectorProperties::SetStyleSheet(SfxStyleSheet* pNewStyleSheet, bool bDontRemoveHardAttr)
      84             :         {
      85          35 :             SdrEdgeObj& rObj = static_cast<SdrEdgeObj&>(GetSdrObject());
      86             : 
      87             :             // call parent
      88          35 :             TextProperties::SetStyleSheet(pNewStyleSheet, bDontRemoveHardAttr);
      89             : 
      90             :             // local changes
      91          35 :             rObj.ImpSetAttrToEdgeInfo();
      92          35 :         }
      93             :     } // end of namespace properties
      94         435 : } // end of namespace sdr
      95             : 
      96             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11