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

Unified Diff: chrome/installer/util/shell_util.cc

Issue 14021010: Add file association for .webp to Chrome. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 8 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 | « chrome/installer/util/shell_util.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/installer/util/shell_util.cc
diff --git a/chrome/installer/util/shell_util.cc b/chrome/installer/util/shell_util.cc
index 4a60171174d5526e3b21bab49799e9406b19f4c5..c75b1087be5f35bfee2c064cf088c9d011611e9a 100644
--- a/chrome/installer/util/shell_util.cc
+++ b/chrome/installer/util/shell_util.cc
@@ -399,10 +399,10 @@ class RegistryEntry {
L"StartMenuInternet", reg_app_name));
const string16 html_prog_id(GetBrowserProgId(suffix));
- for (int i = 0; ShellUtil::kFileAssociations[i] != NULL; i++) {
+ for (int i = 0; ShellUtil::kPotentialFileAssociations[i] != NULL; i++) {
entries->push_back(new RegistryEntry(
capabilities + L"\\FileAssociations",
- ShellUtil::kFileAssociations[i], html_prog_id));
+ ShellUtil::kPotentialFileAssociations[i], html_prog_id));
}
for (int i = 0; ShellUtil::kPotentialProtocolAssociations[i] != NULL;
i++) {
@@ -432,10 +432,10 @@ class RegistryEntry {
ShellUtil::kAppPathsRegistryPathName, chrome_path.DirName().value()));
const string16 html_prog_id(GetBrowserProgId(suffix));
- for (int i = 0; ShellUtil::kFileAssociations[i] != NULL; i++) {
+ for (int i = 0; ShellUtil::kPotentialFileAssociations[i] != NULL; i++) {
string16 key(ShellUtil::kRegClasses);
key.push_back(base::FilePath::kSeparators[0]);
- key.append(ShellUtil::kFileAssociations[i]);
+ key.append(ShellUtil::kPotentialFileAssociations[i]);
key.push_back(base::FilePath::kSeparators[0]);
key.append(ShellUtil::kRegOpenWithProgids);
entries->push_back(new RegistryEntry(key, html_prog_id, string16()));
@@ -1222,6 +1222,8 @@ const wchar_t* ShellUtil::kChromeHTMLProgIdDesc = L"Chromium HTML Document";
const wchar_t* ShellUtil::kFileAssociations[] = {L".htm", L".html", L".shtml",
gab 2013/04/29 21:15:04 nit: Please rename this to kDefaultFileAssociation
Stephen 2013/04/30 04:08:37 Done.
L".xht", L".xhtml", NULL};
+const wchar_t* ShellUtil::kPotentialFileAssociations[] = {L".htm", L".html",
+ L".shtml", L".xht", L".xhtml", L".webp", NULL};
const wchar_t* ShellUtil::kBrowserProtocolAssociations[] = {L"ftp", L"http",
L"https", NULL};
const wchar_t* ShellUtil::kPotentialProtocolAssociations[] = {L"ftp", L"http",
« no previous file with comments | « chrome/installer/util/shell_util.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698