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

Side by Side Diff: chrome/browser/ui/webui/ntp/bookmarks_handler.h

Issue 7610014: [ntp4] Bookmarks page implementation, first-pass. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Final review tweaks, rebase. Created 9 years, 4 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) 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 #ifndef CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_ 5 #ifndef CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_
6 #define CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_ 6 #define CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_
7 #pragma once 7 #pragma once
8 8
9 #include "content/browser/webui/web_ui.h" 9 #include "content/browser/webui/web_ui.h"
10 #include "content/common/notification_observer.h" 10 #include "content/common/notification_observer.h"
11 11
12 class PrefService;
13 class Profile;
14
12 // The handler for Javascript messages related to the "bookmarks" view. 15 // The handler for Javascript messages related to the "bookmarks" view.
13 class BookmarksHandler : public WebUIMessageHandler, 16 class BookmarksHandler : public WebUIMessageHandler,
14 public NotificationObserver { 17 public NotificationObserver {
15 public: 18 public:
16 explicit BookmarksHandler(); 19 explicit BookmarksHandler();
17 virtual ~BookmarksHandler(); 20 virtual ~BookmarksHandler();
18 21
19 // WebUIMessageHandler implementation. 22 // WebUIMessageHandler implementation.
20 virtual void RegisterMessages() OVERRIDE; 23 virtual void RegisterMessages() OVERRIDE;
21 24
22 // NotificationObserver 25 // NotificationObserver
23 virtual void Observe(int type, 26 virtual void Observe(int type,
24 const NotificationSource& source, 27 const NotificationSource& source,
25 const NotificationDetails& details) OVERRIDE; 28 const NotificationDetails& details) OVERRIDE;
26 29
30 // Callback for the "getBookmarksData" message.
31 void HandleGetBookmarksData(const base::ListValue* args);
32
33 // Register NTP preferences.
34 static void RegisterUserPrefs(PrefService* prefs);
35
27 private: 36 private:
28 DISALLOW_COPY_AND_ASSIGN(BookmarksHandler); 37 DISALLOW_COPY_AND_ASSIGN(BookmarksHandler);
29 }; 38 };
30 39
31 #endif // CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_ 40 #endif // CHROME_BROWSER_UI_WEBUI_NTP_BOOKMARKS_HANDLER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698