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

Side by Side Diff: chrome/browser/ui/webui/md_history_ui.cc

Issue 1717213003: [MD History] Extract shared stylesheet. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: fix nits Created 4 years, 10 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
« no previous file with comments | « chrome/browser/resources/md_history/shared_style.html ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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_history_ui.h" 5 #include "chrome/browser/ui/webui/md_history_ui.h"
6 6
7 #include "build/build_config.h" 7 #include "build/build_config.h"
8 #include "chrome/browser/profiles/profile.h" 8 #include "chrome/browser/profiles/profile.h"
9 #include "chrome/browser/ui/webui/browsing_history_handler.h" 9 #include "chrome/browser/ui/webui/browsing_history_handler.h"
10 #include "chrome/browser/ui/webui/metrics_handler.h" 10 #include "chrome/browser/ui/webui/metrics_handler.h"
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 IDR_MD_HISTORY_HISTORY_ITEM_HTML); 53 IDR_MD_HISTORY_HISTORY_ITEM_HTML);
54 source->AddResourcePath("history_item.js", IDR_MD_HISTORY_HISTORY_ITEM_JS); 54 source->AddResourcePath("history_item.js", IDR_MD_HISTORY_HISTORY_ITEM_JS);
55 source->AddResourcePath("history_list.html", 55 source->AddResourcePath("history_list.html",
56 IDR_MD_HISTORY_HISTORY_LIST_HTML); 56 IDR_MD_HISTORY_HISTORY_LIST_HTML);
57 source->AddResourcePath("history_list.js", IDR_MD_HISTORY_HISTORY_LIST_JS); 57 source->AddResourcePath("history_list.js", IDR_MD_HISTORY_HISTORY_LIST_JS);
58 source->AddResourcePath("history_toolbar.html", 58 source->AddResourcePath("history_toolbar.html",
59 IDR_MD_HISTORY_HISTORY_TOOLBAR_HTML); 59 IDR_MD_HISTORY_HISTORY_TOOLBAR_HTML);
60 source->AddResourcePath("history_toolbar.js", 60 source->AddResourcePath("history_toolbar.js",
61 IDR_MD_HISTORY_HISTORY_TOOLBAR_JS); 61 IDR_MD_HISTORY_HISTORY_TOOLBAR_JS);
62 source->AddResourcePath("history.js", IDR_MD_HISTORY_HISTORY_JS); 62 source->AddResourcePath("history.js", IDR_MD_HISTORY_HISTORY_JS);
63 source->AddResourcePath("shared_style.html",
64 IDR_MD_HISTORY_SHARED_STYLE_HTML);
63 65
64 source->SetDefaultResource(IDR_MD_HISTORY_HISTORY_HTML); 66 source->SetDefaultResource(IDR_MD_HISTORY_HISTORY_HTML);
65 source->SetJsonPath("strings.js"); 67 source->SetJsonPath("strings.js");
66 68
67 return source; 69 return source;
68 } 70 }
69 71
70 } // namespace 72 } // namespace
71 73
72 MdHistoryUI::MdHistoryUI(content::WebUI* web_ui) : WebUIController(web_ui) { 74 MdHistoryUI::MdHistoryUI(content::WebUI* web_ui) : WebUIController(web_ui) {
(...skipping 12 matching lines...) Expand all
85 content::WebUIDataSource::Add(profile, CreateMdHistoryUIHTMLSource(profile)); 87 content::WebUIDataSource::Add(profile, CreateMdHistoryUIHTMLSource(profile));
86 } 88 }
87 89
88 MdHistoryUI::~MdHistoryUI() {} 90 MdHistoryUI::~MdHistoryUI() {}
89 91
90 base::RefCountedMemory* MdHistoryUI::GetFaviconResourceBytes( 92 base::RefCountedMemory* MdHistoryUI::GetFaviconResourceBytes(
91 ui::ScaleFactor scale_factor) { 93 ui::ScaleFactor scale_factor) {
92 return ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale( 94 return ResourceBundle::GetSharedInstance().LoadDataResourceBytesForScale(
93 IDR_HISTORY_FAVICON, scale_factor); 95 IDR_HISTORY_FAVICON, scale_factor);
94 } 96 }
OLDNEW
« no previous file with comments | « chrome/browser/resources/md_history/shared_style.html ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698