| Index: chrome/browser/ui/webui/bookmarks_ui.cc
|
| ===================================================================
|
| --- chrome/browser/ui/webui/bookmarks_ui.cc (revision 176443)
|
| +++ chrome/browser/ui/webui/bookmarks_ui.cc (working copy)
|
| @@ -19,17 +19,20 @@
|
| //
|
| ////////////////////////////////////////////////////////////////////////////////
|
|
|
| -BookmarksUIHTMLSource::BookmarksUIHTMLSource()
|
| - : DataSource(chrome::kChromeUIBookmarksHost, MessageLoop::current()) {
|
| +BookmarksUIHTMLSource::BookmarksUIHTMLSource() {
|
| }
|
|
|
| +std::string BookmarksUIHTMLSource::GetSource() {
|
| + return chrome::kChromeUIBookmarksHost;
|
| +}
|
| +
|
| void BookmarksUIHTMLSource::StartDataRequest(const std::string& path,
|
| bool is_incognito,
|
| int request_id) {
|
| NOTREACHED() << "We should never get here since the extension should have"
|
| << "been triggered";
|
|
|
| - SendResponse(request_id, NULL);
|
| + url_data_source()->SendResponse(request_id, NULL);
|
| }
|
|
|
| std::string BookmarksUIHTMLSource::GetMimeType(const std::string& path) const {
|
| @@ -47,11 +50,10 @@
|
| ////////////////////////////////////////////////////////////////////////////////
|
|
|
| BookmarksUI::BookmarksUI(content::WebUI* web_ui) : WebUIController(web_ui) {
|
| - BookmarksUIHTMLSource* html_source = new BookmarksUIHTMLSource();
|
| -
|
| // Set up the chrome://bookmarks/ source.
|
| - Profile* profile = Profile::FromWebUI(web_ui);
|
| - ChromeURLDataManager::AddDataSource(profile, html_source);
|
| + ChromeURLDataManager::AddDataSource(
|
| + Profile::FromWebUI(web_ui),
|
| + new BookmarksUIHTMLSource);
|
| }
|
|
|
| // static
|
|
|