Bug 1401069 - Part 5. Remove two local variables since we do not need them.
dcWidth and dcHieght are used only once, we do not need to define a local
variable for any of them.
MozReview-Commit-ID: Fw5rHqtUPQN
--- a/widget/windows/PDFViaEMFPrintHelper.cpp
+++ b/widget/windows/PDFViaEMFPrintHelper.cpp
@@ -82,19 +82,18 @@ PDFViaEMFPrintHelper::RenderPageToDC(HDC
if (aPageWidth <= 0 || aPageHeight <= 0) {
return false;
}
FPDF_PAGE pdfPage = mPDFiumEngine->LoadPage(mPDFDoc, aPageIndex);
NS_ENSURE_TRUE(pdfPage, false);
- int dcWidth = ::GetDeviceCaps(aDC, HORZRES);
- int dcHeight = ::GetDeviceCaps(aDC, VERTRES);
- float scaleFactor = ComputeScaleFactor(dcWidth,dcHeight,
+ float scaleFactor = ComputeScaleFactor(::GetDeviceCaps(aDC, HORZRES),
+ ::GetDeviceCaps(aDC, VERTRES),
aPageWidth, aPageHeight);
int savedState = ::SaveDC(aDC);
::SetGraphicsMode(aDC, GM_ADVANCED);
XFORM xform = { 0 };
xform.eM11 = xform.eM22 = scaleFactor;
::ModifyWorldTransform(aDC, &xform, MWT_LEFTMULTIPLY);
// The caller wanted all drawing to happen within the bounds specified.