| OLD | NEW |
| (Empty) | |
| 1 // Copyright (c) 2010 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_DOM_UI_BOOKMARKS_UI_H_ |
| 6 #define CHROME_BROWSER_DOM_UI_BOOKMARKS_UI_H_ |
| 7 |
| 8 #include <string> |
| 9 |
| 10 #include "chrome/browser/dom_ui/chrome_url_data_manager.h" |
| 11 #include "chrome/browser/dom_ui/dom_ui.h" |
| 12 |
| 13 class GURL; |
| 14 class RefCountedMemory; |
| 15 |
| 16 // This class provides the source for chrome://bookmarks/ |
| 17 class BookmarksUIHTMLSource : public ChromeURLDataManager::DataSource { |
| 18 public: |
| 19 BookmarksUIHTMLSource(); |
| 20 |
| 21 // Called when the network layer has requested a resource underneath |
| 22 // the path we registered. |
| 23 virtual void StartDataRequest(const std::string& path, |
| 24 bool is_off_the_record, |
| 25 int request_id); |
| 26 virtual std::string GetMimeType(const std::string&) const { |
| 27 return "text/html"; |
| 28 } |
| 29 |
| 30 private: |
| 31 DISALLOW_COPY_AND_ASSIGN(BookmarksUIHTMLSource); |
| 32 }; |
| 33 |
| 34 // This class is used to hook up chrome://bookmarks/ which in turn gets |
| 35 // overridden by an extension. |
| 36 class BookmarksUI : public DOMUI { |
| 37 public: |
| 38 explicit BookmarksUI(TabContents* contents); |
| 39 |
| 40 static RefCountedMemory* GetFaviconResourceBytes(); |
| 41 |
| 42 private: |
| 43 DISALLOW_COPY_AND_ASSIGN(BookmarksUI); |
| 44 }; |
| 45 |
| 46 #endif // CHROME_BROWSER_DOM_UI_BOOKMARKS_UI_H_ |
| OLD | NEW |