LCOV - code coverage report
Current view: top level - sd/source/ui/func - fuarea.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 25 0.0 %
Date: 2012-08-25 Functions: 0 10 0.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 0 44 0.0 %

           Branch data     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 "fuarea.hxx"
      21                 :            : 
      22                 :            : #include <svx/svxids.hrc>
      23                 :            : #include <vcl/msgbox.hxx>
      24                 :            : #include <svl/intitem.hxx>
      25                 :            : #include <svl/stritem.hxx>
      26                 :            : #include <sfx2/request.hxx>
      27                 :            : #include <sfx2/viewfrm.hxx>
      28                 :            : #include <sfx2/bindings.hxx>
      29                 :            : #include "ViewShell.hxx"
      30                 :            : 
      31                 :            : #include "drawdoc.hxx"
      32                 :            : #include "View.hxx"
      33                 :            : #include "Window.hxx"
      34                 :            : #include "app.hrc"
      35                 :            : #include <svx/svxdlg.hxx>
      36                 :            : #include <svx/dialogs.hrc>
      37                 :            : 
      38                 :            : namespace sd {
      39 [ #  # ][ #  # ]:          0 : TYPEINIT1( FuArea, FuPoor );
      40                 :            : 
      41                 :            : /*************************************************************************
      42                 :            : |*
      43                 :            : |* Konstruktor
      44                 :            : |*
      45                 :            : \************************************************************************/
      46                 :            : 
      47                 :          0 : FuArea::FuArea( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::View* _pView, SdDrawDocument* pDoc, SfxRequest& rReq)
      48                 :          0 : : FuPoor(pViewSh, pWin, _pView, pDoc, rReq)
      49                 :            : {
      50                 :          0 : }
      51                 :            : 
      52                 :          0 : FunctionReference FuArea::Create( ViewShell* pViewSh, ::sd::Window* pWin, ::sd::View* _pView, SdDrawDocument* pDoc, SfxRequest& rReq )
      53                 :            : {
      54 [ #  # ][ #  # ]:          0 :     FunctionReference xFunc( new FuArea( pViewSh, pWin, _pView, pDoc, rReq ) );
      55         [ #  # ]:          0 :     xFunc->DoExecute(rReq);
      56                 :          0 :     return xFunc;
      57                 :            : }
      58                 :            : 
      59                 :          0 : void FuArea::DoExecute( SfxRequest& rReq )
      60                 :            : {
      61                 :          0 :     const SfxItemSet* pArgs = rReq.GetArgs();
      62                 :            : 
      63         [ #  # ]:          0 :     if( !pArgs )
      64                 :            :     {
      65         [ #  # ]:          0 :         SfxItemSet aNewAttr( mpDoc->GetPool() );
      66         [ #  # ]:          0 :         mpView->GetAttributes( aNewAttr );
      67                 :            : 
      68         [ #  # ]:          0 :         SvxAbstractDialogFactory* pFact = SvxAbstractDialogFactory::Create();
      69                 :            :         AbstractSvxAreaTabDialog * pDlg = pFact ? pFact->CreateSvxAreaTabDialog( NULL,
      70                 :            :                                                                         &aNewAttr,
      71                 :            :                                                                         mpDoc,
      72 [ #  # ][ #  # ]:          0 :                                                                         mpView) : 0;
      73 [ #  # ][ #  # ]:          0 :         if( pDlg && (pDlg->Execute() == RET_OK) )
         [ #  # ][ #  # ]
      74                 :            :         {
      75 [ #  # ][ #  # ]:          0 :             mpView->SetAttributes (*(pDlg->GetOutputItemSet ()));
      76                 :            :         }
      77                 :            : 
      78                 :            :         // Attribute wurden geaendert, Listboxes in Objectbars muessen aktualisiert werden
      79                 :            :         static sal_uInt16 SidArray[] = {
      80                 :            :                         SID_ATTR_FILL_STYLE,
      81                 :            :                         SID_ATTR_FILL_COLOR,
      82                 :            :                         SID_ATTR_FILL_GRADIENT,
      83                 :            :                         SID_ATTR_FILL_HATCH,
      84                 :            :                         SID_ATTR_FILL_BITMAP,
      85                 :            :                         0 };
      86                 :            : 
      87 [ #  # ][ #  # ]:          0 :         mpViewShell->GetViewFrame()->GetBindings().Invalidate( SidArray );
      88                 :            : 
      89 [ #  # ][ #  # ]:          0 :         delete pDlg;
                 [ #  # ]
      90                 :            :     }
      91                 :            : 
      92                 :          0 :     rReq.Ignore ();
      93                 :            : 
      94                 :          0 : }
      95                 :            : 
      96                 :          0 : void FuArea::Activate()
      97                 :            : {
      98                 :          0 : }
      99                 :            : 
     100                 :          0 : void FuArea::Deactivate()
     101                 :            : {
     102                 :          0 : }
     103                 :            : 
     104                 :            : } // end of namespace sd
     105                 :            : 
     106                 :            : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10