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

Unified Diff: chrome/browser/translate/translate_infobar_delegate2.h

Issue 2815013: Refactor the translate infobars on mac to match the new windows code. (Closed)
Patch Set: Move unittest stuff back to class files Created 10 years, 6 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 | « chrome/browser/cocoa/translate_infobar.mm ('k') | chrome/browser/translate/translate_infobar_delegate2.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/translate/translate_infobar_delegate2.h
diff --git a/chrome/browser/translate/translate_infobar_delegate2.h b/chrome/browser/translate/translate_infobar_delegate2.h
index 2129776d28b9122433848e354e78a900cc9f32c3..bb535ad3b254936c10c159a855963776918d175e 100644
--- a/chrome/browser/translate/translate_infobar_delegate2.h
+++ b/chrome/browser/translate/translate_infobar_delegate2.h
@@ -2,8 +2,8 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-#ifndef CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H
-#define CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H
+#ifndef CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H_
+#define CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H_
#include <string>
#include <vector>
@@ -129,21 +129,22 @@ class TranslateInfoBarDelegate2 : public InfoBarDelegate {
static void GetAfterTranslateStrings(std::vector<string16>* strings,
bool* swap_languages);
- private:
- typedef std::pair<std::string, string16> LanguageNamePair;
-
- // Gets the host of the page being translated, or an empty string if no URL is
- // associated with the current page.
- std::string GetPageHost();
-
+ protected:
+ // For testing.
TranslateInfoBarDelegate2(Type infobar_type,
TranslateErrors::Type error,
TabContents* tab_contents,
const std::string& original_language,
const std::string& target_language);
-
Type type_;
+ private:
+ typedef std::pair<std::string, string16> LanguageNamePair;
+
+ // Gets the host of the page being translated, or an empty string if no URL is
+ // associated with the current page.
+ std::string GetPageHost();
+
// The type of fading animation if any that should be used when showing this
// infobar.
BackgroundAnimationType background_animation_;
@@ -174,5 +175,5 @@ class TranslateInfoBarDelegate2 : public InfoBarDelegate {
DISALLOW_COPY_AND_ASSIGN(TranslateInfoBarDelegate2);
};
-#endif // CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H
+#endif // CHROME_BROWSER_TRANSLATE_TRANSLATE_INFOBAR_DELEGATE2_H_
« no previous file with comments | « chrome/browser/cocoa/translate_infobar.mm ('k') | chrome/browser/translate/translate_infobar_delegate2.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698