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

Side by Side Diff: chrome/browser/bookmarks/bookmark_manager_extension_api.h

Issue 10694085: Refactor extension event distribution to use Values instead of JSON strings. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Build fix. Created 8 years, 5 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_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_ 5 #ifndef CHROME_BROWSER_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_
6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_ 6 #define CHROME_BROWSER_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_
7 #pragma once 7 #pragma once
8 8
9 #include "chrome/browser/bookmarks/bookmark_extension_api.h" 9 #include "chrome/browser/bookmarks/bookmark_extension_api.h"
10 #include "chrome/browser/bookmarks/bookmark_node_data.h" 10 #include "chrome/browser/bookmarks/bookmark_node_data.h"
(...skipping 23 matching lines...) Expand all
34 34
35 // The bookmark drag and drop data. This gets set after a drop was done on 35 // The bookmark drag and drop data. This gets set after a drop was done on
36 // the page. This returns NULL if no data is available. 36 // the page. This returns NULL if no data is available.
37 const BookmarkNodeData* GetBookmarkNodeData(); 37 const BookmarkNodeData* GetBookmarkNodeData();
38 38
39 // Clears the drag and drop data. 39 // Clears the drag and drop data.
40 void ClearBookmarkNodeData(); 40 void ClearBookmarkNodeData();
41 41
42 private: 42 private:
43 // Helper to actually dispatch an event to extension listeners. 43 // Helper to actually dispatch an event to extension listeners.
44 void DispatchEvent(const char* event_name, const base::ListValue* args); 44 void DispatchEvent(const char* event_name, base::ListValue* args);
45 45
46 void DispatchDragEvent(const BookmarkNodeData& data, const char* event_name); 46 void DispatchDragEvent(const BookmarkNodeData& data, const char* event_name);
47 47
48 Profile* profile_; 48 Profile* profile_;
49 TabContents* tab_; 49 TabContents* tab_;
50 BookmarkNodeData bookmark_drag_data_; 50 BookmarkNodeData bookmark_drag_data_;
51 51
52 DISALLOW_COPY_AND_ASSIGN(BookmarkManagerExtensionEventRouter); 52 DISALLOW_COPY_AND_ASSIGN(BookmarkManagerExtensionEventRouter);
53 }; 53 };
54 54
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
187 187
188 protected: 188 protected:
189 virtual ~CanOpenNewWindowsBookmarkFunction() {} 189 virtual ~CanOpenNewWindowsBookmarkFunction() {}
190 190
191 // ExtensionFunction: 191 // ExtensionFunction:
192 virtual bool RunImpl() OVERRIDE; 192 virtual bool RunImpl() OVERRIDE;
193 }; 193 };
194 194
195 195
196 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_ 196 #endif // CHROME_BROWSER_BOOKMARKS_BOOKMARK_MANAGER_EXTENSION_API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698