From 205d4913718714a1165489bcbbc1b896f4fb4208 Mon Sep 17 00:00:00 2001 From: Brandon DeRosier Date: Thu, 1 Jun 2023 11:54:09 -0700 Subject: [PATCH] Fix lint in rectangle packer (flutter/engine#42489) --- .../src/flutter/impeller/typographer/rectangle_packer.cc | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/engine/src/flutter/impeller/typographer/rectangle_packer.cc b/engine/src/flutter/impeller/typographer/rectangle_packer.cc index bb8cba42b8..b80faa7d4e 100644 --- a/engine/src/flutter/impeller/typographer/rectangle_packer.cc +++ b/engine/src/flutter/impeller/typographer/rectangle_packer.cc @@ -22,7 +22,7 @@ class SkylineRectanglePacker final : public RectanglePacker { ~SkylineRectanglePacker() final {} void reset() final { - areaSoFar_ = 0; + area_so_far_ = 0; skyline_.clear(); skyline_.push_back(SkylineSegment{0, 0, this->width()}); } @@ -30,7 +30,7 @@ class SkylineRectanglePacker final : public RectanglePacker { bool addRect(int w, int h, IPoint16* loc) final; float percentFull() const final { - return areaSoFar_ / ((float)this->width() * this->height()); + return area_so_far_ / ((float)this->width() * this->height()); } private: @@ -42,7 +42,7 @@ class SkylineRectanglePacker final : public RectanglePacker { std::vector skyline_; - int32_t areaSoFar_; + int32_t area_so_far_; // Can a width x height rectangle fit in the free space represented by // the skyline segments >= 'skylineIndex'? If so, return true and fill in @@ -84,7 +84,7 @@ bool SkylineRectanglePacker::addRect(int width, int height, IPoint16* loc) { loc->x_ = bestX; loc->y_ = bestY; - areaSoFar_ += width * height; + area_so_far_ += width * height; return true; }