Pass parameters as const reference

Spotted by Coverity scan.
This commit is contained in:
Jean-Marc Lasgouttes 2024-10-01 11:12:14 +02:00
parent b39cc9ed89
commit 54b6846941
2 changed files with 4 additions and 4 deletions

View File

@ -2326,7 +2326,7 @@ QRectF GuiApplication::baseInputItemRectangle()
} }
void GuiApplication::setBaseInputItemRectangle(QRectF rect) void GuiApplication::setBaseInputItemRectangle(QRectF const & rect)
{ {
d->item_rect_base_ = rect; d->item_rect_base_ = rect;
} }
@ -2338,7 +2338,7 @@ QTransform GuiApplication::baseInputItemTransform()
} }
void GuiApplication::setBaseInputItemTransform(QTransform trans) void GuiApplication::setBaseInputItemTransform(QTransform const & trans)
{ {
d->item_trans_base_ = trans; d->item_trans_base_ = trans;
} }

View File

@ -192,11 +192,11 @@ public:
/// input item rectangle of the base view /// input item rectangle of the base view
QRectF baseInputItemRectangle(); QRectF baseInputItemRectangle();
/// set input item rectangle of the base view /// set input item rectangle of the base view
void setBaseInputItemRectangle(QRectF rect); void setBaseInputItemRectangle(QRectF const & rect);
/// input item transform of the base view /// input item transform of the base view
QTransform baseInputItemTransform(); QTransform baseInputItemTransform();
/// set input item transform of the base view /// set input item transform of the base view
void setBaseInputItemTransform(QTransform trans); void setBaseInputItemTransform(QTransform const & trans);
/// \name Methods to process FuncRequests /// \name Methods to process FuncRequests
//@{ //@{