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

Unified Diff: ui/views/controls/textfield/textfield_controller.h

Issue 9250016: Aura: Add "Edit Search Engines" option to the aura omnibox context menu. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 11 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: ui/views/controls/textfield/textfield_controller.h
diff --git a/ui/views/controls/textfield/textfield_controller.h b/ui/views/controls/textfield/textfield_controller.h
index a831cbf4066ec257fd6f2584f51a30f4ccb46ac9..9e7d2f33e8b69c48d319000cbf09d713fac09c2b 100644
--- a/ui/views/controls/textfield/textfield_controller.h
+++ b/ui/views/controls/textfield/textfield_controller.h
@@ -11,6 +11,7 @@
namespace ui {
class OSExchangeData;
+class SimpleMenuModel;
} // namespace ui
namespace views {
@@ -49,6 +50,15 @@ class VIEWS_EXPORT TextfieldController {
// chance to modify the drag data.
virtual void OnWriteDragData(ui::OSExchangeData* data) {}
+ // Gives the controller a chance to modify the context menu contents.
+ virtual void UpdateContextMenu(ui::SimpleMenuModel* menu_contents) {}
+
+ // Returns true is the |command_id| should be enabled in the context menu.
oshima 2012/01/18 22:24:24 /is/if/
varunjain 2012/01/18 23:31:36 Done.
+ virtual bool IsCommandIdEnabled(int command_id) const { return false; }
+
+ // Execute context menu command specified by |command_id|.
+ virtual void ExecuteCommand(int command_id) {}
+
protected:
virtual ~TextfieldController() {}
};

Powered by Google App Engine
This is Rietveld 408576698