summaryrefslogtreecommitdiff
path: root/svtools/source/hatchwindow
diff options
context:
space:
mode:
authorVladimir Glazounov <vg@openoffice.org>2006-11-01 17:18:51 +0000
committerVladimir Glazounov <vg@openoffice.org>2006-11-01 17:18:51 +0000
commitcec19a68457e22df1759a3d1c3b8957b8af39f6f (patch)
treecf0cadbd5da9b834db29065c4357d726c2c355e5 /svtools/source/hatchwindow
parentc787015256fa3130ad9ab45802bf1205b541eeac (diff)
INTEGRATION: CWS inplaceobjects (1.4.80); FILE MERGED
2006/09/28 19:30:31 mba 1.4.80.3: RESYNC: (1.5-1.6); FILE MERGED 2006/07/06 16:04:51 mba 1.4.80.2: RESYNC: (1.4-1.5); FILE MERGED 2006/06/14 10:57:13 mba 1.4.80.1: #i66239#: new API for inplace active objects
Diffstat (limited to 'svtools/source/hatchwindow')
-rw-r--r--svtools/source/hatchwindow/ipwin.cxx31
1 files changed, 29 insertions, 2 deletions
diff --git a/svtools/source/hatchwindow/ipwin.cxx b/svtools/source/hatchwindow/ipwin.cxx
index 217c8ccfd303..55958c32192a 100644
--- a/svtools/source/hatchwindow/ipwin.cxx
+++ b/svtools/source/hatchwindow/ipwin.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: ipwin.cxx,v $
*
- * $Revision: 1.6 $
+ * $Revision: 1.7 $
*
- * last change: $Author: obo $ $Date: 2006-09-17 14:57:53 $
+ * last change: $Author: vg $ $Date: 2006-11-01 18:18:51 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -482,6 +482,7 @@ SvResizeWindow::SvResizeWindow
)
: Window( pParent, WB_CLIPCHILDREN )
, m_nMoveGrab( -1 )
+ , m_bActive( sal_False )
, m_pWrapper( pWrapper )
{
OSL_ENSURE( pParent != NULL && pWrapper != NULL, "Wrong initialization of hatch window!\n" );
@@ -667,3 +668,29 @@ void SvResizeWindow::Paint( const Rectangle & /*rRect*/ )
m_aResizer.Draw( this );
}
+long SvResizeWindow::PreNotify( NotifyEvent& rEvt )
+{
+ if ( rEvt.GetType() == EVENT_GETFOCUS && !m_bActive )
+ {
+ m_bActive = sal_True;
+ m_pWrapper->Activated();
+ }
+
+ return Window::PreNotify(rEvt);
+}
+
+long SvResizeWindow::Notify( NotifyEvent& rEvt )
+{
+ if ( rEvt.GetType() == EVENT_LOSEFOCUS && m_bActive )
+ {
+ BOOL bHasFocus = HasChildPathFocus(TRUE);
+ if ( !bHasFocus )
+ {
+ m_bActive = sal_False;
+ m_pWrapper->Deactivated();
+ }
+ }
+
+ return Window::Notify(rEvt);
+}
+