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

Unified Diff: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm

Issue 7541043: Revert 95611 - Always call the class methods to save/restore contexts. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 9 years, 4 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
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/download/download_item_cell.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm
===================================================================
--- chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm (revision 95630)
+++ chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm (working copy)
@@ -56,7 +56,8 @@
if (!themeProvider)
return;
- gfx::ScopedNSGraphicsContextSaveGState scopedGState;
+ NSGraphicsContext* context = [NSGraphicsContext currentContext];
+ gfx::ScopedNSGraphicsContextSaveGState scopedGState(context);
// Draw the background.
{
@@ -102,9 +103,8 @@
// Fade in/out the background.
{
- gfx::ScopedNSGraphicsContextSaveGState bgScopedState;
+ gfx::ScopedNSGraphicsContextSaveGState bgScopedState(context);
[border setClip];
- NSGraphicsContext* context = [NSGraphicsContext currentContext];
CGContextRef cgContext = (CGContextRef)[context graphicsPort];
CGContextBeginTransparencyLayer(cgContext, NULL);
CGContextSetAlpha(cgContext, 1 - morph);
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/download/download_item_cell.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698