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

Unified Diff: chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc

Issue 356383002: Remove flags. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Add author to AUTHORS Created 6 years, 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « AUTHORS ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc
diff --git a/chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc b/chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc
index 717add4f1f2563ea7d93acdae333abcef69d8ca4..d4a74f5aeacce849a6c7d1f3a8432c77e8e2e4a3 100644
--- a/chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc
+++ b/chrome/browser/ui/webui/ntp/suggestions_source_top_sites.cc
@@ -124,22 +124,11 @@ void SuggestionsSourceTopSites::OnSuggestionsUrlsAvailable(
// static
base::TimeDelta SuggestionsSourceTopSites::GetFilterWidth() {
- const CommandLine* cli = CommandLine::ForCurrentProcess();
- const std::string filter_width_switch =
- cli->GetSwitchValueASCII(switches::kSuggestionNtpFilterWidth);
- unsigned int filter_width;
- if (base::StringToUint(filter_width_switch, &filter_width))
- return base::TimeDelta::FromMinutes(filter_width);
return base::TimeDelta::FromHours(1);
}
// static
history::VisitFilter::SortingOrder
SuggestionsSourceTopSites::GetSortingOrder() {
- const CommandLine* cli = CommandLine::ForCurrentProcess();
- if (cli->HasSwitch(switches::kSuggestionNtpGaussianFilter))
- return history::VisitFilter::ORDER_BY_TIME_GAUSSIAN;
- if (cli->HasSwitch(switches::kSuggestionNtpLinearFilter))
- return history::VisitFilter::ORDER_BY_TIME_LINEAR;
return history::VisitFilter::ORDER_BY_RECENCY;
}
« no previous file with comments | « AUTHORS ('k') | chrome/common/chrome_switches.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698