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

Side by Side Diff: src/ports/SkFontConfigInterface_direct.cpp

Issue 1214603003: Revert of Remove SkThread.h, include SkMutex.h or SkAtomics.h as appropriate. (Closed) Base URL: https://skia.googlesource.com/skia@master
Patch Set: Created 5 years, 5 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 unified diff | Download patch
« no previous file with comments | « src/pathops/SkPathOpsDebug.cpp ('k') | src/ports/SkFontHost_FreeType.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright 2009 Google Inc. 2 * Copyright 2009 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 /* migrated from chrome/src/skia/ext/SkFontHost_fontconfig_direct.cpp */ 8 /* migrated from chrome/src/skia/ext/SkFontHost_fontconfig_direct.cpp */
9 9
10 #include <unistd.h> 10 #include <unistd.h>
11 #include <fcntl.h> 11 #include <fcntl.h>
12 12
13 #include <fontconfig/fontconfig.h> 13 #include <fontconfig/fontconfig.h>
14 14
15 #include "SkBuffer.h" 15 #include "SkBuffer.h"
16 #include "SkFontConfigInterface.h" 16 #include "SkFontConfigInterface.h"
17 #include "SkLazyPtr.h" 17 #include "SkLazyPtr.h"
18 #include "SkMutex.h"
19 #include "SkStream.h" 18 #include "SkStream.h"
20 #include "SkString.h" 19 #include "SkString.h"
21 20
22 size_t SkFontConfigInterface::FontIdentity::writeToMemory(void* addr) const { 21 size_t SkFontConfigInterface::FontIdentity::writeToMemory(void* addr) const {
23 size_t size = sizeof(fID) + sizeof(fTTCIndex); 22 size_t size = sizeof(fID) + sizeof(fTTCIndex);
24 size += sizeof(int32_t) + sizeof(int32_t) + sizeof(uint8_t); // weight, widt h, italic 23 size += sizeof(int32_t) + sizeof(int32_t) + sizeof(uint8_t); // weight, widt h, italic
25 size += sizeof(int32_t) + fString.size(); // store length+data 24 size += sizeof(int32_t) + fString.size(); // store length+data
26 if (addr) { 25 if (addr) {
27 SkWBuffer buffer(addr, size); 26 SkWBuffer buffer(addr, size);
28 27
(...skipping 699 matching lines...) Expand 10 before | Expand all | Expand 10 after
728 *trimmedMatches.append() = match[i]; 727 *trimmedMatches.append() = match[i];
729 } 728 }
730 } 729 }
731 730
732 SkFontStyleSet_FC* sset = SkNEW_ARGS(SkFontStyleSet_FC, 731 SkFontStyleSet_FC* sset = SkNEW_ARGS(SkFontStyleSet_FC,
733 (trimmedMatches.begin(), 732 (trimmedMatches.begin(),
734 trimmedMatches.count())); 733 trimmedMatches.count()));
735 #endif 734 #endif
736 return false; 735 return false;
737 } 736 }
OLDNEW
« no previous file with comments | « src/pathops/SkPathOpsDebug.cpp ('k') | src/ports/SkFontHost_FreeType.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698