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

Side by Side Diff: chrome/browser/ui/ash/launcher/launcher_context_menu.h

Issue 10984034: Revert 158691 - Give platform apps control over launcher right-click context menu. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 2 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 unified diff | Download patch | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_ 5 #ifndef CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_
6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_ 6 #define CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_
7 7
8 #include "ash/launcher/launcher_alignment_menu.h" 8 #include "ash/launcher/launcher_alignment_menu.h"
9 #include "ash/launcher/launcher_types.h" 9 #include "ash/launcher/launcher_types.h"
10 #include "base/basictypes.h" 10 #include "base/basictypes.h"
11 #include "base/memory/scoped_ptr.h"
12 #include "ui/base/models/simple_menu_model.h" 11 #include "ui/base/models/simple_menu_model.h"
13 12
14 class ChromeLauncherController; 13 class ChromeLauncherController;
15 14
16 namespace extensions {
17 class ContextMenuMatcher;
18 }
19
20 // Context menu shown for a launcher item. 15 // Context menu shown for a launcher item.
21 class LauncherContextMenu : public ui::SimpleMenuModel, 16 class LauncherContextMenu : public ui::SimpleMenuModel,
22 public ui::SimpleMenuModel::Delegate { 17 public ui::SimpleMenuModel::Delegate {
23 public: 18 public:
24 // |item| is NULL if the context menu is for the launcher (the user right 19 // |item| is NULL if the context menu is for the launcher (the user right
25 // |clicked on an area with no icons). 20 // |clicked on an area with no icons).
26 LauncherContextMenu(ChromeLauncherController* controller, 21 LauncherContextMenu(ChromeLauncherController* controller,
27 const ash::LauncherItem* item); 22 const ash::LauncherItem* item);
28 virtual ~LauncherContextMenu(); 23 virtual ~LauncherContextMenu();
29 24
(...skipping 26 matching lines...) Expand all
56 // Does |item_| represent a valid item? See description of constructor for 51 // Does |item_| represent a valid item? See description of constructor for
57 // details on why it may not be valid. 52 // details on why it may not be valid.
58 bool is_valid_item() const { return item_.id != 0; } 53 bool is_valid_item() const { return item_.id != 0; }
59 54
60 ChromeLauncherController* controller_; 55 ChromeLauncherController* controller_;
61 56
62 ash::LauncherItem item_; 57 ash::LauncherItem item_;
63 58
64 ash::LauncherAlignmentMenu alignment_menu_; 59 ash::LauncherAlignmentMenu alignment_menu_;
65 60
66 scoped_ptr<extensions::ContextMenuMatcher> extension_items_;
67
68 DISALLOW_COPY_AND_ASSIGN(LauncherContextMenu); 61 DISALLOW_COPY_AND_ASSIGN(LauncherContextMenu);
69 }; 62 };
70 63
71 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_ 64 #endif // CHROME_BROWSER_UI_ASH_LAUNCHER_LAUNCHER_CONTEXT_MENU_H_
OLDNEW
« no previous file with comments | « chrome/browser/ui/ash/launcher/chrome_launcher_controller.cc ('k') | chrome/browser/ui/ash/launcher/launcher_context_menu.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698