LCOV - code coverage report
Current view: top level - extensions/source/dbpilots - listcombowizard.cxx (source / functions) Hit Total Coverage
Test: commit 0e63ca4fde4e446f346e35849c756a30ca294aab Lines: 0 226 0.0 %
Date: 2014-04-11 Functions: 0 40 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             : #include "listcombowizard.hxx"
      21             : #include "commonpagesdbp.hxx"
      22             : #include <com/sun/star/sdbc/XConnection.hpp>
      23             : #include <com/sun/star/sdbcx/XTablesSupplier.hpp>
      24             : #include <com/sun/star/container/XNameAccess.hpp>
      25             : #include <com/sun/star/form/ListSourceType.hpp>
      26             : #include <com/sun/star/sdbcx/XColumnsSupplier.hpp>
      27             : #include <tools/debug.hxx>
      28             : #include <vcl/msgbox.hxx>
      29             : #include <connectivity/dbtools.hxx>
      30             : #include "dbpilots.hrc"
      31             : #include <comphelper/extract.hxx>
      32             : 
      33             : 
      34             : namespace dbp
      35             : {
      36             : 
      37             : 
      38             :     using namespace ::com::sun::star::uno;
      39             :     using namespace ::com::sun::star::lang;
      40             :     using namespace ::com::sun::star::beans;
      41             :     using namespace ::com::sun::star::sdbc;
      42             :     using namespace ::com::sun::star::sdbcx;
      43             :     using namespace ::com::sun::star::container;
      44             :     using namespace ::com::sun::star::form;
      45             :     using namespace ::svt;
      46             :     using namespace ::dbtools;
      47             : 
      48             : 
      49             :     //= OListComboWizard
      50             : 
      51             : 
      52           0 :     OListComboWizard::OListComboWizard( Window* _pParent,
      53             :             const Reference< XPropertySet >& _rxObjectModel, const Reference< XComponentContext >& _rxContext )
      54             :         :OControlWizard(_pParent, ModuleRes(RID_DLG_LISTCOMBOWIZARD), _rxObjectModel, _rxContext)
      55             :         ,m_bListBox(sal_False)
      56           0 :         ,m_bHadDataSelection(sal_True)
      57             :     {
      58           0 :         initControlSettings(&m_aSettings);
      59             : 
      60           0 :         m_pPrevPage->SetHelpId(HID_LISTWIZARD_PREVIOUS);
      61           0 :         m_pNextPage->SetHelpId(HID_LISTWIZARD_NEXT);
      62           0 :         m_pCancel->SetHelpId(HID_LISTWIZARD_CANCEL);
      63           0 :         m_pFinish->SetHelpId(HID_LISTWIZARD_FINISH);
      64             : 
      65             :         // if we do not need the data source selection page ...
      66           0 :         if (!needDatasourceSelection())
      67             :         {   // ... skip it!
      68           0 :             skip(1);
      69           0 :             m_bHadDataSelection = sal_False;
      70             :         }
      71           0 :     }
      72             : 
      73             : 
      74           0 :     sal_Bool OListComboWizard::approveControl(sal_Int16 _nClassId)
      75             :     {
      76           0 :         switch (_nClassId)
      77             :         {
      78             :             case FormComponentType::LISTBOX:
      79           0 :                 m_bListBox = sal_True;
      80           0 :                 setTitleBase(ModuleRes(RID_STR_LISTWIZARD_TITLE).toString());
      81           0 :                 return sal_True;
      82             :             case FormComponentType::COMBOBOX:
      83           0 :                 m_bListBox = sal_False;
      84           0 :                 setTitleBase(ModuleRes(RID_STR_COMBOWIZARD_TITLE).toString());
      85           0 :                 return sal_True;
      86             :         }
      87           0 :         return sal_False;
      88             :     }
      89             : 
      90             : 
      91           0 :     OWizardPage* OListComboWizard::createPage(WizardState _nState)
      92             :     {
      93           0 :         switch (_nState)
      94             :         {
      95             :             case LCW_STATE_DATASOURCE_SELECTION:
      96           0 :                 return new OTableSelectionPage(this);
      97             :             case LCW_STATE_TABLESELECTION:
      98           0 :                 return new OContentTableSelection(this);
      99             :             case LCW_STATE_FIELDSELECTION:
     100           0 :                 return new OContentFieldSelection(this);
     101             :             case LCW_STATE_FIELDLINK:
     102           0 :                 return new OLinkFieldsPage(this);
     103             :             case LCW_STATE_COMBODBFIELD:
     104           0 :                 return new OComboDBFieldPage(this);
     105             :         }
     106             : 
     107           0 :         return NULL;
     108             :     }
     109             : 
     110             : 
     111           0 :     WizardTypes::WizardState OListComboWizard::determineNextState( WizardState _nCurrentState ) const
     112             :     {
     113           0 :         switch (_nCurrentState)
     114             :         {
     115             :             case LCW_STATE_DATASOURCE_SELECTION:
     116           0 :                 return LCW_STATE_TABLESELECTION;
     117             :             case LCW_STATE_TABLESELECTION:
     118           0 :                 return LCW_STATE_FIELDSELECTION;
     119             :             case LCW_STATE_FIELDSELECTION:
     120           0 :                 return getFinalState();
     121             :         }
     122             : 
     123           0 :         return WZS_INVALID_STATE;
     124             :     }
     125             : 
     126             : 
     127           0 :     void OListComboWizard::enterState(WizardState _nState)
     128             :     {
     129           0 :         OControlWizard::enterState(_nState);
     130             : 
     131           0 :         enableButtons(WZB_PREVIOUS, m_bHadDataSelection ? (LCW_STATE_DATASOURCE_SELECTION < _nState) : LCW_STATE_TABLESELECTION < _nState);
     132           0 :         enableButtons(WZB_NEXT, getFinalState() != _nState);
     133           0 :         if (_nState < getFinalState())
     134           0 :             enableButtons(WZB_FINISH, false);
     135             : 
     136           0 :         if (getFinalState() == _nState)
     137           0 :             defaultButton(WZB_FINISH);
     138           0 :     }
     139             : 
     140             : 
     141           0 :     bool OListComboWizard::leaveState(WizardState _nState)
     142             :     {
     143           0 :         if (!OControlWizard::leaveState(_nState))
     144           0 :             return false;
     145             : 
     146           0 :         if (getFinalState() == _nState)
     147           0 :             defaultButton(WZB_NEXT);
     148             : 
     149           0 :         return true;
     150             :     }
     151             : 
     152             : 
     153           0 :     void OListComboWizard::implApplySettings()
     154             :     {
     155             :         try
     156             :         {
     157             :             // for quoting identifiers, we need the connection meta data
     158           0 :             Reference< XConnection > xConn = getFormConnection();
     159             :             DBG_ASSERT(xConn.is(), "OListComboWizard::implApplySettings: no connection, unable to quote!");
     160           0 :             Reference< XDatabaseMetaData > xMetaData;
     161           0 :             if (xConn.is())
     162           0 :                 xMetaData = xConn->getMetaData();
     163             : 
     164             :             // do some quotings
     165           0 :             if (xMetaData.is())
     166             :             {
     167           0 :                 OUString sQuoteString = xMetaData->getIdentifierQuoteString();
     168           0 :                 if (isListBox()) // only when we have a listbox this should be not empty
     169           0 :                     getSettings().sLinkedListField = quoteName(sQuoteString, getSettings().sLinkedListField);
     170             : 
     171           0 :                 OUString sCatalog, sSchema, sName;
     172           0 :                 ::dbtools::qualifiedNameComponents( xMetaData, getSettings().sListContentTable, sCatalog, sSchema, sName, ::dbtools::eInDataManipulation );
     173           0 :                 getSettings().sListContentTable = ::dbtools::composeTableNameForSelect( xConn, sCatalog, sSchema, sName );
     174             : 
     175           0 :                 getSettings().sListContentField = quoteName(sQuoteString, getSettings().sListContentField);
     176             :             }
     177             : 
     178             :             // ListSourceType: SQL
     179           0 :             getContext().xObjectModel->setPropertyValue("ListSourceType", makeAny((sal_Int32)ListSourceType_SQL));
     180             : 
     181           0 :             if (isListBox())
     182             :             {
     183             :                 // BoundColumn: 1
     184           0 :                 getContext().xObjectModel->setPropertyValue("BoundColumn", makeAny((sal_Int16)1));
     185             : 
     186             :                 // build the statement to set as list source
     187           0 :                 OUString sStatement = "SELECT " +
     188           0 :                     OUString( getSettings().sListContentField ) +  ", " + OUString( getSettings().sLinkedListField ) +
     189           0 :                     " FROM " + OUString( getSettings().sListContentTable );
     190           0 :                 Sequence< OUString > aListSource(1);
     191           0 :                 aListSource[0] = sStatement;
     192           0 :                 getContext().xObjectModel->setPropertyValue("ListSource", makeAny(aListSource));
     193             :             }
     194             :             else
     195             :             {
     196             :                 // build the statement to set as list source
     197           0 :                 OUString sStatement = "SELECT DISTINCT " +
     198           0 :                     OUString( getSettings().sListContentField ) +
     199           0 :                     " FROM " + OUString( getSettings().sListContentTable );
     200           0 :                 getContext().xObjectModel->setPropertyValue( "ListSource", makeAny(OUString(sStatement)));
     201             :             }
     202             : 
     203             :             // the bound field
     204           0 :             getContext().xObjectModel->setPropertyValue("DataField", makeAny(OUString(getSettings().sLinkedFormField)));
     205             :         }
     206           0 :         catch(const Exception&)
     207             :         {
     208             :             OSL_FAIL("OListComboWizard::implApplySettings: could not set the property values for the listbox!");
     209             :         }
     210           0 :     }
     211             : 
     212             : 
     213           0 :     bool OListComboWizard::onFinish()
     214             :     {
     215           0 :         if ( !OControlWizard::onFinish() )
     216           0 :             return false;
     217             : 
     218           0 :         implApplySettings();
     219           0 :         return true;
     220             :     }
     221             : 
     222             : 
     223             :     //= OLCPage
     224             : 
     225             : 
     226           0 :     Reference< XNameAccess > OLCPage::getTables(sal_Bool _bNeedIt)
     227             :     {
     228           0 :         Reference< XConnection > xConn = getFormConnection();
     229             :         DBG_ASSERT(!_bNeedIt || xConn.is(), "OLCPage::getTables: should have an active connection when reaching this page!");
     230             :         (void)_bNeedIt;
     231             : 
     232           0 :         Reference< XTablesSupplier > xSuppTables(xConn, UNO_QUERY);
     233           0 :         Reference< XNameAccess > xTables;
     234           0 :         if (xSuppTables.is())
     235           0 :             xTables = xSuppTables->getTables();
     236             : 
     237             :         DBG_ASSERT(!_bNeedIt || xTables.is() || !xConn.is(), "OLCPage::getTables: got no tables from the connection!");
     238             : 
     239           0 :         return xTables;
     240             :     }
     241             : 
     242             : 
     243           0 :     Sequence< OUString > OLCPage::getTableFields(sal_Bool _bNeedIt)
     244             :     {
     245           0 :         Reference< XNameAccess > xTables = getTables(_bNeedIt);
     246           0 :         Sequence< OUString > aColumnNames;
     247           0 :         if (xTables.is())
     248             :         {
     249             :             try
     250             :             {
     251             :                 // the list table as XColumnsSupplier
     252           0 :                 Reference< XColumnsSupplier > xSuppCols;
     253           0 :                 xTables->getByName(getSettings().sListContentTable) >>= xSuppCols;
     254             :                 DBG_ASSERT(!_bNeedIt || xSuppCols.is(), "OLCPage::getTableFields: no columns supplier!");
     255             : 
     256             :                 // the columns
     257           0 :                 Reference< XNameAccess > xColumns;
     258           0 :                 if (xSuppCols.is())
     259           0 :                     xColumns = xSuppCols->getColumns();
     260             : 
     261             :                 // the column names
     262           0 :                 if (xColumns.is())
     263           0 :                     aColumnNames = xColumns->getElementNames();
     264             :             }
     265           0 :             catch(const Exception&)
     266             :             {
     267             :                 DBG_ASSERT(!_bNeedIt, "OLinkFieldsPage::initializePage: caught an exception while retrieving the columns!");
     268             :             }
     269             :         }
     270           0 :         return aColumnNames;
     271             :     }
     272             : 
     273             : 
     274             :     //= OContentTableSelection
     275             : 
     276             : 
     277           0 :     OContentTableSelection::OContentTableSelection( OListComboWizard* _pParent )
     278             :         :OLCPage(_pParent, ModuleRes(RID_PAGE_LCW_CONTENTSELECTION_TABLE))
     279             :         ,m_aFrame               (this, ModuleRes(FL_FRAME))
     280             :         ,m_aSelectTableLabel    (this, ModuleRes(FT_SELECTTABLE_LABEL))
     281           0 :         ,m_aSelectTable         (this, ModuleRes(LB_SELECTTABLE))
     282             :     {
     283           0 :         FreeResource();
     284             : 
     285           0 :         enableFormDatasourceDisplay();
     286             : 
     287           0 :         m_aSelectTable.SetDoubleClickHdl(LINK(this, OContentTableSelection, OnTableDoubleClicked));
     288           0 :         m_aSelectTable.SetSelectHdl(LINK(this, OContentTableSelection, OnTableSelected));
     289           0 :     }
     290             : 
     291             : 
     292           0 :     void OContentTableSelection::ActivatePage()
     293             :     {
     294           0 :         OLCPage::ActivatePage();
     295           0 :         m_aSelectTable.GrabFocus();
     296           0 :     }
     297             : 
     298             : 
     299           0 :     bool OContentTableSelection::canAdvance() const
     300             :     {
     301           0 :         if (!OLCPage::canAdvance())
     302           0 :             return false;
     303             : 
     304           0 :         return 0 != m_aSelectTable.GetSelectEntryCount();
     305             :     }
     306             : 
     307             : 
     308           0 :     IMPL_LINK( OContentTableSelection, OnTableSelected, ListBox*, /*_pListBox*/ )
     309             :     {
     310           0 :         updateDialogTravelUI();
     311           0 :         return 0L;
     312             :     }
     313             : 
     314             : 
     315           0 :     IMPL_LINK( OContentTableSelection, OnTableDoubleClicked, ListBox*, _pListBox )
     316             :     {
     317           0 :         if (_pListBox->GetSelectEntryCount())
     318           0 :             getDialog()->travelNext();
     319           0 :         return 0L;
     320             :     }
     321             : 
     322             : 
     323           0 :     void OContentTableSelection::initializePage()
     324             :     {
     325           0 :         OLCPage::initializePage();
     326             : 
     327             :         // fill the list with the table name
     328           0 :         m_aSelectTable.Clear();
     329             :         try
     330             :         {
     331           0 :             Reference< XNameAccess > xTables = getTables(sal_True);
     332           0 :             Sequence< OUString > aTableNames;
     333           0 :             if (xTables.is())
     334           0 :                 aTableNames = xTables->getElementNames();
     335           0 :             fillListBox(m_aSelectTable, aTableNames);
     336             :         }
     337           0 :         catch(const Exception&)
     338             :         {
     339             :             OSL_FAIL("OContentTableSelection::initializePage: could not retrieve the table names!");
     340             :         }
     341             : 
     342           0 :         m_aSelectTable.SelectEntry(getSettings().sListContentTable);
     343           0 :     }
     344             : 
     345             : 
     346           0 :     bool OContentTableSelection::commitPage( ::svt::WizardTypes::CommitPageReason _eReason )
     347             :     {
     348           0 :         if (!OLCPage::commitPage(_eReason))
     349           0 :             return false;
     350             : 
     351           0 :         OListComboSettings& rSettings = getSettings();
     352           0 :         rSettings.sListContentTable = m_aSelectTable.GetSelectEntry();
     353           0 :         if (rSettings.sListContentTable.isEmpty() && (::svt::WizardTypes::eTravelBackward != _eReason))
     354             :             // need to select a table
     355           0 :             return false;
     356             : 
     357           0 :         return true;
     358             :     }
     359             : 
     360             : 
     361             :     //= OContentFieldSelection
     362             : 
     363             : 
     364           0 :     OContentFieldSelection::OContentFieldSelection( OListComboWizard* _pParent )
     365             :         :OLCPage(_pParent, ModuleRes(RID_PAGE_LCW_CONTENTSELECTION_FIELD))
     366             :         ,m_aFrame               (this, ModuleRes(FL_FRAME))
     367             :         ,m_aTableFields         (this, ModuleRes(FT_TABLEFIELDS))
     368             :         ,m_aSelectTableField    (this, ModuleRes(LB_SELECTFIELD))
     369             :         ,m_aDisplayedFieldLabel (this, ModuleRes(FT_DISPLAYEDFIELD))
     370             :         ,m_aDisplayedField      (this, ModuleRes(ET_DISPLAYEDFIELD))
     371           0 :         ,m_aInfo                (this, ModuleRes(FT_CONTENTFIELD_INFO))
     372             :     {
     373           0 :         m_aInfo.SetText(ModuleRes( isListBox() ? STR_FIELDINFO_LISTBOX : STR_FIELDINFO_COMBOBOX).toString());
     374           0 :         FreeResource();
     375           0 :         m_aSelectTableField.SetSelectHdl(LINK(this, OContentFieldSelection, OnFieldSelected));
     376           0 :         m_aSelectTableField.SetDoubleClickHdl(LINK(this, OContentFieldSelection, OnTableDoubleClicked));
     377           0 :     }
     378             : 
     379             : 
     380           0 :     void OContentFieldSelection::ActivatePage()
     381             :     {
     382           0 :         OLCPage::ActivatePage();
     383           0 :         m_aTableFields.GrabFocus();
     384           0 :     }
     385             : 
     386             : 
     387           0 :     void OContentFieldSelection::initializePage()
     388             :     {
     389           0 :         OLCPage::initializePage();
     390             : 
     391             :         // fill the list of fields
     392           0 :         fillListBox(m_aSelectTableField, getTableFields(sal_True));
     393             : 
     394           0 :         m_aSelectTableField.SelectEntry(getSettings().sListContentField);
     395           0 :         m_aDisplayedField.SetText(getSettings().sListContentField);
     396           0 :     }
     397             : 
     398             : 
     399           0 :     bool OContentFieldSelection::canAdvance() const
     400             :     {
     401           0 :         if (!OLCPage::canAdvance())
     402           0 :             return false;
     403             : 
     404           0 :         return 0 != m_aSelectTableField.GetSelectEntryCount();
     405             :     }
     406             : 
     407             : 
     408           0 :     IMPL_LINK( OContentFieldSelection, OnTableDoubleClicked, ListBox*, /*NOTINTERESTEDIN*/ )
     409             :     {
     410           0 :         if (m_aSelectTableField.GetSelectEntryCount())
     411           0 :             getDialog()->travelNext();
     412           0 :         return 0L;
     413             :     }
     414             : 
     415             : 
     416           0 :     IMPL_LINK( OContentFieldSelection, OnFieldSelected, ListBox*, /*NOTINTERESTEDIN*/ )
     417             :     {
     418           0 :         updateDialogTravelUI();
     419           0 :         m_aDisplayedField.SetText(m_aSelectTableField.GetSelectEntry());
     420           0 :         return 0L;
     421             :     }
     422             : 
     423             : 
     424           0 :     bool OContentFieldSelection::commitPage( ::svt::WizardTypes::CommitPageReason _eReason )
     425             :     {
     426           0 :         if (!OLCPage::commitPage(_eReason))
     427           0 :             return false;
     428             : 
     429           0 :         getSettings().sListContentField = m_aSelectTableField.GetSelectEntry();
     430             : 
     431           0 :         return true;
     432             :     }
     433             : 
     434             : 
     435             :     //= OLinkFieldsPage
     436             : 
     437             : 
     438           0 :     OLinkFieldsPage::OLinkFieldsPage( OListComboWizard* _pParent )
     439             :         :OLCPage(_pParent, ModuleRes(RID_PAGE_LCW_FIELDLINK))
     440             :         ,m_aDescription         (this, ModuleRes(FT_FIELDLINK_DESC))
     441             :         ,m_aFrame               (this, ModuleRes(FL_FRAME))
     442             :         ,m_aValueListFieldLabel (this, ModuleRes(FT_VALUELISTFIELD))
     443             :         ,m_aValueListField      (this, ModuleRes(CMB_VALUELISTFIELD))
     444             :         ,m_aTableFieldLabel     (this, ModuleRes(FT_TABLEFIELD))
     445           0 :         ,m_aTableField          (this, ModuleRes(CMB_TABLEFIELD))
     446             :     {
     447           0 :         FreeResource();
     448             : 
     449           0 :         m_aValueListField.SetModifyHdl(LINK(this, OLinkFieldsPage, OnSelectionModified));
     450           0 :         m_aTableField.SetModifyHdl(LINK(this, OLinkFieldsPage, OnSelectionModified));
     451           0 :         m_aValueListField.SetSelectHdl(LINK(this, OLinkFieldsPage, OnSelectionModified));
     452           0 :         m_aTableField.SetSelectHdl(LINK(this, OLinkFieldsPage, OnSelectionModified));
     453           0 :     }
     454             : 
     455             : 
     456           0 :     void OLinkFieldsPage::ActivatePage()
     457             :     {
     458           0 :         OLCPage::ActivatePage();
     459           0 :         m_aValueListField.GrabFocus();
     460           0 :     }
     461             : 
     462             : 
     463           0 :     void OLinkFieldsPage::initializePage()
     464             :     {
     465           0 :         OLCPage::initializePage();
     466             : 
     467             :         // fill the value list
     468           0 :         fillListBox(m_aValueListField, getContext().aFieldNames);
     469             :         // fill the table field list
     470           0 :         fillListBox(m_aTableField, getTableFields(sal_True));
     471             : 
     472             :         // the initial selections
     473           0 :         m_aValueListField.SetText(getSettings().sLinkedFormField);
     474           0 :         m_aTableField.SetText(getSettings().sLinkedListField);
     475             : 
     476           0 :         implCheckFinish();
     477           0 :     }
     478             : 
     479             : 
     480           0 :     bool OLinkFieldsPage::canAdvance() const
     481             :     {
     482             :         // we're on the last page here, no travelNext allowed ...
     483           0 :         return false;
     484             :     }
     485             : 
     486             : 
     487           0 :     void OLinkFieldsPage::implCheckFinish()
     488             :     {
     489           0 :         bool bInvalidSelection = (COMBOBOX_ENTRY_NOTFOUND == m_aValueListField.GetEntryPos(m_aValueListField.GetText()));
     490           0 :         bInvalidSelection |= (COMBOBOX_ENTRY_NOTFOUND == m_aTableField.GetEntryPos(m_aTableField.GetText()));
     491           0 :         getDialog()->enableButtons(WZB_FINISH, !bInvalidSelection);
     492           0 :     }
     493             : 
     494             : 
     495           0 :     IMPL_LINK_NOARG(OLinkFieldsPage, OnSelectionModified)
     496             :     {
     497           0 :         implCheckFinish();
     498           0 :         return 0L;
     499             :     }
     500             : 
     501             : 
     502           0 :     bool OLinkFieldsPage::commitPage( ::svt::WizardTypes::CommitPageReason _eReason )
     503             :     {
     504           0 :         if (!OLCPage::commitPage(_eReason))
     505           0 :             return false;
     506             : 
     507           0 :         getSettings().sLinkedFormField = m_aValueListField.GetText();
     508           0 :         getSettings().sLinkedListField = m_aTableField.GetText();
     509             : 
     510           0 :         return true;
     511             :     }
     512             : 
     513             : 
     514             :     //= OComboDBFieldPage
     515             : 
     516             : 
     517           0 :     OComboDBFieldPage::OComboDBFieldPage( OControlWizard* _pParent )
     518           0 :         :ODBFieldPage(_pParent)
     519             :     {
     520           0 :         setDescriptionText(ModuleRes(RID_STR_COMBOWIZ_DBFIELD).toString());
     521           0 :     }
     522             : 
     523             : 
     524           0 :     OUString& OComboDBFieldPage::getDBFieldSetting()
     525             :     {
     526           0 :         return getSettings().sLinkedFormField;
     527             :     }
     528             : 
     529             : 
     530           0 :     void OComboDBFieldPage::ActivatePage()
     531             :     {
     532           0 :         ODBFieldPage::ActivatePage();
     533           0 :         getDialog()->enableButtons(WZB_FINISH, true);
     534           0 :     }
     535             : 
     536             : 
     537           0 :     bool OComboDBFieldPage::canAdvance() const
     538             :     {
     539             :         // we're on the last page here, no travelNext allowed ...
     540           0 :         return false;
     541             :     }
     542             : 
     543             : 
     544             : }   // namespace dbp
     545             : 
     546             : 
     547             : /* vim:set shiftwidth=4 softtabstop=4 expandtab: */

Generated by: LCOV version 1.10