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

Side by Side Diff: chrome/browser/extensions/api/bookmarks/bookmarks_api.h

Issue 660513002: BookmarksFunction sending response after execution in all cases (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 2 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_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_ 5 #ifndef CHROME_BROWSER_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_
6 #define CHROME_BROWSER_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_ 6 #define CHROME_BROWSER_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_
7 7
8 #include <list> 8 #include <list>
9 #include <string> 9 #include <string>
10 #include <vector> 10 #include <vector>
(...skipping 148 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 // is NULL, or a managed node, or the root node. In these cases the node 159 // is NULL, or a managed node, or the root node. In these cases the node
160 // can't be edited, can't have new child nodes appended, and its direct 160 // can't be edited, can't have new child nodes appended, and its direct
161 // children can't be moved or reordered. 161 // children can't be moved or reordered.
162 bool CanBeModified(const BookmarkNode* node); 162 bool CanBeModified(const BookmarkNode* node);
163 163
164 private: 164 private:
165 // BaseBookmarkModelObserver: 165 // BaseBookmarkModelObserver:
166 virtual void BookmarkModelChanged() override; 166 virtual void BookmarkModelChanged() override;
167 virtual void BookmarkModelLoaded(BookmarkModel* model, 167 virtual void BookmarkModelLoaded(BookmarkModel* model,
168 bool ids_reassigned) override; 168 bool ids_reassigned) override;
169
170 void RunAndSendResponse();
169 }; 171 };
170 172
171 class BookmarksGetFunction : public BookmarksFunction { 173 class BookmarksGetFunction : public BookmarksFunction {
172 public: 174 public:
173 DECLARE_EXTENSION_FUNCTION("bookmarks.get", BOOKMARKS_GET) 175 DECLARE_EXTENSION_FUNCTION("bookmarks.get", BOOKMARKS_GET)
174 176
175 protected: 177 protected:
176 virtual ~BookmarksGetFunction() {} 178 virtual ~BookmarksGetFunction() {}
177 179
178 // BookmarksFunction: 180 // BookmarksFunction:
(...skipping 175 matching lines...) Expand 10 before | Expand all | Expand 10 after
354 private: 356 private:
355 virtual ~BookmarksExportFunction() {} 357 virtual ~BookmarksExportFunction() {}
356 358
357 // BookmarksFunction: 359 // BookmarksFunction:
358 virtual bool RunOnReady() override; 360 virtual bool RunOnReady() override;
359 }; 361 };
360 362
361 } // namespace extensions 363 } // namespace extensions
362 364
363 #endif // CHROME_BROWSER_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_ 365 #endif // CHROME_BROWSER_EXTENSIONS_API_BOOKMARKS_BOOKMARKS_API_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698