diff options
author | Jan Holesovsky <kendy@suse.cz> | 2013-01-09 11:16:47 +0100 |
---|---|---|
committer | Jan Holesovsky <kendy@suse.cz> | 2013-01-09 11:17:53 +0100 |
commit | 0721b5b83e34de1e2fcb320d6a7deae1ad109d61 (patch) | |
tree | 0c210865ffc8df7218f47b9bb6f87647c5f80401 /vcl/source/window | |
parent | 0d91792ae34ca6531fbd6244d7717a2738f6a607 (diff) |
Personas: As Michael suggested, use BitmapEx instead of BitmapEx*.
Change-Id: Ib1d84b37d452785d12502095c0eedaac4a25fb6b
Diffstat (limited to 'vcl/source/window')
-rw-r--r-- | vcl/source/window/dockingarea.cxx | 8 | ||||
-rw-r--r-- | vcl/source/window/menu.cxx | 12 |
2 files changed, 10 insertions, 10 deletions
diff --git a/vcl/source/window/dockingarea.cxx b/vcl/source/window/dockingarea.cxx index 8269c5e94985..e20265ded966 100644 --- a/vcl/source/window/dockingarea.cxx +++ b/vcl/source/window/dockingarea.cxx @@ -50,10 +50,10 @@ DockingAreaWindow::ImplData::~ImplData() static void ImplInitBackground( DockingAreaWindow* pThis ) { - const BitmapEx* pPersonaBitmap = Application::GetSettings().GetStyleSettings().GetPersonaHeader(); - if ( pPersonaBitmap != NULL && pThis->GetAlign() == WINDOWALIGN_TOP ) + const BitmapEx& rPersonaBitmap = Application::GetSettings().GetStyleSettings().GetPersonaHeader(); + if ( !rPersonaBitmap.IsEmpty() && pThis->GetAlign() == WINDOWALIGN_TOP ) { - Wallpaper aWallpaper( *pPersonaBitmap ); + Wallpaper aWallpaper( rPersonaBitmap ); aWallpaper.SetStyle( WALLPAPER_TOPRIGHT ); // we need to shift the bitmap vertically so that it spans over the @@ -175,7 +175,7 @@ void DockingAreaWindow::Paint( const Rectangle& ) } ControlState nState = CTRL_STATE_ENABLED; - if ( GetAlign() == WINDOWALIGN_TOP && Application::GetSettings().GetStyleSettings().GetPersonaHeader() ) + if ( GetAlign() == WINDOWALIGN_TOP && !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty() ) Erase(); else if ( !ImplGetSVData()->maNWFData.mbDockingAreaSeparateTB ) { diff --git a/vcl/source/window/menu.cxx b/vcl/source/window/menu.cxx index d2d6adf89b20..dc70650f090a 100644 --- a/vcl/source/window/menu.cxx +++ b/vcl/source/window/menu.cxx @@ -3874,10 +3874,10 @@ static void ImplInitMenuWindow( Window* pWin, sal_Bool bFont, sal_Bool bMenuBar pWin->SetPointFont( rStyleSettings.GetMenuFont() ); if( bMenuBar ) { - const BitmapEx* pPersonaBitmap = Application::GetSettings().GetStyleSettings().GetPersonaHeader(); - if ( pPersonaBitmap != NULL ) + const BitmapEx& rPersonaBitmap = Application::GetSettings().GetStyleSettings().GetPersonaHeader(); + if ( !rPersonaBitmap.IsEmpty() ) { - Wallpaper aWallpaper( *pPersonaBitmap ); + Wallpaper aWallpaper( rPersonaBitmap ); aWallpaper.SetStyle( WALLPAPER_TOPRIGHT ); pWin->SetBackground( aWallpaper ); pWin->SetPaintTransparent( sal_False ); @@ -5521,7 +5521,7 @@ void MenuBarWindow::HighlightItem( sal_uInt16 nPos, sal_Bool bHighlight ) MenubarValue aControlValue; aControlValue.maTopDockingAreaHeight = ImplGetTopDockingAreaHeight( this ); - if ( Application::GetSettings().GetStyleSettings().GetPersonaHeader() ) + if ( !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty() ) Erase(); else { @@ -5557,7 +5557,7 @@ void MenuBarWindow::HighlightItem( sal_uInt16 nPos, sal_Bool bHighlight ) MenubarValue aMenubarValue; aMenubarValue.maTopDockingAreaHeight = ImplGetTopDockingAreaHeight( this ); - if ( Application::GetSettings().GetStyleSettings().GetPersonaHeader() ) + if ( !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty() ) Erase( aRect ); else { @@ -5793,7 +5793,7 @@ void MenuBarWindow::Paint( const Rectangle& ) MenubarValue aMenubarValue; aMenubarValue.maTopDockingAreaHeight = ImplGetTopDockingAreaHeight( this ); - if ( Application::GetSettings().GetStyleSettings().GetPersonaHeader() ) + if ( !Application::GetSettings().GetStyleSettings().GetPersonaHeader().IsEmpty() ) Erase(); else { |