Tag: cws_dev300_dba31b
User: oj      
Date: 2008-08-19 10:59:38+0000
Modified:
   dba/dbaccess/source/ui/querydesign/TableWindow.cxx
   dba/dbaccess/source/ui/querydesign/TableWindowData.cxx

Log:
 #i44447# dispose listener

File Changes:

Directory: /dba/dbaccess/source/ui/querydesign/
===============================================

File [changed]: TableWindow.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/querydesign/TableWindow.cxx?r1=1.41.26.1&r2=1.41.26.2
Delta lines:  +5 -2
-------------------
--- TableWindow.cxx     2008-08-15 10:34:29+0000        1.41.26.1
+++ TableWindow.cxx     2008-08-19 10:59:35+0000        1.41.26.2
@@ -7,7 +7,7 @@
  * OpenOffice.org - a multi-platform office productivity suite
  *
  * $RCSfile: TableWindow.cxx,v $
- * $Revision: 1.41.26.1 $
+ * $Revision: 1.41.26.2 $
  *
  * This file is part of OpenOffice.org.
  *
@@ -144,7 +144,10 @@
                OSL_ENSURE(m_pListBox->GetEntryCount()==0,"Forgot to call 
EmptyListbox()!");
                ::std::auto_ptr<Window> aTemp(m_pListBox);
                m_pListBox = NULL;
-       }
+       } // if (m_pListBox)
+    if ( m_pContainerListener.is() )
+        m_pContainerListener->dispose();
+    
        m_pAccessible = NULL;
 }
 // 
-----------------------------------------------------------------------------

File [changed]: TableWindowData.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/querydesign/TableWindowData.cxx?r1=1.15&r2=1.15.42.1
Delta lines:  +10 -16
---------------------
--- TableWindowData.cxx 2008-06-06 14:13:46+0000        1.15
+++ TableWindowData.cxx 2008-08-19 10:59:35+0000        1.15.42.1
@@ -7,7 +7,7 @@
  * OpenOffice.org - a multi-platform office productivity suite
  *
  * $RCSfile: TableWindowData.cxx,v $
- * $Revision: 1.15 $
+ * $Revision: 1.15.42.1 $
  *
  * This file is part of OpenOffice.org.
  *
@@ -85,10 +85,6 @@
     Reference<XComponent> xComponent( m_xTable, UNO_QUERY );
        if ( xComponent.is() )
                stopComponentListening( xComponent );
-    // obtain the columns
-    xComponent.set( m_xColumns, UNO_QUERY );
-    if ( xComponent.is() )
-           stopComponentListening( xComponent );
 }
 
 
//------------------------------------------------------------------------------
@@ -107,8 +103,9 @@
 {
        ::osl::MutexGuard aGuard( m_aMutex );
        // it doesn't matter which one was disposed
+    m_xColumns.clear();
+    m_xKeys.clear();
        m_xTable.clear();
-    m_xColumns.clear();;
 }
 // 
-----------------------------------------------------------------------------
 bool OTableWindowData::init(const Reference< XConnection  >& _xConnection,bool 
_bAllowQueries)
@@ -126,9 +123,9 @@
     bool bIsKnownTable = xTables->hasByName( m_sComposedName );
 
     if ( bIsKnownQuery )
-        m_xTable.set( xQueries->getByName( m_sComposedName ), UNO_QUERY_THROW 
);
+        m_xTable.set( xQueries->getByName( m_sComposedName ), UNO_QUERY );
     else if ( bIsKnownTable )
-        m_xTable.set( xTables->getByName( m_sComposedName ), UNO_QUERY_THROW );
+        m_xTable.set( xTables->getByName( m_sComposedName ), UNO_QUERY );
     else
         m_bIsValid = false;
 
@@ -137,7 +134,6 @@
 
     listen();
     
-
     Reference< XIndexAccess > xColumnsAsIndex( m_xColumns,UNO_QUERY );
     return xColumnsAsIndex.is() && ( xColumnsAsIndex->getCount() > 0 );
 }
@@ -152,11 +148,9 @@
                    startComponentListening( xComponent );
 
         // obtain the columns
-        Reference< XColumnsSupplier > xColumnsSups( m_xTable, UNO_QUERY_THROW 
);
+        Reference< XColumnsSupplier > xColumnsSups( m_xTable, UNO_QUERY);
+        if ( xColumnsSups.is() )
            m_xColumns = xColumnsSups->getColumns();
-        xComponent.set( m_xColumns, UNO_QUERY );
-           if ( xComponent.is() )
-                   startComponentListening( xComponent );
 
         Reference<XKeysSupplier> xKeySup(m_xTable,UNO_QUERY);
            if ( xKeySup.is() )




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to