summaryrefslogtreecommitdiff
path: root/forms
diff options
context:
space:
mode:
authorFrank Schönheit <fs@openoffice.org>2001-11-07 14:07:44 +0000
committerFrank Schönheit <fs@openoffice.org>2001-11-07 14:07:44 +0000
commitaea93141f3a8db5a5600d835f98333baa87424ea (patch)
treee5c444cfbde3d5e8c5f3b05f849f07b6a443edfc /forms
parent904e6145a21d0a6e196c44a055b01e9abda72dab (diff)
loadData: be less generous with creating unnecessary connections
Diffstat (limited to 'forms')
-rw-r--r--forms/source/component/ListBox.cxx12
1 files changed, 8 insertions, 4 deletions
diff --git a/forms/source/component/ListBox.cxx b/forms/source/component/ListBox.cxx
index 838be478c3ed..be2b8b585649 100644
--- a/forms/source/component/ListBox.cxx
+++ b/forms/source/component/ListBox.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: ListBox.cxx,v $
*
- * $Revision: 1.21 $
+ * $Revision: 1.22 $
*
- * last change: $Author: fs $ $Date: 2001-09-28 18:15:33 $
+ * last change: $Author: fs $ $Date: 2001-11-07 15:07:44 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -756,8 +756,12 @@ void OListBoxModel::loadData()
{
Reference< XPropertySet > xFormProps(xForm, UNO_QUERY);
- xContentSetProperties->setPropertyValue(PROPERTY_COMMANDTYPE, makeAny(CommandType::COMMAND));
- xContentSetProperties->setPropertyValue(PROPERTY_DATASOURCE, xFormProps->getPropertyValue(PROPERTY_DATASOURCE));
+ xContentSetProperties->setPropertyValue( PROPERTY_COMMANDTYPE, makeAny( CommandType::COMMAND ) );
+ xContentSetProperties->setPropertyValue( PROPERTY_DATASOURCE, xFormProps->getPropertyValue( PROPERTY_DATASOURCE ) );
+
+ // try to give the row set the connection of our form - this saves the rowset from creating an own one
+ xContentSetProperties->setPropertyValue( PROPERTY_ACTIVE_CONNECTION, xFormProps->getPropertyValue( PROPERTY_ACTIVE_CONNECTION ) );
+
xContentRowSet->execute();
}
}