aboutsummaryrefslogtreecommitdiff
path: root/src/engine/data/bounds.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/engine/data/bounds.cpp')
-rw-r--r--src/engine/data/bounds.cpp14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/engine/data/bounds.cpp b/src/engine/data/bounds.cpp
index 1a8c4d0..ca67008 100644
--- a/src/engine/data/bounds.cpp
+++ b/src/engine/data/bounds.cpp
@@ -5,7 +5,7 @@ Bounds::Bounds(const BoundsOptions &options) noexcept
{
}
-Bounds::Value Bounds::get_width() const noexcept
+auto Bounds::get_width() const noexcept -> Bounds::Value
{
return _width;
}
@@ -15,7 +15,7 @@ void Bounds::set_width(Bounds::Value width) noexcept
_width = width;
}
-Bounds::Value Bounds::get_height() const noexcept
+auto Bounds::get_height() const noexcept -> Bounds::Value
{
return _height;
}
@@ -25,7 +25,7 @@ void Bounds::set_height(Bounds::Value height) noexcept
_height = height;
}
-CoordsValidation Bounds::validate_coords(const Vector2 &coords) const noexcept
+auto Bounds::validate_coords(const Vector2 &coords) const noexcept -> CoordsValidation
{
if (static_cast<Bounds::Value>(coords.get_x()) >= _width)
{
@@ -50,7 +50,7 @@ CoordsValidation Bounds::validate_coords(const Vector2 &coords) const noexcept
return CoordsValidation::VALID;
}
-const Bounds &Bounds::operator*=(const Bounds &rhs) noexcept
+auto Bounds::operator*=(const Bounds &rhs) noexcept -> const Bounds &
{
_width *= rhs._width;
_height *= rhs._height;
@@ -58,7 +58,7 @@ const Bounds &Bounds::operator*=(const Bounds &rhs) noexcept
return *this;
}
-const Bounds &Bounds::operator+=(const Bounds &rhs) noexcept
+auto Bounds::operator+=(const Bounds &rhs) noexcept -> const Bounds &
{
_width += rhs._width;
_height += rhs._height;
@@ -66,7 +66,7 @@ const Bounds &Bounds::operator+=(const Bounds &rhs) noexcept
return *this;
}
-const Bounds &Bounds::operator-=(const Bounds &rhs) noexcept
+auto Bounds::operator-=(const Bounds &rhs) noexcept -> const Bounds &
{
_width -= rhs._width;
_height -= rhs._height;
@@ -74,7 +74,7 @@ const Bounds &Bounds::operator-=(const Bounds &rhs) noexcept
return *this;
}
-Bounds Bounds::operator-(const Bounds &rhs) const noexcept
+auto Bounds::operator-(const Bounds &rhs) const noexcept -> Bounds
{
auto new_bounds = Bounds(*this);