LCOV - code coverage report
Current view: top level - usr/local/src/libreoffice/sc/source/ui/miscdlgs - inscldlg.cxx (source / functions) Hit Total Coverage
Test: libreoffice_filtered.info Lines: 0 37 0.0 %
Date: 2013-07-09 Functions: 0 6 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             : 
      21             : #undef SC_DLLIMPLEMENTATION
      22             : 
      23             : 
      24             : 
      25             : //------------------------------------------------------------------
      26             : 
      27             : #include "inscldlg.hxx"
      28             : #include "scresid.hxx"
      29             : #include "miscdlgs.hrc"
      30             : 
      31             : 
      32             : static sal_uInt8 nInsItemChecked=0;
      33             : 
      34             : //==================================================================
      35             : 
      36           0 : ScInsertCellDlg::ScInsertCellDlg( Window* pParent,sal_Bool bDisallowCellMove) :
      37           0 :     ModalDialog     ( pParent, "InsertCellsDialog", "modules/scalc/ui/insertcells.ui")
      38             : {
      39           0 :     get(m_pBtnCellsDown, "down");
      40           0 :     get(m_pBtnCellsRight, "right");
      41           0 :     get(m_pBtnInsRow, "rows");
      42           0 :     get(m_pBtnInsCol, "cols");
      43             : 
      44           0 :     if (bDisallowCellMove)
      45             :     {
      46           0 :         m_pBtnCellsDown->Disable();
      47           0 :         m_pBtnCellsRight->Disable();
      48           0 :         m_pBtnInsRow->Check();
      49             : 
      50           0 :         switch(nInsItemChecked)
      51             :         {
      52           0 :             case 2: m_pBtnInsRow->Check();break;
      53           0 :             case 3: m_pBtnInsCol->Check();break;
      54           0 :             default:m_pBtnInsRow->Check();break;
      55             :         }
      56             :     }
      57             :     else
      58             :     {
      59           0 :         switch(nInsItemChecked)
      60             :         {
      61           0 :             case 0: m_pBtnCellsDown->Check();break;
      62           0 :             case 1: m_pBtnCellsRight->Check();break;
      63           0 :             case 2: m_pBtnInsRow->Check();break;
      64           0 :             case 3: m_pBtnInsCol->Check();break;
      65             :         }
      66             :     }
      67           0 : }
      68             : 
      69             : //------------------------------------------------------------------------
      70             : 
      71           0 : InsCellCmd ScInsertCellDlg::GetInsCellCmd() const
      72             : {
      73           0 :     InsCellCmd nReturn = INS_NONE;
      74             : 
      75           0 :     if ( m_pBtnCellsDown->IsChecked() )
      76             :     {
      77           0 :         nInsItemChecked=0;
      78           0 :         nReturn = INS_CELLSDOWN;
      79             :     }
      80           0 :     else if ( m_pBtnCellsRight->IsChecked())
      81             :     {
      82           0 :         nInsItemChecked=1;
      83           0 :         nReturn = INS_CELLSRIGHT;
      84             :     }
      85           0 :     else if ( m_pBtnInsRow->IsChecked()   )
      86             :     {
      87           0 :         nInsItemChecked=2;
      88           0 :         nReturn = INS_INSROWS;
      89             :     }
      90           0 :     else if ( m_pBtnInsCol->IsChecked()   )
      91             :     {
      92           0 :         nInsItemChecked=3;
      93           0 :         nReturn = INS_INSCOLS;
      94             :     }
      95             : 
      96           0 :     return nReturn;
      97             : }
      98             : 
      99           0 : ScInsertCellDlg::~ScInsertCellDlg()
     100             : {
     101           0 : }
     102             : 
     103             : 
     104             : 
     105             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10