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

Unified Diff: chrome/browser/app_controller_mac.mm

Issue 12623005: [mac] App shims (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: -> _mac Created 7 years, 9 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/app/chrome_main_app_mode_mac.mm ('k') | chrome/browser/browser_process_impl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/app_controller_mac.mm
diff --git a/chrome/browser/app_controller_mac.mm b/chrome/browser/app_controller_mac.mm
index 14135fb6e4fc6b216b34067bc65638626f3ffaa9..89a0240b22ad97b0c9e335ef0a827ba5dc27e017 100644
--- a/chrome/browser/app_controller_mac.mm
+++ b/chrome/browser/app_controller_mac.mm
@@ -184,8 +184,6 @@ void RecordLastRunAppBundlePath() {
- (void)getUrl:(NSAppleEventDescriptor*)event
withReply:(NSAppleEventDescriptor*)reply;
- (void)submitCloudPrintJob:(NSAppleEventDescriptor*)event;
-- (void)launchPlatformApp:(NSAppleEventDescriptor*)event
- withReply:(NSAppleEventDescriptor*)reply;
- (void)windowLayeringDidChange:(NSNotification*)inNotification;
- (void)windowChangedToProfile:(Profile*)profile;
- (void)checkForAnyKeyWindows;
@@ -217,11 +215,6 @@ void RecordLastRunAppBundlePath() {
forEventClass:'WWW!' // A particularly ancient AppleEvent that dates
andEventID:'OURL']; // back to the Spyglass days.
- [em setEventHandler:self
- andSelector:@selector(launchPlatformApp:withReply:)
- forEventClass:app_mode::kAEChromeAppClass
- andEventID:app_mode::kAEChromeAppLaunch];
-
// Register for various window layering changes. We use these to update
// various UI elements (command-key equivalents, etc) when the frontmost
// window changes.
@@ -1146,38 +1139,6 @@ void RecordLastRunAppBundlePath() {
[self openUrls:gurlVector];
}
-- (void)launchPlatformApp:(NSAppleEventDescriptor*)event
- withReply:(NSAppleEventDescriptor*)reply {
- NSString* appId =
- [[event paramDescriptorForKeyword:keyDirectObject] stringValue];
- NSString* profileDir =
- [[event paramDescriptorForKeyword:app_mode::kAEProfileDirKey]
- stringValue];
-
- ProfileManager* profileManager = g_browser_process->profile_manager();
- base::FilePath path = base::FilePath(base::SysNSStringToUTF8(profileDir));
- path = profileManager->user_data_dir().Append(path);
- Profile* profile = profileManager->GetProfile(path);
- if (!profile) {
- LOG(ERROR) << "Unable to locate a suitable profile for profile directory '"
- << profileDir << "' while trying to load app with id '"
- << appId << "'.";
- return;
- }
- ExtensionServiceInterface* extensionService =
- extensions::ExtensionSystem::Get(profile)->extension_service();
- const extensions::Extension* extension =
- extensionService->GetExtensionById(
- base::SysNSStringToUTF8(appId), false);
- if (!extension) {
- LOG(ERROR) << "Shortcut attempted to launch nonexistent app with id '"
- << base::SysNSStringToUTF8(appId) << "'.";
- return;
- }
- chrome::OpenApplication(chrome::AppLaunchParams(
- profile, extension, extension_misc::LAUNCH_NONE, NEW_WINDOW));
-}
-
// Apple Event handler that receives print event from service
// process, gets the required data and launches Print dialog.
- (void)submitCloudPrintJob:(NSAppleEventDescriptor*)event {
« no previous file with comments | « chrome/app/chrome_main_app_mode_mac.mm ('k') | chrome/browser/browser_process_impl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698