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

Side by Side Diff: src/views/win/SkOSWindow_win.cpp

Issue 12536008: Enable init'ed but unused var warning on windows for closer parity with mac/linux warnings. (Closed) Base URL: http://skia.googlecode.com/svn/trunk/
Patch Set: Created 7 years, 9 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 | Annotate | Revision Log
OLDNEW
1 1
2 /* 2 /*
3 * Copyright 2011 Google Inc. 3 * Copyright 2011 Google Inc.
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 #include "SkTypes.h" 8 #include "SkTypes.h"
9 9
10 #if defined(SK_BUILD_FOR_WIN) 10 #if defined(SK_BUILD_FOR_WIN)
(...skipping 184 matching lines...) Expand 10 before | Expand all | Expand 10 after
195 // Do the SetDIBitsToDevice. 195 // Do the SetDIBitsToDevice.
196 // 196 //
197 // TODO(wjmaclean): 197 // TODO(wjmaclean):
198 // Fix this call to handle SkBitmaps that have rowBytes != width, 198 // Fix this call to handle SkBitmaps that have rowBytes != width,
199 // i.e. may have padding at the end of lines. The SkASSERT below 199 // i.e. may have padding at the end of lines. The SkASSERT below
200 // may be ignored by builds, and the only obviously safe option 200 // may be ignored by builds, and the only obviously safe option
201 // seems to be to copy the bitmap to a temporary (contiguous) 201 // seems to be to copy the bitmap to a temporary (contiguous)
202 // buffer before passing to SetDIBitsToDevice(). 202 // buffer before passing to SetDIBitsToDevice().
203 SkASSERT(bitmap.width() * bitmap.bytesPerPixel() == bitmap.rowBytes()); 203 SkASSERT(bitmap.width() * bitmap.bytesPerPixel() == bitmap.rowBytes());
204 bitmap.lockPixels(); 204 bitmap.lockPixels();
205 int iRet = SetDIBitsToDevice(hdc, 205 SetDIBitsToDevice(hdc,
reed1 2013/03/21 13:14:24 can we say (void)SetDIBitsToDevice to sorta docu
bsalomon 2013/03/21 13:45:29 Done.
206 0, 0, 206 0, 0,
207 bitmap.width(), bitmap.height(), 207 bitmap.width(), bitmap.height(),
208 0, 0, 208 0, 0,
209 0, bitmap.height(), 209 0, bitmap.height(),
210 bitmap.getPixels(), 210 bitmap.getPixels(),
211 &bmi, 211 &bmi,
212 DIB_RGB_COLORS); 212 DIB_RGB_COLORS);
213 bitmap.unlockPixels(); 213 bitmap.unlockPixels();
214 } 214 }
215 } 215 }
(...skipping 386 matching lines...) Expand 10 before | Expand all | Expand 10 after
602 break; 602 break;
603 #endif // SK_ANGLE 603 #endif // SK_ANGLE
604 #endif // SK_SUPPORT_GPU 604 #endif // SK_SUPPORT_GPU
605 default: 605 default:
606 SkASSERT(false); 606 SkASSERT(false);
607 break; 607 break;
608 } 608 }
609 } 609 }
610 610
611 #endif 611 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698