| Index: chrome/browser/web_applications/web_app_mac.mm
|
| diff --git a/chrome/browser/web_applications/web_app_mac.mm b/chrome/browser/web_applications/web_app_mac.mm
|
| index 89f6e04d7328ac0dbebc23ab1681dbc558f2d0a9..225a0f5b3f259a623cfd95d2ec4e33ced817c577 100644
|
| --- a/chrome/browser/web_applications/web_app_mac.mm
|
| +++ b/chrome/browser/web_applications/web_app_mac.mm
|
| @@ -966,11 +966,34 @@ void WebAppShortcutCreator::RevealAppShimInFinder() const {
|
| if (app_path.empty())
|
| return;
|
|
|
| + if (!base::PathExists(app_path)) {
|
| + app_path = app_path.DirName();
|
| + }
|
| +
|
| [[NSWorkspace sharedWorkspace]
|
| selectFile:base::mac::FilePathToNSString(app_path)
|
| inFileViewerRootedAtPath:nil];
|
| }
|
|
|
| +void WebAppShortcutCreator::RevealAppShimInFinderForApp(
|
| + Profile* profile,
|
| + const extensions::Extension* app) {
|
| + const web_app::ShortcutInfo shortcut_info =
|
| + ShortcutInfoForExtensionAndProfile(app, profile);
|
| + content::BrowserThread::PostTask(
|
| + content::BrowserThread::FILE, FROM_HERE,
|
| + base::Bind(&RevealAppShimInFinderForAppOnFileThread, shortcut_info,
|
| + app->path()));
|
| +}
|
| +
|
| +void WebAppShortcutCreator::RevealAppShimInFinderForAppOnFileThread(
|
| + const ShortcutInfo& shortcut_info,
|
| + const base::FilePath& app_path) {
|
| + web_app::WebAppShortcutCreator shortcut_creator(
|
| + app_path, shortcut_info, extensions::FileHandlersInfo());
|
| + shortcut_creator.RevealAppShimInFinder();
|
| +}
|
| +
|
| base::FilePath GetAppInstallPath(const ShortcutInfo& shortcut_info) {
|
| WebAppShortcutCreator shortcut_creator(
|
| base::FilePath(), shortcut_info, extensions::FileHandlersInfo());
|
|
|