| OLD | NEW |
| (Empty) |
| 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 | |
| 3 // found in the LICENSE file. | |
| 4 | |
| 5 #ifndef CHROME_BROWSER_GTK_BACK_FORWARD_MENU_MODEL_GTK_H_ | |
| 6 #define CHROME_BROWSER_GTK_BACK_FORWARD_MENU_MODEL_GTK_H_ | |
| 7 | |
| 8 #include <string> | |
| 9 | |
| 10 #include "base/basictypes.h" | |
| 11 | |
| 12 #include "chrome/browser/back_forward_menu_model.h" | |
| 13 #include "chrome/browser/gtk/menu_gtk.h" | |
| 14 | |
| 15 class BackForwardButtonGtk; | |
| 16 | |
| 17 // For the most part, this class simply passes calls through to | |
| 18 // the BackForwardMenuModel. | |
| 19 class BackForwardMenuModelGtk : public BackForwardMenuModel, | |
| 20 public MenuGtk::Delegate { | |
| 21 public: | |
| 22 BackForwardMenuModelGtk(Browser* browser, ModelType model_type, | |
| 23 BackForwardButtonGtk* button); | |
| 24 | |
| 25 // MenuGtk::Delegate | |
| 26 virtual int GetItemCount() const; | |
| 27 virtual bool IsItemSeparator(int menu_id) const; | |
| 28 virtual std::string GetLabel(int menu_id) const; | |
| 29 virtual bool HasIcon(int menu_id) const; | |
| 30 virtual const SkBitmap* GetIcon(int menu_id) const; | |
| 31 virtual bool IsCommandEnabled(int command_id) const; | |
| 32 virtual void ExecuteCommand(int command_id); | |
| 33 virtual void StoppedShowing(); | |
| 34 virtual bool AlwaysShowImages() const; | |
| 35 | |
| 36 private: | |
| 37 BackForwardButtonGtk* button_; | |
| 38 | |
| 39 DISALLOW_COPY_AND_ASSIGN(BackForwardMenuModelGtk); | |
| 40 }; | |
| 41 | |
| 42 #endif // CHROME_BROWSER_GTK_BACK_FORWARD_MENU_MODEL_GTK_H_ | |
| OLD | NEW |