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

Unified Diff: chrome/browser/ui/tests/ui_gfx_image_unittest.mm

Issue 10933083: Remove deprecated gfx::Image::operator NSImage*(). (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Comments and merge Created 8 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 side-by-side diff with in-line comments
Download patch
Index: chrome/browser/ui/tests/ui_gfx_image_unittest.mm
diff --git a/chrome/browser/ui/tests/ui_gfx_image_unittest.mm b/chrome/browser/ui/tests/ui_gfx_image_unittest.mm
index 8f11203c7d82daee6a06ee5819630be4397ed26a..1e81579c0d4181d0235c3f97a96517c45fb2dfe9 100644
--- a/chrome/browser/ui/tests/ui_gfx_image_unittest.mm
+++ b/chrome/browser/ui/tests/ui_gfx_image_unittest.mm
@@ -18,9 +18,10 @@ class UiGfxImageTest : public CocoaTest {
TEST_F(UiGfxImageTest, CheckColor) {
gfx::Image image(gfx::test::CreateBitmap(25, 25));
- [image lockFocus];
+ NSImage* ns_image = image.ToNSImage();
+ [ns_image lockFocus];
NSColor* color = NSReadPixel(NSMakePoint(10, 10));
- [image unlockFocus];
+ [ns_image unlockFocus];
// SkBitmapToNSImage returns a bitmap in the calibrated color space (sRGB),
// while NSReadPixel returns a color in the device color space. Convert back
« no previous file with comments | « chrome/browser/ui/panels/panel_window_controller_cocoa.mm ('k') | content/browser/web_contents/web_drag_source_mac.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698