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

Side by Side Diff: src/device/xps/SkXPSDevice.cpp

Issue 66593004: Fix Windows build after the SkAutoFoo guard CL. (Closed) Base URL: https://skia.googlecode.com/svn/trunk
Patch Set: Created 7 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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 2011 Google Inc. 2 * Copyright 2011 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 #ifndef UNICODE 8 #ifndef UNICODE
9 #define UNICODE 9 #define UNICODE
10 #endif 10 #endif
(...skipping 2076 matching lines...) Expand 10 before | Expand all | Expand 10 after
2087 bool isTTC = (data && 2087 bool isTTC = (data &&
2088 fontData->getLength() >= sizeof(SkTTCFHeader) && 2088 fontData->getLength() >= sizeof(SkTTCFHeader) &&
2089 ((SkTTCFHeader*)data)->ttcTag == SkTTCFHeader::TAG); 2089 ((SkTTCFHeader*)data)->ttcTag == SkTTCFHeader::TAG);
2090 2090
2091 TypefaceUse& newTypefaceUse = this->fTypefaces.push_back(); 2091 TypefaceUse& newTypefaceUse = this->fTypefaces.push_back();
2092 newTypefaceUse.typefaceId = typefaceID; 2092 newTypefaceUse.typefaceId = typefaceID;
2093 newTypefaceUse.ttcIndex = isTTC ? ttcIndex : -1; 2093 newTypefaceUse.ttcIndex = isTTC ? ttcIndex : -1;
2094 newTypefaceUse.fontData = fontData; 2094 newTypefaceUse.fontData = fontData;
2095 newTypefaceUse.xpsFont = xpsFontResource.release(); 2095 newTypefaceUse.xpsFont = xpsFontResource.release();
2096 2096
2097 SkAutoGlyphCache agc = SkAutoGlyphCache(paint, NULL, &SkMatrix::I()); 2097 SkAutoGlyphCache agc(paint, NULL, &SkMatrix::I());
2098 SkGlyphCache* glyphCache = agc.getCache(); 2098 SkGlyphCache* glyphCache = agc.getCache();
2099 unsigned int glyphCount = glyphCache->getGlyphCount(); 2099 unsigned int glyphCount = glyphCache->getGlyphCount();
2100 newTypefaceUse.glyphsUsed = new SkBitSet(glyphCount); 2100 newTypefaceUse.glyphsUsed = new SkBitSet(glyphCount);
2101 2101
2102 *typefaceUse = &newTypefaceUse; 2102 *typefaceUse = &newTypefaceUse;
2103 return S_OK; 2103 return S_OK;
2104 } 2104 }
2105 2105
2106 HRESULT SkXPSDevice::AddGlyphs(const SkDraw& d, 2106 HRESULT SkXPSDevice::AddGlyphs(const SkDraw& d,
2107 IXpsOMObjectFactory* xpsFactory, 2107 IXpsOMObjectFactory* xpsFactory,
(...skipping 344 matching lines...) Expand 10 before | Expand all | Expand 10 after
2452 IID_PPV_ARGS(&this->fXpsFactory)), 2452 IID_PPV_ARGS(&this->fXpsFactory)),
2453 "Could not create factory for layer."); 2453 "Could not create factory for layer.");
2454 2454
2455 HRVM(this->fXpsFactory->CreateCanvas(&this->fCurrentXpsCanvas), 2455 HRVM(this->fXpsFactory->CreateCanvas(&this->fCurrentXpsCanvas),
2456 "Could not create canvas for layer."); 2456 "Could not create canvas for layer.");
2457 } 2457 }
2458 2458
2459 bool SkXPSDevice::allowImageFilter(SkImageFilter*) { 2459 bool SkXPSDevice::allowImageFilter(SkImageFilter*) {
2460 return false; 2460 return false;
2461 } 2461 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698