Bug 1930725 - Clean up a bit nsDeviceContext. r=layout-reviewers,TYLin

Differential Revision: https://phabricator.services.mozilla.com/D228703
This commit is contained in:
Emilio Cobos Álvarez
2024-11-13 11:04:01 +00:00
parent 82060ef30e
commit d3fa60ccdb
8 changed files with 34 additions and 91 deletions

View File

@@ -5080,8 +5080,7 @@ already_AddRefed<SourceSurface> PresShell::PaintRangePaintInfo(
// if the image should not be resized, scale must be 1
float scale = 1.0;
nsRect maxSize;
pc->DeviceContext()->GetClientRect(maxSize);
const nsRect maxSize = pc->DeviceContext()->GetClientRect();
// check if the image should be resized
bool resize = !!(aFlags & RenderImageFlags::AutoScale);