| Log Message: |
cc: Remove all usage of GetArea() from production code in cc
Consolidate the calls to turn gfx::Size into a number of bytes onto
the cc::SharedBitmap class. The class offers the following methods:
1. Get a size_t bytes and bool saying if you overflowed or not.
2. Get a size_t bytes and crash if you overflow.
3. Get a size_t bytes and don't check for overflow.
4. Tell me if the gfx::Size would overflow to create the size_t bytes.
These were the use cases I found in the existing code, plus the
addition of case 2. A few places that were finding the size_t bytes
without looking for overflow (case 3), from a previously-unchecked
gfx::Size, were changed to crash on overflow instead (case 2).
R=jbauman@chromium.org, piman@chromium.org
BUG=348332
Review URL: https://codereview.chromium.org/221523003
|