OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 #ifndef CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ | 5 #ifndef CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ |
6 #define CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ | 6 #define CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ |
7 | 7 |
8 #include "app/menus/simple_menu_model.h" | 8 #include "app/menus/simple_menu_model.h" |
9 | 9 |
10 class TranslateInfoBarDelegate; | 10 class TranslateInfoBarDelegate; |
| 11 class TranslateInfoBarDelegate2; |
| 12 class String16; |
11 | 13 |
12 // A menu model that builds the contents of the options menu in the translate | 14 // A menu model that builds the contents of the options menu in the translate |
13 // infobar. This menu has only one level (no submenus). | 15 // infobar. This menu has only one level (no submenus). |
14 class OptionsMenuModel : public menus::SimpleMenuModel { | 16 class OptionsMenuModel : public menus::SimpleMenuModel { |
15 public: | 17 public: |
16 explicit OptionsMenuModel(menus::SimpleMenuModel::Delegate* menu_delegate, | 18 // TODO(jcivelli): remove this constructor once we have migrated to the new |
17 TranslateInfoBarDelegate* translate_delegate); | 19 // translate infobars. |
| 20 OptionsMenuModel(menus::SimpleMenuModel::Delegate* menu_delegate, |
| 21 TranslateInfoBarDelegate* translate_delegate); |
| 22 OptionsMenuModel(menus::SimpleMenuModel::Delegate* menu_delegate, |
| 23 TranslateInfoBarDelegate2* translate_delegate); |
18 virtual ~OptionsMenuModel(); | 24 virtual ~OptionsMenuModel(); |
19 | 25 |
20 private: | 26 private: |
| 27 void Init(const string16& original_language, const string16& target_language); |
| 28 |
21 DISALLOW_COPY_AND_ASSIGN(OptionsMenuModel); | 29 DISALLOW_COPY_AND_ASSIGN(OptionsMenuModel); |
22 }; | 30 }; |
23 | 31 |
24 #endif // CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ | 32 #endif // CHROME_BROWSER_TRANSLATE_OPTIONS_MENU_MODEL_H_ |
OLD | NEW |