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

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

Issue 19918002: Refactor [FramedBrowserWindow drawWindowThemeInDirtyRect:] to use themeImagePositionForAlignment: (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebased Created 7 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/browser_window_controller.h » ('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
diff --git a/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm b/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm
index 3a7cef4f69c9900f5119438f702ab46415997656..c530a23e78b5514d4cda4eb23529ffc149cd3aa5 100644
--- a/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm
+++ b/chrome/browser/ui/cocoa/bookmarks/bookmark_bar_toolbar_view.mm
@@ -46,9 +46,10 @@ const CGFloat kBorderRadius = 3.0;
[controller_ isAnimatingFromState:BookmarkBar::DETACHED]) {
[self drawAsDetachedBubble];
} else {
- NSPoint phase = [[self window]
- themePatternPhaseForAlignment:THEME_PATTERN_ALIGN_WITH_TAB_STRIP];
- [[NSGraphicsContext currentContext] cr_setPatternPhase:phase forView:self];
+ NSPoint position = [[self window]
+ themeImagePositionForAlignment:THEME_IMAGE_ALIGN_WITH_TAB_STRIP];
+ [[NSGraphicsContext currentContext] cr_setPatternPhase:position
+ forView:self];
[self drawBackgroundWithOpaque:YES];
}
}
@@ -77,9 +78,9 @@ const CGFloat kBorderRadius = 3.0;
CGContextRef cgContext = static_cast<CGContextRef>([context graphicsPort]);
CGContextSetAlpha(cgContext, 1 - morph);
CGContextBeginTransparencyLayer(cgContext, NULL);
- NSPoint phase = [[self window]
- themePatternPhaseForAlignment:THEME_PATTERN_ALIGN_WITH_TAB_STRIP];
- [context cr_setPatternPhase:phase forView:self];
+ NSPoint position = [[self window]
+ themeImagePositionForAlignment:THEME_IMAGE_ALIGN_WITH_TAB_STRIP];
+ [context cr_setPatternPhase:position forView:self];
[self drawBackgroundWithOpaque:YES];
CGContextEndTransparencyLayer(cgContext);
}
« no previous file with comments | « no previous file | chrome/browser/ui/cocoa/browser_window_controller.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698