Tag: cws_src680_dba24b
User: oj      
Date: 2007-10-16 08:31:50+0000
Modified:
   dba/dbaccess/source/ui/querydesign/TableWindowListBox.cxx

Log:
 #i56898# post 2nd user event

File Changes:

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

File [changed]: TableWindowListBox.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/querydesign/TableWindowListBox.cxx?r1=1.32&r2=1.32.130.1
Delta lines:  +16 -5
--------------------
--- TableWindowListBox.cxx      2006-09-17 07:26:11+0000        1.32
+++ TableWindowListBox.cxx      2007-10-16 08:31:48+0000        1.32.130.1
@@ -4,9 +4,9 @@
  *
  *  $RCSfile: TableWindowListBox.cxx,v $
  *
- *  $Revision: 1.32 $
+ *  $Revision: 1.32.130.1 $
  *
- *  last change: $Author: obo $ $Date: 2006/09/17 07:26:11 $
+ *  last change: $Author: oj $ $Date: 2007/10/16 08:31:48 $
  *
  *  The Contents of this file are made available subject to
  *  the terms of GNU Lesser General Public License Version 2.1.
@@ -88,6 +88,7 @@
        ,m_aMousePos( Point(0,0) )
        ,m_pTabWin( pParent )
        ,m_nDropEvent(0)
+       ,m_nUiEvent(0)
        ,m_bReallyScrolled( sal_False )
        ,m_bDragSource( sal_False )
 {
@@ -107,7 +108,9 @@
        // first show the error msg when existing
        
m_pTabWin->getDesignView()->getController()->showError(m_pTabWin->getDesignView()->getController()->clearOccuredError());
        // second look for ui activities which should happen after d&d
-       m_pTabWin->getTableView()->lookForUiActivities();
+       if (m_nUiEvent)
+               Application::RemoveUserEvent(m_nUiEvent);
+       m_nUiEvent = Application::PostUserEvent(LINK(this, OTableWindowListBox, 
LookForUiHdl));
 }
 
 
//------------------------------------------------------------------------------
@@ -116,6 +119,8 @@
        DBG_DTOR(OTableWindowListBox,NULL);
        if (m_nDropEvent)
                Application::RemoveUserEvent(m_nDropEvent);
+       if (m_nUiEvent)
+               Application::RemoveUserEvent(m_nUiEvent);
        if( m_aScrollTimer.IsActive() )
                m_aScrollTimer.Stop();
        m_pTabWin = NULL;
@@ -331,6 +336,13 @@
 // 
-----------------------------------------------------------------------------
 
 
//------------------------------------------------------------------------------
+IMPL_LINK( OTableWindowListBox, LookForUiHdl, void *, /*EMPTY_ARG*/)
+{
+       m_nUiEvent = 0;
+       m_pTabWin->getTableView()->lookForUiActivities();
+       return 0L;
+}
+//------------------------------------------------------------------------------
 IMPL_LINK( OTableWindowListBox, DropHdl, void *, /*EMPTY_ARG*/)
 {
        // create the connection
@@ -355,7 +367,6 @@
        TransferableDataHelper aDropped(_rEvt.maDropEvent.Transferable);
        if (!m_bDragSource && 
OJoinExchObj::isFormatAvailable(aDropped.GetDataFlavorExVector()))
        {       // don't drop into the window if it's the drag source itself
-               
                m_aDropInfo.aSource     = OJoinExchangeData(this);
                m_aDropInfo.aDest       = 
OJoinExchObj::GetSourceDescription(_rEvt.maDropEvent.Transferable);
 




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

Reply via email to