summaryrefslogtreecommitdiffstats
path: root/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'dbaccess/source/ui/relationdesign/RTableConnectionData.cxx')
-rw-r--r--dbaccess/source/ui/relationdesign/RTableConnectionData.cxx19
1 files changed, 8 insertions, 11 deletions
diff --git a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
index c1c408ee8f1a..46b3671c40e2 100644
--- a/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
+++ b/dbaccess/source/ui/relationdesign/RTableConnectionData.cxx
@@ -38,7 +38,6 @@ using namespace ::com::sun::star::sdbcx;
using namespace ::com::sun::star::uno;
using namespace ::com::sun::star::beans;
using namespace ::com::sun::star::container;
-using namespace ::com::sun::star::lang;
ORelationTableConnectionData::ORelationTableConnectionData()
:m_nUpdateRules(KeyRule::NO_ACTION)
@@ -112,9 +111,7 @@ void ORelationTableConnectionData::ChangeOrientation()
}
// adapt member
- TTableWindowData::value_type pTemp = m_pReferencingTable;
- m_pReferencingTable = m_pReferencedTable;
- m_pReferencedTable = pTemp;
+ std::swap( m_pReferencingTable, m_pReferencedTable );
}
void ORelationTableConnectionData::SetCardinality()
@@ -256,11 +253,11 @@ bool ORelationTableConnectionData::Update()
xTableProp->getPropertyValue(PROPERTY_NAME) >>= sSourceName;
OUString sKeyName = sSourceName + getReferencedTable()->GetTableName();
- xKey->setPropertyValue(PROPERTY_NAME,makeAny(sKeyName));
- xKey->setPropertyValue(PROPERTY_TYPE,makeAny(KeyType::FOREIGN));
- xKey->setPropertyValue(PROPERTY_REFERENCEDTABLE,makeAny(getReferencedTable()->GetTableName()));
- xKey->setPropertyValue(PROPERTY_UPDATERULE, makeAny(GetUpdateRules()));
- xKey->setPropertyValue(PROPERTY_DELETERULE, makeAny(GetDeleteRules()));
+ xKey->setPropertyValue(PROPERTY_NAME,Any(sKeyName));
+ xKey->setPropertyValue(PROPERTY_TYPE,Any(KeyType::FOREIGN));
+ xKey->setPropertyValue(PROPERTY_REFERENCEDTABLE,Any(getReferencedTable()->GetTableName()));
+ xKey->setPropertyValue(PROPERTY_UPDATERULE, Any(GetUpdateRules()));
+ xKey->setPropertyValue(PROPERTY_DELETERULE, Any(GetDeleteRules()));
}
Reference<XColumnsSupplier> xColSup(xKey,UNO_QUERY);
@@ -278,8 +275,8 @@ bool ORelationTableConnectionData::Update()
Reference<XPropertySet> xColumn = xColumnFactory->createDataDescriptor();
if ( xColumn.is() )
{
- xColumn->setPropertyValue(PROPERTY_NAME,makeAny(elem->GetSourceFieldName()));
- xColumn->setPropertyValue(PROPERTY_RELATEDCOLUMN,makeAny(elem->GetDestFieldName()));
+ xColumn->setPropertyValue(PROPERTY_NAME,Any(elem->GetSourceFieldName()));
+ xColumn->setPropertyValue(PROPERTY_RELATEDCOLUMN,Any(elem->GetDestFieldName()));
xColumnAppend->appendByDescriptor(xColumn);
}
}