LCOV - code coverage report
Current view: top level - sc/source/ui/inc - dpgroupdlg.hxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 0 5 0.0 %
Date: 2014-11-03 Functions: 0 9 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 INCLUDED_SC_SOURCE_UI_INC_DPGROUPDLG_HXX
      21             : #define INCLUDED_SC_SOURCE_UI_INC_DPGROUPDLG_HXX
      22             : 
      23             : #include <vcl/fixed.hxx>
      24             : #include <vcl/dialog.hxx>
      25             : #include <vcl/button.hxx>
      26             : #include <vcl/field.hxx>
      27             : #include <svx/checklbx.hxx>
      28             : #include "editfield.hxx"
      29             : #include "dpgroup.hxx"
      30             : 
      31             : class ScDPGroupEditHelper
      32             : {
      33             : public:
      34             :     explicit            ScDPGroupEditHelper(
      35             :                             RadioButton* rRbAuto, RadioButton* rRbMan,
      36             :                             Edit* rEdValue );
      37             : 
      38             :     bool                IsAuto() const;
      39             :     double              GetValue() const;
      40             :     void                SetValue( bool bAuto, double fValue );
      41             : 
      42             : protected:
      43           0 :     ~ScDPGroupEditHelper() {}
      44             : 
      45             : private:
      46             :     virtual bool        ImplGetValue( double& rfValue ) const = 0;
      47             :     virtual void        ImplSetValue( double fValue ) = 0;
      48             : 
      49             :     DECL_LINK( ClickHdl, RadioButton* );
      50             : 
      51             : private:
      52             :     RadioButton*        mpRbAuto;
      53             :     RadioButton*        mpRbMan;
      54             :     Edit*               mpEdValue;
      55             : };
      56             : 
      57             : class ScDPNumGroupEditHelper : public ScDPGroupEditHelper
      58             : {
      59             : public:
      60             :     explicit            ScDPNumGroupEditHelper(
      61             :                             RadioButton* pRbAuto, RadioButton* pRbMan,
      62             :                             ScDoubleField* pEdValue );
      63             : 
      64           0 :     virtual ~ScDPNumGroupEditHelper() {}
      65             : 
      66             : private:
      67             :     virtual bool        ImplGetValue( double& rfValue ) const SAL_OVERRIDE;
      68             :     virtual void        ImplSetValue( double fValue ) SAL_OVERRIDE;
      69             : 
      70             : private:
      71             :     ScDoubleField*      mpEdValue;
      72             : };
      73             : 
      74             : class ScDPDateGroupEditHelper : public ScDPGroupEditHelper
      75             : {
      76             : public:
      77             :     explicit            ScDPDateGroupEditHelper(
      78             :                             RadioButton* pRbAuto, RadioButton* pRbMan,
      79             :                             DateField* pEdValue, const Date& rNullDate );
      80             : 
      81           0 :     virtual ~ScDPDateGroupEditHelper() {}
      82             : 
      83             : private:
      84             :     virtual bool        ImplGetValue( double& rfValue ) const SAL_OVERRIDE;
      85             :     virtual void        ImplSetValue( double fValue ) SAL_OVERRIDE;
      86             : 
      87             : private:
      88             :     DateField*          mpEdValue;
      89             :     Date                maNullDate;
      90             : };
      91             : 
      92           0 : class ScDPNumGroupDlg : public ModalDialog
      93             : {
      94             : public:
      95             :     explicit            ScDPNumGroupDlg( vcl::Window* pParent, const ScDPNumGroupInfo& rInfo );
      96             : 
      97             :     ScDPNumGroupInfo    GetGroupInfo() const;
      98             : 
      99             : private:
     100             :     RadioButton*         mpRbAutoStart;
     101             :     RadioButton*         mpRbManStart;
     102             :     ScDoubleField*       mpEdStart;
     103             :     RadioButton*         mpRbAutoEnd;
     104             :     RadioButton*         mpRbManEnd;
     105             :     ScDoubleField*       mpEdEnd;
     106             :     ScDoubleField*       mpEdBy;
     107             :     ScDPNumGroupEditHelper maStartHelper;
     108             :     ScDPNumGroupEditHelper maEndHelper;
     109             : };
     110             : 
     111           0 : class ScDPDateGroupDlg : public ModalDialog
     112             : {
     113             : public:
     114             :     explicit            ScDPDateGroupDlg( vcl::Window* pParent, const ScDPNumGroupInfo& rInfo,
     115             :                             sal_Int32 nDatePart, const Date& rNullDate );
     116             : 
     117             :     ScDPNumGroupInfo    GetGroupInfo() const;
     118             :     sal_Int32           GetDatePart() const;
     119             : 
     120             : private:
     121             :     DECL_LINK( ClickHdl, RadioButton* );
     122             :     DECL_LINK( CheckHdl, SvxCheckListBox* );
     123             : 
     124             : private:
     125             :     RadioButton*         mpRbAutoStart;
     126             :     RadioButton*         mpRbManStart;
     127             :     DateField*           mpEdStart;
     128             :     RadioButton*         mpRbAutoEnd;
     129             :     RadioButton*         mpRbManEnd;
     130             :     DateField*           mpEdEnd;
     131             :     RadioButton*         mpRbNumDays;
     132             :     RadioButton*         mpRbUnits;
     133             :     NumericField*        mpEdNumDays;
     134             :     SvxCheckListBox*     mpLbUnits;
     135             :     OKButton*            mpBtnOk;
     136             :     ScDPDateGroupEditHelper maStartHelper;
     137             :     ScDPDateGroupEditHelper maEndHelper;
     138             : };
     139             : 
     140             : #endif
     141             : 
     142             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10