diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-03-07 17:35:53 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-03-08 08:13:44 +0100 |
commit | 44d5188b2fd8afc82aa8fda1ad4b374734129aea (patch) | |
tree | 07fae7bdc2d87332370d064f9fc81b693a477215 /vcl/source | |
parent | 5eba05a0582cbb836c3715089e5d3bfe1ee19ded (diff) |
loplugin:unusedfields
Change-Id: Id332557cbe7fb42d3d794612f26aa3ac161548d9
Reviewed-on: https://gerrit.libreoffice.org/50902
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl/source')
-rw-r--r-- | vcl/source/edit/vclmedit.cxx | 5 | ||||
-rw-r--r-- | vcl/source/gdi/sallayout.cxx | 8 |
2 files changed, 5 insertions, 8 deletions
diff --git a/vcl/source/edit/vclmedit.cxx b/vcl/source/edit/vclmedit.cxx index 24b3ae713f30..092970d08f28 100644 --- a/vcl/source/edit/vclmedit.cxx +++ b/vcl/source/edit/vclmedit.cxx @@ -42,7 +42,6 @@ private: VclPtr<ScrollBar> mpVScrollBar; VclPtr<ScrollBarBox> mpScrollBox; - Point maTextWindowOffset; long mnTextWidth; mutable Selection maSelection; @@ -379,7 +378,7 @@ void ImpVclMEdit::Resize() else mpHScrollBar->setPosSizePixel( 0, aEditSize.Height()-nSBWidth, aSz.Width(), nSBWidth ); - Point aTextWindowPos( maTextWindowOffset ); + Point aTextWindowPos; if ( mpVScrollBar ) { if( AllSettings::GetLayoutRTL() ) @@ -395,8 +394,6 @@ void ImpVclMEdit::Resize() mpScrollBox->setPosSizePixel( aSz.Width(), aSz.Height(), nSBWidth, nSBWidth ); Size aTextWindowSize( aSz ); - aTextWindowSize.AdjustWidth( -(maTextWindowOffset.X()) ); - aTextWindowSize.AdjustHeight( -(maTextWindowOffset.Y()) ); if ( aTextWindowSize.Width() < 0 ) aTextWindowSize.setWidth( 0 ); if ( aTextWindowSize.Height() < 0 ) diff --git a/vcl/source/gdi/sallayout.cxx b/vcl/source/gdi/sallayout.cxx index 368247cfb76d..616fc63e27fc 100644 --- a/vcl/source/gdi/sallayout.cxx +++ b/vcl/source/gdi/sallayout.cxx @@ -770,7 +770,7 @@ void GenericSalLayout::Justify( DeviceCoordinate nNewWidth ) if( nNewWidth < nMaxGlyphWidth) nNewWidth = nMaxGlyphWidth; nNewWidth -= pGlyphIterRight->mnOrigWidth; - pGlyphIterRight->maLinearPos.setX( maBasePoint.X() + nNewWidth ); + pGlyphIterRight->maLinearPos.setX( nNewWidth ); // justify glyph widths and positions int nDiffWidth = nNewWidth - nOldWidth; @@ -802,9 +802,9 @@ void GenericSalLayout::Justify( DeviceCoordinate nNewWidth ) { for( pGlyphIter = m_GlyphItems.begin(); ++pGlyphIter != pGlyphIterRight;) { - int nX = pGlyphIter->maLinearPos.X() - maBasePoint.X(); + int nX = pGlyphIter->maLinearPos.X(); nX = static_cast<int>(nX * fSqueeze); - pGlyphIter->maLinearPos.setX( nX + maBasePoint.X() ); + pGlyphIter->maLinearPos.setX( nX ); } } // adjust glyph widths to new positions @@ -928,7 +928,7 @@ int GenericSalLayout::GetNextGlyphs(int nLen, const GlyphItem** pGlyphs, return 0; // calculate absolute position in pixel units - Point aRelativePos = pGlyphIter->maLinearPos - maBasePoint; + Point aRelativePos = pGlyphIter->maLinearPos; // find more glyphs which can be merged into one drawing instruction int nCount = 0; |