summaryrefslogtreecommitdiff
path: root/svtools
diff options
context:
space:
mode:
authorTomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>2015-05-29 16:54:48 +0900
committerJan Holesovsky <kendy@collabora.com>2015-05-29 20:16:54 +0200
commit6d0696980a39b5a0618221c0120ecead4846ff05 (patch)
tree6fd8513dd9a6fdc1e21e17d9c136626452694c35 /svtools
parent22e168424d774fb29dd9a77664bc1d2d6833c40b (diff)
tdf#91677 fix invidsible menu in Base
Change-Id: Ie1a8d6125d4a9d67f06f7dc37aa4d5115ad1af28 Signed-off-by: Jan Holesovsky <kendy@collabora.com>
Diffstat (limited to 'svtools')
-rw-r--r--svtools/source/contnr/imivctl1.cxx12
1 files changed, 4 insertions, 8 deletions
diff --git a/svtools/source/contnr/imivctl1.cxx b/svtools/source/contnr/imivctl1.cxx
index a6cf4575545d..7c790ff30b27 100644
--- a/svtools/source/contnr/imivctl1.cxx
+++ b/svtools/source/contnr/imivctl1.cxx
@@ -663,10 +663,6 @@ void SvxIconChoiceCtrl_Impl::Paint(vcl::RenderContext& rRenderContext, const Rec
pCursor = aEntries[ 0 ];
}
- // Show Focus at Init-Time
- if (pView->HasFocus())
- GetFocus();
-
size_t nCount = pZOrderList->size();
if (!nCount)
return;
@@ -1650,20 +1646,20 @@ void SvxIconChoiceCtrl_Impl::PaintEntry(SvxIconChoiceCtrlEntry* pEntry, const Po
bool bDropTarget = pEntry->IsDropTarget();
bool bNoEmphasis = pEntry->IsBlockingEmphasis();
- vcl::Font aTempFont(rRenderContext.GetFont());
+ rRenderContext.Push(PushFlags::FONT | PushFlags::TEXTCOLOR);
OUString aEntryText(SvtIconChoiceCtrl::GetEntryText(pEntry, false));
Rectangle aTextRect(CalcTextRect(pEntry, &rPos, false, &aEntryText));
Rectangle aBmpRect(CalcBmpRect(pEntry, &rPos));
- bool bShowSelection = (((bSelected && !bCursored) || bDropTarget) && !bNoEmphasis && (eSelectionMode != NO_SELECTION));
+ bool bShowSelection = ((bSelected && !bCursored) && !bNoEmphasis && (eSelectionMode != NO_SELECTION));
bool bActiveSelection = (0 != (nWinBits & WB_NOHIDESELECTION)) || pView->HasFocus();
if (bShowSelection)
{
const StyleSettings& rSettings = rRenderContext.GetSettings().GetStyleSettings();
- vcl::Font aNewFont(aTempFont);
+ vcl::Font aNewFont(rRenderContext.GetFont());
// font fill colors that are attributed "hard" need corresponding "hard"
// attributed highlight colors
@@ -1718,7 +1714,7 @@ void SvxIconChoiceCtrl_Impl::PaintEntry(SvxIconChoiceCtrlEntry* pEntry, const Po
if (pEntry == pCurHighlightFrame && !bNoEmphasis)
DrawHighlightFrame(rRenderContext, CalcFocusRect(pEntry), false);
- rRenderContext.SetFont(aTempFont);
+ rRenderContext.Pop();
if (bResetClipRegion)
rRenderContext.SetClipRegion();
}