summaryrefslogtreecommitdiff
path: root/vcl
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2018-04-12 10:04:35 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2018-04-17 08:13:06 +0200
commitb9f9f8253f89151beed27499e6db5c11a7d81eba (patch)
tree67e1506ecce80867e8a7fbf07ffe2ac5c1f6ad11 /vcl
parent0a910746b19f10f184f6ff8f41c868994a472ca9 (diff)
loplugin:constparams
Change-Id: I3d1b88dbd0ff73fddc08d52f50e0efb42daab89b Reviewed-on: https://gerrit.libreoffice.org/52756 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'vcl')
-rw-r--r--vcl/backendtest/outputdevice/line.cxx2
-rw-r--r--vcl/backendtest/outputdevice/polygon.cxx2
-rw-r--r--vcl/backendtest/outputdevice/polyline.cxx2
-rw-r--r--vcl/backendtest/outputdevice/polypolygon.cxx2
-rw-r--r--vcl/backendtest/outputdevice/rectangle.cxx2
-rw-r--r--vcl/inc/impgraph.hxx2
-rw-r--r--vcl/inc/unx/gtk/gtkframe.hxx2
-rw-r--r--vcl/source/bitmap/BitmapTools.cxx4
-rw-r--r--vcl/source/control/tabctrl.cxx2
-rw-r--r--vcl/source/gdi/gdimtf.cxx2
-rw-r--r--vcl/source/gdi/impgraph.cxx2
-rw-r--r--vcl/source/outdev/bitmap.cxx11
-rw-r--r--vcl/unx/gtk/gtksalframe.cxx2
-rw-r--r--vcl/unx/gtk3/gtk3gtkframe.cxx2
14 files changed, 20 insertions, 19 deletions
diff --git a/vcl/backendtest/outputdevice/line.cxx b/vcl/backendtest/outputdevice/line.cxx
index 5b06e85826b8..59a2294bfa38 100644
--- a/vcl/backendtest/outputdevice/line.cxx
+++ b/vcl/backendtest/outputdevice/line.cxx
@@ -16,7 +16,7 @@ namespace test {
namespace
{
-void drawLineOffset(OutputDevice& rDevice, tools::Rectangle& rRect, int nOffset)
+void drawLineOffset(OutputDevice& rDevice, tools::Rectangle const & rRect, int nOffset)
{
Point aLeftTop (rRect.Left() + nOffset, rRect.Top() + nOffset);
Point aRightTop (rRect.Right() - nOffset, rRect.Top() + nOffset);
diff --git a/vcl/backendtest/outputdevice/polygon.cxx b/vcl/backendtest/outputdevice/polygon.cxx
index dd3da404daf3..785bc5dab72c 100644
--- a/vcl/backendtest/outputdevice/polygon.cxx
+++ b/vcl/backendtest/outputdevice/polygon.cxx
@@ -16,7 +16,7 @@ namespace test {
namespace
{
-void drawPolygonOffset(OutputDevice& rDevice, tools::Rectangle& rRect, int nOffset)
+void drawPolygonOffset(OutputDevice& rDevice, tools::Rectangle const & rRect, int nOffset)
{
tools::Polygon aPolygon(4);
aPolygon.SetPoint(Point(rRect.Left() + nOffset, rRect.Top() + nOffset), 0);
diff --git a/vcl/backendtest/outputdevice/polyline.cxx b/vcl/backendtest/outputdevice/polyline.cxx
index 404cf3a53500..49894a1a2186 100644
--- a/vcl/backendtest/outputdevice/polyline.cxx
+++ b/vcl/backendtest/outputdevice/polyline.cxx
@@ -16,7 +16,7 @@ namespace test {
namespace
{
-void drawPolyLineOffset(OutputDevice& rDevice, tools::Rectangle& rRect, int nOffset)
+void drawPolyLineOffset(OutputDevice& rDevice, tools::Rectangle const & rRect, int nOffset)
{
tools::Polygon aPolygon(4);
aPolygon.SetPoint(Point(rRect.Left() + nOffset, rRect.Top() + nOffset), 0);
diff --git a/vcl/backendtest/outputdevice/polypolygon.cxx b/vcl/backendtest/outputdevice/polypolygon.cxx
index d01465251d7c..10ebc85e2d62 100644
--- a/vcl/backendtest/outputdevice/polypolygon.cxx
+++ b/vcl/backendtest/outputdevice/polypolygon.cxx
@@ -17,7 +17,7 @@ namespace test {
namespace
{
-tools::Polygon createPolygonOffset(tools::Rectangle& rRect, int nOffset)
+tools::Polygon createPolygonOffset(tools::Rectangle const & rRect, int nOffset)
{
tools::Polygon aPolygon(4);
aPolygon.SetPoint(Point(rRect.Left() + nOffset, rRect.Top() + nOffset), 0);
diff --git a/vcl/backendtest/outputdevice/rectangle.cxx b/vcl/backendtest/outputdevice/rectangle.cxx
index 5daffc6c0fdf..199c299b2b2d 100644
--- a/vcl/backendtest/outputdevice/rectangle.cxx
+++ b/vcl/backendtest/outputdevice/rectangle.cxx
@@ -15,7 +15,7 @@ namespace test {
namespace
{
- void drawRectOffset(OutputDevice& rDevice, tools::Rectangle& rRect, int nOffset)
+ void drawRectOffset(OutputDevice& rDevice, tools::Rectangle const & rRect, int nOffset)
{
rDevice.DrawRect(tools::Rectangle(rRect.Left() + nOffset, rRect.Top() + nOffset,
rRect.Right() - nOffset, rRect.Bottom() - nOffset));
diff --git a/vcl/inc/impgraph.hxx b/vcl/inc/impgraph.hxx
index a24f786a5b86..814f9feed6f5 100644
--- a/vcl/inc/impgraph.hxx
+++ b/vcl/inc/impgraph.hxx
@@ -44,7 +44,7 @@ private:
BitmapChecksum mnID4;
public:
- GraphicID(ImpGraphic& rGraphic);
+ GraphicID(ImpGraphic const & rGraphic);
bool operator==(const GraphicID& rID) const
{
diff --git a/vcl/inc/unx/gtk/gtkframe.hxx b/vcl/inc/unx/gtk/gtkframe.hxx
index 3db18f03fbcf..0940736738fa 100644
--- a/vcl/inc/unx/gtk/gtkframe.hxx
+++ b/vcl/inc/unx/gtk/gtkframe.hxx
@@ -341,7 +341,7 @@ class GtkSalFrame : public SalFrame
enum class SetType { RetainSize, Fullscreen, UnFullscreen };
- void SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle *pSize = nullptr );
+ void SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle const *pSize = nullptr );
public:
#if GTK_CHECK_VERSION(3,0,0)
diff --git a/vcl/source/bitmap/BitmapTools.cxx b/vcl/source/bitmap/BitmapTools.cxx
index 6d3b0af31015..c21d5fd2a369 100644
--- a/vcl/source/bitmap/BitmapTools.cxx
+++ b/vcl/source/bitmap/BitmapTools.cxx
@@ -724,7 +724,7 @@ static bool readAlpha( BitmapReadAccess const * pAlphaReadAcc, long nY, const lo
* @param data will be filled with alpha data, if xBitmap is alpha/transparent image
* @param bHasAlpha will be set to true if resulting surface has alpha
**/
-void CanvasCairoExtractBitmapData( BitmapEx & aBmpEx, Bitmap & aBitmap, unsigned char*& data, bool& bHasAlpha, long& rnWidth, long& rnHeight )
+void CanvasCairoExtractBitmapData( BitmapEx const & aBmpEx, Bitmap & aBitmap, unsigned char*& data, bool& bHasAlpha, long& rnWidth, long& rnHeight )
{
AlphaMask aAlpha = aBmpEx.GetAlpha();
@@ -944,7 +944,7 @@ void CanvasCairoExtractBitmapData( BitmapEx & aBmpEx, Bitmap & aBitmap, unsigned
}
- uno::Sequence< sal_Int8 > CanvasExtractBitmapData(BitmapEx & rBitmapEx, const geometry::IntegerRectangle2D& rect)
+ uno::Sequence< sal_Int8 > CanvasExtractBitmapData(BitmapEx const & rBitmapEx, const geometry::IntegerRectangle2D& rect)
{
Bitmap aBitmap( rBitmapEx.GetBitmap() );
Bitmap aAlpha( rBitmapEx.GetAlpha().GetBitmap() );
diff --git a/vcl/source/control/tabctrl.cxx b/vcl/source/control/tabctrl.cxx
index a4f06757c2ea..13f08e464724 100644
--- a/vcl/source/control/tabctrl.cxx
+++ b/vcl/source/control/tabctrl.cxx
@@ -760,7 +760,7 @@ void TabControl::ImplShowFocus()
ShowFocus( aRect );
}
-void TabControl::ImplDrawItem(vcl::RenderContext& rRenderContext, ImplTabItem* pItem, const tools::Rectangle& rCurRect,
+void TabControl::ImplDrawItem(vcl::RenderContext& rRenderContext, ImplTabItem const * pItem, const tools::Rectangle& rCurRect,
bool bFirstInGroup, bool bLastInGroup )
{
if (pItem->maRect.IsEmpty())
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx
index 06700e436c5d..7955c5608b84 100644
--- a/vcl/source/gdi/gdimtf.cxx
+++ b/vcl/source/gdi/gdimtf.cxx
@@ -2609,7 +2609,7 @@ namespace
ImplMetaReadData& m_rData;
rtl_TextEncoding m_eOrigCharSet;
public:
- DepthGuard(ImplMetaReadData& rData, SvStream& rIStm)
+ DepthGuard(ImplMetaReadData& rData, SvStream const & rIStm)
: m_rData(rData)
, m_eOrigCharSet(m_rData.meActualCharSet)
{
diff --git a/vcl/source/gdi/impgraph.cxx b/vcl/source/gdi/impgraph.cxx
index 0f1e849183de..c4ef749ec6da 100644
--- a/vcl/source/gdi/impgraph.cxx
+++ b/vcl/source/gdi/impgraph.cxx
@@ -101,7 +101,7 @@ Size GraphicReader::GetPreviewSize() const
return aSize;
}
-GraphicID::GraphicID(ImpGraphic & rGraphic)
+GraphicID::GraphicID(ImpGraphic const & rGraphic)
{
mnID1 = static_cast<sal_uLong>(rGraphic.ImplGetType()) << 28;
mnID2 = mnID3 = mnID4 = 0;
diff --git a/vcl/source/outdev/bitmap.cxx b/vcl/source/outdev/bitmap.cxx
index eb0093d164cd..a9d2215f7791 100644
--- a/vcl/source/outdev/bitmap.cxx
+++ b/vcl/source/outdev/bitmap.cxx
@@ -720,8 +720,8 @@ struct LinearScaleContext
std::unique_ptr<long[]> mpMapXOffset;
std::unique_ptr<long[]> mpMapYOffset;
- LinearScaleContext(tools::Rectangle const & aDstRect, tools::Rectangle& aBitmapRect,
- Size& aOutSize, long nOffX, long nOffY)
+ LinearScaleContext(tools::Rectangle const & aDstRect, tools::Rectangle const & aBitmapRect,
+ Size const & aOutSize, long nOffX, long nOffY)
: mpMapX(new long[aDstRect.GetWidth()])
, mpMapY(new long[aDstRect.GetHeight()])
@@ -884,8 +884,8 @@ struct TradScaleContext
std::unique_ptr<long[]> mpMapX;
std::unique_ptr<long[]> mpMapY;
- TradScaleContext(tools::Rectangle const & aDstRect, tools::Rectangle& aBitmapRect,
- Size& aOutSize, long nOffX, long nOffY)
+ TradScaleContext(tools::Rectangle const & aDstRect, tools::Rectangle const & aBitmapRect,
+ Size const & aOutSize, long nOffX, long nOffY)
: mpMapX(new long[aDstRect.GetWidth()])
, mpMapY(new long[aDstRect.GetHeight()])
@@ -927,7 +927,8 @@ private:
} // end anonymous namespace
-void OutputDevice::DrawDeviceAlphaBitmapSlowPath(const Bitmap& rBitmap, const AlphaMask& rAlpha, tools::Rectangle aDstRect, tools::Rectangle aBmpRect, Size& aOutSize, Point& aOutPoint)
+void OutputDevice::DrawDeviceAlphaBitmapSlowPath(const Bitmap& rBitmap,
+ const AlphaMask& rAlpha, tools::Rectangle aDstRect, tools::Rectangle aBmpRect, Size const & aOutSize, Point const & aOutPoint)
{
assert(!is_double_buffered_window());
diff --git a/vcl/unx/gtk/gtksalframe.cxx b/vcl/unx/gtk/gtksalframe.cxx
index d95fa6ec60ac..78bfae5559e4 100644
--- a/vcl/unx/gtk/gtksalframe.cxx
+++ b/vcl/unx/gtk/gtksalframe.cxx
@@ -1816,7 +1816,7 @@ bool GtkSalFrame::GetWindowState( SalFrameState* pState )
return true;
}
-void GtkSalFrame::SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle *pSize )
+void GtkSalFrame::SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle const *pSize )
{
if( !m_pWindow )
return;
diff --git a/vcl/unx/gtk3/gtk3gtkframe.cxx b/vcl/unx/gtk3/gtk3gtkframe.cxx
index 4ba26b017ed4..63ac768836ed 100644
--- a/vcl/unx/gtk3/gtk3gtkframe.cxx
+++ b/vcl/unx/gtk3/gtk3gtkframe.cxx
@@ -1827,7 +1827,7 @@ bool GtkSalFrame::GetWindowState( SalFrameState* pState )
return true;
}
-void GtkSalFrame::SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle *pSize )
+void GtkSalFrame::SetScreen( unsigned int nNewScreen, SetType eType, tools::Rectangle const *pSize )
{
if( !m_pWindow )
return;