| OLD | NEW |
| 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 #import "chrome/browser/web_applications/web_app_mac.h" | 5 #import "chrome/browser/web_applications/web_app_mac.h" |
| 6 | 6 |
| 7 #import <Carbon/Carbon.h> | 7 #import <Carbon/Carbon.h> |
| 8 #import <Cocoa/Cocoa.h> | 8 #import <Cocoa/Cocoa.h> |
| 9 | 9 |
| 10 #include "base/command_line.h" | 10 #include "base/command_line.h" |
| (...skipping 301 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 312 | 312 |
| 313 web_app::GetInfoForApp(extension, profile, base::Bind(&UpdateAndLaunchShim)); | 313 web_app::GetInfoForApp(extension, profile, base::Bind(&UpdateAndLaunchShim)); |
| 314 } | 314 } |
| 315 | 315 |
| 316 base::FilePath GetLocalizableAppShortcutsSubdirName() { | 316 base::FilePath GetLocalizableAppShortcutsSubdirName() { |
| 317 static const char kChromiumAppDirName[] = "Chromium Apps.localized"; | 317 static const char kChromiumAppDirName[] = "Chromium Apps.localized"; |
| 318 static const char kChromeAppDirName[] = "Chrome Apps.localized"; | 318 static const char kChromeAppDirName[] = "Chrome Apps.localized"; |
| 319 static const char kChromeCanaryAppDirName[] = "Chrome Canary Apps.localized"; | 319 static const char kChromeCanaryAppDirName[] = "Chrome Canary Apps.localized"; |
| 320 | 320 |
| 321 switch (chrome::VersionInfo::GetChannel()) { | 321 switch (chrome::VersionInfo::GetChannel()) { |
| 322 case chrome::VersionInfo::CHANNEL_UNKNOWN: | 322 case version_info::Channel::UNKNOWN: |
| 323 return base::FilePath(kChromiumAppDirName); | 323 return base::FilePath(kChromiumAppDirName); |
| 324 | 324 |
| 325 case chrome::VersionInfo::CHANNEL_CANARY: | 325 case version_info::Channel::CANARY: |
| 326 return base::FilePath(kChromeCanaryAppDirName); | 326 return base::FilePath(kChromeCanaryAppDirName); |
| 327 | 327 |
| 328 default: | 328 default: |
| 329 return base::FilePath(kChromeAppDirName); | 329 return base::FilePath(kChromeAppDirName); |
| 330 } | 330 } |
| 331 } | 331 } |
| 332 | 332 |
| 333 // Creates a canvas the same size as |overlay|, copies the appropriate | 333 // Creates a canvas the same size as |overlay|, copies the appropriate |
| 334 // representation from |backgound| into it (according to Cocoa), then draws | 334 // representation from |backgound| into it (according to Cocoa), then draws |
| 335 // |overlay| over it using NSCompositeSourceOver. | 335 // |overlay| over it using NSCompositeSourceOver. |
| (...skipping 885 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1221 web_app::GetShortcutInfoForApp( | 1221 web_app::GetShortcutInfoForApp( |
| 1222 app, | 1222 app, |
| 1223 profile, | 1223 profile, |
| 1224 base::Bind(&web_app::CreateAppShortcutInfoLoaded, | 1224 base::Bind(&web_app::CreateAppShortcutInfoLoaded, |
| 1225 profile, | 1225 profile, |
| 1226 app, | 1226 app, |
| 1227 close_callback)); | 1227 close_callback)); |
| 1228 } | 1228 } |
| 1229 | 1229 |
| 1230 } // namespace chrome | 1230 } // namespace chrome |
| OLD | NEW |