diff options
author | obo <obo@openoffice.org> | 2011-03-16 12:21:09 +0100 |
---|---|---|
committer | obo <obo@openoffice.org> | 2011-03-16 12:21:09 +0100 |
commit | 61879c218dd0e6e94884e7c6e06e3c5c18540b4a (patch) | |
tree | 0811b9c5668345ffc2191ec732b03d857ffc97fe /framework | |
parent | 160329d6fb16c593f651fc143f5a8973566c6c22 (diff) | |
parent | 8f5e5867a9b31120502e59367b2f9d407390abdb (diff) |
CWS-TOOLING: integrate CWS vcl120
Notes
Notes:
split repo tag: libs-core_ooo/DEV300_m103
Diffstat (limited to 'framework')
-rwxr-xr-x[-rw-r--r--] | framework/source/services/backingwindow.cxx | 57 |
1 files changed, 30 insertions, 27 deletions
diff --git a/framework/source/services/backingwindow.cxx b/framework/source/services/backingwindow.cxx index 1d1e877a5a86..780efb1f3c6d 100644..100755 --- a/framework/source/services/backingwindow.cxx +++ b/framework/source/services/backingwindow.cxx @@ -400,7 +400,7 @@ void BackingWindow::prepareRecentFileMenu() void BackingWindow::initBackground() { - SetBackground( GetSettings().GetStyleSettings().GetWorkspaceGradient() ); + SetBackground(); bool bDark = GetSettings().GetStyleSettings().GetHighContrastMode(); if( bDark ) @@ -707,36 +707,39 @@ void BackingWindow::layoutButton( void BackingWindow::Paint( const Rectangle& ) { + Wallpaper aBack( GetSettings().GetStyleSettings().GetWorkspaceGradient() ); + Region aClip( Rectangle( Point( 0, 0 ), GetOutputSizePixel() ) ); + Rectangle aBmpRect(maControlRect); + aBmpRect.Left() -= nShadowLeft; + aBmpRect.Top() -= nShadowTop; + aBmpRect.Right() += nShadowRight; + aBmpRect.Bottom() += nShadowBottom; + aClip.Exclude( aBmpRect ); + Push( PUSH_CLIPREGION ); + IntersectClipRegion( aClip ); + DrawWallpaper( Rectangle( Point( 0, 0 ), GetOutputSizePixel() ), aBack ); + Pop(); + + VirtualDevice aDev( *this ); + aDev.EnableRTL( IsRTLEnabled() ); + aDev.SetOutputSizePixel( aBmpRect.GetSize() ); + Point aOffset( Point( 0, 0 ) - aBmpRect.TopLeft() ); + aDev.DrawWallpaper( Rectangle( aOffset, GetOutputSizePixel() ), aBack ); // draw bitmap - if( GetSettings().GetLayoutRTL() ) + Point aTL( 0, 0 ); + aDev.DrawBitmapEx( aTL, maBackgroundLeft ); + aTL.X() += maBackgroundLeft.GetSizePixel().Width(); + if( !!maBackgroundMiddle ) { - Point aTL( maControlRect.TopLeft() ); - aTL.X() -= nShadowRight; - aTL.Y() -= nShadowTop; - DrawBitmapEx( aTL, maBackgroundLeft ); - aTL.X() += maBackgroundLeft.GetSizePixel().Width(); - if( !!maBackgroundMiddle ) - { - DrawBitmapEx( aTL, maBackgroundMiddle ); - aTL.X() += maBackgroundMiddle.GetSizePixel().Width(); - } - DrawBitmapEx( aTL, maBackgroundRight ); - } - else - { - Point aTL( maControlRect.TopLeft() ); - aTL.X() -= nShadowLeft; - aTL.Y() -= nShadowTop; - DrawBitmapEx( aTL, maBackgroundLeft ); - aTL.X() += maBackgroundLeft.GetSizePixel().Width(); - if( !!maBackgroundMiddle ) - { - DrawBitmapEx( aTL, maBackgroundMiddle ); - aTL.X() += maBackgroundMiddle.GetSizePixel().Width(); - } - DrawBitmapEx( aTL, maBackgroundRight ); + aDev.DrawBitmapEx( aTL, maBackgroundMiddle ); + aTL.X() += maBackgroundMiddle.GetSizePixel().Width(); } + aDev.DrawBitmapEx( aTL, maBackgroundRight ); + + DrawOutDev( aBmpRect.TopLeft(), aBmpRect.GetSize(), + Point( 0, 0 ), aBmpRect.GetSize(), + aDev ); } long BackingWindow::Notify( NotifyEvent& rNEvt ) |