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

Side by Side Diff: chrome/browser/ui/views/extensions/browser_action_overflow_menu_controller.cc

Issue 8477004: Have content/ create and destroy its own threads. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: More IWYU, missing link-time dependency for Chrome Frame. Created 9 years, 1 month 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 #include "chrome/browser/ui/views/extensions/browser_action_overflow_menu_contro ller.h" 5 #include "chrome/browser/ui/views/extensions/browser_action_overflow_menu_contro ller.h"
6 6
7 #include "base/message_loop.h"
7 #include "base/utf_string_conversions.h" 8 #include "base/utf_string_conversions.h"
8 #include "chrome/browser/extensions/extension_context_menu_model.h" 9 #include "chrome/browser/extensions/extension_context_menu_model.h"
9 #include "chrome/browser/profiles/profile.h" 10 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/ui/browser_list.h" 11 #include "chrome/browser/ui/browser_list.h"
11 #include "chrome/browser/ui/views/browser_actions_container.h" 12 #include "chrome/browser/ui/views/browser_actions_container.h"
12 #include "chrome/browser/ui/views/extensions/browser_action_drag_data.h" 13 #include "chrome/browser/ui/views/extensions/browser_action_drag_data.h"
13 #include "chrome/common/extensions/extension.h" 14 #include "chrome/common/extensions/extension.h"
14 #include "chrome/common/extensions/extension_action.h" 15 #include "chrome/common/extensions/extension_action.h"
15 #include "ui/gfx/canvas_skia.h" 16 #include "ui/gfx/canvas_skia.h"
16 #include "views/controls/menu/menu_item_view.h" 17 #include "views/controls/menu/menu_item_view.h"
(...skipping 195 matching lines...) Expand 10 before | Expand all | Expand 10 after
212 213
213 BrowserActionView* BrowserActionOverflowMenuController::ViewForId( 214 BrowserActionView* BrowserActionOverflowMenuController::ViewForId(
214 int id, size_t* index) { 215 int id, size_t* index) {
215 // The index of the view being dragged (GetCommand gives a 1-based index into 216 // The index of the view being dragged (GetCommand gives a 1-based index into
216 // the overflow menu). 217 // the overflow menu).
217 size_t view_index = owner_->VisibleBrowserActions() + id - 1; 218 size_t view_index = owner_->VisibleBrowserActions() + id - 1;
218 if (index) 219 if (index)
219 *index = view_index; 220 *index = view_index;
220 return owner_->GetBrowserActionViewAt(view_index); 221 return owner_->GetBrowserActionViewAt(view_index);
221 } 222 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698