From e51ec1618df9b1622480c4958a6f59742f6623f0 Mon Sep 17 00:00:00 2001 From: Andre Fischer Date: Thu, 17 Jun 2010 10:00:09 +0200 Subject: [PATCH] renaissance1: #i107215# Focus indicator not lost anymore on mouse-over. --- .../ui/slidesorter/inc/view/SlsPageObjectPainter.hxx | 1 + .../ui/slidesorter/view/SlsPageObjectPainter.cxx | 12 ++++++++++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx b/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx index e41d020e3688..a34a067843c7 100644 --- a/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx +++ b/sd/source/ui/slidesorter/inc/view/SlsPageObjectPainter.hxx @@ -101,6 +101,7 @@ private: Bitmap maFocusedSelectionBackground; Bitmap maFocusedBackground; Bitmap maMouseOverBackground; + Bitmap maMouseOverFocusedBackground; Bitmap maMouseOverSelectedAndFocusedBackground; ::rtl::OUString msUnhideString; ButtonBar& mrButtonBar; diff --git a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx index cb0312238523..efd7c494c5ab 100644 --- a/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx +++ b/sd/source/ui/slidesorter/view/SlsPageObjectPainter.cxx @@ -119,6 +119,7 @@ PageObjectPainter::PageObjectPainter ( maSelectionBackground(), maFocusedSelectionBackground(), maMouseOverBackground(), + maMouseOverFocusedBackground(), msUnhideString(mpTheme->GetString(Theme::String_Unhide)), mrButtonBar(rSlideSorter.GetView().GetButtonBar()) { @@ -179,6 +180,7 @@ void PageObjectPainter::NotifyResize (const bool bForce) maFocusedSelectionBackground.SetEmpty(); maFocusedBackground.SetEmpty(); maMouseOverBackground.SetEmpty(); + maMouseOverFocusedBackground.SetEmpty(); maMouseOverSelectedAndFocusedBackground.SetEmpty(); } @@ -408,13 +410,19 @@ Bitmap& PageObjectPainter::GetBackgroundForState ( true); case MouseOver | Selected: - case MouseOver | Focused: case MouseOver: return GetBackground( maMouseOverBackground, Theme::Gradient_MouseOverPage, rReferenceDevice, - (eState & Focused)!=0); + false); + + case MouseOver | Focused: + return GetBackground( + maMouseOverFocusedBackground, + Theme::Gradient_MouseOverPage, + rReferenceDevice, + true); case Selected | Focused: return GetBackground(