summaryrefslogtreecommitdiff
path: root/sw/source/core/unocore/unofield.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'sw/source/core/unocore/unofield.cxx')
-rw-r--r--sw/source/core/unocore/unofield.cxx208
1 files changed, 14 insertions, 194 deletions
diff --git a/sw/source/core/unocore/unofield.cxx b/sw/source/core/unocore/unofield.cxx
index bd4a4ce5ef98..ccb0a3ee0194 100644
--- a/sw/source/core/unocore/unofield.cxx
+++ b/sw/source/core/unocore/unofield.cxx
@@ -124,11 +124,13 @@ static const sal_uInt16 aDocInfoSubTypeFromService[] =
DI_TITEL, //PROPERTY_MAP_FLDTYP_DOCINFO_TITLE
DI_DOCNO //PROPERTY_MAP_FLDTYP_DOCINFO_REVISION
};
+
struct ServiceIdResId
{
USHORT nResId;
USHORT nServiceId;
};
+
static const ServiceIdResId aServiceToRes[] =
{
{RES_DATETIMEFLD, SW_SERVICE_FIELDTYPE_DATETIME },
@@ -185,7 +187,7 @@ static const ServiceIdResId aServiceToRes[] =
{RES_TABLEFLD, SW_SERVICE_FIELDTYPE_TABLE_FORMULA },
{USHRT_MAX, USHRT_MAX }
};
-//-----------------------------------------------------------------
+
sal_uInt16 lcl_ServiceIdToResId(sal_uInt16 nServiceId)
{
const ServiceIdResId* pMap = aServiceToRes;
@@ -197,7 +199,7 @@ sal_uInt16 lcl_ServiceIdToResId(sal_uInt16 nServiceId)
#endif
return pMap->nResId;
}
-//-----------------------------------------------------------------
+
sal_uInt16 lcl_GetServiceForField( const SwField& rFld )
{
sal_uInt16 nWhich = rFld.Which(), nSrvId = USHRT_MAX;
@@ -293,7 +295,6 @@ sal_uInt16 lcl_GetPropMapIdForFieldType( USHORT nWhich )
return nId;
}
-
USHORT GetFieldTypeMId( const OUString& rProperty, const SwFieldType& rTyp )
{
USHORT nId = lcl_GetPropMapIdForFieldType( rTyp.Which() );
@@ -392,17 +393,13 @@ USHORT lcl_GetPropertyMapOfService( USHORT nServiceId )
* SwXFieldMaster
******************************************************************/
TYPEINIT1(SwXFieldMaster, SwClient);
-/* -----------------------------13.03.00 12:15--------------------------------
- ---------------------------------------------------------------------------*/
const uno::Sequence< sal_Int8 > & SwXFieldMaster::getUnoTunnelId()
{
static uno::Sequence< sal_Int8 > aSeq = ::CreateUnoTunnelId();
return aSeq;
}
-/* -----------------------------10.03.00 18:04--------------------------------
- ---------------------------------------------------------------------------*/
sal_Int64 SAL_CALL SwXFieldMaster::getSomething( const uno::Sequence< sal_Int8 >& rId )
throw(uno::RuntimeException)
{
@@ -414,16 +411,12 @@ sal_Int64 SAL_CALL SwXFieldMaster::getSomething( const uno::Sequence< sal_Int8 >
}
return 0;
}
-/* -----------------------------06.04.00 13:22--------------------------------
- ---------------------------------------------------------------------------*/
OUString SwXFieldMaster::getImplementationName(void) throw( uno::RuntimeException )
{
return C2U("SwXFieldMaster");
}
-/* -----------------------------06.04.00 13:22--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SwXFieldMaster::supportsService(const OUString& rServiceName) throw( uno::RuntimeException )
{
sal_Bool bRet = sal_False;
@@ -452,9 +445,7 @@ BOOL SwXFieldMaster::supportsService(const OUString& rServiceName) throw( uno::R
}
return bRet;
}
-/* -----------------------------06.04.00 13:22--------------------------------
- ---------------------------------------------------------------------------*/
uno::Sequence< OUString > SwXFieldMaster::getSupportedServiceNames(void) throw( uno::RuntimeException )
{
uno::Sequence< OUString > aRet(2);
@@ -479,9 +470,7 @@ uno::Sequence< OUString > SwXFieldMaster::getSupportedServiceNames(void) throw(
}
return aRet;
}
-/*-- 14.12.98 11:08:33---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXFieldMaster::SwXFieldMaster(SwDoc* pDoc, sal_uInt16 nResId) :
aLstnrCntnr( (XPropertySet*)this),
nResTypeId(nResId),
@@ -494,9 +483,7 @@ SwXFieldMaster::SwXFieldMaster(SwDoc* pDoc, sal_uInt16 nResId) :
{
pDoc->GetPageDescFromPool(RES_POOLPAGE_STANDARD)->Add(this);
}
-/*-- 14.12.98 11:08:33---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXFieldMaster::SwXFieldMaster(SwFieldType& rType, SwDoc* pDoc) :
SwClient(&rType),
aLstnrCntnr( (XPropertySet*)this),
@@ -509,16 +496,12 @@ SwXFieldMaster::SwXFieldMaster(SwFieldType& rType, SwDoc* pDoc) :
{
}
-/*-- 14.12.98 11:08:34---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXFieldMaster::~SwXFieldMaster()
{
}
-/*-- 14.12.98 11:08:35---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Reference< beans::XPropertySetInfo > SwXFieldMaster::getPropertySetInfo(void)
throw( uno::RuntimeException )
{
@@ -528,9 +511,7 @@ uno::Reference< beans::XPropertySetInfo > SwXFieldMaster::getPropertySetInfo(vo
lcl_GetPropMapIdForFieldType( nResTypeId ) )->getPropertySetInfo();
return aRef;
}
-/*-- 14.12.98 11:08:35---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::setPropertyValue( const OUString& rPropertyName,
const uno::Any& rValue)
throw( beans::UnknownPropertyException, beans::PropertyVetoException,
@@ -712,9 +693,7 @@ void SwXFieldMaster::setPropertyValue( const OUString& rPropertyName,
}
}
}
-/* -----------------------------30.03.01 14:40--------------------------------
- ---------------------------------------------------------------------------*/
SwFieldType* SwXFieldMaster::GetFldType(sal_Bool bDontCreate) const
{
if(!bDontCreate && RES_DBFLD == nResTypeId && m_bIsDescriptor && m_pDoc)
@@ -743,9 +722,6 @@ SwFieldType* SwXFieldMaster::GetFldType(sal_Bool bDontCreate) const
return (SwFieldType*)GetRegisteredIn();
}
-/*-- 14.12.98 11:08:36---------------------------------------------------
-
- -----------------------------------------------------------------------*/
typedef SwFmtFld* SwFmtFldPtr;
SV_DECL_PTRARR(SwDependentFields, SwFmtFldPtr, 5, 5)
SV_IMPL_PTRARR(SwDependentFields, SwFmtFldPtr)
@@ -900,38 +876,27 @@ uno::Any SwXFieldMaster::getPropertyValue(const OUString& rPropertyName)
}
return aRet;
}
-/*-- 14.12.98 11:08:36---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::addPropertyChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XPropertyChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:08:36---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::removePropertyChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XPropertyChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:08:37---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::addVetoableChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XVetoableChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:08:37---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::removeVetoableChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XVetoableChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 25.02.99 11:01:57---------------------------------------------------
-
- -----------------------------------------------------------------------*/
void SwXFieldMaster::dispose(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -969,9 +934,7 @@ void SwXFieldMaster::dispose(void) throw( uno::RuntimeException )
else
throw uno::RuntimeException();
}
-/*-- 25.02.99 11:02:00---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::addEventListener(const uno::Reference< lang::XEventListener > & aListener)
throw( uno::RuntimeException )
{
@@ -979,9 +942,7 @@ void SwXFieldMaster::addEventListener(const uno::Reference< lang::XEventListener
throw uno::RuntimeException();
aLstnrCntnr.AddListener(aListener);
}
-/*-- 25.02.99 11:02:02---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXFieldMaster::removeEventListener(const uno::Reference< lang::XEventListener > & aListener)
throw( uno::RuntimeException )
{
@@ -989,9 +950,6 @@ void SwXFieldMaster::removeEventListener(const uno::Reference< lang::XEventListe
throw uno::RuntimeException();
}
-/*-- 14.12.98 11:08:38---------------------------------------------------
-
- -----------------------------------------------------------------------*/
void SwXFieldMaster::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew)
{
ClientModify(this, pOld, pNew);
@@ -1023,9 +981,7 @@ const Programmatic2UIName_Impl* lcl_GetFieldNameTable()
return &aFieldNames[0];
}
---------------------------------------------------------------------------*/
-/* -----------------------------06.11.00 10:26--------------------------------
- ---------------------------------------------------------------------------*/
OUString SwXFieldMaster::GetProgrammaticName(const SwFieldType& rType, SwDoc& rDoc)
{
OUString sRet(rType.GetName());
@@ -1043,9 +999,7 @@ OUString SwXFieldMaster::GetProgrammaticName(const SwFieldType& rType, SwDoc& rD
}
return sRet;
}
-/* -----------------------------06.11.00 14:12--------------------------------
- ---------------------------------------------------------------------------*/
OUString SwXFieldMaster::LocalizeFormula(
const SwSetExpField& rFld,
const OUString& rFormula,
@@ -1067,7 +1021,6 @@ OUString SwXFieldMaster::LocalizeFormula(
return rFormula;
}
-
SwXTextField * CreateSwXTextField(SwDoc & rDoc, SwFmtFld const& rFmt)
{
SwClientIter aIter(*rFmt.GetFld()->GetTyp());
@@ -1086,9 +1039,6 @@ SwXTextField * CreateSwXTextField(SwDoc & rDoc, SwFmtFld const& rFmt)
return pField ? pField : new SwXTextField( rFmt, &rDoc );
}
-/******************************************************************
- *
- ******************************************************************/
struct SwFieldProperties_Impl
{
String sPar1;
@@ -1136,17 +1086,13 @@ struct SwFieldProperties_Impl
};
TYPEINIT1(SwXTextField, SwClient);
-/* -----------------------------13.03.00 12:15--------------------------------
- ---------------------------------------------------------------------------*/
const uno::Sequence< sal_Int8 > & SwXTextField::getUnoTunnelId()
{
static uno::Sequence< sal_Int8 > aSeq = ::CreateUnoTunnelId();
return aSeq;
}
-/* -----------------------------10.03.00 18:04--------------------------------
- ---------------------------------------------------------------------------*/
sal_Int64 SAL_CALL SwXTextField::getSomething( const uno::Sequence< sal_Int8 >& rId )
throw(uno::RuntimeException)
{
@@ -1158,9 +1104,6 @@ sal_Int64 SAL_CALL SwXTextField::getSomething( const uno::Sequence< sal_Int8 >&
}
return 0;
}
-/*-- 14.12.98 11:37:14---------------------------------------------------
-
- -----------------------------------------------------------------------*/
SwXTextField::SwXTextField(sal_uInt16 nServiceId, SwDoc* pDoc) :
aLstnrCntnr( (XTextContent*)this),
@@ -1184,9 +1127,7 @@ SwXTextField::SwXTextField(sal_uInt16 nServiceId, SwDoc* pDoc) :
m_pProps->nUSHORT2 = USHRT_MAX;
}
-/*-- 14.12.98 11:37:15---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextField::SwXTextField(const SwFmtFld& rFmt, SwDoc* pDc) :
aLstnrCntnr( (XTextContent*)this),
pFmtFld(&rFmt),
@@ -1199,9 +1140,7 @@ SwXTextField::SwXTextField(const SwFmtFld& rFmt, SwDoc* pDc) :
{
pDc->GetUnoCallBack()->Add(this);
}
-/*-- 14.12.98 11:37:15---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextField::~SwXTextField()
{
if ( m_pTextObject )
@@ -1212,9 +1151,7 @@ SwXTextField::~SwXTextField()
delete m_pProps;
}
-/*-- 14.12.98 11:37:16---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::attachTextFieldMaster(const uno::Reference< beans::XPropertySet > & xFieldMaster)
throw( lang::IllegalArgumentException, uno::RuntimeException )
{
@@ -1237,9 +1174,7 @@ void SwXTextField::attachTextFieldMaster(const uno::Reference< beans::XPropertyS
throw lang::IllegalArgumentException();
}
-/*-- 14.12.98 11:37:16---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Reference< beans::XPropertySet > SwXTextField::getTextFieldMaster(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -1261,9 +1196,7 @@ uno::Reference< beans::XPropertySet > SwXTextField::getTextFieldMaster(void) th
return pMaster;
}
-/*-- 14.12.98 11:37:16---------------------------------------------------
- -----------------------------------------------------------------------*/
OUString SwXTextField::getPresentation(sal_Bool bShowCommand) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -1275,9 +1208,7 @@ OUString SwXTextField::getPresentation(sal_Bool bShowCommand) throw( uno::Runtim
throw uno::RuntimeException();
return sRet;
}
-/* -----------------18.02.99 13:39-------------------
- *
- * --------------------------------------------------*/
+
void SwXTextField::attachToRange(
const uno::Reference< text::XTextRange > & xTextRange)
throw( lang::IllegalArgumentException, uno::RuntimeException )
@@ -1851,18 +1782,14 @@ void SwXTextField::attachToRange(
else
throw lang::IllegalArgumentException();
}
-/*-- 14.12.98 11:37:18---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::attach(const uno::Reference< text::XTextRange > & xTextRange)
throw( lang::IllegalArgumentException, uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
attachToRange( xTextRange );
}
-/*-- 14.12.98 11:37:18---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Reference< text::XTextRange > SwXTextField::getAnchor(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -1883,9 +1810,7 @@ uno::Reference< text::XTextRange > SwXTextField::getAnchor(void) throw( uno::Ru
return aRef;
}
-/*-- 14.12.98 11:37:18---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::dispose(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -1908,26 +1833,20 @@ void SwXTextField::dispose(void) throw( uno::RuntimeException )
m_pTextObject = 0;
}
}
-/*-- 14.12.98 11:37:18---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::addEventListener(const uno::Reference< lang::XEventListener > & aListener) throw( uno::RuntimeException )
{
if(!GetRegisteredIn())
throw uno::RuntimeException();
aLstnrCntnr.AddListener(aListener);
}
-/*-- 14.12.98 11:37:18---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::removeEventListener(const uno::Reference< lang::XEventListener > & aListener) throw( uno::RuntimeException )
{
if(!GetRegisteredIn() || !aLstnrCntnr.RemoveListener(aListener))
throw uno::RuntimeException();
}
-/*-- 14.12.98 11:37:19---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Reference< beans::XPropertySetInfo > SwXTextField::getPropertySetInfo(void)
throw( uno::RuntimeException )
{
@@ -1949,9 +1868,7 @@ uno::Reference< beans::XPropertySetInfo > SwXTextField::getPropertySetInfo(void
throw uno::RuntimeException();
return aRef;
}
-/*-- 14.12.98 11:37:19---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::setPropertyValue(const OUString& rPropertyName, const uno::Any& rValue)
throw( beans::UnknownPropertyException, beans::PropertyVetoException, lang::IllegalArgumentException,
lang::WrappedTargetException, uno::RuntimeException )
@@ -2112,9 +2029,7 @@ void SwXTextField::setPropertyValue(const OUString& rPropertyName, const uno::An
else
throw uno::RuntimeException();
}
-/*-- 14.12.98 11:37:19---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Any SwXTextField::getPropertyValue(const OUString& rPropertyName)
throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
@@ -2300,37 +2215,27 @@ uno::Any SwXTextField::getPropertyValue(const OUString& rPropertyName)
}
return aRet;
}
-/*-- 14.12.98 11:37:20---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::addPropertyChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XPropertyChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:37:20---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::removePropertyChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XPropertyChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:37:20---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::addVetoableChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XVetoableChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/*-- 14.12.98 11:37:20---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextField::removeVetoableChangeListener(const OUString& /*PropertyName*/, const uno::Reference< beans::XVetoableChangeListener > & /*aListener*/) throw( beans::UnknownPropertyException, lang::WrappedTargetException, uno::RuntimeException )
{
DBG_WARNING("not implemented");
}
-/* -----------------------------23.03.01 13:15--------------------------------
- ---------------------------------------------------------------------------*/
void SwXTextField::update( ) throw (uno::RuntimeException)
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -2387,16 +2292,11 @@ void SwXTextField::update( ) throw (uno::RuntimeException)
else
m_bCallUpdate = sal_True;
}
-/* -----------------19.03.99 14:11-------------------
- *
- * --------------------------------------------------*/
+
OUString SwXTextField::getImplementationName(void) throw( uno::RuntimeException )
{
return C2U("SwXTextField");
}
-/* -----------------19.03.99 14:11-------------------
- *
- * --------------------------------------------------*/
static OUString OldNameToNewName_Impl( const OUString &rOld )
{
@@ -2426,9 +2326,7 @@ sal_Bool SwXTextField::supportsService(const OUString& rServiceName) throw( uno:
rServiceName.equalsAsciiL(
RTL_CONSTASCII_STRINGPARAM("com.sun.star.text.TextContent"));
}
-/* -----------------19.03.99 14:11-------------------
- *
- * --------------------------------------------------*/
+
uno::Sequence< OUString > SwXTextField::getSupportedServiceNames(void) throw( uno::RuntimeException )
{
OUString sServiceName = SwXServiceProvider::GetProviderName(m_nServiceId);
@@ -2458,9 +2356,6 @@ void SwXTextField::Invalidate()
}
}
-/* -----------------14.12.98 12:00-------------------
- *
- * --------------------------------------------------*/
void SwXTextField::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew)
{
switch( pOld ? pOld->Which() : 0 )
@@ -2483,9 +2378,7 @@ void SwXTextField::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew)
break;
}
}
-/*-- 14.12.98 11:37:21---------------------------------------------------
- -----------------------------------------------------------------------*/
const SwField* SwXTextField::GetField() const
{
if(GetRegisteredIn() && pFmtFld)
@@ -2494,29 +2387,19 @@ const SwField* SwXTextField::GetField() const
}
/******************************************************************
- *
- ******************************************************************/
-/******************************************************************
* SwXTextFieldMasters
******************************************************************/
-/* -----------------------------06.04.00 13:22--------------------------------
-
- ---------------------------------------------------------------------------*/
OUString SwXTextFieldMasters::getImplementationName(void) throw( uno::RuntimeException )
{
return C2U("SwXTextFieldMasters");
}
-/* -----------------------------06.04.00 13:22--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SwXTextFieldMasters::supportsService(const OUString& rServiceName) throw( uno::RuntimeException )
{
return rServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.text.TextFieldMasters" ));
}
-/* -----------------------------06.04.00 13:22--------------------------------
- ---------------------------------------------------------------------------*/
uno::Sequence< OUString > SwXTextFieldMasters::getSupportedServiceNames(void) throw( uno::RuntimeException )
{
uno::Sequence< OUString > aRet(1);
@@ -2524,20 +2407,17 @@ uno::Sequence< OUString > SwXTextFieldMasters::getSupportedServiceNames(void) th
pArray[0] = C2U("com.sun.star.text.TextFieldMasters");
return aRet;
}
-/*-- 21.12.98 10:37:14---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextFieldMasters::SwXTextFieldMasters(SwDoc* _pDoc) :
SwUnoCollection(_pDoc)
{
}
-/*-- 21.12.98 10:37:32---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextFieldMasters::~SwXTextFieldMasters()
{
}
+
/*-- 21.12.98 10:37:33---------------------------------------------------
Iteration ueber nicht-Standard Feldtypen
USER/SETEXP/DDE/DATABASE
@@ -2550,7 +2430,6 @@ SwXTextFieldMasters::~SwXTextFieldMasters()
Falls wir grosszuegig werden wollen, dann koennte man com.sun.star.text
auch optional weglassen
-----------------------------------------------------------------------*/
-
sal_uInt16 lcl_GetIdByName( String& rName, String& rTypeName )
{
if( rName.EqualsAscii( COM_TEXT_FLDMASTER, 0, RTL_CONSTASCII_LENGTH(COM_TEXT_FLDMASTER ))
@@ -2593,7 +2472,6 @@ sal_uInt16 lcl_GetIdByName( String& rName, String& rTypeName )
return nResId;
}
-//-----------------------------------------------------------------------------
uno::Any SwXTextFieldMasters::getByName(const OUString& rName)
throw( container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException )
{
@@ -2618,9 +2496,7 @@ uno::Any SwXTextFieldMasters::getByName(const OUString& rName)
uno::Any aRet(&aRef, ::getCppuType( static_cast<const uno::Reference<beans::XPropertySet>* >(0)));
return aRet;
}
-/*-- 06.03.2001 11:29:34,5-------------------------------------------------
- -----------------------------------------------------------------------*/
sal_Bool SwXTextFieldMasters::getInstanceName(
const SwFieldType& rFldType, String& rName)
{
@@ -2666,10 +2542,6 @@ sal_Bool SwXTextFieldMasters::getInstanceName(
return bRet;
}
-
-/*-- 21.12.98 10:37:33---------------------------------------------------
-
- -----------------------------------------------------------------------*/
uno::Sequence< OUString > SwXTextFieldMasters::getElementNames(void)
throw( uno::RuntimeException )
{
@@ -2707,9 +2579,7 @@ uno::Sequence< OUString > SwXTextFieldMasters::getElementNames(void)
return aSeq;
}
-/*-- 21.12.98 10:37:33---------------------------------------------------
- -----------------------------------------------------------------------*/
sal_Bool SwXTextFieldMasters::hasByName(const OUString& rName) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -2726,17 +2596,13 @@ sal_Bool SwXTextFieldMasters::hasByName(const OUString& rName) throw( uno::Runti
}
return bRet;
}
-/*-- 21.12.98 10:37:34---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Type SwXTextFieldMasters::getElementType(void) throw( uno::RuntimeException )
{
return ::getCppuType(static_cast<const uno::Reference<beans::XPropertySet>*>(0));
}
-/*-- 21.12.98 10:37:34---------------------------------------------------
- -----------------------------------------------------------------------*/
sal_Bool SwXTextFieldMasters::hasElements(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -2745,27 +2611,17 @@ sal_Bool SwXTextFieldMasters::hasElements(void) throw( uno::RuntimeException )
return sal_True;
}
-/******************************************************************
- *
- ******************************************************************/
-/* -----------------------------06.04.00 13:24--------------------------------
-
- ---------------------------------------------------------------------------*/
OUString SwXTextFieldTypes::getImplementationName(void) throw( uno::RuntimeException )
{
return C2U("SwXTextFieldTypes");
}
-/* -----------------------------06.04.00 13:24--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SwXTextFieldTypes::supportsService(const OUString& rServiceName) throw( uno::RuntimeException )
{
return rServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.text.TextFields" ));
}
-/* -----------------------------06.04.00 13:24--------------------------------
- ---------------------------------------------------------------------------*/
uno::Sequence< OUString > SwXTextFieldTypes::getSupportedServiceNames(void) throw( uno::RuntimeException )
{
uno::Sequence< OUString > aRet(1);
@@ -2773,31 +2629,23 @@ uno::Sequence< OUString > SwXTextFieldTypes::getSupportedServiceNames(void) thro
pArray[0] = C2U("com.sun.star.text.TextFields");
return aRet;
}
-/*-- 21.12.98 10:35:15---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextFieldTypes::SwXTextFieldTypes(SwDoc* _pDoc) :
SwUnoCollection (_pDoc),
aRefreshCont ( static_cast< XEnumerationAccess * >(this) )
{
}
-/*-- 21.12.98 10:35:16---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXTextFieldTypes::~SwXTextFieldTypes()
{
}
-/*-- 11.07.02 14:25:00---------------------------------------------------
- -----------------------------------------------------------------------*/
void SwXTextFieldTypes::Invalidate()
{
SwUnoCollection::Invalidate();
aRefreshCont.Disposing();
}
-/*-- 21.12.98 10:35:17---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Reference< container::XEnumeration > SwXTextFieldTypes::createEnumeration(void)
throw( uno::RuntimeException )
{
@@ -2807,16 +2655,11 @@ uno::Reference< container::XEnumeration > SwXTextFieldTypes::createEnumeration(
return new SwXFieldEnumeration(GetDoc());
}
-/*-- 21.12.98 10:35:17---------------------------------------------------
-
- -----------------------------------------------------------------------*/
uno::Type SwXTextFieldTypes::getElementType(void) throw( uno::RuntimeException )
{
return ::getCppuType(static_cast<const uno::Reference<text::XDependentTextField>*>(0));
}
-/*-- 21.12.98 10:35:17---------------------------------------------------
- -----------------------------------------------------------------------*/
sal_Bool SwXTextFieldTypes::hasElements(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -2825,9 +2668,7 @@ sal_Bool SwXTextFieldTypes::hasElements(void) throw( uno::RuntimeException )
//es gibt sie immer
return sal_True;
}
-/* -----------------24.02.99 16:19-------------------
- *
- * --------------------------------------------------*/
+
void SwXTextFieldTypes::refresh(void) throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
@@ -2841,9 +2682,7 @@ void SwXTextFieldTypes::refresh(void) throw( uno::RuntimeException )
// call refresh listeners
aRefreshCont.Refreshed();
}
-/* -----------------24.02.99 16:19-------------------
- *
- * --------------------------------------------------*/
+
void SwXTextFieldTypes::addRefreshListener(const uno::Reference< util::XRefreshListener > & l)
throw( uno::RuntimeException )
{
@@ -2852,9 +2691,7 @@ void SwXTextFieldTypes::addRefreshListener(const uno::Reference< util::XRefreshL
throw uno::RuntimeException();
aRefreshCont.AddListener ( reinterpret_cast < const uno::Reference < lang::XEventListener > &> ( l ));
}
-/* -----------------24.02.99 16:19-------------------
- *
- * --------------------------------------------------*/
+
void SwXTextFieldTypes::removeRefreshListener(const uno::Reference< util::XRefreshListener > & l)
throw( uno::RuntimeException )
{
@@ -2862,27 +2699,21 @@ void SwXTextFieldTypes::removeRefreshListener(const uno::Reference< util::XRefre
if ( !IsValid() || !aRefreshCont.RemoveListener ( reinterpret_cast < const uno::Reference < lang::XEventListener > &> ( l ) ) )
throw uno::RuntimeException();
}
+
/******************************************************************
* SwXFieldEnumeration
******************************************************************/
-/* -----------------------------06.04.00 13:25--------------------------------
-
- ---------------------------------------------------------------------------*/
OUString SwXFieldEnumeration::getImplementationName(void) throw( uno::RuntimeException )
{
return C2U("SwXFieldEnumeration");
}
-/* -----------------------------06.04.00 13:25--------------------------------
- ---------------------------------------------------------------------------*/
BOOL SwXFieldEnumeration::supportsService(const OUString& rServiceName) throw( uno::RuntimeException )
{
return rServiceName.equalsAsciiL( RTL_CONSTASCII_STRINGPARAM(
"com.sun.star.text.FieldEnumeration" ));
}
-/* -----------------------------06.04.00 13:25--------------------------------
- ---------------------------------------------------------------------------*/
uno::Sequence< OUString > SwXFieldEnumeration::getSupportedServiceNames(void) throw( uno::RuntimeException )
{
uno::Sequence< OUString > aRet(1);
@@ -2890,9 +2721,7 @@ uno::Sequence< OUString > SwXFieldEnumeration::getSupportedServiceNames(void) th
pArray[0] = C2U("com.sun.star.text.FieldEnumeration");
return aRet;
}
-/* -----------------21.12.98 14:57-------------------
- *
- * --------------------------------------------------*/
+
SwXFieldEnumeration::SwXFieldEnumeration(SwDoc* pDc) :
nNextIndex(0),
pDoc(pDc)
@@ -2951,25 +2780,19 @@ SwXFieldEnumeration::SwXFieldEnumeration(SwDoc* pDc) :
// resize sequence to actual used size
aItems.realloc( nFillPos );
}
-/*-- 21.12.98 14:57:23---------------------------------------------------
- -----------------------------------------------------------------------*/
SwXFieldEnumeration::~SwXFieldEnumeration()
{
}
-/*-- 21.12.98 14:57:42---------------------------------------------------
- -----------------------------------------------------------------------*/
sal_Bool SwXFieldEnumeration::hasMoreElements(void)
throw( uno::RuntimeException )
{
vos::OGuard aGuard(Application::GetSolarMutex());
return nNextIndex < aItems.getLength();
}
-/*-- 21.12.98 14:57:42---------------------------------------------------
- -----------------------------------------------------------------------*/
uno::Any SwXFieldEnumeration::nextElement(void)
throw( container::NoSuchElementException, lang::WrappedTargetException, uno::RuntimeException )
{
@@ -2987,9 +2810,7 @@ uno::Any SwXFieldEnumeration::nextElement(void)
rxFld = 0; // free memory for item that is not longer used
return aRet;
}
-/* -----------------21.12.98 15:08-------------------
- *
- * --------------------------------------------------*/
+
void SwXFieldEnumeration::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew)
{
ClientModify(this, pOld, pNew);
@@ -2997,7 +2818,6 @@ void SwXFieldEnumeration::Modify( SfxPoolItem *pOld, SfxPoolItem *pNew)
pDoc = 0;
}
-
String& GetString( const uno::Any& rAny, String& rStr )
{
OUString aStr;