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

Unified Diff: src/ports/SkFontConfigInterface_direct_google3_factory.cpp

Issue 1471033002: Fix Google3 fonts. (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Rename back to SkFontConfigInterface_direct.h Created 5 years, 1 month 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 | « src/ports/SkFontConfigInterface_direct_google3.cpp ('k') | tools/BUILD.public.expected » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/ports/SkFontConfigInterface_direct_google3_factory.cpp
diff --git a/src/ports/SkFontConfigInterface_direct_google3_factory.cpp b/src/ports/SkFontConfigInterface_direct_google3_factory.cpp
new file mode 100644
index 0000000000000000000000000000000000000000..f0ac53fd8b5e62e176876690af99f8ca23b72d33
--- /dev/null
+++ b/src/ports/SkFontConfigInterface_direct_google3_factory.cpp
@@ -0,0 +1,20 @@
+/*
+ * Copyright 2009-2015 Google Inc.
+ *
+ * Use of this source code is governed by a BSD-style license that can be
+ * found in the LICENSE file.
+ */
+
+/* migrated from chrome/src/skia/ext/SkFontHost_fontconfig_direct.cpp */
+
+#include "SkFontConfigInterface_direct_google3.h"
+#include "SkMutex.h"
+
+SkFontConfigInterface* SkFontConfigInterface::GetSingletonDirectInterface(SkBaseMutex* mutex) {
+ SkAutoMutexAcquire ac(mutex);
+ static SkFontConfigInterfaceDirectGoogle3* singleton = nullptr;
+ if (singleton == nullptr) {
+ singleton = new SkFontConfigInterfaceDirectGoogle3;
+ }
+ return singleton;
+}
« no previous file with comments | « src/ports/SkFontConfigInterface_direct_google3.cpp ('k') | tools/BUILD.public.expected » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698