Kaydet (Commit) a5330f50 authored tarafından Tomaž Vajngerl's avatar Tomaž Vajngerl

refactor ThesaurusAlternativesCtrl to use RenderContext

Change-Id: I65d55c9d57eeb5eb878008885417d1e2118a946d
üst 1a83ac55
...@@ -260,14 +260,13 @@ void ThesaurusAlternativesCtrl::Paint(vcl::RenderContext& rRenderContext, const ...@@ -260,14 +260,13 @@ void ThesaurusAlternativesCtrl::Paint(vcl::RenderContext& rRenderContext, const
{ {
if (!m_pDialog->WordFound()) if (!m_pDialog->WordFound())
{ {
Size aTextSize( GetTextWidth( m_pDialog->getErrStr() ), GetTextHeight() ); Size aTextSize(rRenderContext.GetTextWidth(m_pDialog->getErrStr()), rRenderContext.GetTextHeight());
aTextSize = LogicToPixel( aTextSize ); aTextSize = rRenderContext.LogicToPixel(aTextSize);
Point aPos; Point aPos;
aPos.X() += GetSizePixel().Width() / 2 - aTextSize.Width() / 2; aPos.X() += GetSizePixel().Width() / 2 - aTextSize.Width() / 2;
aPos.Y() += GetSizePixel().Height() / 2; aPos.Y() += GetSizePixel().Height() / 2;
aPos = PixelToLogic( aPos ); aPos = rRenderContext.PixelToLogic(aPos);
DrawText( aPos, m_pDialog->getErrStr() ); rRenderContext.DrawText(aPos, m_pDialog->getErrStr());
} }
else else
SvxCheckListBox::Paint(rRenderContext, rRect); SvxCheckListBox::Paint(rRenderContext, rRect);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment