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

Unified Diff: src/utils/SkDumpCanvas.cpp

Issue 27192003: Start cleaning up 64bit Win warnings (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: revertedGrBytesPerPixel to returning a size_t Created 7 years, 2 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
« no previous file with comments | « src/utils/SkDeferredCanvas.cpp ('k') | src/utils/win/SkWGL_win.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/utils/SkDumpCanvas.cpp
===================================================================
--- src/utils/SkDumpCanvas.cpp (revision 11758)
+++ src/utils/SkDumpCanvas.cpp (working copy)
@@ -142,15 +142,15 @@
// FIXME: this code appears to be untested - and probably unused - and probably wrong
switch (enc) {
case SkPaint::kUTF8_TextEncoding:
- str->appendf("\"%.*s\"%s", SkMax32(byteLen, 32), (const char*) text,
+ str->appendf("\"%.*s\"%s", SkTMax<size_t>(byteLen, 32), (const char*) text,
byteLen > 32 ? "..." : "");
break;
case SkPaint::kUTF16_TextEncoding:
- str->appendf("\"%.*ls\"%s", SkMax32(byteLen, 32), (const wchar_t*) text,
+ str->appendf("\"%.*ls\"%s", SkTMax<size_t>(byteLen, 32), (const wchar_t*) text,
byteLen > 64 ? "..." : "");
break;
case SkPaint::kUTF32_TextEncoding:
- str->appendf("\"%.*ls\"%s", SkMax32(byteLen, 32), (const wchar_t*) text,
+ str->appendf("\"%.*ls\"%s", SkTMax<size_t>(byteLen, 32), (const wchar_t*) text,
byteLen > 128 ? "..." : "");
break;
case SkPaint::kGlyphID_TextEncoding:
@@ -444,7 +444,7 @@
void SkDumpCanvas::drawData(const void* data, size_t length) {
// this->dump(kDrawData_Verb, NULL, "drawData(%d)", length);
this->dump(kDrawData_Verb, NULL, "drawData(%d) %.*s", length,
- SkMin32(length, 64), data);
+ SkTMin<size_t>(length, 64), data);
}
void SkDumpCanvas::beginCommentGroup(const char* description) {
« no previous file with comments | « src/utils/SkDeferredCanvas.cpp ('k') | src/utils/win/SkWGL_win.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698