LCOV - code coverage report
Current view: top level - dbaccess/source/ui/dlg - detailpages.hxx (source / functions) Hit Total Coverage
Test: commit 10e77ab3ff6f4314137acd6e2702a6e5c1ce1fae Lines: 0 6 0.0 %
Date: 2014-11-03 Functions: 0 12 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_DBACCESS_SOURCE_UI_DLG_DETAILPAGES_HXX
      21             : #define INCLUDED_DBACCESS_SOURCE_UI_DLG_DETAILPAGES_HXX
      22             : 
      23             : #include "adminpages.hxx"
      24             : #include "charsets.hxx"
      25             : #include "charsetlistbox.hxx"
      26             : #include <vcl/field.hxx>
      27             : #include <vcl/fixed.hxx>
      28             : #include <vcl/lstbox.hxx>
      29             : #include <vcl/edit.hxx>
      30             : #include <vcl/button.hxx>
      31             : #include "TextConnectionHelper.hxx"
      32             : #include "admincontrols.hxx"
      33             : 
      34             : #include <svtools/dialogcontrolling.hxx>
      35             : 
      36             : namespace dbaui
      37             : {
      38             :     // OCommonBehaviourTabPage
      39             :     #define     CBTP_NONE                           0x00000000
      40             :     #define     CBTP_USE_CHARSET                    0x00000002
      41             :     #define     CBTP_USE_OPTIONS                    0x00000004
      42             : 
      43             :     /** eases the implementation of tab pages handling user/password and/or character
      44             :         set and/or generic options input
      45             :         <BR>
      46             :         The controls to be used have to be defined within the resource, as usual, but
      47             :         this class does all the handling necessary.
      48             :     */
      49             :     class OCommonBehaviourTabPage : public OGenericAdministrationPage
      50             :     {
      51             :     protected:
      52             : 
      53             :         FixedText*          m_pOptionsLabel;
      54             :         Edit*               m_pOptions;
      55             : 
      56             :         FixedText*          m_pCharsetLabel;
      57             :         CharSetListBox*     m_pCharset;
      58             : 
      59             :         CheckBox*           m_pAutoRetrievingEnabled;
      60             :         FixedText*          m_pAutoIncrementLabel;
      61             :         Edit*               m_pAutoIncrement;
      62             :         FixedText*          m_pAutoRetrievingLabel;
      63             :         Edit*               m_pAutoRetrieving;
      64             : 
      65             :         sal_uInt32          m_nControlFlags;
      66             : 
      67             :         bool                m_bDelete;
      68             : 
      69             :     public:
      70             :         virtual bool        FillItemSet (SfxItemSet* _rCoreAttrs) SAL_OVERRIDE;
      71             : 
      72             :         // nControlFlags is a combination of the CBTP_xxx-constants
      73             :         OCommonBehaviourTabPage(vcl::Window* pParent, const OString& rId, const OUString& rUIXMLDescription, const SfxItemSet& _rCoreAttrs, sal_uInt32 nControlFlags);
      74             :     protected:
      75             : 
      76             :         virtual ~OCommonBehaviourTabPage();
      77             : 
      78             :         // must be overloaded by subclasses, but it isn't pure virtual
      79             :         virtual void        implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
      80             : 
      81             :         // <method>OGenericAdministrationPage::fillControls</method>
      82             :         virtual void fillControls(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
      83             : 
      84             :         // <method>OGenericAdministrationPage::fillWindows</method>
      85             :         virtual void fillWindows(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
      86             :     };
      87             : 
      88             :     // ODbaseDetailsPage
      89             :     class ODbaseDetailsPage : public OCommonBehaviourTabPage
      90             :     {
      91             :     public:
      92             :         virtual bool        FillItemSet ( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
      93             : 
      94             :         ODbaseDetailsPage(vcl::Window* pParent, const SfxItemSet& _rCoreAttrs);
      95             :     private:
      96             :         CheckBox*           m_pShowDeleted;
      97             :         FixedText*          m_pFT_Message;
      98             :         PushButton*         m_pIndexes;
      99             : 
     100             :         OUString            m_sDsn;
     101             : 
     102             :     protected:
     103             : 
     104             :         virtual ~ODbaseDetailsPage();
     105             : 
     106             :     protected:
     107             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     108             : 
     109             :     private:
     110             :         DECL_LINK( OnButtonClicked, Button * );
     111             :     };
     112             : 
     113             :     // OAdoDetailsPage
     114             :     class OAdoDetailsPage : public OCommonBehaviourTabPage
     115             :     {
     116             :     protected:
     117             :         virtual ~OAdoDetailsPage();
     118             :     public:
     119             : 
     120             :         OAdoDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     121             :     };
     122             : 
     123             :     // OOdbcDetailsPage
     124           0 :     class OOdbcDetailsPage : public OCommonBehaviourTabPage
     125             :     {
     126             :     public:
     127             :         virtual bool        FillItemSet ( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     128             : 
     129             :         OOdbcDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     130             :     protected:
     131             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     132             :     private:
     133             :         CheckBox*           m_pUseCatalog;
     134             :     };
     135             : 
     136             :     // OUserDriverDetailsPage
     137           0 :     class OUserDriverDetailsPage : public OCommonBehaviourTabPage
     138             :     {
     139             :     public:
     140             :         virtual bool        FillItemSet ( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     141             : 
     142             :         OUserDriverDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     143             :     protected:
     144             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     145             :         virtual void fillControls(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     146             :         virtual void fillWindows(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     147             :     private:
     148             :         FixedText*          m_pFTHostname;
     149             :         Edit*               m_pEDHostname;
     150             :         FixedText*          m_pPortNumber;
     151             :         NumericField*       m_pNFPortNumber;
     152             :         CheckBox*           m_pUseCatalog;
     153             :     };
     154             : 
     155             :     // OMySQLODBCDetailsPage
     156           0 :     class OMySQLODBCDetailsPage : public OCommonBehaviourTabPage
     157             :     {
     158             :     public:
     159             :         OMySQLODBCDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     160             :     };
     161             : 
     162             :     // OGeneralSpecialJDBCDetailsPage
     163           0 :     class OGeneralSpecialJDBCDetailsPage : public OCommonBehaviourTabPage
     164             :     {
     165             :     public:
     166             :         OGeneralSpecialJDBCDetailsPage(   vcl::Window* pParent
     167             :                                         , const SfxItemSet& _rCoreAttrs
     168             :                                         , sal_uInt16 _nPortId
     169             :                                         , bool bShowSocket = true
     170             :                                         );
     171             : 
     172             :     protected:
     173             : 
     174             :         virtual bool FillItemSet( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     175             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     176             : 
     177             :         DECL_LINK(OnTestJavaClickHdl,PushButton*);
     178             :         DECL_LINK(OnEditModified,Edit*);
     179             : 
     180             :         Edit*               m_pEDHostname;
     181             :         NumericField*       m_pNFPortNumber;
     182             :         FixedText*          m_pFTSocket;
     183             :         Edit*               m_pEDSocket;
     184             : 
     185             :         FixedText*          m_pFTDriverClass;
     186             :         Edit*               m_pEDDriverClass;
     187             :         PushButton*         m_pTestJavaDriver;
     188             : 
     189             :         OUString              m_sDefaultJdbcDriverName;
     190             :         sal_uInt16              m_nPortId;
     191             :         bool                m_bUseClass;
     192             :     };
     193             : 
     194             :     // MySQLNativePage
     195           0 :     class MySQLNativePage : public OCommonBehaviourTabPage
     196             :     {
     197             :     public:
     198             :         MySQLNativePage(    vcl::Window* pParent,
     199             :                             const SfxItemSet& _rCoreAttrs );
     200             : 
     201             :     private:
     202             :         FixedText           *m_pSeparator1;
     203             :         MySQLNativeSettings m_aMySQLSettings;
     204             : 
     205             :         FixedText           *m_pSeparator2;
     206             :         FixedText           *m_pUserNameLabel;
     207             :         Edit                *m_pUserName;
     208             :         CheckBox            *m_pPasswordRequired;
     209             : 
     210             :     protected:
     211             :         virtual bool FillItemSet( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     212             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     213             :         virtual void fillControls(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     214             :         virtual void fillWindows(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     215             :     };
     216             : 
     217             :     // OOdbcDetailsPage
     218           0 :     class OLDAPDetailsPage : public OCommonBehaviourTabPage
     219             :     {
     220             :     public:
     221             :         virtual bool        FillItemSet ( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     222             : 
     223             :         OLDAPDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     224             :     protected:
     225             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     226             :     private:
     227             :         Edit*               m_pETBaseDN;
     228             :         CheckBox*           m_pCBUseSSL;
     229             :         NumericField*       m_pNFPortNumber;
     230             :         NumericField*       m_pNFRowCount;
     231             : 
     232             :         sal_Int32           m_iSSLPort;
     233             :         sal_Int32           m_iNormalPort;
     234             :         DECL_LINK( OnCheckBoxClick, CheckBox * );
     235             :     };
     236             : 
     237             :     // OMozillaDetailsPage Detail page for Mozilla and Thunderbird addressbook
     238             :     class OMozillaDetailsPage : public OCommonBehaviourTabPage
     239             :     {
     240             :     protected:
     241             :         virtual ~OMozillaDetailsPage();
     242             :     public:
     243             : 
     244             :         OMozillaDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     245             :     };
     246             : 
     247             :     // OTextDetailsPage
     248             :     class OTextDetailsPage : public OCommonBehaviourTabPage
     249             :     {
     250             :     public:
     251             :         virtual bool        FillItemSet ( SfxItemSet* _rCoreAttrs ) SAL_OVERRIDE;
     252             : 
     253             :         OTextDetailsPage( vcl::Window* pParent, const SfxItemSet& _rCoreAttrs );
     254             :         OTextConnectionHelper*  m_pTextConnectionHelper;
     255             : 
     256             :     protected:
     257             :         virtual ~OTextDetailsPage();
     258             :         virtual bool prepareLeave() SAL_OVERRIDE;
     259             : 
     260             :         virtual void implInitControls(const SfxItemSet& _rSet, bool _bSaveValue) SAL_OVERRIDE;
     261             :         virtual void fillControls(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     262             :         virtual void fillWindows(::std::vector< ISaveValueWrapper* >& _rControlList) SAL_OVERRIDE;
     263             : 
     264             :     private:
     265             :     };
     266             : 
     267             : }   // namespace dbaui
     268             : 
     269             : #endif // INCLUDED_DBACCESS_SOURCE_UI_DLG_DETAILPAGES_HXX
     270             : 
     271             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10