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

Side by Side Diff: ash/shell_context_menu.h

Issue 9960024: Remove "set wallpaper..." option in system context menu when guest logged in (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: IsLoggedInAsGuest => CanOpenSetWallpaperPage Created 8 years, 8 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
« no previous file with comments | « ash/shell.cc ('k') | ash/shell_context_menu.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
(Empty)
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
3 // found in the LICENSE file.
4
5 #ifndef ASH_SHELL_CONTEXT_MENU_H_
6 #define ASH_SHELL_CONTEXT_MENU_H_
7 #pragma once
8
9 #include "base/memory/scoped_ptr.h"
10 #include "ui/base/models/simple_menu_model.h"
11
12 namespace gfx {
13 class Point;
14 class Size;
15 }
16
17 namespace views {
18 class MenuRunner;
19 class Widget;
20 }
21
22 namespace ash {
23 namespace internal {
24
25 class ShellContextMenu : public ui::SimpleMenuModel::Delegate {
26 public:
27 ShellContextMenu();
28 virtual ~ShellContextMenu();
29
30 // Shows the context menu when right click on background.
31 void ShowMenu(views::Widget* widget, const gfx::Point& location);
32
33 // ui::SimpleMenuModel::Delegate overrides:
34 virtual bool IsCommandIdChecked(int command_id) const OVERRIDE;
35 virtual bool IsCommandIdEnabled(int command_id) const OVERRIDE;
36 virtual void ExecuteCommand(int command_id) OVERRIDE;
37 virtual bool GetAcceleratorForCommandId(
38 int command_id,
39 ui::Accelerator* accelerator) OVERRIDE;
40
41 private:
42 enum MenuItem {
43 MENU_CHANGE_WALLPAPER,
44 };
45
46 scoped_ptr<views::MenuRunner> menu_runner_;
47
48 DISALLOW_COPY_AND_ASSIGN(ShellContextMenu);
49 };
50
51 } // namespace internal
52 } // namespace ash
53
54 #endif // ASH_SHELL_CONTEXT_MENU_H_
OLDNEW
« no previous file with comments | « ash/shell.cc ('k') | ash/shell_context_menu.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698