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

Unified Diff: chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm

Issue 151283006: Mac OS X: Show the Translate icon on Omnibox (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@issue-307352-translate-bubble-2
Patch Set: groby's review Created 6 years, 10 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
Index: chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
diff --git a/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm b/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
index 023442911e33bb7a21c26e776514320dee668f48..effa045c0423452598f9145db49b04bab5f1f250 100644
--- a/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
+++ b/chrome/browser/ui/cocoa/toolbar/toolbar_controller.mm
@@ -450,7 +450,11 @@ class NotificationBridge
}
- (void)setStarredState:(BOOL)isStarred {
- locationBarView_->SetStarred(isStarred ? true : false);
+ locationBarView_->SetStarred(isStarred);
+}
+
+- (void)setTranslateIconLit:(BOOL)on {
+ locationBarView_->SetTranslateIconLit(on);
}
- (void)zoomChangedForActiveTab:(BOOL)canShowBubble {
@@ -744,6 +748,10 @@ class NotificationBridge
return [self.view convertPoint:point toView:nil];
}
+- (NSPoint)translateBubblePoint {
+ return locationBarView_->GetTranslateBubblePoint();
+}
+
- (CGFloat)desiredHeightForCompression:(CGFloat)compressByHeight {
// With no toolbar, just ignore the compression.
if (!hasToolbar_)

Powered by Google App Engine
This is Rietveld 408576698