summaryrefslogtreecommitdiff
path: root/automation
diff options
context:
space:
mode:
authorGregor Hartmann <gh@openoffice.org>2007-06-13 08:02:52 +0000
committerGregor Hartmann <gh@openoffice.org>2007-06-13 08:02:52 +0000
commita857bfd8e435f91206f5cffbc393b6d59552c118 (patch)
tree26ea2d56f3bb42c1c25f6e7588feafa5a3b1d828 /automation
parent90b9d35e53644a084f1ce1bb8168743352750a9a (diff)
#144461#no user events on deleted window anymore
Diffstat (limited to 'automation')
-rw-r--r--automation/source/server/sta_list.cxx16
1 files changed, 9 insertions, 7 deletions
diff --git a/automation/source/server/sta_list.cxx b/automation/source/server/sta_list.cxx
index b62ba0378823..27a4086b11fc 100644
--- a/automation/source/server/sta_list.cxx
+++ b/automation/source/server/sta_list.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: sta_list.cxx,v $
*
- * $Revision: 1.23 $
+ * $Revision: 1.24 $
*
- * last change: $Author: kz $ $Date: 2007-05-11 08:54:44 $
+ * last change: $Author: gh $ $Date: 2007-06-13 09:02:52 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -1128,11 +1128,13 @@ void ImplKeyInput( Window* pWin, KeyEvent &aKEvnt, BOOL bForceDirect )
{
if ( StatementList::WinPtrValid( pWin ) )
{
- ULONG nID;
- nID = Application::PostKeyEvent( VCLEVENT_WINDOW_KEYINPUT, pWin, &aKEvnt );
- ImplEventWait( nID );
- nID = Application::PostKeyEvent( VCLEVENT_WINDOW_KEYUP, pWin, &aKEvnt );
- ImplEventWait( nID );
+ ULONG nID1;
+ ULONG nID2;
+ nID1 = Application::PostKeyEvent( VCLEVENT_WINDOW_KEYINPUT, pWin, &aKEvnt );
+ nID2 = Application::PostKeyEvent( VCLEVENT_WINDOW_KEYUP, pWin, &aKEvnt );
+ // wait after posting both events so deleting pWin will remove the second event also
+ ImplEventWait( nID1 );
+ ImplEventWait( nID2 );
}
}
else