diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-16 11:56:18 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-16 15:13:53 +0100 |
commit | 1d180f48bc61444c610c35083e35745d38c6cce2 (patch) | |
tree | e580741aa902908a9fcf0c4b224e93ff42da1405 /forms | |
parent | 26783527823883ccd5bbf3b9e014a0a3c1e3a022 (diff) |
Revert "loplugin:changetoolsgen in filter..framework" and reapply plugin
because I
(a) forgot to insert parentheses which changes the meaning of some expressions and
(b) I now use the AdjustFoo calls when changing unary operations, which reads much better
This reverts commit bf8a6cacd06d7c1961b5db8cc79ee4bbdb342e43.
Change-Id: I4b5a9bf0c38ee1b57af91e6b7f184f1e8807f6f7
Reviewed-on: https://gerrit.libreoffice.org/49843
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'forms')
-rw-r--r-- | forms/source/richtext/richtextimplcontrol.cxx | 12 | ||||
-rw-r--r-- | forms/source/solar/control/navtoolbar.cxx | 2 |
2 files changed, 7 insertions, 7 deletions
diff --git a/forms/source/richtext/richtextimplcontrol.cxx b/forms/source/richtext/richtextimplcontrol.cxx index 003e11b03145..ed3cce56bc2c 100644 --- a/forms/source/richtext/richtextimplcontrol.cxx +++ b/forms/source/richtext/richtextimplcontrol.cxx @@ -545,10 +545,10 @@ namespace frm { void lcl_inflate( tools::Rectangle& _rRect, long _nInflateX, long _nInflateY ) { - _rRect.SetLeft( _rRect.Left() - _nInflateX ); - _rRect.SetRight( _rRect.Right() + _nInflateX ); - _rRect.SetTop( _rRect.Top() - _nInflateY ); - _rRect.SetBottom( _rRect.Bottom() + _nInflateY ); + _rRect.AdjustLeft( -_nInflateX ); + _rRect.AdjustRight(_nInflateX ); + _rRect.AdjustTop( -_nInflateY ); + _rRect.AdjustBottom(_nInflateY ); } } @@ -594,8 +594,8 @@ namespace frm tools::Rectangle aPlayground( aPos, aSize ); Size aOnePixel( _pDev->PixelToLogic( Size( 1, 1 ) ) ); - aPlayground.SetRight( aPlayground.Right() - aOnePixel.Width() ); - aPlayground.SetBottom( aPlayground.Bottom() - aOnePixel.Height() ); + aPlayground.AdjustRight( -(aOnePixel.Width()) ); + aPlayground.AdjustBottom( -(aOnePixel.Height()) ); // background _pDev->SetLineColor(); diff --git a/forms/source/solar/control/navtoolbar.cxx b/forms/source/solar/control/navtoolbar.cxx index dc8de707c0c4..f80952e44162 100644 --- a/forms/source/solar/control/navtoolbar.cxx +++ b/forms/source/solar/control/navtoolbar.cxx @@ -634,7 +634,7 @@ namespace frm } Size aSize( _pItemWindow->GetTextWidth( sItemText ), /* _pItemWindow->GetSizePixel( ).Height() */ _pItemWindow->GetTextHeight() + 4 ); - aSize.setWidth( aSize.Width() + 6 ); + aSize.AdjustWidth(6 ); _pItemWindow->SetSizePixel( aSize ); m_pToolbar->SetItemWindow( _nItemId, _pItemWindow ); |