Index: chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm |
diff --git a/chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm b/chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm |
index 06ca79d0eb0b4900a16641b106d61ef4d159403e..bb1631fd59aabf84bdbb398e36f15dc1c9259166 100644 |
--- a/chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm |
+++ b/chrome/browser/ui/cocoa/location_bar/instant_opt_in_view.mm |
@@ -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 @@ const CGFloat kHorizontalLineInset = 2; |
bottomLeftCornerRadius:kPopupRoundingRadius |
bottomRightCornerRadius:kPopupRoundingRadius]; |
- [NSGraphicsContext saveGraphicsState]; |
+ gfx::ScopedNSGraphicsContextSaveGState scopedGState; |
[path addClip]; |
// Background is white. |
@@ -47,8 +48,6 @@ const CGFloat kHorizontalLineInset = 2; |
[[NSColor lightGrayColor] set]; |
NSRectFill(NSMakeRect(minX, lineY, maxX - minX, 1)); |
- |
- [NSGraphicsContext restoreGraphicsState]; |
} |
@end |