summaryrefslogtreecommitdiff
path: root/core/fxge/android/fx_android_imp.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'core/fxge/android/fx_android_imp.cpp')
-rw-r--r--core/fxge/android/fx_android_imp.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/core/fxge/android/fx_android_imp.cpp b/core/fxge/android/fx_android_imp.cpp
index bbaa2ba27a..08fdea3d89 100644
--- a/core/fxge/android/fx_android_imp.cpp
+++ b/core/fxge/android/fx_android_imp.cpp
@@ -8,6 +8,9 @@
#if _FX_OS_ == _FX_ANDROID_
+#include <memory>
+#include <utility>
+
#include "core/fxge/android/fpf_skiamodule.h"
#include "core/fxge/android/fx_android_font.h"
#include "core/fxge/include/fx_ge.h"
@@ -19,9 +22,9 @@ void CFX_GEModule::InitPlatform() {
CFPF_SkiaFontMgr* pFontMgr = pDeviceModule->GetFontMgr();
if (pFontMgr) {
- CFX_AndroidFontInfo* pFontInfo = new CFX_AndroidFontInfo;
+ std::unique_ptr<CFX_AndroidFontInfo> pFontInfo(new CFX_AndroidFontInfo);
pFontInfo->Init(pFontMgr);
- m_pFontMgr->SetSystemFontInfo(pFontInfo);
+ m_pFontMgr->SetSystemFontInfo(std::move(pFontInfo));
}
m_pPlatformData = pDeviceModule;
}