summaryrefslogtreecommitdiff
path: root/dbaccess/source/ui/querydesign
diff options
context:
space:
mode:
authorJens-Heiner Rechtien <hr@openoffice.org>2008-11-19 17:43:08 +0000
committerJens-Heiner Rechtien <hr@openoffice.org>2008-11-19 17:43:08 +0000
commit0e8ff6898609c3291ec605f8e97450fb2735290a (patch)
treeab7b6860136a46d4fce9f8c06c0f4933b014ddf4 /dbaccess/source/ui/querydesign
parent5524ea27e2162f33c37baeb3de1ae41ba850b919 (diff)
CWS-TOOLING: integrate CWS dba301a_DEV300
Diffstat (limited to 'dbaccess/source/ui/querydesign')
-rw-r--r--dbaccess/source/ui/querydesign/QueryDesignView.cxx13
-rw-r--r--dbaccess/source/ui/querydesign/TableWindowAccess.cxx15
2 files changed, 20 insertions, 8 deletions
diff --git a/dbaccess/source/ui/querydesign/QueryDesignView.cxx b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
index d6fcba7dbe67..8372f6689347 100644
--- a/dbaccess/source/ui/querydesign/QueryDesignView.cxx
+++ b/dbaccess/source/ui/querydesign/QueryDesignView.cxx
@@ -641,15 +641,11 @@ namespace
}
else if(pEntryTabTo == pEntryConn->GetDestWin())
{
- ::rtl::OUString aTmpJoin('(');
- (aTmpJoin += aJoin) += ::rtl::OUString(')');
- aJoin = BuildJoin(_xConnection,aTmpJoin,pEntryTabTo,pEntryConnData);
+ aJoin = BuildJoin(_xConnection,aJoin,pEntryTabTo,pEntryConnData);
}
else if(pEntryTabTo == pEntryConn->GetSourceWin())
{
- ::rtl::OUString aTmpJoin('(');
- (aTmpJoin += aJoin) += ::rtl::OUString(')');
- aJoin = BuildJoin(_xConnection,pEntryTabTo,aTmpJoin,pEntryConnData);
+ aJoin = BuildJoin(_xConnection,pEntryTabTo,aJoin,pEntryConnData);
}
pEntryConn->SetVisited(sal_True);
@@ -1912,6 +1908,11 @@ namespace
sal_Bool bRet = sal_True;
if (SQL_ISRULE(_pNode,qualified_join))
pJoinNode = _pNode;
+ else if (SQL_ISRULE(_pNode,table_ref)
+ && _pNode->count() == 3
+ && SQL_ISPUNCTUATION(_pNode->getChild(0),"(")
+ && SQL_ISPUNCTUATION(_pNode->getChild(2),")") ) // '(' joined_table ')'
+ pJoinNode = _pNode->getChild(1);
else if (! ( SQL_ISRULE(_pNode, table_ref) && _pNode->count() == 2) ) // table_node table_primary_as_range_column
bRet = sal_False;
diff --git a/dbaccess/source/ui/querydesign/TableWindowAccess.cxx b/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
index 13e843f3552a..9db1be38959f 100644
--- a/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
+++ b/dbaccess/source/ui/querydesign/TableWindowAccess.cxx
@@ -7,7 +7,7 @@
* OpenOffice.org - a multi-platform office productivity suite
*
* $RCSfile: TableWindowAccess.cxx,v $
- * $Revision: 1.14 $
+ * $Revision: 1.14.34.2 $
*
* This file is part of OpenOffice.org.
*
@@ -92,6 +92,17 @@ namespace dbaui
VCLXAccessibleComponent::disposing();
}
// -----------------------------------------------------------------------------
+ void OTableWindowAccess::ProcessWindowEvent( const VclWindowEvent& rVclWindowEvent )
+ {
+ if ( rVclWindowEvent.GetId() == VCLEVENT_OBJECT_DYING )
+ {
+ ::osl::MutexGuard aGuard( m_aMutex );
+ m_pTable = NULL;
+ }
+
+ VCLXAccessibleComponent::ProcessWindowEvent( rVclWindowEvent );
+ }
+ // -----------------------------------------------------------------------------
Any SAL_CALL OTableWindowAccess::queryInterface( const Type& aType ) throw (RuntimeException)
{
Any aRet(VCLXAccessibleComponent::queryInterface( aType ));
@@ -255,7 +266,7 @@ namespace dbaui
{
::osl::MutexGuard aGuard( m_aMutex );
return AccessibleRelationType::CONTROLLER_FOR == aRelationType
- && m_pTable->getTableView()->ExistsAConn(m_pTable);
+ && m_pTable && m_pTable->getTableView()->ExistsAConn(m_pTable);
}
// -----------------------------------------------------------------------------
AccessibleRelation SAL_CALL OTableWindowAccess::getRelationByType( sal_Int16 aRelationType ) throw (RuntimeException)