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

Unified Diff: chrome/browser/ui/views/task_manager_view.cc

Issue 2381183002: mash: Fix shelf window property use in Chrome. (Closed)
Patch Set: Address comments. Created 4 years, 2 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/browser/ui/ash/property_util.cc ('k') | services/ui/public/interfaces/window_manager.mojom » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/views/task_manager_view.cc
diff --git a/chrome/browser/ui/views/task_manager_view.cc b/chrome/browser/ui/views/task_manager_view.cc
index ba09251951a93c765242979e80dc937a3c4bf8f6..f1ab1fb939c521da90cce64c4fa08ac6750e6794 100644
--- a/chrome/browser/ui/views/task_manager_view.cc
+++ b/chrome/browser/ui/views/task_manager_view.cc
@@ -34,12 +34,12 @@
#include "ui/views/window/dialog_client_view.h"
#if defined(USE_ASH)
-#include "ash/common/shelf/shelf_item_types.h" // nogncheck
-#include "ash/common/wm_lookup.h" // nogncheck
-#include "ash/common/wm_window.h" // nogncheck
-#include "ash/common/wm_window_property.h" // nogncheck
-#include "ash/resources/grit/ash_resources.h" // nogncheck
-#include "ash/wm/window_util.h" // nogncheck
+// Note: gn check complains here, despite the correct conditional //ash dep.
+#include "ash/common/shelf/shelf_item_types.h" // nogncheck
+#include "ash/resources/grit/ash_resources.h" // nogncheck
+#include "ash/wm/window_properties.h" // nogncheck
+#include "ash/wm/window_util.h" // nogncheck
+#include "chrome/browser/ui/ash/property_util.h" // nogncheck
#endif // defined(USE_ASH)
#if defined(OS_WIN)
@@ -103,12 +103,12 @@ task_manager::TaskManagerTableModel* TaskManagerView::Show(Browser* browser) {
focus_manager->SetFocusedView(g_task_manager_view->tab_table_);
#if defined(USE_ASH)
- ash::WmWindow* wm_window = ash::WmLookup::Get()->GetWindowForWidget(
- g_task_manager_view->GetWidget());
- wm_window->SetIntProperty(ash::WmWindowProperty::SHELF_ITEM_TYPE,
- ash::TYPE_DIALOG);
- wm_window->SetIntProperty(ash::WmWindowProperty::SHELF_ICON_RESOURCE_ID,
- IDR_ASH_SHELF_ICON_TASK_MANAGER);
+ aura::Window* aura_window =
+ g_task_manager_view->GetWidget()->GetNativeWindow();
+ property_util::SetIntProperty(aura_window, ash::kShelfItemTypeKey,
+ ash::TYPE_DIALOG);
+ property_util::SetIntProperty(aura_window, ash::kShelfIconResourceIdKey,
+ IDR_ASH_SHELF_ICON_TASK_MANAGER);
#endif
return g_task_manager_view->table_model_.get();
}
« no previous file with comments | « chrome/browser/ui/ash/property_util.cc ('k') | services/ui/public/interfaces/window_manager.mojom » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698