Win7/8 compiler warnings/errors fix for r9980
git-svn-id: http://skia.googlecode.com/svn/trunk@9991 2bbb7eff-a529-9590-31e7-b0007b416f81
diff --git a/gm/xfermodeimagefilter.cpp b/gm/xfermodeimagefilter.cpp
index e602c70..ca7b677 100644
--- a/gm/xfermodeimagefilter.cpp
+++ b/gm/xfermodeimagefilter.cpp
@@ -167,8 +167,10 @@
(mode, offsetBackground, offsetForeground)));
paint.setImageFilter(filter);
canvas->save();
- canvas->clipRect(SkRect::MakeXYWH(x, y,
- SkIntToScalar(fBitmap.width() + 4), SkIntToScalar(fBitmap.height() + 4)));
+ canvas->clipRect(SkRect::MakeXYWH(SkIntToScalar(x),
+ SkIntToScalar(y),
+ SkIntToScalar(fBitmap.width() + 4),
+ SkIntToScalar(fBitmap.height() + 4)));
canvas->drawPaint(paint);
canvas->restore();
x += fBitmap.width() + MARGIN;
@@ -181,8 +183,10 @@
filter.reset(SkNEW_ARGS(SkXfermodeImageFilter, (mode, offsetBackground, offsetForeground)));
paint.setImageFilter(filter);
canvas->save();
- canvas->clipRect(SkRect::MakeXYWH(x, y,
- SkIntToScalar(fBitmap.width() + 4), SkIntToScalar(fBitmap.height() + 4)));
+ canvas->clipRect(SkRect::MakeXYWH(SkIntToScalar(x),
+ SkIntToScalar(y),
+ SkIntToScalar(fBitmap.width() + 4),
+ SkIntToScalar(fBitmap.height() + 4)));
canvas->drawPaint(paint);
canvas->restore();
}
diff --git a/src/gpu/SkGpuDevice.cpp b/src/gpu/SkGpuDevice.cpp
index d9de0ca..3b0d143 100644
--- a/src/gpu/SkGpuDevice.cpp
+++ b/src/gpu/SkGpuDevice.cpp
@@ -1432,14 +1432,14 @@
}
fContext->drawRectToRect(grPaint,
- GrRect::MakeXYWH(SkIntToScalar(left),
- SkIntToScalar(top),
- SkIntToScalar(w),
- SkIntToScalar(h)),
- GrRect::MakeXYWH(offset.fX,
- offset.fY,
- SK_Scalar1 * w / texture->width(),
- SK_Scalar1 * h / texture->height()));
+ GrRect::MakeXYWH(SkIntToScalar(left),
+ SkIntToScalar(top),
+ SkIntToScalar(w),
+ SkIntToScalar(h)),
+ GrRect::MakeXYWH(SkIntToScalar(offset.fX),
+ SkIntToScalar(offset.fY),
+ SK_Scalar1 * w / texture->width(),
+ SK_Scalar1 * h / texture->height()));
}
void SkGpuDevice::drawBitmapRect(const SkDraw& draw, const SkBitmap& bitmap,