summaryrefslogtreecommitdiff
path: root/toolkit
diff options
context:
space:
mode:
authorMalte Timmermann <mt@openoffice.org>2001-02-16 10:15:57 +0000
committerMalte Timmermann <mt@openoffice.org>2001-02-16 10:15:57 +0000
commit1092a3ee6b14b49d8df2403628e592698cc54d00 (patch)
tree55480133cdfc9991b077551ea1d833b615d74859 /toolkit
parent59d2c10162b4bf1d34e80d4640cfdc70366e52d7 (diff)
changed the draw method for workwindows
Diffstat (limited to 'toolkit')
-rw-r--r--toolkit/source/awt/vclxwindow.cxx39
1 files changed, 22 insertions, 17 deletions
diff --git a/toolkit/source/awt/vclxwindow.cxx b/toolkit/source/awt/vclxwindow.cxx
index e2edefc73c8c..4af506201608 100644
--- a/toolkit/source/awt/vclxwindow.cxx
+++ b/toolkit/source/awt/vclxwindow.cxx
@@ -2,9 +2,9 @@
*
* $RCSfile: vclxwindow.cxx,v $
*
- * $Revision: 1.5 $
+ * $Revision: 1.6 $
*
- * last change: $Author: mt $ $Date: 2001-02-12 15:49:14 $
+ * last change: $Author: mt $ $Date: 2001-02-16 11:15:57 $
*
* The Contents of this file are made available subject to the terms of
* either of the following licenses
@@ -871,37 +871,42 @@ void VCLXWindow::draw( sal_Int32 nX, sal_Int32 nY ) throw(::com::sun::star::uno:
{
::vos::OGuard aGuard( GetMutex() );
- if ( GetWindow() )
+ Window* pWindow = GetWindow();
+
+ if ( pWindow )
{
OutputDevice* pDev = VCLUnoHelper::GetOutputDevice( mxViewGraphics );
Point aPos( nX, nY );
- if ( GetWindow()->GetParent() && !GetWindow()->IsVisible()
- && ( !pDev || ( GetWindow()->GetParent() == pDev ) ) )
+ if ( !pDev )
+ pDev = pWindow->GetParent();
+
+ if ( pWindow->GetParent() && !pWindow->IsVisible()
+ && !pWindow->IsSystemWindow() && ( pWindow->GetParent() == pDev ) )
{
- Point aOldPos( GetWindow()->GetPosPixel() );
- GetWindow()->SetPosPixel( aPos );
+ Point aOldPos( pWindow->GetPosPixel() );
+ pWindow->SetPosPixel( aPos );
// Erstmal ein Update auf den Parent, damit nicht beim Update
// auf dieses Fenster noch ein Paint vom Parent abgearbeitet wird,
// wo dann ggf. dieses Fenster sofort wieder gehidet wird.
- if( GetWindow()->GetParent() )
- GetWindow()->GetParent()->Update();
+ if( pWindow->GetParent() )
+ pWindow->GetParent()->Update();
- GetWindow()->Show();
- GetWindow()->Update();
- GetWindow()->SetParentUpdateMode( sal_False );
- GetWindow()->Hide();
- GetWindow()->SetParentUpdateMode( sal_True );
+ pWindow->Show();
+ pWindow->Update();
+ pWindow->SetParentUpdateMode( sal_False );
+ pWindow->Hide();
+ pWindow->SetParentUpdateMode( sal_True );
- GetWindow()->SetPosPixel( aOldPos );
+ pWindow->SetPosPixel( aOldPos );
}
else if ( pDev )
{
- Size aSz = GetWindow()->GetSizePixel();
+ Size aSz = pWindow->GetSizePixel();
aSz = pDev->PixelToLogic( aSz );
Point aP = pDev->PixelToLogic( aPos );
- GetWindow()->Draw( pDev, aP, aSz, WINDOW_DRAW_NOCONTROLS );
+ pWindow->Draw( pDev, aP, aSz, WINDOW_DRAW_NOCONTROLS );
}
}
}