LCOV - code coverage report
Current view: top level - libreoffice/sc/source/ui/view - prevwsh2.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 22 0.0 %
Date: 2012-12-27 Functions: 0 1 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             : // TOOLS
      21             : #define _BIGINT_HXX
      22             : #define _CACHESTR_HXX
      23             : #define _SVMEMPOOL_HXX
      24             : #define _CACHESTR_HXX
      25             : 
      26             : //SV
      27             : #define _CONFIG_HXX
      28             : #define _CURSOR_HXX
      29             : #define _HELP_HXX
      30             : #define _SPIN_HXX
      31             : #define _SOUND_HXX
      32             : 
      33             : //svtools
      34             : #define _SCRWIN_HXX
      35             : #define _RULER_HXX
      36             : #define _STDMENU_HXX
      37             : #define _CTRLTOOL_HXX
      38             : 
      39             : //SVTOOLS
      40             : #define _FILTER_HXX
      41             : #define _SVTABBX_HXX
      42             : 
      43             : //sfxcore.hxx
      44             : #define _SFXGENLINK_HXX
      45             : #define _SFXHINTPOST_HXX
      46             : #define _SFXDOCINF_HXX
      47             : 
      48             : // SFX
      49             : #define _SFXMSGPOOL_HXX
      50             : #define _PASSWD_HXX
      51             : #define _SFXTBXCTRL_HXX
      52             : #define _SFXSTBITEM_HXX
      53             : #define _SFXMNUITEM_HXX
      54             : #define _SFXIMGMGR_HXX
      55             : #define _SFX_MINFITEM_HXX
      56             : #define _SFXEVENT_HXX
      57             : 
      58             : //sfxdlg.hxx
      59             : #define _SFX_DINFDLG_HXX
      60             : #define _SFX_MGETEMPL_HXX
      61             : #define _SFX_TPLPITEM_HXX
      62             : #define _NEWSTYLE_HXX
      63             : #define _SFXDOCKWIN_HXX
      64             : 
      65             : //sfxitems.hxx
      66             : #define _SFXFLAGITEM_HXX
      67             : #define _SFXPTITEM_HXX
      68             : #define _SFXRECTITEM_HXX
      69             : #define _SFXITEMITER_HXX
      70             : #define _SFX_WHITER_HXX
      71             : #define _SFXPOOLCACH_HXX
      72             : #define _SFXRNGITEM_HXX
      73             : 
      74             : #define _SVX_HYPHEN_HXX
      75             : #define _SVX_OPTSAVE_HXX
      76             : #define _SVX_OPTPATH_HXX
      77             : #define _SVX_OPTLINGU_HXX
      78             : #define _SVX_RULER_HXX
      79             : #define _SVX_RULRITEM_HXX
      80             : #define _SVX_SPLWRAP_HXX
      81             : #define _SVX_THESDLG_HXX
      82             : 
      83             : #include <svx/svdmodel.hxx>
      84             : #include <svl/smplhint.hxx>
      85             : 
      86             : #include "prevwsh.hxx"
      87             : #include "docsh.hxx"
      88             : #include "preview.hxx"
      89             : #include "hints.hxx"
      90             : #include "sc.hrc"
      91             : 
      92             : // STATIC DATA -----------------------------------------------------------
      93             : 
      94             : // -----------------------------------------------------------------------
      95             : 
      96           0 : void ScPreviewShell::Notify( SfxBroadcaster&, const SfxHint& rHint )
      97             : {
      98           0 :     sal_Bool bDataChanged = false;
      99             : 
     100           0 :     if (rHint.ISA(SfxSimpleHint))
     101             :     {
     102           0 :         sal_uLong nSlot = ((const SfxSimpleHint&)rHint).GetId();
     103           0 :         switch ( nSlot )
     104             :         {
     105             :             case FID_DATACHANGED:
     106             :             case SID_SCPRINTOPTIONS:
     107           0 :                 bDataChanged = sal_True;
     108           0 :                 break;
     109             :             case SC_HINT_DRWLAYER_NEW:
     110             :                 {
     111           0 :                     SfxBroadcaster* pDrawBC = pDocShell->GetDocument()->GetDrawBroadcaster();
     112           0 :                     if (pDrawBC)
     113           0 :                         StartListening(*pDrawBC);
     114             :                 }
     115           0 :                 break;
     116             :         }
     117             :     }
     118           0 :     else if (rHint.ISA(ScPaintHint))
     119             :     {
     120           0 :         if ( ((const ScPaintHint&)rHint).GetPrintFlag() )
     121             :         {
     122           0 :             sal_uInt16 nParts = ((const ScPaintHint&)rHint).GetParts();
     123           0 :             if (nParts & ( PAINT_GRID | PAINT_LEFT | PAINT_TOP | PAINT_SIZE ))
     124           0 :                 bDataChanged = sal_True;
     125             :         }
     126             :     }
     127           0 :     else if (rHint.ISA(SdrHint))
     128             :     {
     129             :         // SdrHints are no longer used for invalidating, thus react on objectchange instead
     130           0 :         if(HINT_OBJCHG == ((const SdrHint&)rHint).GetKind())
     131           0 :             bDataChanged = sal_True;
     132             :     }
     133             : 
     134           0 :     if (bDataChanged)
     135           0 :         pPreview->DataChanged(sal_True);
     136           0 : }
     137             : 
     138             : 
     139             : 
     140             : 
     141             : 
     142             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10