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

Side by Side Diff: chrome/browser/ui/cocoa/browser_window_cocoa.mm

Issue 420713003: Translate: Don't show 'Translated' bubble when the user dismisses the bubble (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: cocoa Created 6 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 unified diff | Download patch
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "chrome/browser/ui/cocoa/browser_window_cocoa.h" 5 #include "chrome/browser/ui/cocoa/browser_window_cocoa.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/mac/mac_util.h" 10 #include "base/mac/mac_util.h"
(...skipping 477 matching lines...) Expand 10 before | Expand all | Expand 10 after
488 488
489 void BrowserWindowCocoa::ShowBookmarkAppBubble( 489 void BrowserWindowCocoa::ShowBookmarkAppBubble(
490 const WebApplicationInfo& web_app_info, 490 const WebApplicationInfo& web_app_info,
491 const std::string& extension_id) { 491 const std::string& extension_id) {
492 NOTIMPLEMENTED(); 492 NOTIMPLEMENTED();
493 } 493 }
494 494
495 void BrowserWindowCocoa::ShowTranslateBubble( 495 void BrowserWindowCocoa::ShowTranslateBubble(
496 content::WebContents* contents, 496 content::WebContents* contents,
497 translate::TranslateStep step, 497 translate::TranslateStep step,
498 translate::TranslateErrors::Type error_type) { 498 translate::TranslateErrors::Type error_type,
499 bool is_user_gesture) {
499 ChromeTranslateClient* chrome_translate_client = 500 ChromeTranslateClient* chrome_translate_client =
500 ChromeTranslateClient::FromWebContents(contents); 501 ChromeTranslateClient::FromWebContents(contents);
501 translate::LanguageState& language_state = 502 translate::LanguageState& language_state =
502 chrome_translate_client->GetLanguageState(); 503 chrome_translate_client->GetLanguageState();
503 language_state.SetTranslateEnabled(true); 504 language_state.SetTranslateEnabled(true);
504 505
505 [controller_ showTranslateBubbleForWebContents:contents 506 [controller_ showTranslateBubbleForWebContents:contents
506 step:step 507 step:step
507 errorType:error_type]; 508 errorType:error_type];
508 } 509 }
(...skipping 250 matching lines...) Expand 10 before | Expand all | Expand 10 after
759 760
760 void BrowserWindowCocoa::ShowPageActionPopup( 761 void BrowserWindowCocoa::ShowPageActionPopup(
761 const extensions::Extension* extension) { 762 const extensions::Extension* extension) {
762 [cocoa_controller() activatePageAction:extension->id()]; 763 [cocoa_controller() activatePageAction:extension->id()];
763 } 764 }
764 765
765 void BrowserWindowCocoa::ShowBrowserActionPopup( 766 void BrowserWindowCocoa::ShowBrowserActionPopup(
766 const extensions::Extension* extension) { 767 const extensions::Extension* extension) {
767 [cocoa_controller() activateBrowserAction:extension->id()]; 768 [cocoa_controller() activateBrowserAction:extension->id()];
768 } 769 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/browser_window_cocoa.h ('k') | chrome/browser/ui/translate/translate_bubble_factory.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698