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

Unified Diff: core/fxge/dib/fx_dib_main.cpp

Issue 2382443004: Replace a few more std::unique_ptr.reset() with WrapUnique assignments. (Closed)
Patch Set: Created 4 years, 3 months 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/dib/fx_dib_engine.cpp ('k') | core/fxge/dib/fx_dib_transform.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fxge/dib/fx_dib_main.cpp
diff --git a/core/fxge/dib/fx_dib_main.cpp b/core/fxge/dib/fx_dib_main.cpp
index 16106fec7fa011496190fe33a39c2b363e7065af..9575e6aac42811961979b1487bf567d66cbd1d36 100644
--- a/core/fxge/dib/fx_dib_main.cpp
+++ b/core/fxge/dib/fx_dib_main.cpp
@@ -1461,7 +1461,7 @@ CFX_DIBitmap* CFX_DIBSource::FlipImage(FX_BOOL bXFlip, FX_BOOL bYFlip) const {
CFX_DIBExtractor::CFX_DIBExtractor(const CFX_DIBSource* pSrc) {
if (pSrc->GetBuffer()) {
- m_pBitmap.reset(new CFX_DIBitmap);
+ m_pBitmap = WrapUnique(new CFX_DIBitmap);
if (!m_pBitmap->Create(pSrc->GetWidth(), pSrc->GetHeight(),
pSrc->GetFormat(), pSrc->GetBuffer())) {
m_pBitmap.reset();
@@ -1567,9 +1567,9 @@ FX_BOOL CFX_ImageRenderer::Start(CFX_DIBitmap* pDevice,
m_Composer.Compose(pDevice, pClipRgn, bitmap_alpha, mask_color, m_ClipBox,
TRUE, m_Matrix.c > 0, m_Matrix.b < 0, m_bRgbByteOrder,
alpha_flag, pIccTransform, m_BlendType);
- m_Stretcher.reset(new CFX_ImageStretcher(&m_Composer, pSource,
- dest_height, dest_width,
- bitmap_clip, dib_flags));
+ m_Stretcher = WrapUnique(new CFX_ImageStretcher(&m_Composer, pSource,
+ dest_height, dest_width,
+ bitmap_clip, dib_flags));
if (!m_Stretcher->Start())
return FALSE;
@@ -1600,7 +1600,7 @@ FX_BOOL CFX_ImageRenderer::Start(CFX_DIBitmap* pDevice,
FALSE, FALSE, FALSE, m_bRgbByteOrder, alpha_flag,
pIccTransform, m_BlendType);
m_Status = 1;
- m_Stretcher.reset(new CFX_ImageStretcher(
+ m_Stretcher = WrapUnique(new CFX_ImageStretcher(
&m_Composer, pSource, dest_width, dest_height, bitmap_clip, dib_flags));
return m_Stretcher->Start();
}
@@ -1680,7 +1680,7 @@ FX_BOOL CFX_BitmapStorer::SetInfo(int width,
int height,
FXDIB_Format src_format,
uint32_t* pSrcPalette) {
- m_pBitmap.reset(new CFX_DIBitmap);
+ m_pBitmap = WrapUnique(new CFX_DIBitmap);
if (!m_pBitmap->Create(width, height, src_format)) {
m_pBitmap.reset();
return FALSE;
« no previous file with comments | « core/fxge/dib/fx_dib_engine.cpp ('k') | core/fxge/dib/fx_dib_transform.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698