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

Unified Diff: ui/views/controls/menu/menu_runner.h

Issue 59383003: Add the button style for combobox (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: sky's review (5) Created 7 years 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/menu/menu_runner.h
diff --git a/ui/views/controls/menu/menu_runner.h b/ui/views/controls/menu/menu_runner.h
index 277ffd5334a41005ec75d84762cc579fadb4c6d5..d4c091fceb018c054363b46f0e113561149b736d 100644
--- a/ui/views/controls/menu/menu_runner.h
+++ b/ui/views/controls/menu/menu_runner.h
@@ -18,6 +18,7 @@ namespace views {
class MenuButton;
class MenuModelAdapter;
+class MenuRunnerCore;
class Widget;
namespace internal {
@@ -111,11 +112,20 @@ class VIEWS_EXPORT MenuRunner {
// Returns the time from the event which closed the menu - or 0.
base::TimeDelta closing_event_time() const;
+ // Sets an implementation of RunMenuAt. This is intended to be used at test.
+ void set_runner_core(MenuRunnerCore* runner_core) {
sky 2013/12/09 14:54:04 Make this private and only settable by way of a te
hajimehoshi 2013/12/10 06:04:25 Done.
+ runner_core_ = runner_core;
+ }
+
private:
scoped_ptr<MenuModelAdapter> menu_model_adapter_;
internal::MenuRunnerImpl* holder_;
+ // An implementation of RunMenuAt. This is usually NULL and ignored. If this
+ // is not NULL, this implementation will be used.
+ MenuRunnerCore* runner_core_;
+
scoped_ptr<internal::DisplayChangeListener> display_change_listener_;
DISALLOW_COPY_AND_ASSIGN(MenuRunner);

Powered by Google App Engine
This is Rietveld 408576698