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

Side by Side Diff: chrome/browser/ui/views/apps/chrome_native_app_window_views.cc

Issue 550413002: Revert "Add AppWindow.setVisibleOnAllWorkspaces." (https://codereview.chromium.org/469993003) (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 3 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 unified diff | Download patch
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 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 #include "chrome/browser/ui/views/apps/chrome_native_app_window_views.h" 5 #include "chrome/browser/ui/views/apps/chrome_native_app_window_views.h"
6 6
7 #include "apps/ui/views/app_window_frame_view.h" 7 #include "apps/ui/views/app_window_frame_view.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "chrome/app/chrome_command_ids.h" 9 #include "chrome/app/chrome_command_ids.h"
10 #include "chrome/browser/app_mode/app_mode_utils.h" 10 #include "chrome/browser/app_mode/app_mode_utils.h"
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 std::string app_name = web_app::GenerateApplicationNameFromExtensionId( 208 std::string app_name = web_app::GenerateApplicationNameFromExtensionId(
209 app_window()->extension_id()); 209 app_window()->extension_id());
210 210
211 views::Widget::InitParams init_params(views::Widget::InitParams::TYPE_WINDOW); 211 views::Widget::InitParams init_params(views::Widget::InitParams::TYPE_WINDOW);
212 init_params.delegate = this; 212 init_params.delegate = this;
213 init_params.remove_standard_frame = IsFrameless() || has_frame_color_; 213 init_params.remove_standard_frame = IsFrameless() || has_frame_color_;
214 init_params.use_system_default_icon = true; 214 init_params.use_system_default_icon = true;
215 if (create_params.alpha_enabled) 215 if (create_params.alpha_enabled)
216 init_params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW; 216 init_params.opacity = views::Widget::InitParams::TRANSLUCENT_WINDOW;
217 init_params.keep_on_top = create_params.always_on_top; 217 init_params.keep_on_top = create_params.always_on_top;
218 init_params.visible_on_all_workspaces =
219 create_params.visible_on_all_workspaces;
220 218
221 #if defined(OS_LINUX) && !defined(OS_CHROMEOS) 219 #if defined(OS_LINUX) && !defined(OS_CHROMEOS)
222 // Set up a custom WM_CLASS for app windows. This allows task switchers in 220 // Set up a custom WM_CLASS for app windows. This allows task switchers in
223 // X11 environments to distinguish them from main browser windows. 221 // X11 environments to distinguish them from main browser windows.
224 init_params.wm_class_name = web_app::GetWMClassFromAppName(app_name); 222 init_params.wm_class_name = web_app::GetWMClassFromAppName(app_name);
225 init_params.wm_class_class = shell_integration_linux::GetProgramClassName(); 223 init_params.wm_class_class = shell_integration_linux::GetProgramClassName();
226 const char kX11WindowRoleApp[] = "app"; 224 const char kX11WindowRoleApp[] = "app";
227 init_params.wm_role_name = std::string(kX11WindowRoleApp); 225 init_params.wm_role_name = std::string(kX11WindowRoleApp);
228 #endif 226 #endif
229 227
(...skipping 440 matching lines...) Expand 10 before | Expand all | Expand 10 after
670 InitializePanelWindow(create_params); 668 InitializePanelWindow(create_params);
671 } else { 669 } else {
672 InitializeDefaultWindow(create_params); 670 InitializeDefaultWindow(create_params);
673 } 671 }
674 extension_keybinding_registry_.reset(new ExtensionKeybindingRegistryViews( 672 extension_keybinding_registry_.reset(new ExtensionKeybindingRegistryViews(
675 Profile::FromBrowserContext(app_window->browser_context()), 673 Profile::FromBrowserContext(app_window->browser_context()),
676 widget()->GetFocusManager(), 674 widget()->GetFocusManager(),
677 extensions::ExtensionKeybindingRegistry::PLATFORM_APPS_ONLY, 675 extensions::ExtensionKeybindingRegistry::PLATFORM_APPS_ONLY,
678 NULL)); 676 NULL));
679 } 677 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/cocoa/apps/native_app_window_cocoa.mm ('k') | chrome/common/extensions/api/_api_features.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698