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

Unified Diff: chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm

Issue 6927058: Merge 83125 - Add and use gfx::ScopedNSGraphicsContextState (ui/gfx/scoped_ns_graphics_context_st... (Closed) Base URL: svn://svn.chromium.org/chrome/branches/742/src/
Patch Set: Created 9 years, 8 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/cocoa/location_bar/instant_opt_in_view.mm
===================================================================
--- chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm (revision 84308)
+++ chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm (working copy)
@@ -1,4 +1,4 @@
-// Copyright (c) 2010 The Chromium Authors. All rights reserved.
+// Copyright (c) 2011 The Chromium Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
@@ -6,6 +6,7 @@
#import "chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.h"
#import "third_party/GTM/AppKit/GTMNSBezierPath+RoundRect.h"
+#include "ui/gfx/scoped_ns_graphics_context_save_gstate_mac.h"
namespace {
// How to round off the popup's corners. Goal is to match star and go
@@ -30,7 +31,7 @@
bottomLeftCornerRadius:kPopupRoundingRadius
bottomRightCornerRadius:kPopupRoundingRadius];
- [NSGraphicsContext saveGraphicsState];
+ gfx::ScopedNSGraphicsContextSaveGState scopedGState;
[path addClip];
// Background is white.
@@ -47,8 +48,6 @@
[[NSColor lightGrayColor] set];
NSRectFill(NSMakeRect(minX, lineY, maxX - minX, 1));
-
- [NSGraphicsContext restoreGraphicsState];
}
@end
« no previous file with comments | « chrome/browser/ui/cocoa/location_bar/content_setting_decoration.mm ('k') | chrome/browser/ui/cocoa/styled_text_field_cell.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698