LCOV - code coverage report
Current view: top level - usr/local/src/libreoffice/sd/source/ui/table - TableDesignPane.hxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 3 0.0 %
Date: 2013-07-09 Functions: 0 4 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             : #ifndef _SD_TABLEDESIGNPANE_HXX
      21             : #define _SD_TABLEDESIGNPANE_HXX
      22             : 
      23             : #include <com/sun/star/beans/XPropertySet.hpp>
      24             : #include <com/sun/star/ui/XUIElement.hpp>
      25             : #include <com/sun/star/ui/LayoutSize.hpp>
      26             : #include <com/sun/star/drawing/XDrawView.hpp>
      27             : #include <com/sun/star/container/XIndexAccess.hpp>
      28             : 
      29             : #include <vcl/dialog.hxx>
      30             : #include <vcl/fixed.hxx>
      31             : #include <vcl/button.hxx>
      32             : #include <sfx2/sidebar/ILayoutableWindow.hxx>
      33             : 
      34             : #include <boost/scoped_ptr.hpp>
      35             : 
      36             : #include "TableDesignPane.hrc"
      37             : 
      38             : namespace sd
      39             : {
      40             : 
      41             : namespace tools {
      42             : class EventMultiplexerEvent;
      43             : }
      44             : 
      45             : class ViewShellBase;
      46             : 
      47             : // --------------------------------------------------------------------
      48             : 
      49             : class TableDesignPane : public Control, public sfx2::sidebar::ILayoutableWindow
      50             : {
      51             : public:
      52             :     TableDesignPane( ::Window* pParent, ViewShellBase& rBase, bool bModal );
      53             :     virtual ~TableDesignPane();
      54             : 
      55             :     // callbacks
      56             :     void onSelectionChanged();
      57             : 
      58             :     // Control
      59             :     virtual void Resize();
      60             : 
      61             :     // ILayoutableWindow
      62             :     virtual ::com::sun::star::ui::LayoutSize GetHeightForWidth (const sal_Int32 nWidth);
      63             : 
      64             :     virtual void    DataChanged( const DataChangedEvent& rDCEvt );
      65             : 
      66             :     void ApplyOptions();
      67             :     void ApplyStyle();
      68             : 
      69           0 :     bool isStyleChanged() const { return mbStyleSelected; }
      70           0 :     bool isOptionsChanged() const { return mbOptionsChanged; }
      71             : 
      72             : private:
      73             :     void addListener();
      74             :     void removeListener();
      75             :     void updateLayout();
      76             :     void updateControls();
      77             : 
      78             :     void FillDesignPreviewControl();
      79             : 
      80             :     DECL_LINK(EventMultiplexerListener, tools::EventMultiplexerEvent*);
      81             :     DECL_LINK(implValueSetHdl, void *);
      82             :     DECL_LINK(implCheckBoxHdl, void *);
      83             : 
      84             : private:
      85             :     ViewShellBase& mrBase;
      86             :     const OUString msTableTemplate;
      87             : 
      88             :     boost::scoped_ptr< Control > mxControls[DESIGNPANE_CONTROL_COUNT];
      89             :     int mnOrgOffsetY[DESIGNPANE_CONTROL_COUNT];
      90             : 
      91             :     ::com::sun::star::uno::Reference< ::com::sun::star::beans::XPropertySet > mxSelectedTable;
      92             :     ::com::sun::star::uno::Reference< ::com::sun::star::drawing::XDrawView > mxView;
      93             :     ::com::sun::star::uno::Reference< ::com::sun::star::container::XIndexAccess > mxTableFamily;
      94             :     ::com::sun::star::uno::Reference< ::com::sun::star::ui::XUIElement > mxToolbar;
      95             : 
      96             :     bool mbModal;
      97             :     bool mbStyleSelected;
      98             :     bool mbOptionsChanged;
      99             : };
     100             : 
     101             : // --------------------------------------------------------------------
     102             : 
     103           0 : class TableDesignDialog : public ModalDialog
     104             : {
     105             : public:
     106             :     TableDesignDialog( ::Window* pParent, ViewShellBase& rBase );
     107             : 
     108             :     virtual short Execute();
     109             : private:
     110             :     boost::scoped_ptr< TableDesignPane > mpDesignPane;
     111             : 
     112             :     boost::scoped_ptr< FixedLine >       mxFlSep1;
     113             :     boost::scoped_ptr< FixedLine >       mxFlSep2;
     114             :     boost::scoped_ptr< HelpButton >      mxHelpButton;
     115             :     boost::scoped_ptr< OKButton >        mxOkButton;
     116             :     boost::scoped_ptr< CancelButton >    mxCancelButton;
     117             : };
     118             : 
     119             : }
     120             : 
     121             : #endif // _SD_TABLEFORMATPANE_HXX
     122             : 
     123             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10