OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 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 CHROME_BROWSER_UI_WEBUI_USER_ACTIONS_USER_ACTIONS_UI_HANDLER_H_ | |
6 #define CHROME_BROWSER_UI_WEBUI_USER_ACTIONS_USER_ACTIONS_UI_HANDLER_H_ | |
7 | |
8 #include "content/public/browser/notification_observer.h" | |
9 #include "content/public/browser/notification_registrar.h" | |
10 #include "content/public/browser/web_ui_message_handler.h" | |
11 | |
12 // UI Handler for chrome://user-actions/ | |
13 // It listens to user action notifications and passes those notifications | |
14 // into the Javascript to update the page. | |
15 class UserActionsUIHandler : public content::NotificationObserver, | |
16 public content::WebUIMessageHandler { | |
17 public: | |
18 // Sets up this class as an observer for NOTIFICATION_USER_ACTION. | |
Evan Stade
2012/11/20 23:09:57
remove comment
Mark P
2012/11/20 23:45:41
Done.
| |
19 explicit UserActionsUIHandler(); | |
Evan Stade
2012/11/20 23:09:57
no explicit
Mark P
2012/11/20 23:45:41
Done.
| |
20 | |
Evan Stade
2012/11/20 23:09:57
remove newline
Mark P
2012/11/20 23:45:41
Done.
| |
21 virtual ~UserActionsUIHandler(); | |
22 | |
23 // Listens for user action notifications and passes the message to | |
24 // observeUserAction in user_actions.js. | |
Evan Stade
2012/11/20 23:09:57
comment should be "NotificationObserver implementa
Mark P
2012/11/20 23:45:41
Removed entirely. Putting it in the implementatio
| |
25 virtual void Observe(int type, | |
26 const content::NotificationSource& source, | |
27 const content::NotificationDetails& details); | |
28 | |
29 protected: | |
30 // Does nothing for now. | |
31 virtual void RegisterMessages(); | |
Evan Stade
2012/11/20 23:09:57
OVERRIDE; comment should be "WebUIMessageHandler i
Mark P
2012/11/20 23:45:41
Done.
| |
32 | |
33 private: | |
34 content::NotificationRegistrar registrar_; | |
35 | |
36 DISALLOW_COPY_AND_ASSIGN(UserActionsUIHandler); | |
37 }; | |
38 | |
39 #endif // CHROME_BROWSER_UI_WEBUI_USER_ACTIONS_USER_ACTIONS_UI_HANDLER_H_ | |
OLD | NEW |