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

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

Issue 544233002: "NULL !=" = NULL (Closed) Base URL: https://skia.googlesource.com/skia.git@are
Patch Set: rebase Created 6 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 unified diff | Download patch
« no previous file with comments | « src/ports/SkFontHost_linux.cpp ('k') | src/ports/SkFontMgr_android.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 /* 2 /*
3 * Copyright 2006 The Android Open Source Project 3 * Copyright 2006 The Android Open Source Project
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 #include <vector> 9 #include <vector>
10 #ifdef SK_BUILD_FOR_MAC 10 #ifdef SK_BUILD_FOR_MAC
(...skipping 879 matching lines...) Expand 10 before | Expand all | Expand 10 after
890 fFBoundingBoxesGlyphOffset = fGlyphCount; // fallback for all fonts 890 fFBoundingBoxesGlyphOffset = fGlyphCount; // fallback for all fonts
891 AutoCGTable<SkOTTableHorizontalHeader> hheaTable(fCGFont); 891 AutoCGTable<SkOTTableHorizontalHeader> hheaTable(fCGFont);
892 if (hheaTable.fData) { 892 if (hheaTable.fData) {
893 fFBoundingBoxesGlyphOffset = SkEndian_SwapBE16(hheaTable->numberOfHMetri cs); 893 fFBoundingBoxesGlyphOffset = SkEndian_SwapBE16(hheaTable->numberOfHMetri cs);
894 } 894 }
895 return fFBoundingBoxesGlyphOffset; 895 return fFBoundingBoxesGlyphOffset;
896 } 896 }
897 897
898 bool SkScalerContext_Mac::generateBBoxes() { 898 bool SkScalerContext_Mac::generateBBoxes() {
899 if (fGeneratedFBoundingBoxes) { 899 if (fGeneratedFBoundingBoxes) {
900 return NULL != fFBoundingBoxes.get(); 900 return SkToBool(fFBoundingBoxes.get());
901 } 901 }
902 fGeneratedFBoundingBoxes = true; 902 fGeneratedFBoundingBoxes = true;
903 903
904 AutoCGTable<SkOTTableHead> headTable(fCGFont); 904 AutoCGTable<SkOTTableHead> headTable(fCGFont);
905 if (!headTable.fData) { 905 if (!headTable.fData) {
906 return false; 906 return false;
907 } 907 }
908 908
909 AutoCGTable<SkOTTableIndexToLocation> locaTable(fCGFont); 909 AutoCGTable<SkOTTableIndexToLocation> locaTable(fCGFont);
910 if (!locaTable.fData) { 910 if (!locaTable.fData) {
(...skipping 1393 matching lines...) Expand 10 before | Expand all | Expand 10 after
2304 return create_typeface(NULL, familyName, (SkTypeface::Style)styleBits); 2304 return create_typeface(NULL, familyName, (SkTypeface::Style)styleBits);
2305 } 2305 }
2306 }; 2306 };
2307 2307
2308 /////////////////////////////////////////////////////////////////////////////// 2308 ///////////////////////////////////////////////////////////////////////////////
2309 2309
2310 SkFontMgr* SkFontMgr::Factory() { 2310 SkFontMgr* SkFontMgr::Factory() {
2311 return SkNEW(SkFontMgr_Mac); 2311 return SkNEW(SkFontMgr_Mac);
2312 } 2312 }
2313 #endif 2313 #endif
OLDNEW
« no previous file with comments | « src/ports/SkFontHost_linux.cpp ('k') | src/ports/SkFontMgr_android.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698