From 455dcd1bb5fd197d69b002299dcc72e09609869d Mon Sep 17 00:00:00 2001 From: Luis Fung Date: Thu, 19 Dec 2013 21:13:41 -0500 Subject: [PATCH] Focus chrome window when launching Live Development --- appshell/appshell_extensions_mac.mm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/appshell/appshell_extensions_mac.mm b/appshell/appshell_extensions_mac.mm index fcc48df95..04d063ab6 100644 --- a/appshell/appshell_extensions_mac.mm +++ b/appshell/appshell_extensions_mac.mm @@ -263,7 +263,7 @@ int32 OpenLiveBrowser(ExtensionString argURL, bool enableRemoteDebugging) nil]; NSDictionary* appConfig = [NSDictionary dictionaryWithObject:parameters forKey:NSWorkspaceLaunchConfigurationArguments]; - NSUInteger launchOptions = NSWorkspaceLaunchDefault | NSWorkspaceLaunchWithoutActivation | NSWorkspaceLaunchNewInstance; + NSUInteger launchOptions = NSWorkspaceLaunchDefault | NSWorkspaceLaunchNewInstance; liveBrowser = [[NSWorkspace sharedWorkspace] launchApplicationAtURL:appURL options:launchOptions configuration:appConfig error:nil]; if (!liveBrowser) { @@ -276,6 +276,8 @@ int32 OpenLiveBrowser(ExtensionString argURL, bool enableRemoteDebugging) return NO_ERROR; } + [liveBrowser activateWithOptions:NSApplicationActivateIgnoringOtherApps]; + // Check for existing tab with url already loaded for (GoogleChromeWindow* chromeWindow in [chromeApp windows]) { for (GoogleChromeTab* tab in [chromeWindow tabs]) {