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

Side by Side Diff: chrome/browser/renderer_context_menu/render_view_context_menu_browsertest_util.h

Issue 178193005: Move render_view_context_menu.* related files out of tab_contents. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: context_menu->renderer_context_menu for disambiguation Created 6 years, 9 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
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_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_BROWSERTEST_UTIL_H_ 5 #ifndef CHROME_BROWSER_RENDERER_CONTEXT_MENU_RENDER_VIEW_CONTEXT_MENU_BROWSERTES T_UTIL_H_
6 #define CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_BROWSERTEST_UTIL_H_ 6 #define CHROME_BROWSER_RENDERER_CONTEXT_MENU_RENDER_VIEW_CONTEXT_MENU_BROWSERTES T_UTIL_H_
7 7
8 #include "base/basictypes.h" 8 #include "base/basictypes.h"
9 #include "content/public/browser/notification_observer.h" 9 #include "content/public/browser/notification_observer.h"
10 #include "content/public/browser/notification_registrar.h" 10 #include "content/public/browser/notification_registrar.h"
11 11
12 class RenderViewContextMenu; 12 class RenderViewContextMenu;
13 13
14 class ContextMenuNotificationObserver : public content::NotificationObserver { 14 class ContextMenuNotificationObserver : public content::NotificationObserver {
15 public: 15 public:
16 // Wait for a context menu to be shown, and then execute |command_to_execute|. 16 // Wait for a context menu to be shown, and then execute |command_to_execute|.
17 explicit ContextMenuNotificationObserver(int command_to_execute); 17 explicit ContextMenuNotificationObserver(int command_to_execute);
18 virtual ~ContextMenuNotificationObserver(); 18 virtual ~ContextMenuNotificationObserver();
19 19
20 private: 20 private:
21 virtual void Observe(int type, 21 virtual void Observe(int type,
22 const content::NotificationSource& source, 22 const content::NotificationSource& source,
23 const content::NotificationDetails& details) OVERRIDE; 23 const content::NotificationDetails& details) OVERRIDE;
24 24
25 void ExecuteCommand(RenderViewContextMenu* context_menu); 25 void ExecuteCommand(RenderViewContextMenu* context_menu);
26 26
27 content::NotificationRegistrar registrar_; 27 content::NotificationRegistrar registrar_;
28 int command_to_execute_; 28 int command_to_execute_;
29 29
30 DISALLOW_COPY_AND_ASSIGN(ContextMenuNotificationObserver); 30 DISALLOW_COPY_AND_ASSIGN(ContextMenuNotificationObserver);
31 }; 31 };
32 32
33 #endif // CHROME_BROWSER_TAB_CONTENTS_RENDER_VIEW_CONTEXT_MENU_BROWSERTEST_UTIL _H_ 33 #endif // CHROME_BROWSER_RENDERER_CONTEXT_MENU_RENDER_VIEW_CONTEXT_MENU_BROWSER TEST_UTIL_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698