Index: chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_cell.mm |
diff --git a/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_cell.mm b/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_cell.mm |
index fc6fe0e81304c1c1ef2e318b5d60266b1333f0ec..8de2c8e1888fcbef59c78ca72ebb1b5ba33cfb58 100644 |
--- a/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_cell.mm |
+++ b/chrome/browser/ui/cocoa/location_bar/autocomplete_text_field_cell.mm |
@@ -15,7 +15,7 @@ |
#import "third_party/mozilla/NSPasteboard+Utils.h" |
#import "ui/base/cocoa/appkit_utils.h" |
#import "ui/base/cocoa/nsview_additions.h" |
-#include "ui/gfx/scoped_ns_graphics_context_save_gstate_mac.h" |
+#include "ui/base/cocoa/scoped_cg_context_smooth_fonts.h" |
using extensions::FeatureSwitch; |
@@ -346,16 +346,8 @@ size_t CalculatePositionsInFrame( |
// |-textFrameForFrame:|. |
// Superclass draws text portion WRT original |cellFrame|. |
- // Even though -isOpaque is NO due to rounded corners, we know that the text |
- // will be drawn on top of an opaque area, therefore it is safe to enable |
- // font smoothing. |
- { |
- gfx::ScopedNSGraphicsContextSaveGState scopedGState; |
- NSGraphicsContext* context = [NSGraphicsContext currentContext]; |
- CGContextRef cgContext = static_cast<CGContextRef>([context graphicsPort]); |
- CGContextSetShouldSmoothFonts(cgContext, true); |
- [super drawInteriorWithFrame:cellFrame inView:controlView]; |
- } |
+ ui::ScopedCGContextSmoothFonts lcd_smoothing; |
Robert Sesek
2015/09/25 23:00:52
naming: font_smoothing? (and throughout)
tapted
2015/09/28 04:30:38
Done (fontSmoothing because I had by objc/C++ styl
|
+ [super drawInteriorWithFrame:cellFrame inView:controlView]; |
} |
- (LocationBarDecoration*)decorationForEvent:(NSEvent*)theEvent |