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

Issue 250943008: Move enum MenuAnchorPosition to reduce deps on menu_item_view.h (Closed)

Created:
6 years, 7 months ago by tapted
Modified:
6 years, 7 months ago
Reviewers:
sky, pfeldman
CC:
chromium-reviews, asanka, sadrul, yusukes+watch_chromium.org, yukishiino+watch_chromium.org, markusheintz_, Ilya Sherman, extensions-reviews_chromium.org, benquan, jam, nona+watch_chromium.org, darin-cc_chromium.org, rouslan+autofillwatch_chromium.org, chromium-apps-reviews_chromium.org, penghuang+watch_chromium.org, kalyank, jochen+watch_chromium.org, chrome-apps-syd-reviews_chromium.org, tfarina, benjhayden+dwatch_chromium.org, Dane Wallinga, dyu1, estade+watch_chromium.org, James Su, ben+ash_chromium.org, mac-views-reviews_chromium.org
Visibility:
Public.

Description

Move enum MenuAnchorPosition to reduce deps on menu_item_view.h [Menu]AnchorPosition is used by the MenuRunner and other APIs. Having the enum nested in MenuItemView means that a lot of files must depend on menu_item_view.h, even if they are just using a MenuRunner created with a MenuModel (rather than a MenuItemView). This CL moves the MenuItemView::AnchorPosition enum to views::MenuAnchorPosition in menu_types.h. This allows the menu_item_view.h dependency to be removed from a lot of places (directly, and transitively by removing menu_item_view.h includes from any header files). BUG=366007, 363889 TBR=pfeldman@chromium.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=267471

Patch Set 1 #

Patch Set 2 : manual dependency pass #

Patch Set 3 : IWYU #

Patch Set 4 : fix win #

Total comments: 4

Patch Set 5 : rebase #

Patch Set 6 : Move to views, no views:: prefix within views #

Patch Set 7 : another rebase for r267046 conflict #

Total comments: 2

Patch Set 8 : paranoid rebase #

Patch Set 9 : fix indent #

