Index: chrome/browser/extensions/api/app_current_window_internal/app_current_window_internal_api.cc |
diff --git a/chrome/browser/extensions/api/app_current_window_internal/app_current_window_internal_api.cc b/chrome/browser/extensions/api/app_current_window_internal/app_current_window_internal_api.cc |
index 28ffe4e39261170bc1f1d533c1412d5c91451e1b..18554f7cba492090c8b714d9b1eeedcdecc52d5c 100644 |
--- a/chrome/browser/extensions/api/app_current_window_internal/app_current_window_internal_api.cc |
+++ b/chrome/browser/extensions/api/app_current_window_internal/app_current_window_internal_api.cc |
@@ -27,6 +27,8 @@ namespace SetIcon = app_current_window_internal::SetIcon; |
namespace SetBadgeIcon = app_current_window_internal::SetBadgeIcon; |
namespace SetShape = app_current_window_internal::SetShape; |
namespace SetAlwaysOnTop = app_current_window_internal::SetAlwaysOnTop; |
+namespace SetVisibleOnAllWorkspaces = |
+ app_current_window_internal::SetVisibleOnAllWorkspaces; |
using app_current_window_internal::Bounds; |
using app_current_window_internal::Region; |
@@ -397,4 +399,18 @@ bool AppCurrentWindowInternalSetAlwaysOnTopFunction::RunWithWindow( |
return true; |
} |
+bool AppCurrentWindowInternalSetVisibleOnAllWorkspacesFunction::RunWithWindow( |
+ AppWindow* window) { |
+ if (GetCurrentChannel() > chrome::VersionInfo::CHANNEL_DEV) { |
+ error_ = kDevChannelOnly; |
+ return false; |
+ } |
+ |
+ scoped_ptr<SetVisibleOnAllWorkspaces::Params> params( |
+ SetVisibleOnAllWorkspaces::Params::Create(*args_)); |
+ CHECK(params.get()); |
+ window->GetBaseWindow()->SetVisibleOnAllWorkspaces(params->always_visible); |
+ return true; |
+} |
+ |
} // namespace extensions |