diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2015-04-28 17:48:03 +0900 |
---|---|---|
committer | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2015-04-29 09:27:54 +0900 |
commit | d0ab8e0cb961c43f7975b496c191ac88859139ed (patch) | |
tree | d06f5234ec68ec86dd5e2c4de79234fdd415baf3 | |
parent | 53ef550ac6fc3505914c3d77e9d0575913e54bb3 (diff) |
vcl edit: Delegate RenderContext to sub-methods, use Invalidate
Change-Id: Ifb1a54e852bc9011389cac758e6f0dfd6c84d464
-rw-r--r-- | include/vcl/edit.hxx | 2 | ||||
-rw-r--r-- | vcl/source/control/edit.cxx | 12 |
2 files changed, 7 insertions, 7 deletions
diff --git a/include/vcl/edit.hxx b/include/vcl/edit.hxx index 30c97d085acc..dde925f47051 100644 --- a/include/vcl/edit.hxx +++ b/include/vcl/edit.hxx @@ -105,7 +105,7 @@ private: SAL_DLLPRIVATE void ImplInitEditData(); SAL_DLLPRIVATE void ImplModified(); SAL_DLLPRIVATE OUString ImplGetText() const; - SAL_DLLPRIVATE void ImplRepaint(bool bLayout = false); + SAL_DLLPRIVATE void ImplRepaint(vcl::RenderContext& rRenderContext, bool bLayout = false); SAL_DLLPRIVATE void ImplInvalidateOrRepaint(); SAL_DLLPRIVATE void ImplDelete( const Selection& rSelection, sal_uInt8 nDirection, sal_uInt8 nMode ); SAL_DLLPRIVATE void ImplSetText( const OUString& rStr, const Selection* pNewSelection = 0 ); diff --git a/vcl/source/control/edit.cxx b/vcl/source/control/edit.cxx index 4e07e3b16740..ece4f5680af4 100644 --- a/vcl/source/control/edit.cxx +++ b/vcl/source/control/edit.cxx @@ -475,7 +475,7 @@ void Edit::ImplInvalidateOrRepaint() Update(); } else - ImplRepaint(); + Invalidate(); } long Edit::ImplGetTextYPosition() const @@ -487,7 +487,7 @@ long Edit::ImplGetTextYPosition() const return ( GetOutputSizePixel().Height() - GetTextHeight() ) / 2; } -void Edit::ImplRepaint(bool bLayout) +void Edit::ImplRepaint(vcl::RenderContext& /*rRenderContext*/, bool bLayout) { if ( !IsReallyVisible() ) return; @@ -1758,13 +1758,13 @@ void Edit::KeyInput( const KeyEvent& rKEvt ) void Edit::FillLayoutData() const { mpControlData->mpLayoutData = new vcl::ControlLayoutData(); - const_cast<Edit*>(this)->ImplRepaint(true); + const_cast<Edit*>(this)->Invalidate(); } -void Edit::Paint( vcl::RenderContext& /*rRenderContext*/, const Rectangle& ) +void Edit::Paint(vcl::RenderContext& rRenderContext, const Rectangle&) { - if ( !mpSubEdit ) - ImplRepaint(); + if (!mpSubEdit) + ImplRepaint(rRenderContext); } void Edit::Resize() |