LCOV - code coverage report
Current view: top level - usr/local/src/libreoffice/sc/source/ui/inc - sortkeydlg.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             : 
      10             : #ifndef SC_SORTKEYDLG_HXX
      11             : #define SC_SORTKEYDLG_HXX
      12             : 
      13             : #include <boost/ptr_container/ptr_vector.hpp>
      14             : 
      15             : #include "anyrefdg.hxx"
      16             : #include "sortdlg.hrc"
      17             : 
      18             : #include <vcl/edit.hxx>
      19             : #include <vcl/fixed.hxx>
      20             : #include <vcl/layout.hxx>
      21             : #include <vcl/lstbox.hxx>
      22             : #include <vcl/scrbar.hxx>
      23             : #include <vcl/ctrl.hxx>
      24             : #include <svtools/stdctrl.hxx>
      25             : #include <svx/langbox.hxx>
      26             : 
      27             : // =======================================================================
      28             : 
      29           0 : struct ScSortKeyItem : public VclBuilderContainer
      30             : {
      31             :     VclFrame*       m_pFrame;
      32             :     FixedText*      m_pFlSort;
      33             :     ListBox*        m_pLbSort;
      34             :     RadioButton*    m_pBtnUp;
      35             :     RadioButton*    m_pBtnDown;
      36             : 
      37             :     ScSortKeyItem(Window* pParent);
      38             : 
      39             :     void DisableField();
      40             :     void EnableField();
      41             : 
      42             :     long getItemHeight() const;
      43             : };
      44             : 
      45             : typedef boost::ptr_vector<ScSortKeyItem> ScSortKeyItems;
      46             : 
      47             : // =======================================================================
      48             : 
      49             : class ScSortKeyWindow
      50             : {
      51             : private:
      52             :     VclBox*         m_pBox;
      53             :     sal_Int32       nItemHeight;
      54             : 
      55             :     ScSortKeyItems& mrSortKeyItems;
      56             : 
      57             : public:
      58             :     ScSortKeyWindow(SfxTabPage* pParent, ScSortKeyItems& mrSortKeyItems);
      59             :     ~ScSortKeyWindow();
      60             : 
      61             :     void AddSortKey( sal_uInt16 nItem );
      62             :     void DoScroll( sal_Int32 nNewPos );
      63           0 :     sal_Int32 GetItemHeight() const { return nItemHeight; }
      64             :     sal_Int32 GetTotalHeight() const { return m_pBox->GetSizePixel().Height(); }
      65             : };
      66             : 
      67             : // =======================================================================
      68             : 
      69           0 : class ScSortKeyCtrl
      70             : {
      71             : private:
      72             :     ScSortKeyWindow  m_aSortWin;
      73             :     VclScrolledWindow& m_rScrolledWindow;
      74             :     ScrollBar&       m_rVertScroll;
      75             : 
      76             :     DECL_LINK(ScrollHdl, ScrollBar*);
      77             : 
      78             :     void checkAutoVScroll();
      79             : 
      80             : public:
      81             :     ScSortKeyCtrl(SfxTabPage* pParent, ScSortKeyItems& mrSortKeyItems);
      82             :     void setScrollRange();
      83             :     void AddSortKey( sal_uInt16 nItem );
      84             : };
      85             : 
      86             : #endif // SC_SORTKEYDLG_HXX
      87             : 
      88             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10