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

Side by Side Diff: chrome/browser/browser_about_handler.cc

Issue 10978015: Sort ChromePaths alphabetically for chrome://chrome-urls, etc. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 3 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | 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 (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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/browser_about_handler.h" 5 #include "chrome/browser/browser_about_handler.h"
6 6
7 #include <algorithm>
7 #include <string> 8 #include <string>
8 9
9 #include "base/command_line.h" 10 #include "base/command_line.h"
10 #include "base/logging.h" 11 #include "base/logging.h"
11 #include "base/memory/singleton.h" 12 #include "base/memory/singleton.h"
12 #include "base/string_util.h" 13 #include "base/string_util.h"
13 #include "chrome/browser/net/url_fixer_upper.h" 14 #include "chrome/browser/net/url_fixer_upper.h"
14 #include "chrome/browser/ui/browser_dialogs.h" 15 #include "chrome/browser/ui/browser_dialogs.h"
15 #include "chrome/common/chrome_switches.h" 16 #include "chrome/common/chrome_switches.h"
16 #include "chrome/common/url_constants.h" 17 #include "chrome/common/url_constants.h"
(...skipping 142 matching lines...) Expand 10 before | Expand all | Expand 10 after
159 #endif 160 #endif
160 161
161 #endif // OFFICIAL_BUILD 162 #endif // OFFICIAL_BUILD
162 163
163 return false; 164 return false;
164 } 165 }
165 166
166 std::vector<std::string> ChromePaths() { 167 std::vector<std::string> ChromePaths() {
167 std::vector<std::string> paths; 168 std::vector<std::string> paths;
168 paths.reserve(arraysize(kChromePaths)); 169 paths.reserve(arraysize(kChromePaths));
169 for (size_t i = 0; i < arraysize(kChromePaths); i++) 170 for (size_t i = 0; i < arraysize(kChromePaths); ++i)
170 paths.push_back(kChromePaths[i]); 171 paths.push_back(kChromePaths[i]);
Nico 2012/09/25 04:12:22 Can you initialize paths like this: std::vector
msw 2012/09/25 05:00:51 Done.
172 std::sort(paths.begin(), paths.end());
171 return paths; 173 return paths;
172 } 174 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698