diff options
author | Frank Schönheit <fs@openoffice.org> | 2002-12-02 08:56:36 +0000 |
---|---|---|
committer | Frank Schönheit <fs@openoffice.org> | 2002-12-02 08:56:36 +0000 |
commit | b0c4be14883b4390642c3c60da343d0571ca34e7 (patch) | |
tree | 3eb1ff42f79f4f6ad5af7f387195f8abee11cd3f /forms/source/component/Date.cxx | |
parent | 426af421c326aa4670c92c9559bfed40cffea077 (diff) |
#105577# properly (hopefully :) implemented XClonable
Diffstat (limited to 'forms/source/component/Date.cxx')
-rw-r--r-- | forms/source/component/Date.cxx | 29 |
1 files changed, 27 insertions, 2 deletions
diff --git a/forms/source/component/Date.cxx b/forms/source/component/Date.cxx index 189610e4a3e4..ae5c2cbbcbc3 100644 --- a/forms/source/component/Date.cxx +++ b/forms/source/component/Date.cxx @@ -2,9 +2,9 @@ * * $RCSfile: Date.cxx,v $ * - * $Revision: 1.9 $ + * $Revision: 1.10 $ * - * last change: $Author: fs $ $Date: 2002-03-04 14:46:12 $ + * last change: $Author: fs $ $Date: 2002-12-02 09:56:29 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -142,11 +142,15 @@ Sequence<Type> ODateModel::_getTypes() } //------------------------------------------------------------------ +DBG_NAME( ODateModel ) +//------------------------------------------------------------------ ODateModel::ODateModel(const Reference<XMultiServiceFactory>& _rxFactory) :OEditBaseModel(_rxFactory, VCL_CONTROLMODEL_DATEFIELD, FRM_CONTROL_DATEFIELD ) // use the old control name for compytibility reasons ,OLimitedFormats(_rxFactory, FormComponentType::DATEFIELD) { + DBG_CTOR( ODateModel, NULL ); + m_nClassId = FormComponentType::DATEFIELD; m_sDataFieldConnectivityProperty = PROPERTY_DATE; if (ODateModel::nDateHandle == -1) @@ -155,6 +159,27 @@ ODateModel::ODateModel(const Reference<XMultiServiceFactory>& _rxFactory) setAggregateSet(m_xAggregateFastSet, getOriginalHandle(PROPERTY_ID_DATEFORMAT)); } +//------------------------------------------------------------------------------ +ODateModel::ODateModel( const ODateModel* _pOriginal, const Reference<XMultiServiceFactory>& _rxFactory ) + :OEditBaseModel( _pOriginal, _rxFactory ) + ,OLimitedFormats( _rxFactory, FormComponentType::DATEFIELD ) +{ + DBG_CTOR( ODateModel, NULL ); + + setAggregateSet( m_xAggregateFastSet, getOriginalHandle( PROPERTY_ID_DATEFORMAT ) ); +} + +//------------------------------------------------------------------------------ +ODateModel::~ODateModel( ) +{ + setAggregateSet(Reference< XFastPropertySet >(), -1); + DBG_DTOR( ODateModel, NULL ); +} + +// XCloneable +//------------------------------------------------------------------------------ +IMPLEMENT_DEFAULT_CLONING( ODateModel ) + // XServiceInfo //------------------------------------------------------------------------------ StringSequence SAL_CALL ODateModel::getSupportedServiceNames() throw() |