Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(162)

Unified Diff: core/fxge/win32/fx_win32_print.cpp

Issue 2572293002: More unique_ptr returns from DIB methods. (Closed)
Patch Set: win build Created 4 years ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fxge/win32/fx_win32_device.cpp ('k') | xfa/fxgraphics/cfx_graphics.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fxge/win32/fx_win32_print.cpp
diff --git a/core/fxge/win32/fx_win32_print.cpp b/core/fxge/win32/fx_win32_print.cpp
index 5a1a01a4187369a167c914f8315507c040e9031b..2ff072f6a59d22cc4563caf054ae5f31cf6cc5c1 100644
--- a/core/fxge/win32/fx_win32_print.cpp
+++ b/core/fxge/win32/fx_win32_print.cpp
@@ -108,8 +108,8 @@ bool CGdiPrinterDriver::StretchDIBits(const CFX_DIBSource* pSource,
return false;
if (dest_width < 0 || dest_height < 0) {
- std::unique_ptr<CFX_DIBitmap> pFlipped(
- pSource->FlipImage(dest_width < 0, dest_height < 0));
+ std::unique_ptr<CFX_DIBitmap> pFlipped =
+ pSource->FlipImage(dest_width < 0, dest_height < 0);
if (!pFlipped)
return false;
@@ -135,8 +135,8 @@ bool CGdiPrinterDriver::StretchDIBits(const CFX_DIBSource* pSource,
return false;
if (dest_width < 0 || dest_height < 0) {
- std::unique_ptr<CFX_DIBitmap> pFlipped(
- pSource->FlipImage(dest_width < 0, dest_height < 0));
+ std::unique_ptr<CFX_DIBitmap> pFlipped =
+ pSource->FlipImage(dest_width < 0, dest_height < 0);
if (!pFlipped)
return false;
@@ -184,8 +184,8 @@ bool CGdiPrinterDriver::StartDIBits(const CFX_DIBSource* pSource,
if (FXSYS_fabs(pMatrix->a) >= 0.5f || FXSYS_fabs(pMatrix->d) >= 0.5f)
return false;
- std::unique_ptr<CFX_DIBitmap> pTransformed(
- pSource->SwapXY(pMatrix->c > 0, pMatrix->b < 0));
+ std::unique_ptr<CFX_DIBitmap> pTransformed =
+ pSource->SwapXY(pMatrix->c > 0, pMatrix->b < 0);
if (!pTransformed)
return false;
« no previous file with comments | « core/fxge/win32/fx_win32_device.cpp ('k') | xfa/fxgraphics/cfx_graphics.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698