LCOV - code coverage report
Current view: top level - sc/source/ui/inc - prevwsh.hxx (source / functions) Hit Total Coverage
Test: commit c8344322a7af75b84dd3ca8f78b05543a976dfd5 Lines: 2 4 50.0 %
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             : #ifndef INCLUDED_SC_SOURCE_UI_INC_PREVWSH_HXX
      21             : #define INCLUDED_SC_SOURCE_UI_INC_PREVWSH_HXX
      22             : 
      23             : class ScrollBar;
      24             : 
      25             : #include "address.hxx"
      26             : #include <sfx2/viewfac.hxx>
      27             : #include <sfx2/viewsh.hxx>
      28             : #include <sfx2/zoomitem.hxx>
      29             : 
      30             : #include "shellids.hxx"
      31             : 
      32             : class ScDocument;
      33             : class ScDocShell;
      34             : class ScPreview;
      35             : struct ScHeaderFieldData;
      36             : class ScPreviewLocationData;
      37             : class CommandEvent;
      38             : 
      39             : class ScPreviewShell: public SfxViewShell
      40             : {
      41             :     ScDocShell*     pDocShell;
      42             : 
      43             :     VclPtr<SystemWindow>   mpFrameWindow;
      44             :     VclPtr<ScPreview>      pPreview;               // Output window
      45             :     VclPtr<ScrollBar>      pHorScroll;
      46             :     VclPtr<ScrollBar>      pVerScroll;
      47             :     VclPtr<vcl::Window>    pCorner;
      48             : 
      49             :     ::com::sun::star::uno::Sequence< ::com::sun::star::beans::PropertyValue > aSourceData;  // ViewData
      50             :     TriState        nSourceDesignMode;      // form design mode from TabView
      51             :     SvxZoomType     eZoom;
      52             :     long            nMaxVertPos;
      53             : 
      54             :     SfxBroadcaster* pAccessibilityBroadcaster;
      55             :     bool            GetPageSize( Size& aPageSize );
      56             : private:
      57             :     void            Construct( vcl::Window* pParent );
      58             :     DECL_LINK(ScrollHandler, ScrollBar* );
      59             :     DECL_LINK(CloseHdl, SystemWindow*);
      60             :     void            DoScroll( sal_uInt16 nMode );
      61             :     void ExitPreview();
      62             : 
      63             : protected:
      64             :     virtual void    Activate(bool bMDI) SAL_OVERRIDE;
      65             :     virtual void    Deactivate(bool bMDI) SAL_OVERRIDE;
      66             :     virtual void    AdjustPosSizePixel( const Point &rPos, const Size &rSize ) SAL_OVERRIDE;
      67             : 
      68             :     virtual void    InnerResizePixel( const Point &rOfs, const Size &rSize ) SAL_OVERRIDE;
      69             :     virtual void    OuterResizePixel( const Point &rOfs, const Size &rSize ) SAL_OVERRIDE;
      70             : 
      71             :     virtual void    WriteUserData(OUString &, bool bBrowse = false) SAL_OVERRIDE;
      72             :     virtual void    ReadUserData(const OUString &, bool bBrowse = false) SAL_OVERRIDE;
      73             : 
      74             :     virtual void    WriteUserDataSequence (::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, bool bBrowse = false ) SAL_OVERRIDE;
      75             :     virtual void    ReadUserDataSequence (const ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >&, bool bBrowse = false ) SAL_OVERRIDE;
      76             : 
      77             : public:
      78             :                     TYPEINFO_VISIBILITY_OVERRIDE( SC_DLLPUBLIC );
      79          52 :                     SFX_DECL_INTERFACE(SCID_PREVIEW_SHELL)
      80          52 :                     SFX_DECL_VIEWFACTORY(ScPreviewShell);
      81             : 
      82             : private:
      83             :     /// SfxInterface initializer.
      84             :     static void InitInterface_Impl();
      85             : 
      86             : public:
      87             :                     ScPreviewShell( SfxViewFrame*           pViewFrame,
      88             :                                     SfxViewShell*           pOldSh );
      89             : 
      90             :     virtual         ~ScPreviewShell();
      91             : 
      92             :     void            InitStartTable(SCTAB nTab);
      93             : 
      94             :     void            UpdateScrollBars();
      95             :     void            UpdateNeededScrollBars(bool bFromZoom = false);
      96             :     bool            ScrollCommand( const CommandEvent& rCEvt );
      97             : 
      98             :     void            Execute( SfxRequest& rReq );
      99             :     void            GetState( SfxItemSet& rSet );
     100             : 
     101             :     void            FillFieldData( ScHeaderFieldData& rData );
     102             : 
     103             :     ::com::sun::star::uno::Sequence < ::com::sun::star::beans::PropertyValue >
     104             :                     GetSourceData() const       { return aSourceData; }
     105           0 :     TriState        GetSourceDesignMode() const { return nSourceDesignMode; }
     106             : 
     107             :     virtual void Notify( SfxBroadcaster& rBC, const SfxHint& rHint ) SAL_OVERRIDE;
     108             : 
     109             :     virtual SfxPrinter*     GetPrinter( bool bCreate = false ) SAL_OVERRIDE;
     110             :     virtual sal_uInt16      SetPrinter( SfxPrinter* pNewPrinter, SfxPrinterChangeFlags nDiffFlags = SFX_PRINTER_ALL, bool bIsAPI=false ) SAL_OVERRIDE;
     111             :     virtual bool            HasPrintOptionsPage() const SAL_OVERRIDE;
     112             :     virtual VclPtr<SfxTabPage> CreatePrintOptionsPage( vcl::Window *pParent, const SfxItemSet &rOptions ) SAL_OVERRIDE;
     113             : 
     114             :     void    AddAccessibilityObject( SfxListener& rObject );
     115             :     void    RemoveAccessibilityObject( SfxListener& rObject );
     116             :     void    BroadcastAccessibility( const SfxHint &rHint );
     117             :     bool    HasAccessibilityObjects();
     118             : 
     119             :     const ScPreviewLocationData& GetLocationData();
     120             :     ScDocument&     GetDocument();
     121           0 :     SC_DLLPUBLIC ScPreview*      GetPreview() { return pPreview; }
     122             : };
     123             : 
     124             : #endif
     125             : 
     126             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.11