LCOV - code coverage report
Current view: top level - dbaccess/source/ui/inc - TableDesignControl.hxx (source / functions) Hit Total Coverage
Test: commit e02a6cb2c3e2b23b203b422e4e0680877f232636 Lines: 0 2 0.0 %
Date: 2014-04-14 Functions: 0 2 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             : #ifndef INCLUDED_DBACCESS_SOURCE_UI_INC_TABLEDESIGNCONTROL_HXX
      20             : #define INCLUDED_DBACCESS_SOURCE_UI_INC_TABLEDESIGNCONTROL_HXX
      21             : 
      22             : #include <svtools/tabbar.hxx>
      23             : #include <svtools/editbrowsebox.hxx>
      24             : 
      25             : #include "IClipBoardTest.hxx"
      26             : #include "TypeInfo.hxx"
      27             : 
      28             : namespace dbaui
      29             : {
      30             :     class OTableDesignView;
      31             : 
      32             :     class OTableRowView : public ::svt::EditBrowseBox, public IClipboardTest
      33             :     {
      34             :         friend class OTableDesignUndoAct;
      35             : 
      36             :     protected:
      37             :         long    m_nDataPos;    ///< currently needed row
      38             :         long    m_nCurrentPos; ///< current position of selected column
      39             : 
      40             :     private:
      41             :         sal_uInt16  m_nCurUndoActId;
      42             : 
      43             :     protected:
      44             :         sal_Bool    m_bCurrentModified;
      45             :         sal_Bool    m_bUpdatable;
      46             :         sal_Bool    m_bClipboardFilled;
      47             : 
      48             :     public:
      49             :         OTableRowView(Window* pParent);
      50             :         virtual ~OTableRowView();
      51             : 
      52             :         virtual void SetCellData( long nRow, sal_uInt16 nColId, const TOTypeInfoSP& _pTypeInfo ) = 0;
      53             :         virtual void SetCellData( long nRow, sal_uInt16 nColId, const ::com::sun::star::uno::Any& _rNewData ) = 0;
      54             :         virtual ::com::sun::star::uno::Any          GetCellData( long nRow, sal_uInt16 nColId ) = 0;
      55             :         virtual void SetControlText( long nRow, sal_uInt16 nColId, const OUString& rText ) = 0;
      56             :         virtual OUString GetControlText( long nRow, sal_uInt16 nColId ) = 0;
      57             : 
      58             :         virtual OTableDesignView* GetView() const = 0;
      59             : 
      60           0 :         sal_uInt16 GetCurUndoActId(){ return m_nCurUndoActId; }
      61             : 
      62             :         // IClipboardTest
      63             :         virtual void cut() SAL_OVERRIDE;
      64             :         virtual void copy() SAL_OVERRIDE;
      65             :         virtual void paste() SAL_OVERRIDE;
      66             : 
      67             :     protected:
      68             :         void Paste( long nRow );
      69             : 
      70             :         virtual void CopyRows()                             = 0;
      71             :         virtual void DeleteRows()                           = 0;
      72             :         virtual void InsertRows( long nRow )                = 0;
      73             :         virtual void InsertNewRows( long nRow )             = 0;
      74             : 
      75             :         virtual sal_Bool IsPrimaryKeyAllowed( long nRow )   = 0;
      76             :         virtual sal_Bool IsInsertNewAllowed( long nRow )    = 0;
      77             :         virtual sal_Bool IsDeleteAllowed( long nRow )       = 0;
      78             : 
      79           0 :         virtual sal_Bool IsUpdatable() const {return m_bUpdatable;}
      80             :         virtual void SetUpdatable( sal_Bool bUpdate=sal_True );
      81             : 
      82             :         virtual RowStatus GetRowStatus(long nRow) const SAL_OVERRIDE;
      83             :         virtual void KeyInput(const KeyEvent& rEvt) SAL_OVERRIDE;
      84             :         virtual void Command( const CommandEvent& rEvt ) SAL_OVERRIDE;
      85             : 
      86             :         virtual void Init() SAL_OVERRIDE;
      87             :     };
      88             : }
      89             : #endif
      90             : 
      91             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10