Unified diffs Side-by-side diffs Delta from patch set Stats (+384 lines, -268 lines) Patch
M ash/root_window_controller.cc View 1 2 3 4 5 6 7 1 chunk +5 lines, -3 lines 0 comments Download
M ash/shelf/shelf_view.cc View 1 2 3 4 5 2 chunks +5 lines, -6 lines 0 comments Download
M ash/shell/window_type_launcher.cc View 1 2 3 4 5 6 7 1 chunk +9 lines, -6 lines 0 comments Download
M ash/shell_unittest.cc View 1 2 3 4 5 6 7 1 chunk +6 lines, -3 lines 0 comments Download
M chrome/browser/ui/views/apps/chrome_native_app_window_views.cc View 1 2 3 4 5 1 chunk +9 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/autofill/autofill_dialog_views.cc View 1 2 3 4 5 6 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_bar_view.h View 1 2 3 4 5 6 3 chunks +3 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_bar_view.cc View 1 2 3 4 5 6 3 chunks +3 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_context_menu.cc View 1 2 3 4 5 6 1 chunk +7 lines, -3 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_editor_view.cc View 1 2 3 4 5 6 1 chunk +9 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_menu_controller_views.h View 1 2 3 4 5 6 3 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_menu_controller_views.cc View 1 2 3 4 5 6 3 chunks +3 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/bookmarks/bookmark_menu_delegate_unittest.cc View 1 2 3 4 5 6 1 chunk +1 line, -0 lines 0 comments Download
M chrome/browser/ui/views/content_setting_bubble_contents.cc View 1 2 3 4 5 1 chunk +7 lines, -7 lines 0 comments Download
M chrome/browser/ui/views/download/download_shelf_context_menu_view.cc View 1 2 3 4 5 2 chunks +3 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/extensions/browser_action_overflow_menu_controller.cc View 1 2 3 4 5 2 chunks +7 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/extensions/media_galleries_dialog_views.cc View 1 2 3 4 5 1 chunk +5 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/extensions/media_galleries_scan_result_dialog_views.cc View 1 2 3 4 5 1 chunk +5 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/frame/browser_frame.cc View 1 2 3 4 5 6 7 1 chunk +9 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/frame/opaque_browser_frame_view.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/infobars/after_translate_infobar.cc View 1 2 3 4 5 6 7 2 chunks +8 lines, -6 lines 0 comments Download
M chrome/browser/ui/views/infobars/before_translate_infobar.cc View 1 2 3 4 5 6 7 2 chunks +6 lines, -5 lines 0 comments Download
M chrome/browser/ui/views/infobars/extension_infobar.cc View 1 2 3 4 5 2 chunks +2 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/infobars/infobar_view.h View 1 2 3 4 5 6 7 2 chunks +2 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/infobars/infobar_view.cc View 1 2 3 4 5 6 7 1 chunk +1 line, -1 line 0 comments Download
M chrome/browser/ui/views/location_bar/page_action_image_view.cc View 1 2 3 4 5 2 chunks +8 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/menu_model_adapter_test.cc View 1 2 3 4 5 1 chunk +6 lines, -7 lines 0 comments Download
M chrome/browser/ui/views/menu_test_base.cc View 1 2 3 4 5 1 chunk +6 lines, -7 lines 0 comments Download
M chrome/browser/ui/views/renderer_context_menu/render_view_context_menu_views.cc View 1 2 3 4 5 1 chunk +4 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/status_icons/status_icon_win.cc View 1 2 3 4 5 2 chunks +7 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/tabs/browser_tab_strip_controller.cc View 1 2 3 4 5 2 chunks +9 lines, -7 lines 0 comments Download
M chrome/browser/ui/views/task_manager_view.cc View 1 2 3 4 5 1 chunk +7 lines, -3 lines 0 comments Download
M chrome/browser/ui/views/toolbar/browser_action_view.cc View 1 2 3 4 5 2 chunks +7 lines, -2 lines 0 comments Download
M chrome/browser/ui/views/toolbar/toolbar_button.cc View 1 2 3 4 5 2 chunks +6 lines, -4 lines 0 comments Download
M chrome/browser/ui/views/toolbar/wrench_menu.cc View 1 2 3 4 5 6 1 chunk +6 lines, -3 lines 0 comments Download
M chrome/browser/ui/views/website_settings/permission_selector_view.cc View 1 2 3 4 5 1 chunk +8 lines, -7 lines 0 comments Download
M chrome/browser/ui/views/website_settings/permissions_bubble_view.cc View 1 2 3 4 5 1 chunk +8 lines, -7 lines 0 comments Download
M content/shell/browser/shell_views.cc View 1 2 3 4 5 6 7 8 2 chunks +8 lines, -6 lines 0 comments Download
M ui/app_list/views/app_list_item_view.cc View 1 2 3 4 5 2 chunks +8 lines, -6 lines 0 comments Download
M ui/app_list/views/app_list_menu_views.cc View 1 2 3 4 5 1 chunk +5 lines, -3 lines 0 comments Download
M ui/app_list/views/search_result_view.cc View 1 2 3 4 5 2 chunks +6 lines, -5 lines 0 comments Download
M ui/message_center/views/message_view_context_menu_controller.cc View 1 2 3 4 5 1 chunk +6 lines, -7 lines 0 comments Download
M ui/message_center/views/notifier_settings_view.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ui/views/controls/combobox/combobox.cc View 1 2 3 4 5 2 chunks +3 lines, -2 lines 0 comments Download
M ui/views/controls/combobox/combobox_unittest.cc View 1 2 3 4 5 1 chunk +1 line, -1 line 0 comments Download
M ui/views/controls/menu/menu_controller.h View 1 2 3 4 5 6 chunks +7 lines, -5 lines 0 comments Download
M ui/views/controls/menu/menu_controller.cc View 1 2 3 4 5 11 chunks +24 lines, -23 lines 0 comments Download
M ui/views/controls/menu/menu_delegate.h View 1 2 3 4 5 2 chunks +8 lines, -2 lines 0 comments Download
M ui/views/controls/menu/menu_delegate.cc View 1 2 3 4 5 2 chunks +4 lines, -2 lines 0 comments Download
M ui/views/controls/menu/menu_item_view.h View 1 2 3 4 5 3 chunks +2 lines, -16 lines 0 comments Download
M ui/views/controls/menu/menu_item_view.cc View 1 2 3 4 5 1 chunk +5 lines, -5 lines 0 comments Download
M ui/views/controls/menu/menu_message_pump_dispatcher_win.cc View 1 2 3 1 chunk +1 line, -0 lines 0 comments Download
M ui/views/controls/menu/menu_model_adapter.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M ui/views/controls/menu/menu_runner.h View 1 2 3 4 5 3 chunks +13 lines, -2 lines 0 comments Download
M ui/views/controls/menu/menu_runner.cc View 1 2 3 4 5 5 chunks +10 lines, -10 lines 0 comments Download
M ui/views/controls/menu/menu_runner_handler.h View 1 2 3 4 5 2 chunks +2 lines, -2 lines 0 comments Download
M ui/views/controls/menu/menu_scroll_view_container.h View 1 2 3 4 5 2 chunks +2 lines, -3 lines 0 comments Download
M ui/views/controls/menu/menu_scroll_view_container.cc View 1 2 3 4 5 1 chunk +6 lines, -7 lines 0 comments Download
A ui/views/controls/menu/menu_types.h View 1 2 3 4 5 1 chunk +26 lines, -0 lines 0 comments Download
M ui/views/controls/menu/submenu_view.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download
M ui/views/controls/scrollbar/base_scroll_bar.cc View 1 2 3 4 5 1 chunk +9 lines, -4 lines 0 comments Download
M ui/views/controls/textfield/textfield.cc View 1 2 3 4 5 6 2 chunks +6 lines, -3 lines 0 comments Download
M ui/views/examples/menu_example.cc View 1 2 3 4 5 1 chunk +8 lines, -4 lines 0 comments Download
M ui/views/examples/tree_view_example.cc View 1 2 3 4 5 1 chunk +7 lines, -3 lines 0 comments Download
M ui/views/views.gyp View 1 2 3 4 5 6 7 1 chunk +1 line, -0 lines 0 comments Download
M ui/views/widget/widget.cc View 1 2 1 chunk +1 line, -0 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
tapted
Hi sky could you please take a look? I kept dancing around this dependency, so ...
6 years, 7 months ago (2014-04-29 11:53:13 UTC) #1
sky
https://codereview.chromium.org/250943008/diff/100001/ui/base/ui_base_types.h File ui/base/ui_base_types.h (right): https://codereview.chromium.org/250943008/diff/100001/ui/base/ui_base_types.h#newcode60 ui/base/ui_base_types.h:60: enum MenuAnchorPosition { I'm fine with moving MenuAnchorPosition, but ...
6 years, 7 months ago (2014-04-29 15:30:56 UTC) #2
tapted
Thanks sky - PTAL. https://codereview.chromium.org/250943008/diff/100001/ui/base/ui_base_types.h File ui/base/ui_base_types.h (right): https://codereview.chromium.org/250943008/diff/100001/ui/base/ui_base_types.h#newcode60 ui/base/ui_base_types.h:60: enum MenuAnchorPosition { On 2014/04/29 ...
6 years, 7 months ago (2014-04-30 08:32:55 UTC) #3
sky
LGTM
6 years, 7 months ago (2014-04-30 17:03:43 UTC) #4
tapted
Thanks sky! +pfeldman TBR for refactoring change in content/shell/browser/shell_views.cc https://codereview.chromium.org/250943008/diff/200001/content/shell/browser/shell_views.cc File content/shell/browser/shell_views.cc (right): https://codereview.chromium.org/250943008/diff/200001/content/shell/browser/shell_views.cc#newcode197 content/shell/browser/shell_views.cc:197: ...
6 years, 7 months ago (2014-05-01 00:11:31 UTC) #5
tapted
The CQ bit was checked by tapted@chromium.org
6 years, 7 months ago (2014-05-01 00:11:48 UTC) #6
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tapted@chromium.org/250943008/240001
6 years, 7 months ago (2014-05-01 00:14:42 UTC) #7
commit-bot: I haz the power
The CQ bit was unchecked by commit-bot@chromium.org
6 years, 7 months ago (2014-05-01 01:43:59 UTC) #8
commit-bot: I haz the power
Try jobs failed on following builders: mac_chromium_rel on tryserver.chromium
6 years, 7 months ago (2014-05-01 01:44:00 UTC) #9
tapted
The CQ bit was checked by tapted@chromium.org
6 years, 7 months ago (2014-05-01 03:50:53 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tapted@chromium.org/250943008/240001
6 years, 7 months ago (2014-05-01 03:51:46 UTC) #11
commit-bot: I haz the power
6 years, 7 months ago (2014-05-01 07:50:44 UTC) #12
Message was sent while issue was closed.
Change committed as 267471

Powered by Google App Engine
This is Rietveld 408576698