diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-26 13:27:48 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2018-02-27 10:24:26 +0100 |
commit | be5af6cefea2fa43479ec6124e2c847956144a6d (patch) | |
tree | fad5a923c045b7e1b5b3813a037e3e683f2104e8 /sd | |
parent | 8be5a49f377e5451da953aee598fd22f9665fbd6 (diff) |
drop old tools/gen.hxx methods in sd
Change-Id: I8af9c5c0085f5e6f8e498c48bae69f8247ef88ed
Reviewed-on: https://gerrit.libreoffice.org/50362
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sd')
-rw-r--r-- | sd/source/ui/animations/CustomAnimationList.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/dlg/RemoteDialogClientBox.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/func/fusel.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/func/fuzoom.cxx | 6 | ||||
-rw-r--r-- | sd/source/ui/slideshow/slideshowviewimpl.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx | 2 | ||||
-rw-r--r-- | sd/source/ui/view/DocumentRenderer.cxx | 34 | ||||
-rw-r--r-- | sd/source/ui/view/viewoverlaymanager.cxx | 8 |
8 files changed, 29 insertions, 29 deletions
diff --git a/sd/source/ui/animations/CustomAnimationList.cxx b/sd/source/ui/animations/CustomAnimationList.cxx index 086162e99fdb..c2908041be6d 100644 --- a/sd/source/ui/animations/CustomAnimationList.cxx +++ b/sd/source/ui/animations/CustomAnimationList.cxx @@ -421,7 +421,7 @@ void CustomAnimationTriggerEntryItem::Paint(const Point& rPos, SvTreeListBox& rD aOutRect.AdjustLeft(nHorzBorder ); aOutRect.AdjustRight( -nHorzBorder ); - aOutRect.Top() += nVertBorder; + aOutRect.AdjustTop( nVertBorder ); aOutRect.AdjustBottom( -nVertBorder ); rRenderContext.DrawText(aOutRect, rRenderContext.GetEllipsisString(msDescription, aOutRect.GetWidth())); diff --git a/sd/source/ui/dlg/RemoteDialogClientBox.cxx b/sd/source/ui/dlg/RemoteDialogClientBox.cxx index 1fbd88cef57f..f5618622d042 100644 --- a/sd/source/ui/dlg/RemoteDialogClientBox.cxx +++ b/sd/source/ui/dlg/RemoteDialogClientBox.cxx @@ -152,7 +152,7 @@ void ClientBox::CalcActiveHeight() if ( m_bHasScrollBar ) aSize.AdjustWidth( -(m_aScrollBar->GetSizePixel().Width()) ); - aSize.Width() -= ICON_OFFSET; + aSize.AdjustWidth( -ICON_OFFSET ); aSize = LogicToPixel( Size( RSC_CD_PUSHBUTTON_WIDTH, RSC_CD_PUSHBUTTON_HEIGHT ), MapMode( MapUnit::MapAppFont ) ); diff --git a/sd/source/ui/func/fusel.cxx b/sd/source/ui/func/fusel.cxx index 3746ebacb4d6..968fde162a44 100644 --- a/sd/source/ui/func/fusel.cxx +++ b/sd/source/ui/func/fusel.cxx @@ -1222,7 +1222,7 @@ bool FuSelection::AnimateObj(SdrObject* pObj, const Point& rPos) aHitPosR.AdjustX(n2HitLog ); aHitPosL.AdjustX( -n2HitLog ); - aHitPosT.Y() += n2HitLog; + aHitPosT.AdjustY( n2HitLog ); aHitPosB.AdjustY( -n2HitLog ); if ( !bClosed || diff --git a/sd/source/ui/func/fuzoom.cxx b/sd/source/ui/func/fuzoom.cxx index a6d5011e1923..e71452847a9d 100644 --- a/sd/source/ui/func/fuzoom.cxx +++ b/sd/source/ui/func/fuzoom.cxx @@ -118,7 +118,7 @@ bool FuZoom::MouseMove(const MouseEvent& rMEvt) Size aWorkSize = mpView->GetWorkArea().GetSize(); Size aPageSize = mpView->GetSdrPageView()->GetPage()->GetSize(); aScroll.setX( aScroll.X() / ( aWorkSize.Width() / aPageSize.Width()) ); - aScroll.Y() /= aWorkSize.Height() / aPageSize.Height(); + aScroll.setY( aScroll.Y() / ( aWorkSize.Height() / aPageSize.Height()) ); mpViewShell->Scroll(aScroll.X(), aScroll.Y()); aBeginPosPix = aPosPix; } @@ -164,12 +164,12 @@ bool FuZoom::MouseButtonUp(const MouseEvent& rMEvt) if ( rMEvt.IsMod1() ) { aSize.setWidth( aSize.Width() * 2 ); - aSize.Height() *= 2; + aSize.setHeight( aSize.Height() * 2 ); } else { aSize.setWidth( aSize.Width() / 2 ); - aSize.Height() /= 2; + aSize.setHeight( aSize.Height() / 2 ); } aPos.AdjustX( -(aSize.Width() / 2) ); aPos.AdjustY( -(aSize.Height() / 2) ); diff --git a/sd/source/ui/slideshow/slideshowviewimpl.cxx b/sd/source/ui/slideshow/slideshowviewimpl.cxx index 236035c1f73d..f63e1012c749 100644 --- a/sd/source/ui/slideshow/slideshowviewimpl.cxx +++ b/sd/source/ui/slideshow/slideshowviewimpl.cxx @@ -355,7 +355,7 @@ geometry::AffineMatrix2D SAL_CALL SlideShowView::getTransformation( ) // render one pixel wider and higher as aPageSize below specifies // (when shapes of page size have visible border lines) aOutputSize.AdjustWidth( -1 ); - aOutputSize.Height() --; + aOutputSize.AdjustHeight( -1 ); // Record mTranslationOffset mTranslationOffset.Height = aOutputOffset.Y(); diff --git a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx index 31be00214317..377b0932438c 100644 --- a/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx +++ b/sd/source/ui/slidesorter/cache/SlsBitmapFactory.cxx @@ -57,7 +57,7 @@ Bitmap BitmapFactory::CreateBitmap ( // Supersampling factor int aSuperSamplingFactor = 2; aSize.setWidth( aSize.Width() * aSuperSamplingFactor ); - aSize.Height() *= aSuperSamplingFactor; + aSize.setHeight( aSize.Height() * aSuperSamplingFactor ); } Bitmap aPreview (maRenderer.RenderPage ( diff --git a/sd/source/ui/view/DocumentRenderer.cxx b/sd/source/ui/view/DocumentRenderer.cxx index a88448666f2a..91377f2b69f2 100644 --- a/sd/source/ui/view/DocumentRenderer.cxx +++ b/sd/source/ui/view/DocumentRenderer.cxx @@ -1939,8 +1939,8 @@ private: && aPageWidth > aPageHeight ) ) { const sal_Int32 nTmp (rInfo.maPrintSize.Width()); - rInfo.maPrintSize.Width() = rInfo.maPrintSize.Height(); - rInfo.maPrintSize.Height() = nTmp; + rInfo.maPrintSize.setWidth( rInfo.maPrintSize.Height() ); + rInfo.maPrintSize.setHeight( nTmp ); } if (mpOptions->IsTilePage() @@ -1970,22 +1970,22 @@ private: Size aPageSize_2 (rInfo.maPageSize); if (rInfo.meOrientation == Orientation::Landscape) - aPrintSize_2.Width() >>= 1; + aPrintSize_2.setWidth( aPrintSize_2.Width() >> 1 ); else - aPrintSize_2.Height() >>= 1; + aPrintSize_2.setHeight( aPrintSize_2.Height() >> 1 ); const double fPageWH = static_cast<double>(aPageSize_2.Width()) / aPageSize_2.Height(); const double fPrintWH = static_cast<double>(aPrintSize_2.Width()) / aPrintSize_2.Height(); if( fPageWH < fPrintWH ) { - aPageSize_2.Width() = static_cast<long>( aPrintSize_2.Height() * fPageWH ); - aPageSize_2.Height()= aPrintSize_2.Height(); + aPageSize_2.setWidth( static_cast<long>( aPrintSize_2.Height() * fPageWH ) ); + aPageSize_2.setHeight( aPrintSize_2.Height() ); } else { - aPageSize_2.Width() = aPrintSize_2.Width(); - aPageSize_2.Height() = static_cast<long>( aPrintSize_2.Width() / fPageWH ); + aPageSize_2.setWidth( aPrintSize_2.Width() ); + aPageSize_2.setHeight( static_cast<long>( aPrintSize_2.Width() / fPageWH ) ); } MapMode aMap (rInfo.maMap); @@ -2000,13 +2000,13 @@ private: if (rInfo.meOrientation == Orientation::Landscape) { - aOffset.X() = ( ( aAdjustedPrintSize.Width() >> 1 ) - rInfo.maPageSize.Width() ) >> 1; - aOffset.Y() = ( aAdjustedPrintSize.Height() - rInfo.maPageSize.Height() ) >> 1; + aOffset.setX( ( ( aAdjustedPrintSize.Width() >> 1 ) - rInfo.maPageSize.Width() ) >> 1 ); + aOffset.setY( ( aAdjustedPrintSize.Height() - rInfo.maPageSize.Height() ) >> 1 ); } else { - aOffset.X() = ( aAdjustedPrintSize.Width() - rInfo.maPageSize.Width() ) >> 1; - aOffset.Y() = ( ( aAdjustedPrintSize.Height() >> 1 ) - rInfo.maPageSize.Height() ) >> 1; + aOffset.setX( ( aAdjustedPrintSize.Width() - rInfo.maPageSize.Width() ) >> 1 ); + aOffset.setY( ( ( aAdjustedPrintSize.Height() >> 1 ) - rInfo.maPageSize.Height() ) >> 1 ); } // create vector of pages to print @@ -2059,9 +2059,9 @@ private: const std::pair<sal_uInt16, sal_uInt16> aPair (aPairVector[nIndex]); Point aSecondOffset (aOffset); if (rInfo.meOrientation == Orientation::Landscape) - aSecondOffset.X() += aAdjustedPrintSize.Width() / 2; + aSecondOffset.AdjustX( aAdjustedPrintSize.Width() / 2 ); else - aSecondOffset.Y() += aAdjustedPrintSize.Height() / 2; + aSecondOffset.AdjustY( aAdjustedPrintSize.Height() / 2 ); maPrinterPages.push_back( std::shared_ptr<PrinterPage>( new BookletPrinterPage( @@ -2171,11 +2171,11 @@ private: for (Point aPageOrigin = aOrigin; -aPageOrigin.Y()<nPageHeight; - aPageOrigin.Y() -= rInfo.maPrintSize.Height()) + aPageOrigin.AdjustY( -rInfo.maPrintSize.Height() )) { - for (aPageOrigin.X()=aOrigin.X(); + for (aPageOrigin.setX(aOrigin.X()); -aPageOrigin.X()<nPageWidth; - aPageOrigin.X() -= rInfo.maPrintSize.Width()) + aPageOrigin.AdjustX(-rInfo.maPrintSize.Width())) { aMap.SetOrigin(aPageOrigin); maPrinterPages.push_back( diff --git a/sd/source/ui/view/viewoverlaymanager.cxx b/sd/source/ui/view/viewoverlaymanager.cxx index 7db5e61a6929..f7646704b3fb 100644 --- a/sd/source/ui/view/viewoverlaymanager.cxx +++ b/sd/source/ui/view/viewoverlaymanager.cxx @@ -223,8 +223,8 @@ void ImageButtonHdl::CreateB2dIAObject() BitmapEx aBitmapEx( mxChangePlaceholderTag->createOverlayImage( mnHighlightId ) ); // maImageMO.GetBitmapEx() : maImage.GetBitmapEx() ); maImageSize = aBitmapEx.GetSizePixel(); - maImageSize.Width() >>= 1; - maImageSize.Height() >>= 1; + maImageSize.setWidth( maImageSize.Width() >> 1 ); + maImageSize.setHeight( maImageSize.Height() >> 1 ); if(pHdlList) { @@ -384,8 +384,8 @@ void ChangePlaceholderTag::addCustomHandles( SdrHdlList& rHandlerList ) long all_height = nRows * aButtonSize.Height(); Point aPos( rSnapRect.Center() ); - aPos.X() -= all_width >> 1; - aPos.Y() -= all_height >> 1; + aPos.AdjustX( -(all_width >> 1) ); + aPos.AdjustY( -(all_height >> 1) ); ImageButtonHdl* pHdl = new ImageButtonHdl( xThis, aPoint ); pHdl->SetObjHdlNum( SMART_TAG_HDL_NUM ); |