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

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

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: . 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/translate/translate_bubble_controller.h
diff --git a/chrome/browser/ui/cocoa/translate/translate_bubble_controller.h b/chrome/browser/ui/cocoa/translate/translate_bubble_controller.h
new file mode 100644
index 0000000000000000000000000000000000000000..704824d395db38bb6a93b79ce75f4d8a5298e13b
--- /dev/null
+++ b/chrome/browser/ui/cocoa/translate/translate_bubble_controller.h
@@ -0,0 +1,35 @@
+// Copyright 2014 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#import <Cocoa/Cocoa.h>
+
+#include "base/memory/scoped_ptr.h"
+#import "chrome/browser/ui/cocoa/base_bubble_controller.h"
+#include "chrome/browser/ui/translate/translate_bubble_model.h"
+#include "components/translate/core/common/translate_errors.h"
+
+@class BrowserWindowController;
+
+namespace content {
+class WebContents;
+}
+
+@interface TranslateBubbleController : BaseBubbleController {
Nico 2014/02/05 06:07:18 Needs a class comment
hajimehoshi 2014/02/05 11:08:03 Done.
+ @private
+ content::WebContents* webContents_;
+ scoped_ptr<TranslateBubbleModel> model_;
+
+ // Whether the translation is acutually executed.
Nico 2014/02/05 06:07:18 typo "acutually"
hajimehoshi 2014/02/05 11:08:03 Done.
+ BOOL translateExecuted_;
+}
+
+// TODO: WebContents Observer?
+
++ (void)showBubbleWithBrowserWindowController:(BrowserWindowController*)controller
+ webContents:(content::WebContents*)webContents
+ viewState:(TranslateBubbleModel::ViewState
+ )viewState
+ errorType:(TranslateErrors::Type)errorType;
Nico 2014/02/05 06:07:18 `git cl format` produces + (void) showBubbleW
hajimehoshi 2014/02/05 11:08:03 Done.
+
+@end

Powered by Google App Engine
This is Rietveld 408576698