Index: apps/app_shim/extension_app_shim_handler_mac.cc |
diff --git a/apps/app_shim/extension_app_shim_handler_mac.cc b/apps/app_shim/extension_app_shim_handler_mac.cc |
index cef6ca2d3a6c4fdf1c312c177df502224b92aefc..9299aaff86408f13a56a23907ca6b3be4fa4142b 100644 |
--- a/apps/app_shim/extension_app_shim_handler_mac.cc |
+++ b/apps/app_shim/extension_app_shim_handler_mac.cc |
@@ -267,7 +267,7 @@ void ExtensionAppShimHandler::FocusAppForWindow(AppWindow* app_window) { |
} |
// static |
-bool ExtensionAppShimHandler::RequestUserAttentionForWindow( |
+bool ExtensionAppShimHandler::ActivateAndRequestUserAttentionForWindow( |
AppWindow* app_window) { |
ExtensionAppShimHandler* handler = GetInstance(); |
Profile* profile = Profile::FromBrowserContext(app_window->browser_context()); |
@@ -275,7 +275,7 @@ bool ExtensionAppShimHandler::RequestUserAttentionForWindow( |
if (host) { |
// Bring the window to the front without showing it. |
AppWindowRegistry::Get(profile)->AppWindowActivated(app_window); |
- host->OnAppRequestUserAttention(); |
+ host->OnAppRequestUserAttention(APP_SHIM_ATTENTION_INFORMATIONAL); |
return true; |
} else { |
// Just show the app. |
@@ -285,6 +285,18 @@ bool ExtensionAppShimHandler::RequestUserAttentionForWindow( |
} |
// static |
+bool ExtensionAppShimHandler::RequestUserAttentionForWindow( |
+ AppWindow* app_window, |
+ AppShimAttentionType attention_type) { |
+ ExtensionAppShimHandler* handler = GetInstance(); |
+ Profile* profile = Profile::FromBrowserContext(app_window->browser_context()); |
+ Host* host = handler->FindHost(profile, app_window->extension_id()); |
+ if (host) |
+ host->OnAppRequestUserAttention(attention_type); |
+ return host; |
+} |
+ |
+// static |
void ExtensionAppShimHandler::OnChromeWillHide() { |
// Send OnAppHide to all the shims so that they go into the hidden state. |
// This is necessary so that when the shim is next focused, it will know to |