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

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

Issue 13864015: Move app launcher and chrome apps shortcut strings into the installer (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@migrate_app_id_fix
Patch Set: rework Created 7 years, 7 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) 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/shell_integration.h" 5 #include "chrome/browser/shell_integration.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 #include <shobjidl.h> 8 #include <shobjidl.h>
9 #include <propkey.h> 9 #include <propkey.h>
10 10
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 profile_id += basenames[i]; 76 profile_id += basenames[i];
77 } 77 }
78 78
79 return profile_id; 79 return profile_id;
80 } 80 }
81 81
82 string16 GetAppListAppName() { 82 string16 GetAppListAppName() {
83 BrowserDistribution* dist = BrowserDistribution::GetDistribution(); 83 BrowserDistribution* dist = BrowserDistribution::GetDistribution();
84 string16 app_name(dist->GetBaseAppId()); 84 string16 app_name(dist->GetBaseAppId());
85 app_name.append(kAppListAppNameSuffix); 85 app_name.append(kAppListAppNameSuffix);
86
gab 2013/04/29 21:34:44 nit: Remove extra empty line.
calamity 2013/04/30 08:11:28 Done.
86 return app_name; 87 return app_name;
87 } 88 }
88 89
89 // Gets expected app id for given Chrome (based on |command_line| and 90 // Gets expected app id for given Chrome (based on |command_line| and
90 // |is_per_user_install|). 91 // |is_per_user_install|).
91 string16 GetExpectedAppId(const CommandLine& command_line, 92 string16 GetExpectedAppId(const CommandLine& command_line,
92 bool is_per_user_install) { 93 bool is_per_user_install) {
93 base::FilePath user_data_dir; 94 base::FilePath user_data_dir;
94 if (command_line.HasSwitch(switches::kUserDataDir)) 95 if (command_line.HasSwitch(switches::kUserDataDir))
95 user_data_dir = command_line.GetSwitchValuePath(switches::kUserDataDir); 96 user_data_dir = command_line.GetSwitchValuePath(switches::kUserDataDir);
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after
525 } 526 }
526 527
527 shortcut = shortcut.Append(shortcut_name).Append(shortcut_name + 528 shortcut = shortcut.Append(shortcut_name).Append(shortcut_name +
528 installer::kLnkExt); 529 installer::kLnkExt);
529 if (file_util::PathExists(shortcut)) 530 if (file_util::PathExists(shortcut))
530 return shortcut; 531 return shortcut;
531 } 532 }
532 533
533 return base::FilePath(); 534 return base::FilePath();
534 } 535 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/shell_integration_win_unittest.cc » ('j') | chrome/browser/shell_integration_win_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698