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

Side by Side Diff: chrome/browser/ui/webui/md_bookmarks/md_bookmarks_ui.cc

Issue 2926763005: [MD Bookmarks] Refactor window timer mocking. (Closed)
Patch Set: Created 3 years, 6 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) 2016 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2016 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 #include "chrome/browser/ui/webui/md_bookmarks/md_bookmarks_ui.h" 5 #include "chrome/browser/ui/webui/md_bookmarks/md_bookmarks_ui.h"
6 6
7 #include <algorithm> 7 #include <algorithm>
8 #include <string> 8 #include <string>
9 9
10 #include "base/strings/string16.h" 10 #include "base/strings/string16.h"
(...skipping 126 matching lines...) Expand 10 before | Expand all | Expand 10 after
137 IDR_MD_BOOKMARKS_SHARED_VARS_HTML); 137 IDR_MD_BOOKMARKS_SHARED_VARS_HTML);
138 source->AddResourcePath("store.html", IDR_MD_BOOKMARKS_STORE_HTML); 138 source->AddResourcePath("store.html", IDR_MD_BOOKMARKS_STORE_HTML);
139 source->AddResourcePath("store.js", IDR_MD_BOOKMARKS_STORE_JS); 139 source->AddResourcePath("store.js", IDR_MD_BOOKMARKS_STORE_JS);
140 source->AddResourcePath("store_client.html", 140 source->AddResourcePath("store_client.html",
141 IDR_MD_BOOKMARKS_STORE_CLIENT_HTML); 141 IDR_MD_BOOKMARKS_STORE_CLIENT_HTML);
142 source->AddResourcePath("store_client.js", IDR_MD_BOOKMARKS_STORE_CLIENT_JS); 142 source->AddResourcePath("store_client.js", IDR_MD_BOOKMARKS_STORE_CLIENT_JS);
143 source->AddResourcePath("toast_manager.html", 143 source->AddResourcePath("toast_manager.html",
144 IDR_MD_BOOKMARKS_TOAST_MANAGER_HTML); 144 IDR_MD_BOOKMARKS_TOAST_MANAGER_HTML);
145 source->AddResourcePath("toast_manager.js", 145 source->AddResourcePath("toast_manager.js",
146 IDR_MD_BOOKMARKS_TOAST_MANAGER_JS); 146 IDR_MD_BOOKMARKS_TOAST_MANAGER_JS);
147 source->AddResourcePath("timer_proxy.html",
tsergeant 2017/06/13 06:48:43 As above, move this up
calamity 2017/06/16 02:59:26 Done.
148 IDR_MD_BOOKMARKS_TIMER_PROXY_HTML);
149 source->AddResourcePath("timer_proxy.js", IDR_MD_BOOKMARKS_TIMER_PROXY_JS);
147 source->AddResourcePath("toolbar.html", IDR_MD_BOOKMARKS_TOOLBAR_HTML); 150 source->AddResourcePath("toolbar.html", IDR_MD_BOOKMARKS_TOOLBAR_HTML);
148 source->AddResourcePath("toolbar.js", IDR_MD_BOOKMARKS_TOOLBAR_JS); 151 source->AddResourcePath("toolbar.js", IDR_MD_BOOKMARKS_TOOLBAR_JS);
149 source->AddResourcePath("util.html", IDR_MD_BOOKMARKS_UTIL_HTML); 152 source->AddResourcePath("util.html", IDR_MD_BOOKMARKS_UTIL_HTML);
150 source->AddResourcePath("util.js", IDR_MD_BOOKMARKS_UTIL_JS); 153 source->AddResourcePath("util.js", IDR_MD_BOOKMARKS_UTIL_JS);
151 154
152 source->SetDefaultResource(IDR_MD_BOOKMARKS_BOOKMARKS_HTML); 155 source->SetDefaultResource(IDR_MD_BOOKMARKS_BOOKMARKS_HTML);
153 #endif 156 #endif
154 157
155 source->SetJsonPath("strings.js"); 158 source->SetJsonPath("strings.js");
156 159
(...skipping 13 matching lines...) Expand all
170 "toastItemsDeleted", IDS_MD_BOOKMARK_MANAGER_TOAST_ITEMS_DELETED); 173 "toastItemsDeleted", IDS_MD_BOOKMARK_MANAGER_TOAST_ITEMS_DELETED);
171 web_ui->AddMessageHandler(std::move(plural_string_handler)); 174 web_ui->AddMessageHandler(std::move(plural_string_handler));
172 175
173 web_ui->AddMessageHandler(base::MakeUnique<BookmarksMessageHandler>()); 176 web_ui->AddMessageHandler(base::MakeUnique<BookmarksMessageHandler>());
174 } 177 }
175 178
176 // static 179 // static
177 bool MdBookmarksUI::IsEnabled() { 180 bool MdBookmarksUI::IsEnabled() {
178 return base::FeatureList::IsEnabled(features::kMaterialDesignBookmarks); 181 return base::FeatureList::IsEnabled(features::kMaterialDesignBookmarks);
179 } 182 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698