summaryrefslogtreecommitdiff
path: root/forms/source/component
diff options
context:
space:
mode:
authorIvo Hinkelmann <ihi@openoffice.org>2009-04-23 10:42:05 +0000
committerIvo Hinkelmann <ihi@openoffice.org>2009-04-23 10:42:05 +0000
commitba529cb1b23c226f2ac884cdff1677446f6547d4 (patch)
treecacc5832ae2a0b184fdc6351ff7fad1a1a22682f /forms/source/component
parent9be1bfd0ee5741ef435813debb1bf31bddc57a14 (diff)
CWS-TOOLING: integrate CWS dbaperf1
2009-04-02 09:12:25 +0200 oj r270372 : CWS-TOOLING: rebase CWS dbaperf1 to trunk@270033 (milestone: DEV300:m45) 2009-03-17 10:20:34 +0100 oj r269577 : add parameter 2009-03-17 10:20:05 +0100 oj r269576 : add parameter 2009-03-12 12:32:24 +0100 oj r269387 : add missing ++ 2009-03-11 12:53:35 +0100 oj r269315 : compile error 2009-03-06 08:52:11 +0100 oj r268968 : #i99264# remove duplicate code 2009-03-06 08:20:08 +0100 oj r268966 : add missingheader 2009-03-06 08:17:41 +0100 oj r268965 : add header 2009-03-06 08:15:07 +0100 oj r268964 : #i99708# remove duplicate code 2009-03-06 07:24:11 +0100 oj r268963 : #i99708# remove duplicate code 2009-03-06 07:22:24 +0100 oj r268962 : #i99708# use tenary operator 2009-03-06 07:19:21 +0100 oj r268961 : remove unused rtl_logs 2009-03-06 07:15:55 +0100 oj r268960 : #i99708# extract getLength from for loop 2009-03-06 07:15:35 +0100 oj r268959 : #i99708# extract getLength from for loop 2009-03-06 07:14:57 +0100 oj r268958 : remove unused rtl_logs 2009-03-06 07:13:01 +0100 oj r268957 : insert DBG_ helper 2009-03-06 07:12:17 +0100 oj r268956 : remove unused rtl_logs 2009-03-06 07:10:26 +0100 oj r268955 : remove unused rtl_logs 2009-03-06 07:04:51 +0100 oj r268954 : #i99708# use tenary operator 2009-03-05 12:04:46 +0100 oj r268895 : comment RTL_LOG out 2009-03-05 09:05:07 +0100 oj r268874 : add rtl logfile 2009-03-04 14:21:18 +0100 oj r268828 : #i99708# make static inplace and some method calls in for loop removed 2009-03-04 14:20:34 +0100 oj r268827 : #i99708# impl double check pattern for getInfohelper 2009-03-02 09:31:42 +0100 oj r268636 : add rtl logfile 2009-03-02 08:18:37 +0100 oj r268633 : add rtl logfile 2009-02-27 11:22:16 +0100 oj r268570 : #i99709# change algorithm for marking objects 2009-02-27 11:17:04 +0100 oj r268568 : #i99708# some improvements to load forms, controls faster and replacement of size() call with !empty() which is much faster 2009-02-24 10:09:35 +0100 sb r268383 : #i99290# no longer care to set a sensible context class loader for native threads attached to the VM 2009-02-23 13:44:04 +0100 oj r268354 : #i76606# seekrow changes 2009-02-23 12:27:30 +0100 oj r268349 : deleted 2009-02-20 15:14:23 +0100 oj r268325 : #i76606# some code changes 2009-02-19 14:15:25 +0100 oj r268284 : #i76606# use of simple prep stmt instead of full blown rowset, when source and dest connection are the same use insert into ... ( select ... ) 2009-02-19 11:27:55 +0100 oj r268265 : #i76606# insert some RTL_LOG and setObject impl 2009-02-18 14:45:37 +0100 oj r268222 : #i99363# insert RTL_LOG 2009-02-18 14:45:18 +0100 oj r268221 : #i99363# insert RTL_LOG 2009-02-18 11:14:54 +0100 oj r268207 : #i99363# call some impl_ methods to avoid duplicate cechCache calls 2009-02-18 11:10:47 +0100 oj r268206 : #i99363# make isCount inline 2009-02-18 10:33:22 +0100 oj r268203 : #i99363# use bookmarkable if available and inserted some RTL_LOG 2009-02-18 10:32:57 +0100 oj r268202 : #i99363# use bookmarkable if available and inserted some RTL_LOG 2009-02-17 07:29:05 +0100 oj r267843 : #i96897# remove some dll public 2009-02-16 15:01:04 +0100 oj r267816 : #i96897# remove some dll public 2009-02-16 14:25:53 +0100 oj r267810 : #i99264# remove duplicate code 2009-02-16 14:25:33 +0100 oj r267809 : #i99264# remove duplicate code 2009-02-16 14:24:59 +0100 oj r267808 : #i99264# remove duplicate code 2009-02-13 10:56:17 +0100 oj r267703 : #i99191# comment the contextclassloader 2009-02-13 10:32:40 +0100 oj r267700 : reduce call to resultset meta data 2009-02-13 10:27:31 +0100 oj r267699 : reduce call to resultset meta data 2009-02-13 10:27:08 +0100 oj r267698 : reduce call to resultset meta data
Diffstat (limited to 'forms/source/component')
-rw-r--r--forms/source/component/DatabaseForm.cxx161
-rw-r--r--forms/source/component/DatabaseForm.hxx1
-rw-r--r--forms/source/component/FormComponent.cxx113
-rw-r--r--forms/source/component/propertybaghelper.cxx51
4 files changed, 173 insertions, 153 deletions
diff --git a/forms/source/component/DatabaseForm.cxx b/forms/source/component/DatabaseForm.cxx
index c7281f2d0..dc8d5af83 100644
--- a/forms/source/component/DatabaseForm.cxx
+++ b/forms/source/component/DatabaseForm.cxx
@@ -452,14 +452,18 @@ ODatabaseForm::~ODatabaseForm()
//------------------------------------------------------------------------
::rtl::OUString ODatabaseForm::GetDataURLEncoded(const Reference<XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt)
{
-
+ return GetDataEncoded(true,SubmitButton,MouseEvt);
+}
+// -----------------------------------------------------------------------------
+::rtl::OUString ODatabaseForm::GetDataEncoded(bool _bURLEncoded,const Reference<XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt)
+{
// Liste von successful Controls fuellen
HtmlSuccessfulObjList aSuccObjList;
FillSuccessfulList( aSuccObjList, SubmitButton, MouseEvt );
// Liste zu ::rtl::OUString zusammensetzen
- ::rtl::OUString aResult;
+ ::rtl::OUStringBuffer aResult;
::rtl::OUString aName;
::rtl::OUString aValue;
@@ -482,17 +486,24 @@ ODatabaseForm::~ODatabaseForm()
}
Encode( aName );
Encode( aValue );
- aResult += aName;
- aResult += UniString('=');
- aResult += aValue;
+
+ aResult.append(aName);
+ aResult.append(sal_Unicode('='));
+ aResult.append(aValue);
+
if (pSuccObj < aSuccObjList.end() - 1)
- aResult += UniString('&');
+ {
+ if ( _bURLEncoded )
+ aResult.append(sal_Unicode('&'));
+ else
+ aResult.appendAscii("\r\n");
+ }
}
aSuccObjList.clear();
- return aResult;
+ return aResult.makeStringAndClear();
}
//==============================================================================
@@ -500,46 +511,7 @@ ODatabaseForm::~ODatabaseForm()
//------------------------------------------------------------------------
::rtl::OUString ODatabaseForm::GetDataTextEncoded(const Reference<XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt)
{
-
- // Liste von successful Controls fuellen
- HtmlSuccessfulObjList aSuccObjList;
- FillSuccessfulList( aSuccObjList, SubmitButton, MouseEvt );
- // Liste zu ::rtl::OUString zusammensetzen
- ::rtl::OUString aResult;
- ::rtl::OUString aName;
- ::rtl::OUString aValue;
-
- for ( HtmlSuccessfulObjListIterator pSuccObj = aSuccObjList.begin();
- pSuccObj < aSuccObjList.end();
- ++pSuccObj
- )
- {
- aName = pSuccObj->aName;
- aValue = pSuccObj->aValue;
- if (pSuccObj->nRepresentation == SUCCESSFUL_REPRESENT_FILE && aValue.getLength())
- {
- // Bei File-URLs wird der Dateiname und keine URL uebertragen,
- // weil Netscape dies so macht.
- INetURLObject aURL;
- aURL.SetSmartProtocol(INET_PROT_FILE);
- aURL.SetSmartURL(aValue);
- if( INET_PROT_FILE == aURL.GetProtocol() )
- aValue = INetURLObject::decode(aURL.PathToFileName(), '%', INetURLObject::DECODE_UNAMBIGUOUS);
- }
- Encode( aName );
- Encode( aValue );
- aResult += pSuccObj->aName;
- aResult += UniString('=');
- aResult += pSuccObj->aValue;
- if (pSuccObj < aSuccObjList.end() - 1)
- aResult += ::rtl::OUString::createFromAscii("\r\n");
- }
-
-
- // Liste loeschen
- aSuccObjList.clear();
-
- return aResult;
+ return GetDataEncoded(false,SubmitButton,MouseEvt);
}
//------------------------------------------------------------------------
@@ -2148,7 +2120,36 @@ void SAL_CALL ODatabaseForm::submit( const Reference<XControl>& Control,
submit_impl( Control, MouseEvt, true );
}
}
+// -----------------------------------------------------------------------------
+void lcl_dispatch(const Reference< XFrame >& xFrame,const Reference<XURLTransformer>& xTransformer,const ::rtl::OUString& aURLStr,const ::rtl::OUString& aReferer,const ::rtl::OUString& aTargetName
+ ,const ::rtl::OUString& aData,rtl_TextEncoding _eEncoding)
+{
+ URL aURL;
+ aURL.Complete = aURLStr;
+ xTransformer->parseStrict(aURL);
+ Reference< XDispatch > xDisp = Reference< XDispatchProvider > (xFrame,UNO_QUERY)->queryDispatch(aURL, aTargetName,
+ FrameSearchFlag::SELF | FrameSearchFlag::PARENT | FrameSearchFlag::CHILDREN |
+ FrameSearchFlag::SIBLINGS | FrameSearchFlag::CREATE | FrameSearchFlag::TASKS);
+
+ if (xDisp.is())
+ {
+ Sequence<PropertyValue> aArgs(2);
+ aArgs.getArray()[0].Name = ::rtl::OUString::createFromAscii("Referer");
+ aArgs.getArray()[0].Value <<= aReferer;
+
+ // build a sequence from the to-be-submitted string
+ ByteString a8BitData(aData.getStr(), (sal_uInt16)aData.getLength(), _eEncoding);
+ // always ANSI #58641
+ Sequence< sal_Int8 > aPostData((sal_Int8*)a8BitData.GetBuffer(), a8BitData.Len());
+ Reference< XInputStream > xPostData = new SequenceInputStream(aPostData);
+
+ aArgs.getArray()[1].Name = ::rtl::OUString::createFromAscii("PostData");
+ aArgs.getArray()[1].Value <<= xPostData;
+
+ xDisp->dispatch(aURL, aArgs);
+ } // if (xDisp.is())
+}
//------------------------------------------------------------------------------
void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com::sun::star::awt::MouseEvent& MouseEvt, bool _bAproveByListeners)
{
@@ -2196,6 +2197,9 @@ void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com:
if (!xModel.is())
return;
+ Reference< XFrame > xFrame = xModel->getCurrentController()->getFrame();
+ if (!xFrame.is())
+ return;
Reference<XURLTransformer>
xTransformer(m_xServiceFactory->createInstance(
@@ -2211,10 +2215,6 @@ void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com:
aData = GetDataURLEncoded( Control, MouseEvt );
}
- Reference< XFrame > xFrame = xModel->getCurrentController()->getFrame();
- if (!xFrame.is())
- return;
-
URL aURL;
// FormMethod GET
if( eSubmitMethod == FormSubmitMethod_GET )
@@ -2240,38 +2240,11 @@ void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com:
// FormMethod POST
else if( eSubmitMethod == FormSubmitMethod_POST )
{
- aURL.Complete = aURLStr;
- xTransformer->parseStrict(aURL);
-
- Reference< XDispatch > xDisp = Reference< XDispatchProvider > (xFrame,UNO_QUERY)->queryDispatch(aURL, aTargetName,
- FrameSearchFlag::SELF | FrameSearchFlag::PARENT | FrameSearchFlag::CHILDREN |
- FrameSearchFlag::SIBLINGS | FrameSearchFlag::CREATE | FrameSearchFlag::TASKS);
-
- if (xDisp.is())
- {
- Sequence<PropertyValue> aArgs(2);
- aArgs.getArray()[0].Name = ::rtl::OUString::createFromAscii("Referer");
- aArgs.getArray()[0].Value <<= aReferer;
-
- // build a sequence from the to-be-submitted string
- ByteString a8BitData(aData.getStr(), (sal_uInt16)aData.getLength(), RTL_TEXTENCODING_MS_1252);
- // always ANSI #58641
- Sequence< sal_Int8 > aPostData((sal_Int8*)a8BitData.GetBuffer(), a8BitData.Len());
- Reference< XInputStream > xPostData = new SequenceInputStream(aPostData);
-
- aArgs.getArray()[1].Name = ::rtl::OUString::createFromAscii("PostData");
- aArgs.getArray()[1].Value <<= xPostData;
-
- xDisp->dispatch(aURL, aArgs);
- }
+ lcl_dispatch(xFrame,xTransformer,aURLStr,aReferer,aTargetName,aData,RTL_TEXTENCODING_MS_1252);
}
}
else if( eSubmitEncoding == FormSubmitEncoding_MULTIPART )
{
- Reference< XFrame > xFrame = xModel->getCurrentController()->getFrame();
- if (!xFrame.is())
- return;
-
URL aURL;
aURL.Complete = aURLStr;
xTransformer->parseStrict(aURL);
@@ -2314,35 +2287,7 @@ void ODatabaseForm::submit_impl(const Reference<XControl>& Control, const ::com:
aData = GetDataTextEncoded( Reference<XControl> (), MouseEvt );
}
- Reference< XFrame > xFrame = xModel->getCurrentController()->getFrame();
- if (!xFrame.is())
- return;
-
- URL aURL;
-
- aURL.Complete = aURLStr;
- xTransformer->parseStrict(aURL);
-
- Reference< XDispatch > xDisp = Reference< XDispatchProvider > (xFrame,UNO_QUERY)->queryDispatch(aURL, aTargetName,
- FrameSearchFlag::SELF | FrameSearchFlag::PARENT | FrameSearchFlag::CHILDREN |
- FrameSearchFlag::SIBLINGS | FrameSearchFlag::CREATE | FrameSearchFlag::TASKS);
-
- if (xDisp.is())
- {
- Sequence<PropertyValue> aArgs(2);
- aArgs.getArray()[0].Name = ::rtl::OUString::createFromAscii("Referer");
- aArgs.getArray()[0].Value <<= aReferer;
-
- // build a sequence from the to-be-submitted string
- ByteString aSystemEncodedData(aData.getStr(), (sal_uInt16)aData.getLength(), osl_getThreadTextEncoding());
- Sequence< sal_Int8 > aPostData((sal_Int8*)aSystemEncodedData.GetBuffer(), aSystemEncodedData.Len());
- Reference< XInputStream > xPostData = new SequenceInputStream(aPostData);
-
- aArgs.getArray()[1].Name = ::rtl::OUString::createFromAscii("PostData");
- aArgs.getArray()[1].Value <<= xPostData;
-
- xDisp->dispatch(aURL, aArgs);
- }
+ lcl_dispatch(xFrame,xTransformer,aURLStr,aReferer,aTargetName,aData,osl_getThreadTextEncoding());
}
else {
DBG_ERROR("ODatabaseForm::submit_Impl : wrong encoding !");
diff --git a/forms/source/component/DatabaseForm.hxx b/forms/source/component/DatabaseForm.hxx
index ba37eb9c1..1748a2dad 100644
--- a/forms/source/component/DatabaseForm.hxx
+++ b/forms/source/component/DatabaseForm.hxx
@@ -524,6 +524,7 @@ private:
void onError(const ::com::sun::star::sdbc::SQLException&, const ::rtl::OUString& _rContextDescription);
// html tools
+ ::rtl::OUString GetDataEncoded(bool _bURLEncoded,const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt);
::rtl::OUString GetDataURLEncoded(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt);
::rtl::OUString GetDataTextEncoded(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt);
::com::sun::star::uno::Sequence<sal_Int8> GetDataMultiPartEncoded(const ::com::sun::star::uno::Reference< ::com::sun::star::awt::XControl>& SubmitButton, const ::com::sun::star::awt::MouseEvent& MouseEvt,
diff --git a/forms/source/component/FormComponent.cxx b/forms/source/component/FormComponent.cxx
index 23fc5ecaa..f967c7241 100644
--- a/forms/source/component/FormComponent.cxx
+++ b/forms/source/component/FormComponent.cxx
@@ -31,38 +31,38 @@
// MARKER(update_precomp.py): autogen include statement, do not remove
#include "precompiled_forms.hxx"
-#include "componenttools.hxx"
-#include "FormComponent.hxx"
-#include "frm_resource.hrc"
-#include "frm_resource.hxx"
-#include "property.hrc"
-#include "services.hxx"
-
-/** === begin UNO includes === **/
-#include <com/sun/star/awt/XTextComponent.hpp>
-#include <com/sun/star/awt/XVclWindowPeer.hpp>
-#include <com/sun/star/awt/XWindow.hpp>
-#include <com/sun/star/form/XForm.hpp>
-#include <com/sun/star/form/XLoadable.hpp>
-#include <com/sun/star/io/XMarkableStream.hpp>
-#include <com/sun/star/lang/DisposedException.hpp>
-#include <com/sun/star/sdb/XRowSetChangeBroadcaster.hpp>
-#include <com/sun/star/sdb/XRowSetSupplier.hpp>
-#include <com/sun/star/sdbc/ColumnValue.hpp>
-#include <com/sun/star/sdbc/DataType.hpp>
-#include <com/sun/star/util/XModifyBroadcaster.hpp>
-/** === end UNO includes === **/
-
-#include <comphelper/basicio.hxx>
-#include <comphelper/guarding.hxx>
-#include <comphelper/listenernotification.hxx>
-#include <comphelper/property.hxx>
-#include <connectivity/dbtools.hxx>
-#include <cppuhelper/queryinterface.hxx>
-#include <rtl/logfile.hxx>
-#include <toolkit/helper/emptyfontdescriptor.hxx>
-#include <tools/debug.hxx>
-#include <tools/diagnose_ex.h>
+#include "componenttools.hxx"
+#include "FormComponent.hxx"
+#include "frm_resource.hrc"
+#include "frm_resource.hxx"
+#include "property.hrc"
+#include "services.hxx"
+
+/** === begin UNO includes === **/
+#include <com/sun/star/awt/XTextComponent.hpp>
+#include <com/sun/star/awt/XVclWindowPeer.hpp>
+#include <com/sun/star/awt/XWindow.hpp>
+#include <com/sun/star/form/XForm.hpp>
+#include <com/sun/star/form/XLoadable.hpp>
+#include <com/sun/star/io/XMarkableStream.hpp>
+#include <com/sun/star/lang/DisposedException.hpp>
+#include <com/sun/star/sdb/XRowSetChangeBroadcaster.hpp>
+#include <com/sun/star/sdb/XRowSetSupplier.hpp>
+#include <com/sun/star/sdbc/ColumnValue.hpp>
+#include <com/sun/star/sdbc/DataType.hpp>
+#include <com/sun/star/util/XModifyBroadcaster.hpp>
+/** === end UNO includes === **/
+
+#include <comphelper/basicio.hxx>
+#include <comphelper/guarding.hxx>
+#include <comphelper/listenernotification.hxx>
+#include <comphelper/property.hxx>
+#include <connectivity/dbtools.hxx>
+#include <cppuhelper/queryinterface.hxx>
+#include <rtl/logfile.hxx>
+#include <toolkit/helper/emptyfontdescriptor.hxx>
+#include <tools/debug.hxx>
+#include <tools/diagnose_ex.h>
#include <functional>
#include <algorithm>
@@ -523,12 +523,14 @@ DBG_NAME(OControlModel)
//------------------------------------------------------------------
Sequence<sal_Int8> SAL_CALL OControlModel::getImplementationId() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getImplementationId" );
return OImplementationIds::getImplementationId(getTypes());
}
//------------------------------------------------------------------
Sequence<Type> SAL_CALL OControlModel::getTypes() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getTypes" );
TypeBag aTypes( _getTypes() );
Reference< XTypeProvider > xProv;
@@ -541,6 +543,7 @@ Sequence<Type> SAL_CALL OControlModel::getTypes() throw(RuntimeException)
//------------------------------------------------------------------------------
Sequence<Type> OControlModel::_getTypes()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::_getTypes" );
return TypeBag( OComponentHelper::getTypes(),
OPropertySetAggregationHelper::getTypes(),
OControlModel_BASE::getTypes()
@@ -550,6 +553,7 @@ Sequence<Type> OControlModel::_getTypes()
//------------------------------------------------------------------
Any SAL_CALL OControlModel::queryAggregation(const Type& _rType) throw (RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::queryAggregation" );
// base class 1
Any aReturn(OComponentHelper::queryAggregation(_rType));
@@ -573,6 +577,7 @@ Any SAL_CALL OControlModel::queryAggregation(const Type& _rType) throw (RuntimeE
//------------------------------------------------------------------------------
void OControlModel::readHelpTextCompatibly(const staruno::Reference< stario::XObjectInputStream >& _rxInStream)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::readHelpTextCompatibly" );
::rtl::OUString sHelpText;
::comphelper::operator>>( _rxInStream, sHelpText);
try
@@ -589,6 +594,7 @@ void OControlModel::readHelpTextCompatibly(const staruno::Reference< stario::XOb
//------------------------------------------------------------------------------
void OControlModel::writeHelpTextCompatibly(const staruno::Reference< stario::XObjectOutputStream >& _rxOutStream)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::writeHelpTextCompatibly" );
::rtl::OUString sHelpText;
try
{
@@ -619,6 +625,7 @@ OControlModel::OControlModel(
// the native look is ugly ....
// #i37342# / 2004-11-19 / frank.schoenheit@sun.com
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::OControlModel" );
DBG_CTOR(OControlModel, NULL);
if (_rUnoControlModelTypeName.getLength()) // the is a model we have to aggregate
{
@@ -660,6 +667,7 @@ OControlModel::OControlModel( const OControlModel* _pOriginal, const Reference<
,m_nTabIndex( FRM_DEFAULT_TABINDEX )
,m_nClassId( FormComponentType::CONTROL )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::OControlModel(copy)" );
DBG_CTOR( OControlModel, NULL );
DBG_ASSERT( _pOriginal, "OControlModel::OControlModel: invalid original!" );
@@ -704,12 +712,14 @@ OControlModel::~OControlModel()
//------------------------------------------------------------------
void OControlModel::clonedFrom( const OControlModel* /*_pOriginal*/ )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::clonedFrom" );
// nothing to do in this base class
}
//------------------------------------------------------------------------------
void OControlModel::doResetDelegator()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::doResetDelegator" );
if (m_xAggregate.is())
m_xAggregate->setDelegator(NULL);
}
@@ -717,6 +727,7 @@ void OControlModel::doResetDelegator()
//------------------------------------------------------------------------------
void OControlModel::doSetDelegator()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::doSetDelegator" );
increment(m_refCount);
if (m_xAggregate.is())
{
@@ -729,12 +740,14 @@ void OControlModel::doSetDelegator()
//------------------------------------------------------------------------------
InterfaceRef SAL_CALL OControlModel::getParent() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getParent" );
return m_xParent;
}
//------------------------------------------------------------------------------
void SAL_CALL OControlModel::setParent(const InterfaceRef& _rxParent) throw(com::sun::star::lang::NoSupportException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setParent" );
osl::MutexGuard aGuard(m_aMutex);
Reference<XComponent> xComp(m_xParent, UNO_QUERY);
@@ -752,6 +765,7 @@ void SAL_CALL OControlModel::setParent(const InterfaceRef& _rxParent) throw(com:
//------------------------------------------------------------------------------
::rtl::OUString SAL_CALL OControlModel::getName() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getName" );
::rtl::OUString aReturn;
OPropertySetHelper::getFastPropertyValue(PROPERTY_ID_NAME) >>= aReturn;
return aReturn;
@@ -760,6 +774,7 @@ void SAL_CALL OControlModel::setParent(const InterfaceRef& _rxParent) throw(com:
//------------------------------------------------------------------------------
void SAL_CALL OControlModel::setName(const ::rtl::OUString& _rName) throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setName" );
setFastPropertyValue(PROPERTY_ID_NAME, makeAny(_rName));
}
@@ -767,6 +782,7 @@ void SAL_CALL OControlModel::setName(const ::rtl::OUString& _rName) throw(Runtim
//------------------------------------------------------------------------------
sal_Bool SAL_CALL OControlModel::supportsService(const rtl::OUString& _rServiceName) throw ( RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::supportsService" );
Sequence<rtl::OUString> aSupported = getSupportedServiceNames();
const rtl::OUString* pSupported = aSupported.getConstArray();
for (sal_Int32 i=0; i<aSupported.getLength(); ++i, ++pSupported)
@@ -778,6 +794,7 @@ sal_Bool SAL_CALL OControlModel::supportsService(const rtl::OUString& _rServiceN
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > OControlModel::getAggregateServiceNames()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getAggregateServiceNames" );
Sequence< ::rtl::OUString > aAggServices;
Reference< XServiceInfo > xInfo;
if ( query_aggregation( m_xAggregate, xInfo ) )
@@ -788,6 +805,7 @@ Sequence< ::rtl::OUString > OControlModel::getAggregateServiceNames()
//------------------------------------------------------------------------------
Sequence<rtl::OUString> SAL_CALL OControlModel::getSupportedServiceNames() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getSupportedServiceNames" );
return ::comphelper::concatSequences(
getAggregateServiceNames(),
getSupportedServiceNames_Static()
@@ -797,6 +815,7 @@ Sequence<rtl::OUString> SAL_CALL OControlModel::getSupportedServiceNames() throw
//------------------------------------------------------------------------------
Sequence< ::rtl::OUString > SAL_CALL OControlModel::getSupportedServiceNames_Static() throw( RuntimeException )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getSupportedServiceNames_Static" );
Sequence< ::rtl::OUString > aServiceNames( 2 );
aServiceNames[ 0 ] = FRM_SUN_FORMCOMPONENT;
aServiceNames[ 1 ] = ::rtl::OUString::createFromAscii( "com.sun.star.form.FormControlModel" );
@@ -807,6 +826,7 @@ Sequence< ::rtl::OUString > SAL_CALL OControlModel::getSupportedServiceNames_Sta
//------------------------------------------------------------------------------
void SAL_CALL OControlModel::disposing(const com::sun::star::lang::EventObject& _rSource) throw (RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::disposing" );
// release the parent
if (_rSource.Source == m_xParent)
{
@@ -828,6 +848,7 @@ void SAL_CALL OControlModel::disposing(const com::sun::star::lang::EventObject&
//-----------------------------------------------------------------------------
void OControlModel::disposing()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::disposing" );
OPropertySetAggregationHelper::disposing();
Reference<com::sun::star::lang::XComponent> xComp;
@@ -842,6 +863,7 @@ void OControlModel::disposing()
//------------------------------------------------------------------------------
void OControlModel::writeAggregate( const Reference< XObjectOutputStream >& _rxOutStream ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::writeAggregate" );
Reference< XPersistObject > xPersist;
if ( query_aggregation( m_xAggregate, xPersist ) )
xPersist->write( _rxOutStream );
@@ -850,6 +872,7 @@ void OControlModel::writeAggregate( const Reference< XObjectOutputStream >& _rxO
//------------------------------------------------------------------------------
void OControlModel::readAggregate( const Reference< XObjectInputStream >& _rxInStream )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::readAggregate" );
Reference< XPersistObject > xPersist;
if ( query_aggregation( m_xAggregate, xPersist ) )
xPersist->read( _rxInStream );
@@ -859,6 +882,7 @@ void OControlModel::readAggregate( const Reference< XObjectInputStream >& _rxInS
void SAL_CALL OControlModel::write(const Reference<stario::XObjectOutputStream>& _rxOutStream)
throw(stario::IOException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::write" );
osl::MutexGuard aGuard(m_aMutex);
// 1. Schreiben des UnoControls
@@ -904,6 +928,7 @@ void SAL_CALL OControlModel::write(const Reference<stario::XObjectOutputStream>&
//------------------------------------------------------------------------------
void OControlModel::read(const Reference<stario::XObjectInputStream>& InStream) throw (::com::sun::star::io::IOException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::read" );
osl::MutexGuard aGuard(m_aMutex);
Reference<stario::XMarkableStream> xMark(InStream, UNO_QUERY);
@@ -957,6 +982,7 @@ void OControlModel::read(const Reference<stario::XObjectInputStream>& InStream)
//------------------------------------------------------------------------------
PropertyState OControlModel::getPropertyStateByHandle( sal_Int32 _nHandle )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getPropertyStateByHandle" );
// simply compare the current and the default value
Any aCurrentValue = getPropertyDefaultByHandle( _nHandle );
Any aDefaultValue; getFastPropertyValue( aDefaultValue, _nHandle );
@@ -973,6 +999,7 @@ PropertyState OControlModel::getPropertyStateByHandle( sal_Int32 _nHandle )
//------------------------------------------------------------------------------
void OControlModel::setPropertyToDefaultByHandle( sal_Int32 _nHandle)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setPropertyToDefaultByHandle" );
Any aDefault = getPropertyDefaultByHandle( _nHandle );
Any aConvertedValue, aOldValue;
@@ -986,6 +1013,7 @@ void OControlModel::setPropertyToDefaultByHandle( sal_Int32 _nHandle)
//------------------------------------------------------------------------------
Any OControlModel::getPropertyDefaultByHandle( sal_Int32 _nHandle ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getPropertyDefaultByHandle" );
Any aReturn;
switch ( _nHandle )
{
@@ -1018,6 +1046,7 @@ Any OControlModel::getPropertyDefaultByHandle( sal_Int32 _nHandle ) const
//------------------------------------------------------------------------------
void OControlModel::getFastPropertyValue( Any& _rValue, sal_Int32 _nHandle ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getFastPropertyValue" );
switch ( _nHandle )
{
case PROPERTY_ID_NAME:
@@ -1049,6 +1078,7 @@ sal_Bool OControlModel::convertFastPropertyValue(
Any& _rConvertedValue, Any& _rOldValue, sal_Int32 _nHandle, const Any& _rValue)
throw (com::sun::star::lang::IllegalArgumentException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::convertFastPropertyValue" );
sal_Bool bModified(sal_False);
switch (_nHandle)
{
@@ -1078,6 +1108,7 @@ sal_Bool OControlModel::convertFastPropertyValue(
void OControlModel::setFastPropertyValue_NoBroadcast(sal_Int32 _nHandle, const Any& _rValue)
throw (Exception)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setFastPropertyValue_NoBroadcast" );
switch (_nHandle)
{
case PROPERTY_ID_NAME:
@@ -1110,6 +1141,7 @@ void OControlModel::setFastPropertyValue_NoBroadcast(sal_Int32 _nHandle, const A
//------------------------------------------------------------------------------
void OControlModel::describeFixedProperties( Sequence< Property >& _rProps ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::describeFixedProperties" );
BEGIN_DESCRIBE_BASE_PROPERTIES( 4 )
DECL_PROP2 (CLASSID, sal_Int16, READONLY, TRANSIENT);
DECL_PROP1 (NAME, ::rtl::OUString, BOUND);
@@ -1121,6 +1153,7 @@ void OControlModel::describeFixedProperties( Sequence< Property >& _rProps ) con
//------------------------------------------------------------------------------
void OControlModel::describeAggregateProperties( Sequence< Property >& /* [out] */ _rAggregateProps ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::describeAggregateProperties" );
if ( m_xAggregateSet.is() )
{
Reference< XPropertySetInfo > xPSI( m_xAggregateSet->getPropertySetInfo() );
@@ -1132,12 +1165,14 @@ void OControlModel::describeAggregateProperties( Sequence< Property >& /* [out]
//------------------------------------------------------------------------------
::osl::Mutex& OControlModel::getMutex()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getMutex" );
return m_aMutex;
}
//------------------------------------------------------------------------------
void OControlModel::describeFixedAndAggregateProperties( Sequence< Property >& _out_rFixedProperties, Sequence< Property >& _out_rAggregateProperties ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::describeFixedAndAggregateProperties" );
describeFixedProperties( _out_rFixedProperties );
describeAggregateProperties( _out_rAggregateProperties );
}
@@ -1145,42 +1180,49 @@ void OControlModel::describeFixedAndAggregateProperties( Sequence< Property >& _
//------------------------------------------------------------------------------
Reference< XMultiPropertySet > OControlModel::getPropertiesInterface()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getPropertiesInterface" );
return Reference< XMultiPropertySet >( *this, UNO_QUERY );
}
//------------------------------------------------------------------------------
Reference< XPropertySetInfo> SAL_CALL OControlModel::getPropertySetInfo() throw( RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getPropertySetInfo" );
return createPropertySetInfo( getInfoHelper() );
}
//------------------------------------------------------------------------------
::cppu::IPropertyArrayHelper& OControlModel::getInfoHelper()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getInfoHelper" );
return m_aPropertyBagHelper.getInfoHelper();
}
//--------------------------------------------------------------------
void SAL_CALL OControlModel::addProperty( const ::rtl::OUString& _rName, ::sal_Int16 _nAttributes, const Any& _rInitialValue ) throw (PropertyExistException, IllegalTypeException, IllegalArgumentException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::addProperty" );
m_aPropertyBagHelper.addProperty( _rName, _nAttributes, _rInitialValue );
}
//--------------------------------------------------------------------
void SAL_CALL OControlModel::removeProperty( const ::rtl::OUString& _rName ) throw (UnknownPropertyException, NotRemoveableException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::removeProperty" );
m_aPropertyBagHelper.removeProperty( _rName );
}
//--------------------------------------------------------------------
Sequence< PropertyValue > SAL_CALL OControlModel::getPropertyValues() throw (RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getPropertyValues" );
return m_aPropertyBagHelper.getPropertyValues();
}
//--------------------------------------------------------------------
void SAL_CALL OControlModel::setPropertyValues( const Sequence< PropertyValue >& _rProps ) throw (UnknownPropertyException, PropertyVetoException, IllegalArgumentException, WrappedTargetException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setPropertyValues" );
m_aPropertyBagHelper.setPropertyValues( _rProps );
}
@@ -1223,6 +1265,7 @@ Any SAL_CALL OBoundControlModel::queryAggregation( const Type& _rType ) throw (R
Any aReturn( OControlModel::queryAggregation(_rType) );
if (!aReturn.hasValue())
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::queryAggregation" );
aReturn = OBoundControlModel_BASE1::queryInterface(_rType);
if ( !aReturn.hasValue() && m_bCommitable )
@@ -1468,6 +1511,7 @@ Sequence< Type > OBoundControlModel::_getTypes()
//-----------------------------------------------------------------------------
void OBoundControlModel::disposing()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::_getTypes" );
OControlModel::disposing();
::osl::ClearableMutexGuard aGuard(m_aMutex);
@@ -1645,6 +1689,7 @@ void SAL_CALL OBoundControlModel::disposing(const com::sun::star::lang::EventObj
//------------------------------------------------------------------------------
StringSequence SAL_CALL OBoundControlModel::getSupportedServiceNames() throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::disposing" );
return ::comphelper::concatSequences(
getAggregateServiceNames(),
getSupportedServiceNames_Static()
@@ -1667,6 +1712,7 @@ Sequence< ::rtl::OUString > SAL_CALL OBoundControlModel::getSupportedServiceName
//------------------------------------------------------------------------------
void SAL_CALL OBoundControlModel::write( const Reference<stario::XObjectOutputStream>& _rxOutStream ) throw(stario::IOException, RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::getSupportedServiceNames_Static" );
OControlModel::write(_rxOutStream);
osl::MutexGuard aGuard(m_aMutex);
@@ -1767,6 +1813,7 @@ void SAL_CALL OBoundControlModel::read( const Reference< stario::XObjectInputStr
//------------------------------------------------------------------------------
void OBoundControlModel::getFastPropertyValue(Any& rValue, sal_Int32 nHandle) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OBoundControlModel::getFastPropertyValue" );
switch (nHandle)
{
case PROPERTY_ID_INPUT_REQUIRED:
@@ -1835,6 +1882,7 @@ sal_Bool OBoundControlModel::convertFastPropertyValue(
//------------------------------------------------------------------------------
Any OBoundControlModel::getPropertyDefaultByHandle( sal_Int32 _nHandle ) const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::convertFastPropertyValue" );
Any aDefault;
switch ( _nHandle )
{
@@ -1942,6 +1990,7 @@ void OBoundControlModel::setFastPropertyValue_NoBroadcast( sal_Int32 nHandle, co
//------------------------------------------------------------------------------
void SAL_CALL OBoundControlModel::propertyChange( const PropertyChangeEvent& evt ) throw(RuntimeException)
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "OControlModel::setFastPropertyValue_NoBroadcast" );
// if the DBColumn value changed, transfer it to the control
if ( evt.PropertyName.equals( PROPERTY_VALUE ) )
{
diff --git a/forms/source/component/propertybaghelper.cxx b/forms/source/component/propertybaghelper.cxx
index 7bd1e922b..575418fea 100644
--- a/forms/source/component/propertybaghelper.cxx
+++ b/forms/source/component/propertybaghelper.cxx
@@ -45,6 +45,9 @@
#include <tools/diagnose_ex.h>
#include <comphelper/sequence.hxx>
+#include <rtl/logfile.hxx>
+#include "rtl/instance.hxx"
+
#define NEW_HANDLE_BASE 10000
@@ -93,6 +96,7 @@ namespace frm
,m_pPropertyArrayHelper( NULL )
,m_bDisposed( false )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::PropertyBagHelper" );
}
//--------------------------------------------------------------------
@@ -104,12 +108,14 @@ namespace frm
//--------------------------------------------------------------------
void PropertyBagHelper::dispose()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::dispose" );
m_bDisposed = true;
}
//--------------------------------------------------------------------
void PropertyBagHelper::impl_nts_checkDisposed_throw() const
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_nts_checkDisposed_throw" );
if ( m_bDisposed )
throw DisposedException();
}
@@ -117,12 +123,14 @@ namespace frm
//--------------------------------------------------------------------
void PropertyBagHelper::impl_nts_invalidatePropertySetInfo()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_nts_invalidatePropertySetInfo" );
delete m_pPropertyArrayHelper, m_pPropertyArrayHelper = NULL;
}
//--------------------------------------------------------------------
sal_Int32 PropertyBagHelper::impl_findFreeHandle( const ::rtl::OUString& _rPropertyName )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_findFreeHandle" );
::comphelper::OPropertyArrayAggregationHelper& rPropInfo( impl_ts_getArrayHelper() );
// check the preferred handle
@@ -162,29 +170,43 @@ namespace frm
//--------------------------------------------------------------------
::comphelper::OPropertyArrayAggregationHelper& PropertyBagHelper::impl_ts_getArrayHelper() const
{
- ::osl::MutexGuard aGuard( m_rContext.getMutex() );
- if ( !m_pPropertyArrayHelper )
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::impl_ts_getArrayHelper" );
+ //::osl::MutexGuard aGuard( m_rContext.getMutex() );
+ OPropertyArrayAggregationHelper* p = m_pPropertyArrayHelper;
+ if ( !p )
{
- // our own fixed and our aggregate's properties
- Sequence< Property > aFixedProps;
- Sequence< Property > aAggregateProps;
- m_rContext.describeFixedAndAggregateProperties( aFixedProps, aAggregateProps );
+ ::osl::MutexGuard aGuard( m_rContext.getMutex() );
+ p = m_pPropertyArrayHelper;
+ if ( !p )
+ {
+ // our own fixed and our aggregate's properties
+ Sequence< Property > aFixedProps;
+ Sequence< Property > aAggregateProps;
+ m_rContext.describeFixedAndAggregateProperties( aFixedProps, aAggregateProps );
- // our dynamic properties
- Sequence< Property > aDynamicProps;
- m_aDynamicProperties.describeProperties( aDynamicProps );
+ // our dynamic properties
+ Sequence< Property > aDynamicProps;
+ m_aDynamicProperties.describeProperties( aDynamicProps );
- Sequence< Property > aOwnProps(
- ::comphelper::concatSequences( aFixedProps, aDynamicProps ) );
+ Sequence< Property > aOwnProps(
+ ::comphelper::concatSequences( aFixedProps, aDynamicProps ) );
- const_cast< PropertyBagHelper* >( this )->m_pPropertyArrayHelper = new OPropertyArrayAggregationHelper( aOwnProps, aAggregateProps, &lcl_getPropertyInfos(), NEW_HANDLE_BASE );
+ p = new OPropertyArrayAggregationHelper( aOwnProps, aAggregateProps, &lcl_getPropertyInfos(), NEW_HANDLE_BASE );
+ OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
+ const_cast< PropertyBagHelper* >( this )->m_pPropertyArrayHelper = p;
+ }
+ } // if ( !p )
+ else
+ {
+ OSL_DOUBLE_CHECKED_LOCKING_MEMORY_BARRIER();
}
- return *m_pPropertyArrayHelper;
+ return *p;
}
//--------------------------------------------------------------------
void PropertyBagHelper::addProperty( const ::rtl::OUString& _rName, ::sal_Int16 _nAttributes, const Any& _rInitialValue )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::addProperty" );
::osl::MutexGuard aGuard( m_rContext.getMutex() );
impl_nts_checkDisposed_throw();
@@ -212,6 +234,7 @@ namespace frm
//--------------------------------------------------------------------
void PropertyBagHelper::removeProperty( const ::rtl::OUString& _rName )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::removeProperty" );
::osl::MutexGuard aGuard( m_rContext.getMutex() );
impl_nts_checkDisposed_throw();
@@ -260,6 +283,7 @@ namespace frm
//--------------------------------------------------------------------
Sequence< PropertyValue > PropertyBagHelper::getPropertyValues()
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::getPropertyValues" );
::osl::MutexGuard aGuard( m_rContext.getMutex() );
impl_nts_checkDisposed_throw();
@@ -302,6 +326,7 @@ namespace frm
//--------------------------------------------------------------------
void PropertyBagHelper::setPropertyValues( const Sequence< PropertyValue >& _rProps )
{
+ // RTL_LOGFILE_CONTEXT_AUTHOR( aLogger, "forms", "dev@dba.openoffice.org", "PropertyBagHelper::setPropertyValues" );
::osl::ClearableMutexGuard aGuard( m_rContext.getMutex() );
impl_nts_checkDisposed_throw();