diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-24 13:47:25 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-26 07:21:04 +0100 |
commit | 08ab1f46b192a188935fdffbefdc9f3973583cdf (patch) | |
tree | 4c1ecb502f3c3b2a2a8865ea8f84a083b16d310e /sc/source/ui/Accessibility | |
parent | 9bc8714308b6f4b85a4c756229ac8b670d009f42 (diff) |
loplugin:oncevar extend to tools/gen.hxx types
Change-Id: I5c75875da44334569c02e2ff039b33c38397a0a2
Reviewed-on: https://gerrit.libreoffice.org/50283
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc/source/ui/Accessibility')
4 files changed, 9 insertions, 18 deletions
diff --git a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx index b9f0d3188209..4b7d699ce46e 100644 --- a/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx +++ b/sc/source/ui/Accessibility/AccessibleDocumentPagePreview.cxx @@ -1127,8 +1127,7 @@ ScPagePreviewCountData::ScPagePreviewCountData( const ScPreviewLocationData& rDa Size aOutputSize; if ( pSizeWindow ) aOutputSize = pSizeWindow->GetOutputSizePixel(); - Point aPoint; - aVisRect = tools::Rectangle( aPoint, aOutputSize ); + aVisRect = tools::Rectangle( Point(), aOutputSize ); tools::Rectangle aObjRect; @@ -1236,8 +1235,7 @@ void ScAccessibleDocumentPagePreview::Notify( SfxBroadcaster& rBC, const SfxHint vcl::Window* pSizeWindow = mpViewShell->GetWindow(); if ( pSizeWindow ) aOutputSize = pSizeWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); GetNotesChildren()->DataChanged(aVisRect); GetShapeChildren()->DataChanged(); @@ -1273,8 +1271,7 @@ void ScAccessibleDocumentPagePreview::Notify( SfxBroadcaster& rBC, const SfxHint vcl::Window* pSizeWindow = mpViewShell->GetWindow(); if ( pSizeWindow ) aOutputSize = pSizeWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); GetNotesChildren()->DataChanged(aVisRect); GetShapeChildren()->VisAreaChanged(); diff --git a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx index 6f7a84ae8034..6ba7b9e1e527 100644 --- a/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx +++ b/sc/source/ui/Accessibility/AccessiblePreviewHeaderCell.cxx @@ -405,8 +405,7 @@ void ScAccessiblePreviewHeaderCell::FillTableInfo() const vcl::Window* pWindow = mpViewShell->GetWindow(); if ( pWindow ) aOutputSize = pWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); mpTableInfo = new ScPreviewTableInfo; mpViewShell->GetLocationData().GetTableInfo( aVisRect, *mpTableInfo ); diff --git a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx index 912d15af153d..080f2c9c49a8 100644 --- a/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx +++ b/sc/source/ui/Accessibility/AccessiblePreviewTable.cxx @@ -636,8 +636,7 @@ void ScAccessiblePreviewTable::FillTableInfo() const vcl::Window* pWindow = mpViewShell->GetWindow(); if ( pWindow ) aOutputSize = pWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); mpTableInfo = new ScPreviewTableInfo; mpViewShell->GetLocationData().GetTableInfo( aVisRect, *mpTableInfo ); diff --git a/sc/source/ui/Accessibility/AccessibleText.cxx b/sc/source/ui/Accessibility/AccessibleText.cxx index e904086483fc..4842d7b211c6 100644 --- a/sc/source/ui/Accessibility/AccessibleText.cxx +++ b/sc/source/ui/Accessibility/AccessibleText.cxx @@ -265,9 +265,8 @@ bool ScPreviewViewForwarder::IsValid() const tools::Rectangle ScPreviewViewForwarder::GetVisArea() const { - tools::Rectangle aVisArea; OSL_FAIL("should be implemented in an abrevated class"); - return aVisArea; + return tools::Rectangle(); } Point ScPreviewViewForwarder::LogicToPixel( const Point& rPoint, const MapMode& rMapMode ) const @@ -325,8 +324,7 @@ tools::Rectangle ScPreviewViewForwarder::GetVisRect() const vcl::Window* pWindow = mpViewShell->GetWindow(); if ( pWindow ) aOutputSize = pWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); return aVisRect; } return tools::Rectangle(); @@ -1274,8 +1272,7 @@ SvxTextForwarder* ScAccessiblePreviewHeaderCellTextData::GetTextForwarder() vcl::Window* pWindow = mpViewShell->GetWindow(); if ( pWindow ) aOutputSize = pWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); Size aSize(mpViewShell->GetLocationData().GetHeaderCellOutputRect(aVisRect, aCellPos, mbColHeader).GetSize()); if (pWindow) aSize = pWindow->PixelToLogic(aSize, pEditEngine->GetRefMapMode()); @@ -1501,8 +1498,7 @@ SvxTextForwarder* ScAccessibleNoteTextData::GetTextForwarder() vcl::Window* pWindow = mpViewShell->GetWindow(); if ( pWindow ) aOutputSize = pWindow->GetOutputSizePixel(); - Point aPoint; - tools::Rectangle aVisRect( aPoint, aOutputSize ); + tools::Rectangle aVisRect( Point(), aOutputSize ); Size aSize(mpViewShell->GetLocationData().GetNoteInRangeOutputRect(aVisRect, mbMarkNote, maCellPos).GetSize()); if (pWindow) aSize = pWindow->PixelToLogic(aSize, mpEditEngine->GetRefMapMode()); |