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

Unified Diff: chrome/browser/ui/cocoa/translate/translate_bubble_controller.mm

Issue 2511043002: [Mac] Omnibox icons active states (Closed)
Patch Set: Cleaned up Created 4 years, 1 month 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/translate/translate_bubble_controller.mm
diff --git a/chrome/browser/ui/cocoa/translate/translate_bubble_controller.mm b/chrome/browser/ui/cocoa/translate/translate_bubble_controller.mm
index 069db96cc24367f69fb912bb1b3dc4f8f3084a93..27a42786ed3e564e81fbba2a6eb9ad2b0e44393c 100644
--- a/chrome/browser/ui/cocoa/translate/translate_bubble_controller.mm
+++ b/chrome/browser/ui/cocoa/translate/translate_bubble_controller.mm
@@ -212,13 +212,19 @@ const CGFloat kContentWidth = kWindowWidth - 2 * kFramePadding;
- (void)showWindow:(id)sender {
BrowserWindowController* controller = [[self parentWindow] windowController];
- NSPoint anchorPoint = [[controller toolbarController] translateBubblePoint];
+ NSPoint anchorPoint = [[controller toolbarController]
+ bubblePointForDecoration:[self decorationForBubble]];
anchorPoint =
ui::ConvertPointFromWindowToScreen([self parentWindow], anchorPoint);
[self setAnchorPoint:anchorPoint];
[super showWindow:sender];
}
+- (LocationBarDecoration*)decorationForBubble {
+ BrowserWindowController* controller = [[self parentWindow] windowController];
+ return [[controller toolbarController] translateDecoration];
+}
+
- (void)switchView:(TranslateBubbleModel::ViewState)viewState {
if (model_->GetViewState() == viewState)
return;

Powered by Google App Engine
This is Rietveld 408576698