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

Unified Diff: third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp

Issue 2717123003: RemoteFontFaceSource should keep FontCustomPlatformData over FontResource revalidation (Closed)
Patch Set: test description Created 3 years, 10 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
Index: third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp
diff --git a/third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp b/third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp
index 77b8fa5ec765cddbd0cc82d243fd8eee7fcc2046..d600bff9cc4121392284e1f6006e09abb269c790 100644
--- a/third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp
+++ b/third_party/WebKit/Source/platform/fonts/FontCustomPlatformData.cpp
@@ -41,7 +41,6 @@
#include "third_party/skia/include/core/SkStream.h"
#include "third_party/skia/include/core/SkTypeface.h"
#include "wtf/PtrUtil.h"
-#include <memory>
namespace blink {
@@ -98,7 +97,7 @@ FontPlatformData FontCustomPlatformData::fontPlatformData(
italic && !m_baseTypeface->isItalic(), orientation);
}
-std::unique_ptr<FontCustomPlatformData> FontCustomPlatformData::create(
+PassRefPtr<FontCustomPlatformData> FontCustomPlatformData::create(
SharedBuffer* buffer,
String& otsParseMessage) {
DCHECK(buffer);
@@ -108,7 +107,7 @@ std::unique_ptr<FontCustomPlatformData> FontCustomPlatformData::create(
otsParseMessage = decoder.getErrorString();
return nullptr;
}
- return WTF::wrapUnique(
+ return adoptRef(
new FontCustomPlatformData(std::move(typeface), decoder.decodedSize()));
}

Powered by Google App Engine
This is Rietveld 408576698